Commit 1d28d6b
feat: runtime provider configuration API (BYOK setup), rebased on main
Rebased onto upstream main (post cloud-video-gen merge) as a single clean
commit; adapts to the new provider-kind matrix (LiterLLM, LocalAsr,
LocalImageGen, LocalVideoGen, CloudVideoGen dialect) and the
associated-function server style.
- Engine::build_provider extracted from startup assembly; shared with
Engine::add_provider_config, which registers a provider at runtime behind
an RwLock (replacing same-name entries); find_provider, routing_providers,
and discover_all all consult the runtime list, so a registered provider
is routable and discoverable immediately
- SDK: GET/POST /v1/config/providers with masked listing derived from live
capability cards; add validates (name/kind/api_key), appends a
[[providers]] entry to the resolved config file for restart survival,
then registers + refreshes. ProviderConfig::provider_kind made pub so
external API layers can validate before calling into the engine.
- EngineConfig::resolved_path: MOFA_ENGINE_CONFIG env > ./config.toml >
~/.config/mofa-engine/config.toml.
- Tests: factory smoke over the full kind matrix + full runtime registration
(discoverability, invoke routing, disabled rejection) against a live mock
endpoint.
Co-Authored-By: Claude <noreply@anthropic.com>1 parent 99e6036 commit 1d28d6b
17 files changed
Lines changed: 2340 additions & 118 deletions
File tree
- .claude
- .idea
- docs
- mofa-engine-core
- src
- mofa-engine-sdk/src
- weekly-reports
Binary file not shown.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
0 commit comments