* Fix cloud media save retry after CAS write failure
* Address review feedback on retry_save state transition, cancellation, requestId, and docs
- Transition retry_save rows atomically from failed to queued (stage=saving) before enqueuing so cancel before worker pickup marks the row cancelled and prevents worker claim.
- Require and propagate caller requestId for BullMQ jobId deduplication (clearing stale terminal BullMQ entries on explicit re-retry).
- Finalize cancelling rows cleanly to cancelled when CAS throws after a missed Redis cancel notification instead of stranding in cancelling or publishing a false failed event.
- Update skills/openmotion-media/references/jobs.md to document Cloud gateway recovery for retry_save.
* Harden cancel/retry_save concurrency, claim-epoch dedupe, and gateway docs
- Guard cancelJob transitions with optimistic state checks and check cancelled state in the worker commit transaction.
- Scope retry_save BullMQ jobId by claimToken epoch and record retrySaveRequestId so same-requestId retries recover cleanly after API restarts and Studio repeated retries never collide with a still-finishing BullMQ active job.
- Guard upstream failed poll transitions against overwriting cancelling rows.
- Update docs/model-gateway.md retry_save Cloud recovery guidance.
* Guard retry_save enqueue-failure rollback against racing replays
* fix(cloud): guard retry_save rollback by state/stage and clear failureStage on resume/completion
* fix(cloud): return 400 for retry_save missing requestId and align timeout hint
---------
Co-authored-by: 罗高 <luogao@users.noreply.github.com>
* Share one OpenDesign sign-in across all workspaces on a computer
Each data directory used to keep its own connector credentials, so a Studio
opened on its own and an Agent host started with another MOTION_DATA_DIR,
installation or channel signed in separately. The account (credentials,
session, model catalogue and private connector) now lives in one per-user
directory; MOTION_ACCOUNT_DIR overrides it and temporary workspaces stay
isolated. An existing workspace sign-in moves there once. Cached plan and
catalogue are tied to the key and session they were read for, and the shared
connector installation runs npm once under a process lock.
* Keep connectors per workspace and never resurrect a signed-out account
Connector versions differ between channels, so each workspace keeps its own
runtime and a workspace signed in through the shared account prepares it on
first use. A legacy sign-in moves only into a shared directory that has never
held an account, under a process lock, and the same directory reached through
another spelling is recognised by device and inode. Temporary-directory checks
resolve Windows short names, and a catalogue read for an older session is not
written over a newer one.
* Bring along a workspace sign-in made after the shared account's last change
A shared directory that was signed out earlier no longer discards a newer
sign-in another workspace made with an earlier release; only sign-ins older
than the shared directory's last sign-in, cancel or sign-out are dropped.
* Make legacy account migration atomic, align storage docs, and avoid personal paths in tests
- Stage legacy account files to temporary paths with 0600 permissions before renaming them into the shared directory, rolling back any committed file on failure so the workspace keeps its only copy and no shared marker is left behind.
- Add regression tests covering copy failures on both empty shared directories and directories with an existing sign-out marker.
- Replace personal-path-shaped strings in sharedAccountDirectory tests with synthetic paths to satisfy the release source privacy scan.
- Update model-gateway, provider-settings, architecture and account skill docs to separate workspace-local account/runtime from the per-user account directory.
* fix(media): enforce OpenDesign parameter contracts, CLI errors, and first-frame references
- Validate paired aspect_ratio/resolution and mutually exclusive size/output parameters for OpenDesign account and Cloud image models even when capabilities.profiles are absent.
- Classify local vela CLI flag errors without HTTP status codes as invalid_request instead of misreporting network or sign-in failures.
- Expose maxInputImages on OpenDesign account video models and forward first-frame images via `vela video gen --first-frame`.
- Enforce the 2 MiB OpenDesign reference image upload limit before queueing account or Cloud media jobs.
- Reset draft.parameters on model or modality switches in AssetComposer, and restrict reference pickers and "Use as reference" / "Edit as new version" actions to image assets.
- Update provider/assets/architecture documentation and add backend and Studio regression tests.
Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
* docs(mcp): align FAQ, schemas, and docs with account first-frame and 2 MiB limit
- Update the MCP Connect reference-image FAQ and all 10 locale translations in studio/src/i18n/mcp-ui.json to reflect OpenDesign account first-frame video support (one image) and the 2 MiB upload limit.
- Propagate the 2 MiB OpenDesign reference image upload limit (while keeping 20 MB for other local adapters) to shared/phase1-tools.ts, mcp-tools.ts, docs/model-gateway.md, and skills/openmotion-media/references/jobs.md.
- Extend tests/mcp-onboarding.test.ts to verify the updated FAQ and schema copy.
Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
---------
Co-authored-by: Awek-015 <zhouhaoran@refly.ai>
Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
Reverts dc01084107 (#552).
Withdraw Fish Audio, MiniMax Speech, and the saved-voice UI and MCP action. Preserve the existing MCP tools, provider configuration, audio-version editing, and streamed response limits. Existing audio files and saved voice records remain on disk.
* docs(skills): drop recreate copies of shared reference-video rules
The recreate entry and its rebuild reference repeated three sentences that
the shared production reference-video method already owns: the
cover-image/unreachable-link rule, the blocked-not-passed rule for missing
runtime tools, and the bounded repair rule. Keep them only in the shared
reference and link to it.
- recreate SKILL.md keeps the links and drops the restated sentences.
- rebuild.md sends an explicitly requested revision to verify.md.
- verify.md links the shared bounded repair guidance directly instead of
going through rebuild.md.
- The layering test now rejects these phrases in recreate and
video-to-template start/rebuild documents.
No routing, Tool or runtime behavior changes.
Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
* docs(skills): move provider guides into the media Skill
Provider guides now live under skills/openmotion-media/references/providers
and are canonical media workflow sections. The production sections keep the
same names and return the same bodies so older resource URIs keep working.
media_use inspect/reference and the HTTP reference route return media URIs.
Request templates are written as openmotion_assets_use arguments, so the
job procedure no longer needs a conversion section. Shell wire examples move
to the add-byok-provider contributor Skill. The Cloud recovery rules and the
MCP instructions point to the single job procedure instead of repeating it.
Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
* docs(skills): keep preview handoff and project loop rules in native.md
The creative entries, the production entry, the shared context and the
runtime adapter now link to the editable preview handoff instead of
restating when and how to open it. Recreation no longer repeats the
import/save/conflict loop, and template delivery no longer repeats the
paused zero-second rule; its test now checks that it links instead.
Codex-specific calls (open_in_codex, IAB visibility, navigate_to_codex_page)
move into one "Codex host calls" subsection so the handoff steps read the
same for every host.
Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
* docs(skills): stop restating entry routing outside the entries
The shared context keeps only the rule for changing entries mid-task and
points to the Skill descriptions and the production navigation table for
each entry's scope. AGENTS.md and docs/skills.md link to the routing summary
instead of repeating the per-entry rules.
Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
* docs(skills): give each entry its own rule for generated media
The media planning reference no longer names the creative entries or
carries their per-route rules. Its motion-first paragraph is split by
owner: the original-film plan moves to director, the keep-the-cut rule for
reference footage moves to recreate, and the replace-in-place rule moves to
template-to-video and production. Planning keeps the mechanism (the calling
entry sets each asset's role) and the default for standalone requests.
Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
* docs(skills): share first-run delivery rules from the template catalog
The first-run reply, next-step invitation and failure rules apply to both
the template and the recreation route, so they move from the template
entry's first-use reference into the shared templates reference. Recreation
no longer reads another entry's internal file; template-to-video keeps its
first-run execution steps and links to the shared delivery section.
Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
* docs(skills): drop director forwarders and shorten connection rules
The shared context now keeps only the connection rules that are not in
production.md (announce OpenMotion, report tool use only after a host call,
disclose failures early, keep planning during recovery) and links to the
diagnosis steps. The capability-priority section links to the material
tool policy instead of restating it, and both sections are now Chinese like
the rest of the page.
The director motion-review and production-decisions files only forwarded to
the production bodies. Remove them; the workflow aliases still resolve the
old director resource URIs and links. docs/skills.md records when the
openmotion-reference-video compatibility entry can be removed.
Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
* docs: count sixteen public MCP names in translated READMEs and Skills
The English README already lists sixteen registered names including one
compatibility alias. Bring the Chinese and Japanese READMEs, docs/skills.md
and the media kit in line, and stop the video-to-template Skill from naming
a stale tool count.
Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
* docs(skills): remove the last restated rules between Skill files
A shingle scan across skills/ found a few rules still written out in two
places. Keep each in one owner and link to it:
- The shared context states once which entry owns review and export scope
(now in Chinese); native.md links to it.
- edit.md links the continuing-edit preview rule instead of repeating its
show-or-queue sentence.
- The director and production entries drop the read-before-write sentence
that the shared context already requires.
- video-to-template links the shared fidelity check without repeating its
last sentence; recreate's verify step points to the generated-shot match
standard in the entry.
- The media Skill description no longer names the video entries.
Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
* test(skills): guard Skill layering against restated rules
Add checks that the media Skill names no video entry, that one entry links
to another creative entry only through its SKILL.md, that no twelve-token
run of text is copied between Skill files (provider guides share a template
and are exempt from each other), and that each moved rule still has its
owner heading and the entry links that point to it.
Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
* docs: describe the removed director forwarders and the sixteen-name MCP surface
The architecture row no longer says old director Markdown paths forward to
the production bodies; the resource URIs and old links still resolve, but
the forwarding files are gone. The media kit now gives one tool surface:
sixteen registered names, with generation reachable through the public
media and asset tools.
Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
---------
Co-authored-by: Awek-015 <zhouhaoran@refly.ai>
Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
OpenDesign speech models elevenlabs-v3 and byteplus-tts-2 now offer voices checked against the media API, defaulting to the first. The adapters fill the default when no voice is given, without writing it into saved model defaults. Other non-empty voice IDs still pass through; other speech models keep a required voice ID.
* Support OpenDesign Cloud edits, image-to-video and speech timestamps
The Cloud adapter only sent text requests, so edit-capable image models,
first-frame video and returned speech timings were unreachable through the
MCP Tools even though the Cloud API supports them.
- Discovery marks edit-capable image models with supportsImageReference
and maxInputImages, video models with maxInputImages, and returns the
provider's native options as nativeOptions.
- Queued references are uploaded (create, credential-free PUT, commit) and
sent to /images/edits, or as one first_frame on /videos/tasks; the
per-model maximum replaces the fixed one-reference rule.
- Speech result metadata (alignment, word timings) is kept as job.result
and returned by status.
- Video jobs get a 30-minute local timeout; Wan can exceed 15 minutes.
- Read-only polling and media downloads retry transient failures, so a
dropped connection no longer discards a paid, finished task.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* Address review: keep key verification, per-model reference caps and agent guidance accurate
- A storage rejection of the presigned reference upload no longer marks
the Cloud API key rejected.
- References are limited by the selected model (up to 16), not a fixed
eight, in both the library validation and the Tool schema.
- Video discovery exposes one input image, matching the implemented
first-frame role; the provider maximum stays in nativeOptions.
- Download failures keep their HTTP status, and retries cover only
network errors, timeouts, 429 and 5xx.
- MCP initialization, the connection guide and the Tool/architecture docs
describe per-model image references and first-frame video.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* Clamp video references to one first frame and keep referenceAsset image-only
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* Resume original Cloud media tasks and align reference consumers
Add explicit guarded recovery without upload or paid resubmission, preserve redacted result metadata, save every output, and apply model reference limits consistently across MCP and Studio.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* Keep cancelled and Cloud-terminal jobs out of resume
- A save-only retry that finds no retained output now leaves a cancelled
job cancelled instead of turning it into a resumable failure.
- Jobs recorded by the earlier adapter carry a confirmed Cloud failure or
cancellation only in their error text; treat that as remote-terminal.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* Persist legacy Cloud-terminal provenance before save-only retry rewrites the error
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* Track the resume asset action and reuse the shared reconnecting label
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
---------
Co-authored-by: Awek-015 <zhouhaoran@refly.ai>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Expose project reference images through the public media tool and route Cloud speech/music by the selected model. Preserve native fal sound-effect text inputs, including both ElevenLabs SFX V3 endpoint spellings. Add regression coverage and localized guidance.
* refactor: centralize provider registration and configuration
* fix: hide text-only providers in settings
* test: keep the OpenAI provider fixture visible in navigation coverage
The provider list now hides text-only entries. The navigation regression
fixture overrode the OpenAI preset with text-only kinds and no media models,
so the provider disappeared from the list and the click target no longer
existed. Mirror the registry preset (text, image and audio kinds) so the
history restoration coverage still exercises a visible provider.
Generated-By: looper 0.16.2 (runner=fixer, agent=pi)
* fix(providers): expose only public connection fields
* test: handle macOS process reaping in cancellation coverage
---------
Co-authored-by: 罗高 <luogao@users.noreply.github.com>
* Save generated media to workspace assets with local save recovery
* Fix POSIX cancellation test state and fixture publication races
* Align unified asset schema checks and recovery documentation
* End unrecoverable save retries as terminal task failures
When the retained outputs manifest is missing, unreadable or no longer
references staged bytes, retry_save previously threw without persisting
anything, so a failed job kept savePending and offered a retry that could
never succeed.
- Validate the retained manifest and its staged bytes before queueing a
save retry.
- Record a terminal failure and clear savePending when nothing is left to
save.
- Apply the same check when a claimed recovery worker starts, so a
vanished manifest cannot recreate the stuck state.
- Assert the cleared state alongside the rejection, and document the
terminal outcome.
Generated-By: looper 0.16.2 (runner=fixer, agent=pi)
* Stop offering save retries for unavailable retained outputs
* Use decodable account music fixtures for automatic asset saving
---------
Co-authored-by: 罗高 <luogao@users.noreply.github.com>
* feat: add a shared asset workspace with generation and version history
Unify direct model jobs and embedded Codex conversations around shared asset operations exposed through MCP. Add reusable media uploads, pinned references, version browsing, trash undo, and verified project imports.
Refine compact creation controls, persistent task history, solid menus, and stable resizable preview layouts. Integrate asset navigation with main's history and deep links, and align onboarding, tracking, documentation, and distribution.
* test: exercise openmotion_assets in the packaged phase-one e2e
The phase-one profile now exposes openmotion_assets, but the packaged
distribution smoke test still asserted that every public Tool was called
without ever invoking it, so the Distribution regression lane failed.
Import a real audio file into the library, read it back by asset and
version, list it by modality, and import the pinned version into the
project so the new Tool is covered end to end.
Generated-By: looper 0.16.2 (runner=fixer, agent=pi)
* fix: preserve asset request receipts and pending draft edits
Exercise asset library replay in the packaged MCP smoke test and align compact control documentation with verified shared geometry.
* Unify Studio navigation, provider settings, and local Agent workflows
* Serve the public provider notice from the editor file handler
The provider icon set added by this branch publishes
packages/design-system/providers/NOTICE.md through publicDesignFiles, but
serveEditorFile rejected .md because its MIME table only knew application
assets. The distribution regression test requests every public design file
and got 404 for the notice, so the attribution file was unreachable in the
editor package.
Map .md like the existing application server does (text/plain, UTF-8) so
the published notice is served with its bytes intact.
Generated-By: looper 0.16.2 (runner=fixer, agent=pi)
* Include the provider icon manifest in the bundled adapter fixture
export-adapters.ts and the bundled runtime import
packages/design-system/index.js, which now also imports provider-icons.js to
publish the provider artwork. The adapter fixture copied every runtime file
the export reads except that new module, so the bundled launch failed with
ERR_MODULE_NOT_FOUND for provider-icons.js in the distribution regression
job.
Copy the icon manifest into the fixture alongside index.js, matching the
runtime distribution list that already ships it.
Generated-By: looper 0.16.2 (runner=fixer, agent=pi)
---------
Co-authored-by: pftom <pftom@pftomdeMacBook-Pro.local>
Co-authored-by: 罗高 <luogao@users.noreply.github.com>
Add editor BYOK settings, provider reference guides and the media-use MCP tool. Preserve inline video work rounds and shared design-system integration. All eight checks passed on the exact reviewed integration head.
* docs(motion): record latest upstream main synchronization
* docs: require English commits and repository collaboration
* docs: replace mandatory change logs with architecture review