feat: Meta Model API preset — Muse Spark, day one#69
Merged
Conversation
Meta opened its first paid API this week (public preview): the Meta Model API serving Muse Spark 1.1, OpenAI-compatible. yoagent supports it via the compat provider with a one-preset addition. - ModelConfig::meta(id, name): base https://api.meta.ai/v1, protocol OpenAiCompletions, 1,048,576 context / 131,072 max output, launch pricing ($1.25/M in, $4.25/M out) pre-configured for session_cost_usd and the telemetry cost_usd span field. - OpenAiCompat::meta(): max_completion_tokens; conservative flags (reasoning_effort/streamed-usage off) until Meta documents them on the chat endpoint. - Key resolution: META_API_KEY preferred, Meta's documented MODEL_API_KEY accepted (registry table + hint updated). - CLI example: --provider meta (default model muse-spark-1.1). Tests: preset values pinned to the launch specs (URL, window, pricing, conservative flags); env resolution incl. preference order. Docs: model-presets table row, README provider list, CHANGELOG. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Fact-check against Meta's official chat-completions schemas and pricing page corrected two false assumptions and confirmed the rest: - reasoning_effort IS documented (none..xhigh, server default medium) — supports_reasoning_effort now true, so ThinkingLevel tunes it. Preset docs note the gotcha: Off omits the field, which means Meta's medium default applies, not "no reasoning". reasoning: true accordingly; README caveat updated (openai/deepseek/meta opt in). - Cached-input pricing added: $0.15/M per the official pricing page (was 0.0 while the CHANGELOG claimed "launch pricing pre-configured") — cache-heavy workloads no longer undercount spend. Test pins it. - Streamed usage is documented (stream_options.include_usage) — flag and comment now say so honestly. - 128K max output softened to "per Meta's integration examples (no official model card yet)"; US-only public preview noted with a date anchor in the preset docs + presets table. - Registry env test hardened (clears a developer-shell META_API_KEY first); comment ages better. - CLI example: qwen-style special case so --provider meta actually reads META_API_KEY / MODEL_API_KEY instead of demanding ANTHROPIC_API_KEY. Verified clean by the fact-checker: base URL, model id casing, 1,048,576 context, $1.25/$4.25 pricing, MODEL_API_KEY attribution wording, and MaxCompletionTokens (Meta deprecates max_tokens — the code reviewer's concern resolved in our favor by the official schemas). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Meta opened its first paid API this week (public preview): the Meta Model API serving Muse Spark 1.1, explicitly OpenAI-compatible. This adds day-one support — exactly what the compat-provider + preset architecture is for (~30 lines of substance).
Details
https://api.meta.ai/v1· 1,048,576 context / 131,072 max output · launch pricing ($1.25/$4.25 per M) pre-configured, sosession_cost_usd()and the telemetrycost_usdspan field work out of the boxreasoning_effort/streamed-usage off) until Meta documents them on the chat endpoint; tool calling +json_schemastructured outputs ride the standard OpenAI-compat pathMETA_API_KEY, accepts Meta's documented (generic)MODEL_API_KEYTests (2 new, 392 total green)
Preset pinned to the launch specs (URL, window, pricing, flags) · env resolution incl. preference order.
Verification
clippy
-Dwarnings --all-featuresclean · 392 passed / 0 failed · docs clean.🤖 Generated with Claude Code