[GH-ISSUE #292] antigravity的内容返回解析被截断了 #206

Closed
opened 2026-02-27 07:18:28 +03:00 by kerem · 1 comment
Owner

Originally created by @Kinhan on GitHub (Jan 30, 2026).
Original GitHub issue: https://github.com/justlovemaki/AIClient-2-API/issues/292

版本:2026-01-25日docker latest版本

使用opencode接入自定义openai协议的API
opencod.json如下

{
  "$schema": "https://opencode.ai/config.json",
  "provider": {
    "apigooan": {
      "npm": "@ai-sdk/openai",
      "name": "APIGOOAN",
      "options": {
        "baseURL": "http://192.168.50.55:3000/gemini-antigravity/v1",
        "setCacheKey": true
      },
      "models": {
        "gemini-3-pro-high": {
          "name": "Gemini 3 Pro High"
        },
        "gemini-3-pro-low": {
          "name": "Gemini 3 Pro Low"
        },
        "gemini-3-flash": {
          "name": "Gemini 3 Flash"
        },
        "claude-sonnet-4-5-thinking": {
          "name": "Claude Sonnet 4.5 Thinking"
        },
        "claude-sonnet-4-5": {
          "name": "Claude Sonnet 4.5"
        },
        "claude-opus-4-5-thinking": {
          "name": "Claude Opus 4.5 Thinking"
        }
      }
    }
  "model": "apigooan/gemini-3-pro-high"
}
Image

用AI Monitor查看日志返回体如下

Image Image

用claude code使用claude协议也存在类似问题

Image

google cli方式则没有这个问题

Originally created by @Kinhan on GitHub (Jan 30, 2026). Original GitHub issue: https://github.com/justlovemaki/AIClient-2-API/issues/292 版本:2026-01-25日docker latest版本 使用opencode接入自定义openai协议的API opencod.json如下 ``` { "$schema": "https://opencode.ai/config.json", "provider": { "apigooan": { "npm": "@ai-sdk/openai", "name": "APIGOOAN", "options": { "baseURL": "http://192.168.50.55:3000/gemini-antigravity/v1", "setCacheKey": true }, "models": { "gemini-3-pro-high": { "name": "Gemini 3 Pro High" }, "gemini-3-pro-low": { "name": "Gemini 3 Pro Low" }, "gemini-3-flash": { "name": "Gemini 3 Flash" }, "claude-sonnet-4-5-thinking": { "name": "Claude Sonnet 4.5 Thinking" }, "claude-sonnet-4-5": { "name": "Claude Sonnet 4.5" }, "claude-opus-4-5-thinking": { "name": "Claude Opus 4.5 Thinking" } } } "model": "apigooan/gemini-3-pro-high" } ``` <img width="1152" height="615" alt="Image" src="https://github.com/user-attachments/assets/6ebc55fc-242f-44e4-9aed-f772961f49b3" /> 用AI Monitor查看日志返回体如下 <img width="751" height="891" alt="Image" src="https://github.com/user-attachments/assets/4b699292-e131-4668-9fd3-a6dc4f96f9fb" /> <img width="690" height="864" alt="Image" src="https://github.com/user-attachments/assets/e44af752-6174-45df-bf4b-d9cda044509a" /> 用claude code使用claude协议也存在类似问题 <img width="1094" height="356" alt="Image" src="https://github.com/user-attachments/assets/40a418f6-9b79-4840-9112-e718d959576e" /> google cli方式则没有这个问题
kerem closed this issue 2026-02-27 07:18:29 +03:00
Author
Owner

@Kinhan commented on GitHub (Jan 30, 2026):

配置npm错了,用这个可以了,"npm": "@ai-sdk/openai-compatible"

<!-- gh-comment-id:3821837080 --> @Kinhan commented on GitHub (Jan 30, 2026): 配置npm错了,用这个可以了,"npm": "@ai-sdk/openai-compatible"
Sign in to join this conversation.
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/AIClient-2-API-justlovemaki#206
No description provided.