βββββββ βββ βββ βββββββ ββββ βββ βββββββ βββ βββ
βββββββββββ βββββββββββββββββ ββββββββββββββββββββ
βββββββββββββββββββ βββββββββ ββββββ βββ ββββββ
βββββββ βββββββββββ ββββββββββββββββ βββ ββββββ
βββ βββ βββββββββββββββ βββββββββββββββββββ βββ
βββ βββ βββ βββββββ βββ βββββ βββββββ βββ βββ
AI-powered Vinyl Collection Agent β Cataloguing, Valuation, and Documentation
Phonox is an intelligent assistant for vinyl record collectors. It helps you:
- πΈ Identify records by snapping photos or uploading images
- π° Get valuations using multiple data sources (Discogs, MusicBrainz)
- π΅ Find Spotify links for listening to your collection
- π Organize your collection with metadata, ratings, and notes
- π¬ Chat about records with an AI agent that remembers your collection
πΌοΈ See it in action β UI Gallery & feature walkthrough π Blog β phonox-blog.web.app
Perfect for collectors managing large vinyl libraries or insuring valuable collections.
Before you start, make sure you have:
-
Docker & Docker Compose installed
- Windows/Mac
- Linux
- Verify: Run
docker --versionanddocker compose version
-
Git (to clone the repository)
-
API Keys (optional but recommended)
- Anthropic API Key (for Claude AI)
- Tavily API Key (for web search, optional β DuckDuckGo fallback is free)
git clone https://github.com/yourusername/phonox.git
cd phonox# Copy the environment template
cp .env.example .env
# Add your Anthropic API key
./phonox-cli configure --anthropic YOUR_ANTHROPIC_KEYGet your API key: console.anthropic.com
# Make executable and run (installs + starts everything)
chmod +x start-cli.sh
./start-cli.shThe start-cli.sh script will:
- β Build Docker images
- β Start all services (database, backend, frontend)
- β Initialize the database
Done! Open your browser:
- Frontend (UI): http://localhost:5173
- API Docs: http://localhost:8000/docs
- Backend Health: http://localhost:8000/health
The .env file contains all configuration. Key variables:
| Variable | Required | Description |
|---|---|---|
ANTHROPIC_API_KEY |
β Yes | Claude AI API key from console.anthropic.com |
TAVILY_API_KEY |
Web search API key from tavily.com | |
DATABASE_URL |
β Pre-configured | PostgreSQL connection (auto-configured for Docker) |
For all configuration options, see .env.example
- Click "Upload Image" on the home page
- Take a photo or upload an image of:
- The album cover (front or back)
- The barcode (if visible)
- The vinyl itself (for condition assessment)
- Phonox AI will:
- Scan for the barcode
- Search Discogs and MusicBrainz
- Extract album metadata automatically
- Review the results and save to your collection
- Visit "Register" to see all your vinyl records
- Edit any record to:
- Add notes or condition notes
- Add Spotify link
- Update valuation
- Rate the record
- Delete records from your collection
- Export your collection (future feature)
- Open the Chat panel on the right
- Ask questions about your collection:
- "What's my rarest record?"
- "Show me all records from the 80s"
- "What's the total value of my collection?"
- The agent remembers context from your collection
./phonox-cli start
# or
docker compose up -d./phonox-cli stop
# or
docker compose downdocker compose logs -f backend
docker compose logs -f frontend./phonox-cli status
# or
curl http://localhost:8000/healthFull CLI Reference:
# Install (build Docker images)
./phonox-cli install
# Install + start services
./phonox-cli install --up
# Configure API keys and models
./phonox-cli configure --anthropic YOUR_KEY --tavily YOUR_KEY
# Configure Anthropic models (for advanced users)
./phonox-cli configure --vision-model claude-sonnet-4-6
./phonox-cli configure --chat-model claude-haiku-4-5-20251001
# Start services
./phonox-cli start
# Stop services
./phonox-cli stop
# Backup your data
./phonox-cli backup
# Restore from backup (use timestamp from backup folder)
./phonox-cli restore 20260128_143000Run without arguments to launch interactive menu:
./phonox-cli
# Shows menu with all options above# Kill process using port 8000
lsof -i :8000 | grep LISTEN | awk '{print $2}' | xargs kill -9
# Or restart Docker
docker compose down
docker compose up -d# Reset database
docker compose down -v
docker compose up -d# Check upload folder permissions
ls -la data/uploads/
# Restart services
docker compose restart backend frontend# Verify .env file
cat .env
# Restart backend to reload keys
docker compose restart backend./phonox-cli backup
# Backups stored in: ./backups/ls -lh backups/./phonox-cli restore 20260128_143000docker compose exec db psql -U phonox -d phonox -c "
SELECT
schemaname,
sum(pg_total_relation_size(schemaname||'.'||tablename)) AS size
FROM pg_tables
GROUP BY schemaname
ORDER BY size DESC;"docker compose exec db psql -U phonox -d phonox -c "
SELECT id, title, artist, release_date, confidence, created_at
FROM vinyl_records
ORDER BY created_at DESC
LIMIT 10;"docker compose exec backend pytest tests/ -v# Unit tests
docker compose exec backend pytest tests/unit -v
# Integration tests
docker compose exec backend pytest tests/integration -v
# With coverage report
docker compose exec backend pytest tests/ --cov=backend --cov-report=html# Open coverage report
open htmlcov/index.html # macOS
xdg-open htmlcov/index.html # Linux
start htmlcov/index.html # Windows- What is Phonox? β Overview and features
- How to Use β Step-by-step user guide
- Troubleshooting β Common issues and fixes
- Tech Stack Guide β Architecture and technologies
- Requirements Spec β Complete feature list
- Testing Guide β How to write and run tests
- Implementation Plan β Project roadmap and progress
- Contributing Guide β How to contribute code
- Agent Collaboration Instructions β Team workflow
- Deployment Guide β Production setup
phonox/
βββ README.md (this file)
βββ requirements.txt (Python dependencies)
βββ docker-compose.yml (Local development)
βββ Dockerfile.backend (FastAPI image)
βββ Dockerfile.frontend (Vite React image)
β
βββ docs/
β βββ tech-stack.md
β βββ requirements_en.md
β βββ .github/agents/
β βββ agent.md (Agent architecture)
β βββ architect.md (Architect role)
β βββ tools.md (Tool engineer role)
β βββ frontend.md (Frontend role)
β βββ deployment.md (Docker & CI/CD)
β βββ testing.md (Testing strategy)
β βββ implementation-plan.md (Roadmap)
β βββ instructions.md (Collaboration guide)
β
βββ backend/
β βββ main.py (FastAPI entry point)
βββ database.py (SQLAlchemy ORM)
βββ agent/
β βββ state.py (State models)
β βββ graph.py (LangGraph workflow)
β βββ vision.py (Vision extraction)
β βββ websearch.py (Web search integration)
β βββ metadata.py (Metadata lookup)
β βββ barcode_utils.py (Barcode extraction)
βββ api/
β βββ routes.py (Identification endpoints)
β βββ register.py (Register endpoints)
β βββ models.py (Pydantic models)
βββ tools/
β βββ web_tools.py (Web search tools)
βββ tests/ (unit, integration, api tests)
β
βββ frontend/
βββ src/
β βββ components/
β β βββ ImageUpload.tsx
β β βββ ResultsView.tsx
β β βββ ReviewForm.tsx
β β βββ ChatPanel.tsx
β β βββ VinylCard.tsx
β β βββ VinylRegister.tsx
β β βββ AnalysisModal.tsx
β βββ App.tsx
βββ package.json
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β Frontend (React) β
β - Upload images β
β - View collection β
β - Chat with AI agent β
ββββββββββββββββββββββ¬βββββββββββββββββββββββββββββββββββββ
β HTTP
βΌ
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β Backend (FastAPI) β
β - AI Agent (LangGraph) β
β - Image Recognition β
β - Metadata Lookup β
ββββββββββββββββββββββ¬βββββββββββββββββββββββββββββββββββββ
β
ββββββββββββββΌβββββββββββββ
βΌ βΌ βΌ
Database Discogs API MusicBrainz
(PostgreSQL) (Metadata) (Metadata)
- Agent β AI decision-maker using LangGraph orchestration
- Tools β Plugins for Discogs, MusicBrainz, image extraction, web search
- Database β PostgreSQL stores your vinyl collection
- API β FastAPI provides endpoints for the frontend
- Frontend β React PWA for mobile and desktop browsers
- Backend: Python 3.12, FastAPI, LangGraph, Pydantic v2, SQLAlchemy
- Frontend: React (Vite), PWA, TypeScript
- Database: PostgreSQL 16
- Cache/Queue: Redis 7
- API Sources: Discogs, MusicBrainz
- Websearch: Tavily (if configured) + DuckDuckGo fallback
- ML Models: ViT-base (image embeddings), Tesseract (OCR)
- DevOps: Docker, Docker Compose, GitHub Actions
See Tech Stack Guide for details.
Q: I don't have an Anthropic API key. Can I still use Phonox?
A: No, Claude API is required. Get a free tier key at console.anthropic.com.
Q: Can I use Phonox without Docker?
A: Not recommended. Docker ensures all dependencies work correctly. If you must, install: Python 3.12, PostgreSQL 16, Redis 7, Node.js 18.
Q: How do I backup my vinyl collection?
A: Run ./phonox-cli backup weekly. Backups are stored in ./backups/.
Q: Can I run Phonox on my phone?
A: Yes! It's a Progressive Web App (PWA). Open http://localhost:5173 on your phone and tap "Install" or "Add to Home Screen".
Q: How do I import my existing vinyl spreadsheet?
A: Currently manual. We're working on CSV import (see roadmap). For now, use the UI to add records.
- π Documentation: See links above
- π Report Issues: Open an issue on GitHub
- π¬ Discuss Features: Start a discussion
- π₯ Join Community: See CONTRIBUTING.md
β¨ Version 1.9.5 (February 22, 2026)
- Full curses arrow-key interactive menu β β/β navigation, white-on-blue selection bar
- Per-service status panel: Frontend / Backend / DB each with own β/β icon
- Interactive configure with 6 masked keys (added Aggregation + Enhancement models)
- Interactive restore: pick backup from list, confirm with
yes - Collection management: rename collections directly from the CLI
β¨ Version 1.9.4 (February 22, 2026)
- Fixed false "Could not access images" warning in backup script β replaced hardcoded container name with
docker compose cpservice name
β¨ Version 1.9.3 (February 21, 2026)
- Fixed page reload when adding multiple images on Samsung Internet Browser (Android)
β¨ Version 1.9.2 (February 21, 2026)
- DuckDuckGo now supplements sparse Tavily results (configurable threshold via
.env) - Added configurable search variables:
WEBSEARCH_MAX_RESULTS,WEBSEARCH_MIN_RESULTS_THRESHOLD,WEBSEARCH_BARCODE_MAX_RESULTS - Memory-first image architecture: uploaded images are now the single source of truth in the UI
- Actionable error messages surfaced directly from the backend (including clickable billing URLs)
- Fixed CLI restart crash and unhealthy database detection
- Fixed Anthropic credit-balance error being masked as an image format error
- Fixed reanalysis dead-code path when backend restarts with no client-sent images
See CHANGELOG.md for complete history.
Last Updated: 2026-02-22
Current Version: 1.9.5
Status: Production Ready β
- β Image-based vinyl identification
- β Metadata lookup (Discogs, MusicBrainz)
- β AI-powered valuation
- β Web-based UI (mobile + desktop)
- β Spotify integration
- β Enhanced web search
- π CSV import/export
- π Barcode printing
- π Collection insurance reports
- π Social sharing
- π Mobile app (iOS/Android)
See Implementation Plan for details.
This project is licensed under the MIT License - see LICENSE file for details.
Contributions are welcome! Please see Contributing Guide for guidelines on how to get started, including:
- Setting up your development environment
- Git workflow and branching strategy
- Code style and commit message conventions
- Testing and validation procedures
- Issues & Feature Requests: GitHub Issues
- Documentation: See docs/ folder for detailed technical documentation
- Built with Claude AI for record identification and chat
- Uses Tavily for web search (with DuckDuckGo fallback)
- Data enrichment from MusicBrainz and Spotify API
- Powered by FastAPI, React, and LangGraph