Repository navigation
feat: add criteria & prompt feature filtering to runs page - #164
Open
Cedric Vidal (cedricvidal) wants to merge 2 commits into
Open
Cedric Vidal (cedricvidal) wants to merge 2 commits into
Cedric Vidal (cedricvidal) wants to merge 2 commits into
Conversation
…T /requests Add two new server-side filters to GET /api/v1/requests: - scenarioCriteria: comma-separated criteria IDs, filters runs whose scenario.criteria contains ALL specified IDs ($all) - promptFeatures: comma-separated feature IDs, resolves task prompts with ALL features detected, then filters runs by those taskPromptIds Extract filter-building logic into request-filters.ts for testability. Include 14 unit tests covering parsing and filter construction. Closes #163 (API layer)
- Extend api.listRuns() to pass scenarioCriteria and promptFeatures params - Create PromptFeatureFilterBar component (mirrors CriteriaFilterBar) - Add CriteriaFilterBar for scenario criteria and PromptFeatureFilterBar to RunsList page with URL search param persistence - Both filters use AND semantics: selecting multiple items shows runs matching ALL of them Closes #163
This branch has not been deployed
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.
Original author: Cedric Vidal (@cedricvidal)
Summary
Add criteria and prompt feature filtering to the Runs page, resolving #163.
Changes
API (
apps/api/)GET /api/v1/requests:scenarioCriteria— comma-separated criteria IDs (e.g.has_azure,has_cloud). Filters runs whosescenario.criteriacontains ALL specified IDs ($all).promptFeatures— comma-separated feature IDs (e.g.asks_for_api,asks_for_azure). Resolves task prompts with ALL specified features detected, then filters runs by matchingtaskPromptId.request-filters.tsfor testability.request-filters.test.tscovering parsing and filter construction.Portal (
apps/portal/)api.listRuns()to passscenarioCriteriaandpromptFeaturesparams.PromptFeatureFilterBar— reusable toggle-badge filter bar for prompt features (mirrors existingCriteriaFilterBar).RunsList- UpdatedRunsList- **Updat f- **Updatio - UpdatedRunsList- UpdatedRunsList- **Updat f- **Updatio ing|
apps/api/src/request-filters.test.ts| New — 14 unit tests ||
apps/api/src/index.ts| Added new query param handling ||
apps/portal/src/lib/api.ts| Extendedl|apps/portal/src/lib/api.ts| Extendedl|apps/portal/src/lib/api.ts| Ex| |apps/portal/src/lib/api.ts| Extendedl|apps/portal/src/lib/api.ts| Extendedl| ba| `apps/portal/src/lib/apiCloses The runs page should allow filtering by criteria and task prompt feature #163