Skip to content

feat: tiered show/snippet lookup fast paths#184

Merged
SutuSebastian merged 7 commits into
mainfrom
feat/tiered-lookup-fast-paths
Jun 11, 2026
Merged

feat: tiered show/snippet lookup fast paths#184
SutuSebastian merged 7 commits into
mainfrom
feat/tiered-lookup-fast-paths

Conversation

@SutuSebastian

Copy link
Copy Markdown
Contributor

Summary

  • Add fast-tier equality lookup for show / snippet when the query is an exact symbol name (positional name, optional kind/in, or lone name:Token without wildcards) via new covering index idx_symbols_name_covering.
  • Route substring LIKE, multi-field, and FTS queries on the unchanged slow tier; behavior-preserving — same result rows, faster SQL for the common exact-name case.
  • Retire docs/plans/tiered-lookup-fast-paths.md and lift tier guidance to architecture, roadmap, glossary, CLI/MCP help, agent-content, and find-symbol-definitions recipe.

Test plan

  • bun test src/application/show-search-mode.test.ts
  • bun test src/application/show-engine.test.ts (EXPLAIN asserts USING COVERING INDEX)
  • bun test src/db.test.ts
  • bun run typecheck / lint / format:check on touched files
  • CI green

Route lone name:Token queries to equality lookup; add
idx_symbols_name_covering; document fast vs slow tiers in CLI/MCP help.
Fix roadmap anchor, glossary/show recipe cross-refs, mcp-instructions
tiers, and consumer-clean changeset wording.
Mirror show lookup-tier docs on snippet --help; extend served rule and
MCP instructions fast-tier row for show/snippet parity.
Document optional kind/in on fast-tier show/snippet across MCP, rule, and
skill; align snippet CLI help and changeset; assert COVERING INDEX use.
@changeset-bot

changeset-bot Bot commented Jun 11, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: b97193a

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@stainless-code/codemap Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@coderabbitai

coderabbitai Bot commented Jun 11, 2026

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

@SutuSebastian, we couldn't start this review because you've reached your PR review rate limit.

More reviews will be available in 53 minutes and 57 seconds. Learn how PR review limits work.

Your organization has run out of usage credits. Purchase more credits in the billing tab to continue.

⌛ How to resolve this issue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available.

Please see our Fair Usage Limits Policy for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 25306b5f-b80e-4e43-a879-f8daee554e98

📥 Commits

Reviewing files that changed from the base of the PR and between b509e4c and b97193a.

📒 Files selected for processing (22)
  • .agents/rules/verify-after-each-step.md
  • .changeset/tiered-lookup-fast-paths.md
  • docs/architecture.md
  • docs/glossary.md
  • docs/plans/tiered-lookup-fast-paths.md
  • docs/roadmap.md
  • lint-staged.config.js
  • src/application/http-server.test.ts
  • src/application/mcp-server.test.ts
  • src/application/mcp-server.ts
  • src/application/show-engine.test.ts
  • src/application/show-search-mode.test.ts
  • src/application/show-search-mode.ts
  • src/cli/cmd-show.ts
  • src/cli/cmd-snippet.ts
  • src/db.test.ts
  • src/db.ts
  • templates/agent-content/mcp-instructions.md
  • templates/agent-content/rule/00-full.md
  • templates/agent-content/skill/10-recipes-context.md
  • templates/agent-content/skill/40-query-patterns.md
  • templates/recipes/find-symbol-definitions.md
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/tiered-lookup-fast-paths

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

Comment @coderabbitai help to get the list of available commands and usage tips.

Lone name:Token without wildcards is fast-tier equality; substring and
multi-field queries use slow-tier LIKE (kind:class name:Auth).
lint-staged relatedTests runs co-located *.test.ts when a src/ source
file is staged without its test; document in verify-after-each-step.
Add *.test.tsx glob for co-staged pairs; align rule table and Rule 4 with
lint-staged.config.js (scripts/**/*.test.mjs, relatedTests scope).
@SutuSebastian SutuSebastian merged commit fb73e0d into main Jun 11, 2026
11 checks passed
@SutuSebastian SutuSebastian deleted the feat/tiered-lookup-fast-paths branch June 11, 2026 09:44
@github-actions github-actions Bot mentioned this pull request Jun 11, 2026
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