Initial TrueGrowth source import
This commit is contained in:
@@ -0,0 +1,64 @@
|
||||
## ADDED Requirements
|
||||
|
||||
### Requirement: Support Suno Lyrics As A Provider-Backed Audio Action
|
||||
|
||||
The system SHALL support Suno lyrics generation as an action within the existing audio routing model.
|
||||
|
||||
#### Scenario: Submit a lyrics generation request through the Suno lyrics endpoint
|
||||
|
||||
- **GIVEN** the active audio binding supports Suno lyrics generation
|
||||
- **WHEN** the user selects the lyrics action and submits a prompt
|
||||
- **THEN** the system SHALL send the request to `/suno/submit/lyrics`
|
||||
- **AND** SHALL include `prompt`
|
||||
- **AND** MAY include `notify_hook` when configured by the caller
|
||||
|
||||
#### Scenario: Poll a lyrics task through the shared Suno fetch endpoint
|
||||
|
||||
- **GIVEN** a Suno lyrics submit request returns a task identifier
|
||||
- **WHEN** the system tracks that task asynchronously
|
||||
- **THEN** it SHALL query `/suno/fetch/{task_id}`
|
||||
- **AND** SHALL normalize provider status into the internal task state
|
||||
|
||||
#### Scenario: Extract title tags and text from a completed lyrics task
|
||||
|
||||
- **GIVEN** a Suno fetch response for a lyrics task reports success
|
||||
- **WHEN** the nested result payload contains `text`, `title`, and `tags`
|
||||
- **THEN** the system SHALL store the generated lyrics text
|
||||
- **AND** SHALL preserve the returned title and tags when available
|
||||
- **AND** SHALL keep the provider task identifier for follow-up actions
|
||||
|
||||
### Requirement: Distinguish Suno Submit Action From Final Result Kind
|
||||
|
||||
The system SHALL distinguish the selected Suno action from the normalized result kind used by task storage and UI rendering.
|
||||
|
||||
#### Scenario: Lyrics action completes without an audio URL
|
||||
|
||||
- **GIVEN** the selected Suno action is `lyrics`
|
||||
- **WHEN** the provider returns a completed task with text output but no playable audio URL
|
||||
- **THEN** the task SHALL still be considered successfully completed
|
||||
- **AND** the normalized result SHALL be marked as a lyrics result rather than an audio asset
|
||||
- **AND** the system SHALL not fail only because `audio_url` is absent
|
||||
|
||||
#### Scenario: Music action continues to produce audio assets
|
||||
|
||||
- **GIVEN** the selected Suno action is `music`
|
||||
- **WHEN** the provider returns generated clips with playable audio URLs
|
||||
- **THEN** the normalized result SHALL remain an audio result
|
||||
- **AND** the existing audio insertion and playback paths SHALL remain available
|
||||
|
||||
### Requirement: Scope User-Facing Parameters By Suno Action
|
||||
|
||||
The system SHALL expose only the parameters relevant to the currently selected Suno action.
|
||||
|
||||
#### Scenario: Music-only parameters are hidden in lyrics mode
|
||||
|
||||
- **GIVEN** the user has selected the lyrics action in the audio flow
|
||||
- **WHEN** the request form is rendered
|
||||
- **THEN** the UI SHALL not present music-only submit controls such as `mv`, `title`, `tags`, `continue_clip_id`, or `continue_at`
|
||||
- **AND** the primary lyrics flow SHALL not require the user to fill any of those music-specific fields
|
||||
|
||||
#### Scenario: Music mode preserves existing Suno parameter controls
|
||||
|
||||
- **GIVEN** the user has selected the music action in the audio flow
|
||||
- **WHEN** the request form is rendered
|
||||
- **THEN** the UI SHALL continue to expose the existing Suno music parameters supported by the binding
|
||||
@@ -0,0 +1,27 @@
|
||||
## ADDED Requirements
|
||||
|
||||
### Requirement: Insert Generated Lyrics Onto The Canvas As Text Content
|
||||
|
||||
The system SHALL insert generated lyrics results onto the canvas as text-oriented content instead of audio components.
|
||||
|
||||
#### Scenario: Manual canvas insertion formats lyrics as user-readable text
|
||||
|
||||
- **GIVEN** a completed lyrics task includes generated `text` and optional `title` or `tags`
|
||||
- **WHEN** the user manually inserts that result onto the canvas
|
||||
- **THEN** the system SHALL generate a text or markdown representation that includes the lyrics body
|
||||
- **AND** SHALL include the title and tags when available
|
||||
- **AND** SHALL use the existing text insertion capability rather than the audio node insertion capability
|
||||
|
||||
#### Scenario: Auto insert uses the same lyrics text rendering path
|
||||
|
||||
- **GIVEN** a lyrics task is configured for automatic insertion
|
||||
- **WHEN** the task completes successfully
|
||||
- **THEN** the automatic insertion flow SHALL route the result through the same text-oriented insertion path
|
||||
- **AND** SHALL not create an audio node or audio playback component for the lyrics result
|
||||
|
||||
#### Scenario: Plain text fallback remains available when markdown card parsing is not applicable
|
||||
|
||||
- **GIVEN** a generated lyrics payload cannot be meaningfully parsed into markdown cards
|
||||
- **WHEN** the system inserts the result onto the canvas
|
||||
- **THEN** the canvas SHALL still insert the lyrics as readable plain text
|
||||
- **AND** SHALL not fail the insertion only because card parsing is unavailable
|
||||
@@ -0,0 +1,37 @@
|
||||
## ADDED Requirements
|
||||
|
||||
### Requirement: Represent Lyrics Tasks In The Queue Without Audio Asset Assumptions
|
||||
|
||||
The task queue SHALL support completed Suno lyrics tasks even when the result does not contain a media URL.
|
||||
|
||||
#### Scenario: Queue item shows lyrics-specific summary after completion
|
||||
|
||||
- **GIVEN** a Suno lyrics task has completed successfully
|
||||
- **WHEN** the task is rendered in the queue
|
||||
- **THEN** the queue SHALL show that the task action is lyrics generation
|
||||
- **AND** SHALL display available semantic fields such as title, tags, or a lyrics excerpt
|
||||
- **AND** SHALL not render the task as if it were a playable audio card
|
||||
|
||||
#### Scenario: Lyrics task survives persistence and refresh recovery
|
||||
|
||||
- **GIVEN** a completed lyrics task has been written to browser storage
|
||||
- **WHEN** the application restores tasks after a refresh or session recovery
|
||||
- **THEN** the restored task SHALL keep its normalized lyrics result fields
|
||||
- **AND** the queue SHALL still be able to show the same lyrics summary and status
|
||||
|
||||
### Requirement: Provide Lyrics-Specific Queue Actions
|
||||
|
||||
The task queue SHALL expose follow-up actions appropriate for lyrics results.
|
||||
|
||||
#### Scenario: Copy lyrics text from the queue
|
||||
|
||||
- **GIVEN** a completed lyrics task exists in the queue
|
||||
- **WHEN** the user chooses a copy action
|
||||
- **THEN** the system SHALL copy the generated lyrics text rather than trying to open or download an audio URL
|
||||
|
||||
#### Scenario: Insert lyrics into the canvas from the queue
|
||||
|
||||
- **GIVEN** a completed lyrics task exists in the queue
|
||||
- **WHEN** the user chooses to insert the result
|
||||
- **THEN** the queue SHALL route the insertion through the text insertion path
|
||||
- **AND** SHALL not attempt to insert an audio node for that task
|
||||
Reference in New Issue
Block a user