Commit 1a993921 authored by Aryan Noshirvani's avatar Aryan Noshirvani

Drop Claude, refine back to a single Gemini call

Per direction: no Claude. Merged the two-step Gemini-describes/Claude-
plans pipeline back into one Gemini call that both listens to every
song's real audio preview and produces the full structured plan
(sections, target key, sidechain, style) directly - simpler than two
model calls, and the audio-perception advantage that motivated the
two-step design in the first place only mattered when comparing
against a text-only Claude call anyway.

Tried gemini-2.5-pro for better reasoning first (background job, can
absorb the latency) - live 429 confirmed this API key's free tier has
a hard zero quota for -pro ("limit: 0", not exhausted), so reverted to
gemini-2.5-flash, which the rest of this app already runs on
successfully. Removed the anthropic dependency and ANTHROPIC_API_KEY
entirely rather than leaving unused Claude plumbing around.

Verified end-to-end against the real API: a "house remix with a big
sidechain pump and a proper build-drop structure" request produced 5
real sections (intro/build/drop/breakdown/outro) with genuinely
different stems active per section, sidechain enabled and targeting
the correct song's drums, style set to house, and a valid ~9s tagged
MP3 out the other end.
Co-Authored-By: 's avatarClaude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01BCxXmJVvDFJVHTUi4QgNzi
parent b1eab28c
Pipeline #996 passed with stage
in 49 minutes and 21 seconds
......@@ -2,10 +2,6 @@ TELEGRAM_BOT_TOKEN=your_telegram_bot_token_here
ACOUSTID_API_KEY=your_acoustid_api_key_here
GEMINI_API_KEY=your_gemini_api_key_here
# Used by the remix engine's planning step (src/services/remix_engine.py plan_remix) -
# Claude reasons about the user's prompt and produces the structured arrangement plan.
ANTHROPIC_API_KEY=your_anthropic_api_key_here
# Optional, used by src/telegram_bot (stem separation feature)
LALAL_API_KEY=your_lalal_api_key_here
......
......@@ -7,7 +7,6 @@ syncedlyrics==1.0.1
pyacoustid==1.3.0
musicbrainzngs==0.7.1
google-generativeai==0.8.3
anthropic>=0.40.0
pedalboard==0.9.8
fastapi>=0.110.0
uvicorn>=0.28.0
......
......@@ -260,7 +260,7 @@
<section id="remix-section">
<h2>🎛 AI Remix</h2>
<p class="desc">Upload 1&ndash;5 songs and describe the remix in plain language. Gemini listens to each track, Claude directs the arrangement (sections, harmonic key matching, sidechain, style), and Demucs does the actual stem separation before rendering.</p>
<p class="desc">Upload 1&ndash;5 songs and describe the remix in plain language. Gemini listens to each track and directs the arrangement (sections, harmonic key matching, sidechain, style), and Demucs does the actual stem separation before rendering.</p>
<div class="dropzone" id="remix-drop">
Drop up to 5 audio files here, or click to choose
......
......@@ -8,7 +8,6 @@ load_dotenv()
TELEGRAM_BOT_TOKEN = os.getenv("TELEGRAM_BOT_TOKEN")
ACOUSTID_API_KEY = os.getenv("ACOUSTID_API_KEY", "8XaBELgH")
GEMINI_API_KEY = os.getenv("GEMINI_API_KEY")
ANTHROPIC_API_KEY = os.getenv("ANTHROPIC_API_KEY")
LALAL_API_KEY = os.getenv("LALAL_API_KEY")
# Gate for the interactive API docs (/docs, /openapi.json) - HTTP Basic Auth.
......
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment