Annotate catalog cards with searchable#630
Merged
Merged
Conversation
There was a problem hiding this comment.
Pull request overview
This PR annotates a set of catalog CardDef fields with searchable metadata so a future “searchable-driven” search-doc generator can reproduce the same link-depth currently present in stored search docs, without affecting the current store-driven generator.
Changes:
- Add
searchableannotations tolinksTo/linksToManyrelationships across multiple catalog cards (and a fewcontainsfields that wrap media sources). - Add targeted, per-field searchable route lists (e.g., for
SubmissionWorkflowCard.listingandListing.specs) to control traversal depth. - Minor formatting adjustment in
VirtualTryOnApparound an inlineQuerytype assertion.
Reviewed changes
Copilot reviewed 21 out of 21 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| system-card/model-configuration.gts | Marks openRouterModel link as searchable. |
| submission-workflow-card/submission-workflow-card.gts | Adds per-route searchable traversal for the linked Listing and marks prCard searchable. |
| fields/audio/Spec/audio-field-spec.gts | Adds searchable: 'file' to audio field variants to include underlying file link in traversal. |
| ef8aea-wine-bottle/wine-bottle.gts | Marks label image link searchable. |
| d8403b-beat-maker-studio-card/beat-maker.gts | Marks current/available kit & pattern links searchable. |
| catalog-app/listing/review.gts | Marks listing link searchable. |
| catalog-app/listing/listing.gts | Adds searchable traversal to specs plus searchable annotations to several listing relationships; marks CardListing.skills searchable. |
| catalog-app/listing/category.gts | Marks sphere link searchable. |
| blog-app/blog-post.gts | Marks authors and categories links searchable. |
| blog-app/blog-app.gts | Adds route-scoped searchable traversal for pinned posts and marks games searchable. |
| b6ac3a-survey/survey-response.gts | Marks survey link searchable. |
| 673fb6-blackjack-cardgame-definition/record-game-result.gts | Marks polymorphic card: linksTo(CardDef) link searchable. |
| 673fb6-blackjack-cardgame-definition/game-result.gts | Marks polymorphic game: linksTo(() => CardDef) link searchable. |
| 673fb6-blackjack-cardgame-definition/blackjack.gts | Marks player and dealer links searchable. |
| 4b6602-wine-cellar-card-definition/wine-cellar.gts | Adds searchable route for bottles → label. |
| 4b6602-wine-cellar-card-definition/wine-bottle.gts | Marks label image link searchable. |
| 25f2fc-homework-grader/homework-grader.gts | Marks gradingSkill link searchable. |
| 19dee3-virtual-try-on-application/virtual-try-on-app.gts | Minor type-assertion formatting change; marks model link searchable via photo.file. |
| 19dee3-virtual-try-on-application/model.gts | Marks photo image source searchable via file. |
| 19dee3-virtual-try-on-application/garment.gts | Marks image image source searchable via file. |
| 150b3a-virtual-piano/music-sheet.gts | Marks genre links searchable. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Adds `searchable` field annotations derived from the cards' live search docs so the searchable-driven search-doc generator reproduces today's link depth. Routes are hoisted to the declaring class, polymorphic links (linksTo(CardDef) etc., which can't be queried) are pruned, and zero-instance defs default their relationships to depth-1. Inert under the store-driven generator (it ignores `searchable`), so no search behavior changes until that generator is authoritative. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0182qehwDYbwBmyYcAhMoij1
83b46c4 to
063dc2b
Compare
Contributor
Author
|
note that the lodash lint errors are not real. lodash is available as a shim for cards to use. unsure why lint is failing for this. but also the lodash imports were never touched in this PR--it was preexisting |
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.
Adds
searchablefield annotations to the catalog cards, derived from the cards' stored search docs so the searchable-driven search-doc generator reproduces the link depth those docs already carry.Per field: routes are hoisted to the class that declares the head field; routes crossing a polymorphic link (
linksTo(CardDef)etc. — unqueryable, so pure search-doc cruft) or a non-declared field are pruned; a card def with no indexed instances defaults its non-query-backed relationships tosearchable: true(depth-1). Query-backed relationships are never annotated.The additions are inert under the store-driven search-doc generator (which ignores
searchable), so no search docs or query results change until the searchable-driven generator becomes authoritative.🤖 Generated with Claude Code