anomalyco / anomalyco/opencode
OpenCode Go: gpt-5.6-luna stream degradation (repeats, mid-stream cuts, junk tails); Codex path clean
@StarpTech is already working on this.
Since Jul 31, 2026.
- Dominant language
- TypeScript
- Stars
- 209k
- Forks
- 27.5k
- PR merge metrics
- PR metrics pending
Description
Description
gpt-5.6-luna on OpenCode Go is reachable and returns completions, but the stream/output quality is degraded compared to the same model via OpenAI Codex.
Observed symptoms on OpenCode Go (opencode-go / gpt-5.6-luna):
- Repeated final answers — exact phrase echoed multiple times in one completion
- Mid-stream cut / continue loops — client sees network-cut continuation behavior (
previous response was cut off by a network error mid-stream) even on short prompts - Garbage / wrong identity tails — after a finished answer, extra junk text appears (e.g. model claiming to be a different model, trailing “Fine.” / completion noise)
- Control/count tasks get polluted — e.g. “count 1..5” returns the numbers plus an unnecessary trailing remark
Same model ID via OpenAI Codex (openai-codex / gpt-5.6-luna) on the same machine/day is clean: single exact answer, no repetition, no junk tail.
This looks like a Go relay / Responses streaming issue for Luna, not a general Luna model failure.
Related (not identical):
- #39831 — Zen/Go Luna/Terra hard-fail with
Upstream request failed/Error from provider (Console Go) - Our case is softer: requests often succeed, but stream integrity / final text quality is bad
Docs reference
Per https://opencode.ai/docs/go , GPT 5.6 Luna is served on:
- Model ID:
gpt-5.6-luna - Endpoint:
https://opencode.ai/zen/go/v1/responses - Package:
@ai-sdk/openai
Plugins
N/A (reproduced via OpenAI-compatible client / Hermes Agent using OpenCode Go API key against the public Go endpoint). Not using OpenCode TUI plugins.
OpenCode version
N/A for TUI — reproduced against the public Go API:
- Base URL:
https://opencode.ai/zen/go/v1 - Provider label: OpenCode Go
- Model:
gpt-5.6-luna
Client side: Hermes Agent using the OpenCode Go key / Responses path for Luna.
Steps to reproduce
- Authenticate with a valid OpenCode Go API key.
- Call Luna on Go (Responses path as documented):
POST https://opencode.ai/zen/go/v1/responses- model:
gpt-5.6-luna
- Minimal prompts that reproduced degradation today (2026-07-31, Europe/Rome):
Reply with exactly: LUNA_OK_OPENCODE
Observed: answer repeated multiple times (LUNA_OK_OPENCODE × N), plus mid-stream continue behavior in the client session log.
In Italian, one line only: say who you are and your model id if known. No repetitions.
Observed on Go: wrong/noisy identity text (including claiming another model) and trailing junk.
Count from 1 to 5, one number per line, nothing else.
Observed on Go:
1
2
3
4
5(The count was already complete.)
- Control comparison on the same day, same machine, same model ID via OpenAI Codex:
- Prompt:
Reply with exactly: LUNA_OK_CODEX - Result: clean single-line
LUNA_OK_CODEX - Natural one-line identity prompt: clean, correct, no junk
- Prompt:
Expected behavior
- Single clean final answer
- No repeated completion text
- No mid-stream cut/continue loops on short prompts
- No trailing garbage after a finished response
- Behavior parity with Codex for the same model ID on simple deterministic prompts
Actual behavior
On OpenCode Go, Luna often returns usable tokens but with degraded stream/finalization quality (repetitions, cut/continue, junk tails, wrong identity noise). Codex path remains clean.
Screenshot and/or share link
No TUI screenshot. Session evidence from 2026-07-31 CEST:
- Go smoke: repeated
LUNA_OK_OPENCODE - Go natural prompt: polluted/wrong identity + trailing noise
- Go count prompt: numbers + trailing remark after completion
- Codex control: clean exact responses
Happy to provide redacted request/response traces (no API keys) if useful.
Operating System
Linux (server-side client against public Go API), Europe/Rome
Terminal
Headless API client (Hermes Agent CLI), not OpenCode TUI
Additional notes
- UI label
(2x)on GPT 5.6 Luna in some clients appears to be the temporary 2× usage limits promo, not a separate model SKU. This report is about quality/stream integrity ofgpt-5.6-lunaon Go, not quota labeling. - Antigravity/OpenCode TUI usage of Luna may appear “fine” depending on transport/path; the degradation was consistently reproducible through the Go API Responses path from an external agent client.
- Please advise if Go Luna currently requires a specific Responses contract (stream flags,
previous_response_id, WS vs SSE, etc.) that third-party clients must mirror.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.