feat(wasap): add GenSpectrum collections analysis mode#1327
Open
fhennig wants to merge 12 commits into
Open
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
2 tasks
Base automatically changed from
rename-collection-mode-to-cov-spectrum-collection
to
main
July 9, 2026 07:08
f07c692 to
b2de732
Compare
Also converts WasapAnalysisMode, SignatureType, ExcludeSetName to const-object pattern (matching VARIANT_TIME_FRAME), adds SEQUENCE_TYPE for the external SequenceType, exports fetchWasapPageData for direct testing, and adds BackendRouteMocker.mockGetCollection to routeMocker.ts. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
… customColumns Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…eFrame tests Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Contributor
Author
|
Waiting for #1332 so we can add some more tests. |
Adds a new 'collection' analysis mode to the WASAP dashboard that browses GenSpectrum's own collection system, enabling RSV-A and RSV-B to have a collections mode (CovSpectrum collections only exist for COVID). - Config: CollectionAnalysisModeConfig discriminated union; no extra URL needed since the backend is our own - Data fetch: getBackendServiceForClientside().getCollection(), handles both 'query' and 'filterObject' variant types via parseQuery validation - Filter UI: GsCollectionAnalysisFilter lists collections by organism via getCollectionSummaries() - COVID gets both modes; RSV-A and RSV-B get only the new mode - CollectionInfo now accepts sourceLabel/collectionUrl to distinguish CovSpectrum vs GenSpectrum collection links in the page view Closes #1324 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…llection link
- Deduplicate display labels in fetchCollectionModeData: duplicate names
get a counter suffix ("Resistance", "Resistance (2)") so GsQueriesOverTime
doesn't throw on collections like the RSV-A resistance set
- Add clickable link to the GenSpectrum collection info box using
Page.viewCollection(config.internalName, id)
See #1328 for the same fix on the CovSpectrum path.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…pdown Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…isFilter Also auto-selects the first collection on load via useEffect and removes the empty placeholder option from the dropdown. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
209b0e1 to
0973b71
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.
Closes #1324, closes #1328
Summary
'collection'analysis mode to WASAP that uses GenSpectrum's own backend collections, separate from the existing'covSpectrumCollection'mode (CovSpectrum API)collectionmode (CovSpectrum collections don't exist for RSV)CollectionInfocomponent updated to acceptsourceLabeland optionalcollectionUrlto show appropriate links per sourceNew files
CollectionAnalysisFilter.tsx— filter dropdown that lists collections for the current organism viagetCollectionSummaries({ organism })Key implementation notes
getBackendServiceForClientside().getCollection({ id })queryvariants (countQuery used directly) andfilterObjectvariants (mutation arrays joined into a query string)parseQuery+validateGenomeOnlybefore display, same as the CovSpectrum pathfilterObjectvariants with only mutation arrays (no lineage catchall fields) are converted; empty results are marked invalidTest plan
npx tsc --noEmit)GsQueriesOverTimewith the collection's variantsTODO
WasapPage.browser.spec.tsxthat mocksgetCollectionviaBackendRouteMockerand asserts the "No valid variants" message renders when all variants are empty/invalid🤖 Generated with Claude Code