rin.kagamine f8969d8585 feat: Complete search overhaul — fuzzy, filters, highlighting, debounce, saved searches
Search improvements (all 7 recommendations implemented):

1. Search all metadata fields:
   - Fuzzy search now includes: title, prompt, artist, album, comment,
     model, status, error_message, key, BPM, duration, structured prompt fields
   - Built _searchText concatenated field for Fuse.js indexing

2. Fuzzy search via fuse.js:
   - Installed fuse.js@7.0.0
   - threshold: 0.4 (balanced precision/recall)
   - ignoreLocation: true (matches anywhere in text)
   - includeScore for ranking

3. Advanced filters panel:
   - Model: All / Clip Preview / Pro
   - Status: All / Ready / Generating / Failed
   - Artwork: All / Has Artwork / No Artwork
   - BPM Range: Min/Max number inputs
   - Date Range: From/To date pickers
   - Active filter chips shown below search bar
   - Clear all button

4. Search term highlighting:
   - HighlightText component wraps matched terms in
     bg-lyria-accent/30 background
   - Applied to title and prompt in both ribbon and tile views

5. Debounced input (300ms):
   - useDebounce hook delays search execution
   - Prevents filtering on every keystroke
   - Smoother UX, less CPU usage

6. Saved searches:
   - Save current search + filters with custom name
   - Stored in localStorage (lyria-saved-searches)
   - Load saved search to restore query + filters
   - Delete saved searches
   - Bookmark icon in search bar

7. Backend search endpoint:
   - GET /api/clips/search?q=&model=&status=&bpm_min=&bpm_max=&date_from=&date_to=&limit=&offset=
   - Full pagination support for large libraries
   - Same fuzzy logic as frontend, server-side

Gallery component completely rewritten with:
- Cleaner header layout with search, filters, saved searches, view toggle
- Results count showing filtered/total
- Empty state when no matches
- Pagination with page info
2026-05-29 23:15:08 -04:00

Lyria Studio

A webapp for generating, playing, and storing music clips using Google's Lyria music generation models.

Built by Kagamine Rin & Ryan.

Quick Start

# Backend
cd backend
python -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt
cd src
uvicorn main:app --reload

# Frontend (new terminal)
cd frontend
npm install
npm run dev

Architecture

  • Backend: FastAPI (Python) — async Lyria API client, SQLite metadata, file storage
  • Frontend: React + Vite + TypeScript + Tailwind — dark theme, audio player
  • Storage: SQLite for clip metadata, local filesystem for MP3 files

API

Endpoint Method Description
/api/health GET Health check
/api/generate POST Start clip generation
/api/clips GET List all clips
/api/clips/{id} GET Get clip metadata
/api/clips/{id}/audio GET Stream MP3
/api/clips/{id} DELETE Delete clip

Models

  • v0.1: Lyria 3 Clip Preview (30s, REST)
  • v0.2: Lyria 3 Pro (structure-aware, ~3min)
  • v0.3: Lyria RealTime (WebSocket streaming)

License

MIT — Hardcore will never die.

S
Description
A webapp for generating, playing, and storing music clips using Google's Lyria models
Readme MIT
1.7 MiB
0 Stars 2 Watchers 0 Forks
Languages
TypeScript 51.8%
Python 47.4%
JavaScript 0.3%
Dockerfile 0.2%
CSS 0.2%
Other 0.1%