Files
openmotion/docs/provider-settings.md
Tom Huang 61ee4787c8 Unify Home navigation, provider settings, and local Agent selection (#393)
* 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>
2026-11-15 11:56:47 +08:00

8.8 KiB

Application settings and model connections

The application shell keeps navigation in the top bar, editor/project controls in the left rail and the current product surface in the center. Desktop projects are collapsible; narrow screens use a drawer. Opening settings preserves the editor instance and pauses preview playback. The bottom account menu opens Account, Subscription & usage, Appearance, Help and Settings. General includes language, connection setup and keyboard shortcuts; Privacy & data retains telemetry preference and diagnostic export. About links to documentation, source, issues and acknowledgements.

Providers and models

The settings directory combines the dedicated media adapters, local Codex, an account connection and 68 provider presets. It supports provider search, configured/custom/local/multimodal/media/language filters, masked saved keys, editable API base URLs, enablement, custom providers, remote catalogue sync, exact-ID manual models, model search, combined type/capability/input/status/source filters, sorting, collapsible groups and defaults. Provider status and protocol filters combine with category and search. Filter selections have immediate results, removable chips and clear-all. OpenAI-compatible, Anthropic and Google Gemini catalogue protocols retain their respective authentication and pagination. A provider can expose multiple capabilities; classification uses explicit catalogue output metadata, not guesses from model names. A model without output metadata is classified as language until the user adds a documented capability explicitly.

Connection Configuration and discovery Executable media
fal.ai, Atlas Cloud, WaveSpeedAI Existing keys, model catalogues and references Their existing image/video/audio adapters
OpenDesign Cloud Separate workspace key and public HTTPS gateway origin Existing image/video/speech contract
OpenAI-compatible API Versioned base URL, Bearer key, /models or manual entries /images/generations and binary /audio/speech; voice required for speech
Anthropic / Google Gemini API Provider-specific catalogue auth and pagination Catalogue/default configuration only; no generic media adapter
OpenDesign account Browser authorization, subscription/balance, remote language/media catalogues Connector image/video/speech tasks
Local Codex Existing CLI installation/login/capability detection Existing native image capability
Dedicated OAuth, cloud IAM or local-network services Presets are visible with a dedicated-integration notice Not implied by a preset; no unimplemented login or local API is presented as working

Language, embedding and reranker defaults are saved for Agent integrations; this change does not create a conversational Agent runner. The public media Tool accepts the original dedicated provider IDs, account, and registered compatible IDs. Its inspect action returns reference URIs; references explain exact supported operations. Existing tasks remain project-bound and idempotent. Configured media defaults fail explicitly if unavailable, without silently selecting another paid provider.

Custom base URLs must be public HTTPS and retain path prefixes. DNS is pinned and checked before credentialed requests, and authenticated redirects are rejected. Changing the API origin requires entering a replacement key. Compatible jobs capture a connection revision and fail before submission if the key, endpoint or protocol changes, or the model is disabled/removed. Removing a provider clears its saved key and models without removing existing project media. A stale media default remains visibly unavailable until explicitly reset or replaced.

Model editing includes display name, group, type, reasoning/tool capabilities, vision/audio/video inputs, context window and maximum input/output token counts. Token presets fill exact numeric values; manual values are accepted. Token limits describe provider capabilities and do not change upstream quotas. Changing a compatible model's type makes its local definition manual so future catalogue sync retains the correction. Metadata overrides survive refresh, and clearing a token limit is explicit.

Default request parameters are JSON objects validated before saving; reserved identity, prompt and credential fields are rejected. Dedicated, compatible, account and Codex media paths merge saved defaults with per-request parameters, with request values taking precedence. Existing adapter validation and protocol restrictions still apply. Language metadata is saved for integrations and does not override an external CLI Agent's parameters. Local Agent download, sign-in, model selection and default selection use the separate Local Agents flow.

Account and subscription

Sign in with OpenDesign prepares the versioned @powerformer/vela-cli@0.1.10 connector outside the checkout, under the installation data directory. It can reuse the exact installed CLI version or an explicit OPENMOTION_ACCOUNT_CLI executable. Automatic preparation uses npm with lifecycle scripts disabled. The connector is installed on demand, not included in plugin/npm application artifacts. Its upstream availability and platform support are separate installation requirements.

The connector's browser authorization uses its stdin-v1 completion receipt. OpenMotion accepts credentials only after the CLI persists them, and records a new opaque session identity. Activation URLs must use HTTPS on open-design.ai or a subdomain. Authorization is cancellable and expires after ten minutes. The CLI receives an installation-owned AMR_HOME; credentials are never copied from another application's profile. Keys supplied by unrelated Vela environment variables are removed from the subprocess environment.

Successful login registers the account provider, synchronizes its enabled models and reads subscription/available USD balance. The subscription action opens the account console; checkout is not reimplemented. Billing failures remain explicit and do not fabricate a plan or credit balance. Logout removes this installation's local session and cached account models. Queue entries capture the account identity; another identity cannot inherit queued work. The connector submits once, saves the remote task ID, polls that task and validates output through the existing import pipeline. Local cancellation does not establish remote cancellation or refund.

Storage and verification

Connection metadata and model defaults live in model-gateway/connections.json; keys live in model-gateway/connection-secrets.json. Legacy media credentials remain in model-gateway/secrets.json. Account runtime, CLI profile, session marker and model cache live under account/. New private files use 0600 and private directories use 0700. This is local file storage, not an OS keychain. API responses, project exports and distribution artifacts contain no credentials.

Deterministic tests cover protocol/authentication mapping, model pagination, failed-sync retention, private credential responses, exact-once generation, connection changes, account receipt/cancellation, billing failure, model entitlement flags and media import. Real Chrome checks exercise the local HTTP server, shell/settings navigation, custom provider CRUD, synchronization/defaults, account subprocess fixture, themes, narrow layouts, opened menus/dialogs and floating Toasts. Live account login, subscription entitlement, provider-specific execution and human visual acceptance remain separate checks.

Sources and acknowledgements

Preset metadata is adapted from the independently MIT-licensed Cherry Studio provider registry; see the notice and license. The model editor and filtering interaction also follow the model classification and token fields contracts. No upstream application UI code is copied. Account behavior follows OpenDesign source and the pinned connector command contract. Endpoint adaptations were checked against PPIO and Vercel's OpenAI API. The compatible API guide and account guide carry operation-specific references.