Home / Archive / More in this area
Archived version Updated Jun 13, 2026 · Affirmology_EndToEndDemo_Plan_v1.md
Date: 2026-06-13. The plan to take the live demo from "looks finished" to "actually works for a real visitor," piece by piece.
End-to-end already works offline. On May 29 and June 2 the agent produced complete demos for two strangers, Alex Carper and Colin: a real mixed mp3 (Charlotte voice over the Heavenly Circuit bed) and a benchmarked Sacred Audio Report PDF, plus a backend payload that holds the exact cosmic blueprint that informed the script. The calculation engines, script generator, voice synthesis, music mix, and PDF report all run.
So this is not a build from scratch. It is a plumbing job: connect the pretty site to the working agent, expose the agent over the internet through your laptop, and turn on email. That is the whole gap.
Ownership tags: [ME] I can do it in the files or the browser. [JEFF] runs on your Mac Terminal or your accounts. [BOTH] we do it together live.
Purpose: guarantee the prettier animated version exists at demo.affirmology.ai right now, even before the backend is wired. The form still runs its polished mock until Piece 3 flips it to real.
cd "/Users/jeffreyparker/CLAUDE/AFFIRMOLOGY/CLAUDE OUTPUTS/Affirmology/demo-site-v2" && npx wrangler pages deploy . --project-name=affirmology-demo. Confirm the project name in the dashboard first so you do not create a duplicate.Purpose: confirm the pipeline still runs green on this machine before we expose anything.
cd "/Users/jeffreyparker/CLAUDE/AFFIRMOLOGY/affirmology-agent"
source .venv/bin/activate
# confirm the ElevenLabs key is set (voice synthesis needs it)
echo $ELEVENLABS_API_KEY
python -m affirmology.cli --name "Test Visitor" --date 1990-07-15 --time 14:20 --location "Miami, FL, USA" --audio --music "music/Heavenly Circuit.mp3" --voice-offset 8.0 --out out/smoke_testThe server already accepts the job and webhooks back. It needs two more things so the page can show results and play audio:
- A GET /status/{job_id} endpoint that returns: state (pending, rendering, done, failed), the blueprint payload (the astrology, gene_keys, human_design, numerology arrays), and the public file URLs once done.
- Static file serving of the out directory so the mp3 and PDF have real URLs.
- [ME] I write these into server/api.py and adjust the Worker contract to match.
/api/render and then routes to result.html with the returned job id./api/status/{job_id} through the Worker. On done, set the audio player source to the real mp3, set the PDF download link, and render the report sections from the real payload. Add the conditional video: if a trailer URL is configured, play it during the wait; otherwise keep the breathing wait screen.Purpose: the Cloudflare Worker and the visitor's browser must reach your laptop. Tailscale is already installed (machine macbook-pro-2, IP 100.98.80.60). Funnel makes one port publicly reachable with automatic TLS.
- [JEFF] Run the FastAPI server, then open the funnel. Exact commands come after Piece 1 passes, but the shape is:
cd "/Users/jeffreyparker/CLAUDE/AFFIRMOLOGY/affirmology-agent"
source .venv/bin/activate
PYTHONPATH=src AFFIRMOLOGY_AUTH_TOKEN=<shared-secret> uvicorn server.api:app --host 127.0.0.1 --port 8443
# in a second Terminal tab:
tailscale funnel 8443
- The funnel gives a public https URL like https://macbook-pro-2.tailXXXX.ts.net. That becomes the Worker's MAC_MINI_URL.
cd "/Users/jeffreyparker/CLAUDE/AFFIRMOLOGY/affirmology-demo-site/worker"
npx wrangler secret put MAC_MINI_URL # the funnel https URL from Piece 4
npx wrangler secret put MAC_MINI_AUTH_TOKEN # the same shared secret as the server
npx wrangler secret put RESEND_API_KEY # from Piece 6
npx wrangler secret put FROM_EMAIL # hello@affirmology.ai
npx wrangler deployPieces 0, 1, 2, 3 are achievable today and give you a real working visit on this network: submit the form, watch the wait, hear the real audio, see the blueprint. Pieces 4 and 5 make it reachable from anywhere over the internet. Piece 6, email, can follow in parallel. We go one piece at a time and confirm each before the next.