Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 13 additions & 14 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -634,21 +634,12 @@ if(EXISTS "${AI_MUSIC_GENERATION_SCRIPT}")
)
endif()

set(AI_OPENSTUDIO_ACE_RUNNER_SCRIPT "${CMAKE_CURRENT_SOURCE_DIR}/tools/openstudio_ace_runner.py")
if(EXISTS "${AI_OPENSTUDIO_ACE_RUNNER_SCRIPT}")
set(AI_STABLE_AUDIO_GENERATION_SCRIPT "${CMAKE_CURRENT_SOURCE_DIR}/tools/stable_audio3_generate.py")
if(EXISTS "${AI_STABLE_AUDIO_GENERATION_SCRIPT}")
openstudio_copy_runtime_file(
"${AI_OPENSTUDIO_ACE_RUNNER_SCRIPT}"
"scripts/openstudio_ace_runner.py"
"Copying OpenStudio ACE runner script to output directory"
)
endif()

set(AI_OPENSTUDIO_ACE_BACKEND_DIR "${CMAKE_CURRENT_SOURCE_DIR}/tools/openstudio_ace_backend")
if(EXISTS "${AI_OPENSTUDIO_ACE_BACKEND_DIR}")
openstudio_copy_runtime_directory(
"${AI_OPENSTUDIO_ACE_BACKEND_DIR}"
"scripts/openstudio_ace_backend"
"Copying OpenStudio ACE backend package to output directory"
"${AI_STABLE_AUDIO_GENERATION_SCRIPT}"
"scripts/stable_audio3_generate.py"
"Copying Stable Audio 3 generation helper script to output directory"
)
endif()

Expand Down Expand Up @@ -708,6 +699,14 @@ openstudio_remove_runtime_file(
"scripts/openstudio_ace_backend/parity_debug.py"
"Removing ACE-Step parity backend helper from output directory"
)
openstudio_remove_runtime_file(
"scripts/openstudio_ace_runner.py"
"Removing legacy OpenStudio ACE split runner from output directory"
)
openstudio_remove_runtime_path(
"scripts/openstudio_ace_backend"
"Removing legacy OpenStudio ACE split backend from output directory"
)
set(LEGACY_EXTERNAL_ACE_RUNNER_PATH "scripts/co")
string(APPEND LEGACY_EXTERNAL_ACE_RUNNER_PATH "mfy_ace_runner.py")
openstudio_remove_runtime_file(
Expand Down
517 changes: 189 additions & 328 deletions README.md

Large diffs are not rendered by default.

199 changes: 158 additions & 41 deletions Source/AITrackEngine.cpp

Large diffs are not rendered by default.

16 changes: 13 additions & 3 deletions Source/AITrackEngine.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ struct AIGenerationProgress
juce::String message;
juce::String backend { "unknown" };
juce::String outputFile;
juce::String modelId;
juce::String workflowId;
juce::String sourceClipId;
juce::String error;
double elapsedMs = 0.0;
double heartbeatTs = 0.0;
Expand Down Expand Up @@ -47,7 +50,8 @@ class AITrackEngine
AITrackEngine() = default;
~AITrackEngine();

bool startGeneration(const juce::String& workflowId,
bool startGeneration(const juce::String& modelId,
const juce::String& workflowId,
const juce::String& paramsJson,
const juce::File& outputDir);

Expand All @@ -58,16 +62,22 @@ class AITrackEngine
private:
juce::File getUserDataRoot() const;
juce::File getUserRuntimeRoot() const;
juce::File getStableAudioRuntimeRoot() const;
juce::File getMusicGenerationCheckpointRoot() const;
juce::File getStableAudioModelRoot() const;
juce::File findPython() const;
juce::File findStableAudioPython() const;
juce::File findScript() const;
juce::File findStableAudioScript() const;
void cleanupLegacyWorkerProcesses(const juce::File& python, const juce::File& script) const;
bool ensureWorkerAvailable(const juce::File& python, const juce::File& script);
bool sendGenerateRequest(const juce::String& workflowId,
bool ensureWorkerAvailable(const juce::File& python, const juce::File& script, const juce::String& modelId);
bool sendGenerateRequest(const juce::String& modelId,
const juce::String& workflowId,
const juce::String& paramsJson,
const juce::File& outputFile);
void launchGenerationTask(const juce::File& python,
const juce::File& script,
const juce::String& modelId,
const juce::String& workflowId,
const juce::String& paramsJson,
const juce::File& outputFile);
Expand Down
Loading
Loading