feat: Taste Fingerprint — personal collection analytics and shareable taste card#120
Merged
SimplicityGuy merged 11 commits intomainfrom Mar 14, 2026
Merged
feat: Taste Fingerprint — personal collection analytics and shareable taste card#120SimplicityGuy merged 11 commits intomainfrom
SimplicityGuy merged 11 commits intomainfrom
Conversation
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
c785f85 to
6a5a997
Compare
Codecov Report❌ Patch coverage is
📢 Thoughts on this report? Let us know! |
Add HeatmapCell, HeatmapResponse, ObscurityScore, TasteDriftYear, BlindSpot, and FingerprintResponse models to support the taste fingerprint feature. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
… blind spots, top labels (#114) Add api/queries/taste_queries.py with get_collection_count, get_taste_heatmap, get_obscurity_score, get_taste_drift, get_blind_spots, and get_top_labels Neo4j queries. Add comprehensive tests covering all query functions. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…indspots, and card endpoints (#114) Create api/routers/taste.py with 4 endpoints using asyncio.gather() for concurrent queries. Includes _MIN_COLLECTION_ITEMS=10 guard, _peak_decade() helper, and configure() function. Register router in api/api.py and tests/api/conftest.py. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Create api/taste_card.py with render_taste_card() producing a 600x400 SVG. Uses html.escape() for XSS prevention and clamps bar width to max(4, min(200, int(obscurity_score * 200))). Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
5a33029 to
bce4330
Compare
Tests were written against a different schema than what was implemented. Updated all 5 failing tests to match the actual field names and types in HeatmapResponse, ObscurityScore, TasteDriftYear, BlindSpot, and FingerprintResponse models. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Keep both PathNode/PathResponse models from main and Taste Fingerprint models from this branch, ordering Path models first. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- Move endpoints from /api/taste/ to /api/user/taste/ for namespace consistency with other user-scoped endpoints - Expose limit query param on blindspots endpoint (default 5, max 20) - Use asyncio.gather() inside get_taste_heatmap and get_obscurity_score for concurrent sub-queries - Add Cache-Control: no-store header to SVG card response - Add tests for limit parameter passthrough and cache header Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Contributor
Contributor
Contributor
Contributor
Contributor
This was referenced Mar 14, 2026
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.
Summary
/api/user/taste/for personal collection analytics (feat: Taste Fingerprint — personal collection analytics and shareable taste card #114)GET /api/user/taste/fingerprint— full analytics object (heatmap, obscurity, taste drift, top labels, peak decade)GET /api/user/taste/heatmap— genre × decade cross-tabulation matrixGET /api/user/taste/blindspots?limit=5— recommended underexplored genres/decades based on artist overlapGET /api/user/taste/card— shareable SVG taste card (≤100KB, server-side generated)1 - collectors/max_collectors)asyncio.gather()for concurrent Neo4j queries in fingerprint and card endpointshtml.escape()for XSS prevention with clamped bar widthsNew Files
api/queries/taste_queries.py— 6 Neo4j Cypher query functionsapi/routers/taste.py— FastAPI router with 4 endpointsapi/taste_card.py— SVG taste card generatortests/api/test_taste_queries.py— query unit teststests/api/test_taste.py— endpoint teststests/api/test_taste_card.py— SVG generation testsModified Files
api/models.py— 6 new Pydantic response modelsapi/api.py— taste router registrationtests/api/conftest.py— taste router in test fixtureTest plan
Closes #114
🤖 Generated with Claude Code