Meta Model API (Muse Spark, Muse Wonder) as an AI provider

未关闭
#4,070 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 1 天内回复

还没有人认领这个 Issue。

评估

难度
3/5
预计耗时
1-2 天
新手友好度
66/100
Issue 类型
功能
描述清晰度
描述清楚
活跃度
活跃
技术栈
swift
领域
ai, desktop

调研方向

Start in apple/TablePro/Models/AI/AIProviderPreset.swift and read the existing Requesty preset and the model fetching and chat streaming paths it uses. Check the Meta API details in the issue, especially the default model and filtering fetched models to chat models. Done when the Meta preset works with authentication, model selection, reasoning, tool calls, and streaming as described.

由索引模型根据 Issue 内容生成。

描述

enhancement platform-macos
Problem

Meta's Muse models (Muse Spark, Muse Wonder) are served by the Meta Model API. Using them today means adding a Custom provider and typing the endpoint and model ID by hand.

Proposed solution

Add Meta as an AIProviderPreset (apple/TablePro/Models/AI/AIProviderPreset.swift), next to Requesty. No new AIProviderType case.

API facts from https://dev.meta.ai/docs/:

  • Base URL https://api.meta.ai/v1, OpenAI-compatible POST /v1/chat/completions. Preset endpoint is https://api.meta.ai.
  • Auth: Authorization: Bearer <key>. Keys from https://dev.meta.ai/api-keys/.
  • Bad, missing or revoked key returns 401 (invalid_api_key), so rejectsBadKeyWithForbidden: false. 403 means the key lacks access to a model.
  • GET /v1/models lists models, newest first.
  • Chat models: muse-spark-1.3 (recommended), muse-spark-1.2, muse-spark-1.1, muse-wonder-1.0 (preview). 1,048,576 token context.
  • -contributor variants are cheaper but Meta may train on the content.
  • reasoning_effort accepts minimal, low, medium, high, xhigh, max. none returns 400. Our ReasoningEffort wire values all fit.
  • Tool calling and SSE streaming are supported.
  • Public preview, availability varies by country.

To check while building:

  • Default model is muse-spark-1.3, not the first fetched model.
  • Fetched list includes non-chat models (muse-image-1.0, muse-voice-transcribe-1.0, sam-3.1). Keep them out of the chat model picker.
  • Server accepts stream_options.include_usage.
  • Streamed tool-call chunks parse with the current OpenAI-compatible decoder.
Alternatives considered

Custom provider with https://api.meta.ai works if the user knows the model ID. OpenRouter also serves Muse Spark.

主要语言
Swift
星标
6.2k
派生
412
平均合并
3 小时 56 分钟
30 天内合并 PR
669

环境准备

这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

TableProApp/TablePro 的其他 Issue

查看 TableProApp/TablePro 的全部 Issue

相似的 Issue

更多 Swift Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。