Commit graph

16 commits

Author SHA1 Message Date
Troll (Hermes Agent)
52415c41fe Show request ID in kiosk queue
Each active request in the kiosk Live Queue now displays its
request number before the customer name (e.g. #42 jess) so
multiple requests from the same email can be distinguished.

Bumps version to 0.5.4.
2026-08-05 20:31:55 +00:00
Troll (Hermes Agent)
52558010e8 Add Live Queue slide to kiosk rotation
- Added a third kiosk slide showing the active customer queue.
- Customer names are derived from the local-part of their email address.
- Statuses are mapped to friendly labels:
    pending -> Received
    prompt_ready / songs_uploaded -> Trollgorithm Recording in Studio
    revisions_requested -> Waiting for Customer Response
    awaiting_payment -> Payment Due
- Completed/delivered statuses are not shown.
- If the queue overflows, a note points customers to the status page.
- Added queue-only mode (kiosk_cycle_seconds = 1) and updated the
  cycle logic to rotate QR -> pricing -> queue.
- Updated /admin/settings help text for the new mode.

Bumps version to 0.5.3.
2026-08-05 20:27:33 +00:00
Troll (Hermes Agent)
96b6470c25 Fix delete-song checkbox alignment on admin request page
- Wrapped each Version A/B row in a flex .song-row container so the
  checkbox sits inline with the label instead of floating above it.
- Added generous gaps/margins since this page is desktop-only.

Bumps version to 0.5.2.
2026-08-05 20:08:22 +00:00
Troll (Hermes Agent)
7eb72e511d Add delete-songs controls to admin request page
Operators can now select Version A and/or Version B in the Upload Songs
section and click 'Delete Selected Songs'. The handler removes the
chosen MP3 files, clears their DB paths, resets customer_approved to
'none', and sets the request status back to 'prompt_ready' so new
songs can be uploaded.

Bumps version to 0.5.1.
2026-08-05 20:05:20 +00:00
Troll (Hermes Agent)
d7e54809c9 Add Limitations section to FAQ
Added a new 'Limitations' section after 'Versions & revisions' using
the content from /mnt/Storage/FAQ.txt. Covers prohibited topics,
explicit lyrics, customer-provided lyrics, and karaoke-style
requests.

Bumps version to 0.5.0.
2026-08-05 19:59:24 +00:00
Troll (Hermes Agent)
d9566f4158 Update extra requests label and placeholder on customer form
- Label now reads: 'Anything else you want in the song? (Trollgorithm is very literal, so be careful!)'
- Placeholder updated to: 'Specific Lyrics, clean/explicit...'

Bumps version to 0.4.9.
2026-08-05 19:27:27 +00:00
Troll (Hermes Agent)
da7dd0e9ee Include lyrics in delivery email
The final delivery email now appends a Song Lyrics section in the same
format shown on the customer player page: section headers like
[Chorus] are stripped, blank lines are preserved as stanza breaks,
and the lyric lines are rendered as plain text.

Bumps version to 0.4.8.
2026-08-05 17:44:11 +00:00
Troll (Hermes Agent)
3f7bbf4b12 Add required pronouns dropdown and fix admin vocal gender selector
- Added a required Pronouns dropdown to /request and /admin/request:
  He/Him/His, She/Her/Hers, They/Them/Their.
- Moved Email to the top of the customer request form; Pronouns sit just below Name.
- Added  column to the requests schema with automatic migration.
- Stored pronouns are included in confirmation emails and Hermes prompt copy.
- Fixed /admin/request so Preferred singer voice / gender is a dropdown
  matching the customer form instead of a free-text input.
- Updated README to describe pronouns and the structured style selectors.

Bumps version to 0.4.7.
2026-08-05 17:21:38 +00:00
Troll (Hermes Agent)
10ee182558 Replace free-text genre field with structured style dropdowns
The customer request form previously had an open 'Style / genre / mood'
text field, which produced inconsistent genre descriptions and confused
Suno. Replace it with three dropdowns:

- Decade / era (required) — loaded from /mnt/Storage/Decades.txt
- Basic style (required) — loaded from /mnt/Storage/Music Genres.txt
- Additional style (optional) — same genre list

The combined value is stored in the existing style_genre column as a
comma-separated string (e.g. '1980's, Pop, Funk'), so no schema change
is required. The admin request page exposes the same dropdowns for
corrections, and the copy-to-Hermes prompt formats the style as a clean
sentence like '1980's-era Pop with Funk influences'.

The canonical lists live in /mnt/Storage; bundled copies under lists/
act as a fallback when that mount is unavailable in the container.

Bumps version to 0.4.6 and updates README.
2026-08-05 17:03:28 +00:00
Troll (Hermes Agent)
235507f499 Extend callback token expiry from 1 hour to 7 days
The signed callback token for /api/prompt/<rid> expired after 1 hour.
That was too short for a workflow where the operator may copy the URL and
paste it to Hermes, then wait for a response. Extend to 7 days.

Also fixes the misleading 401 on expired tokens (token check runs before
API key check). The new /api/key-test endpoint lets callers verify the
API key independently.

Bump version 0.4.4 -> 0.4.5.
2026-08-05 14:44:25 +00:00
Troll (Hermes Agent)
2637cdba61 Add /api/key-test diagnostic endpoint for API key verification
Provides a simple GET endpoint that validates the Authorization Bearer
token against HERMES_API_KEY and returns JSON:
  {"ok": true, "reason": "valid"} or
  {"ok": false, "reason": "key_mismatch" / "missing_bearer" / "not_configured"}

Rate limited to 4 per minute to prevent brute-force guessing.

Bump version 0.4.3 -> 0.4.4.
2026-08-05 14:41:39 +00:00
Troll (Hermes Agent)
4b48e0a44f Fix TypeError when revision_count is stored as TEXT
The previous schema migration added revision_count as TEXT. SQLite stores
the default as TEXT, but the app does integer arithmetic on it, causing:

  TypeError: unsupported operand type(s) for -: 'int' and 'str'

- init_db() now adds revision_count as INTEGER.
- app.py casts revision_count to int in play() and revise() and when
  incrementing in revise(), so existing TEXT values also work.

Bump version 0.4.2 -> 0.4.3.
2026-08-05 14:25:07 +00:00
Troll (Hermes Agent)
f5d3d487af Fix 500 on /play/<token>/revise for missing revision_count column
Deployed DBs persisted without the revision_count column / revision_history
table, causing customer revision requests to 500.

- init_db() now migrates existing tables by adding missing columns.
- log_revision() falls back to init_db() on missing table for full repair.
- Bump version 0.4.1 -> 0.4.2.
2026-08-05 13:51:53 +00:00
Troll (Hermes Agent)
3f9de1449c Fix 500 on customer revision when revision_history table is missing
Deployed databases can persist without the revision_history table,
causing /play/<token>/revise to crash with sqlite3.OperationalError.

- log_revision() now creates the table on the fly if it is missing.
- app.py runs init_db() at import time (safe CREATE TABLE IF NOT EXISTS)
  so new deployments auto-create missing tables on startup.

Bump patch version 0.4.0 -> 0.4.1.
2026-08-05 13:42:10 +00:00
Troll (Hermes Agent)
51f7ffd5ab Add revision prompt copy button for Hermes on admin request page
When a request has revision_note set, the operator now sees a
'Copy revision prompt for Hermes' button in the revision note box.
It copies a prompt that includes:
- the original customer brief,
- the previously generated title/style/lyrics,
- the customer's revision request,
- the signed callback URL and expected JSON shape.

Minor version bump: 0.3.0 → 0.4.0.
2026-08-05 03:25:34 +00:00
Troll (Hermes Agent)
db249e80bd Add VERSION file and live version display on settings page
- New VERSION file at project root, starting at 0.3.0.
- config.py reads VERSION and exposes it as Config.VERSION.
- Admin settings page now renders the live version from config.
- Semantic versioning convention: MAJOR for breaking/user-facing changes,
  MINOR for new features, PATCH for bug fixes and small polish.
2026-08-05 03:17:16 +00:00