Repository navigation
Filter the board by classified place and by company - #1476
Merged
Merged
Conversation
The board's location filter was a substring match on the raw text, though every location is classified into country, region and city. Column filters gain any_of and none_of over a JSON list, and a place field that matches locations.places by containment, so a country takes its regions and cities. The list's facets count places and companies under every other condition.
kensac
force-pushed
the
board-place-company-filters
branch
from
November 18, 2026 19:31
5d1bf7e to
766ef84
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The board's only location filter was a substring match on the raw location text ("Location text contains ..."), even though 99.8% of the board's postings (2,332 of 2,348 on 2026-11-18) have every location classified into country, region and city in
locations.What changes
any_ofandnone_of(a JSON array invalue): OR within a condition, AND across conditions,none_ofas the exclusion. Text fields compare case-insensitively and whole;companystays onlower(btrim(company)), whichidx_jobs_company_keyserves.placefield. A pick isremoteorCOUNTRY[/REGION[/CITY]]. It matches through the same join as the board criteria (locations.text = btrim(loc)) and jsonb containment onlocations.places, soUStakes every region and city in the US. A location not yet classified matches no pick.with_facets=truenow also returnsfacets.placeandfacets.company, counted under every other condition except the field's own, so a selected pick never hides its siblings.docs/agents/frontend.mdstates the contract.Measured against production (user 1, read-only)
US/CAorremote: 1,099 rows, 0.29 s.US/NY/New York: 274 rows, matching its facet count. NotUS: 57 rows.Skipped: role family, career stage and requirement filters.
job_profilescovers 20% of the board andjob_requirements10%, so a filter on them would hide most postings for lack of data rather than for not matching. Terms are empty on every board row.Tests
tests/test_board_column_filters.py: country, region, city and remote picks; exclusion; AND across place and company; facets not narrowed by their own field; malformed lists refused with 422. Related suites (board, catalog, openapi): 82 passed.