Skip to content

fix(search): filters follow the active index for the assistant, Reviews only uses the review type, and the phone tab switch sticks - #1731

Merged
sickerine merged 4 commits into
devfrom
fix/index-aware-filters
Dec 4, 2026
Merged

sickerine merged 4 commits into
devfrom
fix/index-aware-filters

Conversation

@sickerine

Copy link
Copy Markdown
Collaborator

The assistant is offered only the filters the active index serves. UNSERVED_FILTERS (lib/search/source.ts) already drove the sidebar and the works request; each entry now names its setting too. Each reply's tools are built for the active index (servedBy in convex/assistant/tools.ts): a setting it can't serve, study design on our index today, is left out of their arguments, including the update tool's list of settings, and out of their descriptions. A call that sends it anyway is refused with a plain reason (unservedIn). Before, the search dropped it and the assistant reported success. The filter chips now hide it, as the sidebar does.

Reviews only keeps the papers the index types as reviews. It used to add (review OR synthesis OR "meta-analysis") to the query. Measured on our index for "school feeding": that kept 132,564 papers, 110,811 of them typed as articles, and missed 368 typed reviews. The review type keeps 10,848. Both indexes serve the type, so it also works on a search by meaning now. A publication type picked beside it gives way to it. Saved community sources keep the query they were approved with until someone edits them.

On a phone, the Search/Filters switch sticks under the top bar on every page. On the home page the content is short, so a swipe scrolls the page itself, and the switch slid under the sticky top bars and behind the home page's sign-in card (z-20). It now sticks under them, and a tab's content is its own stacking layer. Checked in Safari on an iPhone 17 simulator: swiping, and opening and closing the keyboard.

Checks: npx tsc --noEmit, npm run check:ui-rules, vitest on the assistant tools (two new tests for the active index's filters), the community source query, bucket filters, the library page and request limits (83 passed).

A separate PR brings the same commits to prod.

It used to add (review OR synthesis OR "meta-analysis") to the query, so on
"school feeding" 84% of what it kept were ordinary articles that mention
the word (110,811 of 132,564), and it missed 368 typed reviews. Both
indexes serve OpenAlex's review type. It now works on a search by meaning
too. Saved community sources keep the query they were approved with.
…index serves

UNSERVED_FILTERS names each unserved filter's setting too. Each reply's
tools are built for the active index: a setting it can't serve (study
design on our index) is left out of their arguments and descriptions, and
a call that asks for it anyway is refused with why, instead of the search
dropping it while the assistant reports success. The filter chips hide it
as the sidebar does.
…he top bar on every page

On the home page a swipe scrolls the page itself (its content is short), and
the switch slid under the sticky top bars, behind the sign-in card. It now
sticks under them, and a tab's content is its own layer, so nothing in it
draws over the switch. Checked in Safari on an iPhone simulator, before and
after the keyboard.
@coderabbitai

coderabbitai Bot commented Dec 4, 2026 •

Copy link
Copy Markdown

Important

  • Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: a399edbc-4e7d-4a7f-bbaf-af6abf585e9a
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Dec 4, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-12-04T04:47:03.923378Z f196958 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: f196958356

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread convex/assistant/tools.ts Resolved
… be taken off on our index

The update tool keeps the setting's name, and a change to null or nothing
isn't refused: only asking for an unserved filter is.
@sickerine
sickerine merged commit 4618ad0 into dev Dec 4, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant