github / github/copilot-sdk

[Model Routing] claude-sonnet-5 swallows streaming assistant.reasoning_delta; flushes all thinkingContent at completion

Offen
#2,346 1 Kommentar 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
question
Vorherrschende Sprache
Java
Sterne
10.5k
Forks
1.5k
Ø Merge
1 T. 11 Std.
Gemergte PRs (30 T.)
127

Beschreibung

Environment Details:

Working Model: claude-sonnet-4.5 (streams perfectly)

Failing Model: claude-sonnet-5

Integration: GitHub Copilot SDK (subscribe('assistant.reasoning_delta'))

Observed Behavior:
When routing requests to claude-sonnet-5, the SDK emits zero assistant.reasoning_delta events during the generation lifecycle. Instead, it accumulates them in the background, resulting in a ~25,000ms Time-to-First-Token (TTFT) and blocking client-side UI rendering. A complete, non-empty thinkingContent block is delivered atomically only when the final text stream buffer flushes or the file completes.

Expected Behavior:
The SDK should map Anthropic's streaming reasoning frames into real-time assistant.reasoning_delta events immediately upon receiving them from the upstream model router, preserving low operational TTFT just as it successfully does for claude-sonnet-4.5.

Beitragsleitfaden

Beitragsleitfaden öffnen

Rechercherichtung

Start at the implementation behind subscribe('assistant.reasoning_delta') and follow the model-routing path for claude-sonnet-5. Compare its handling with claude-sonnet-4.5 and verify whether upstream reasoning frames are emitted immediately rather than buffered. Done means real-time reasoning_delta events and low TTFT for claude-sonnet-5, without waiting for final completion.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
github, java
Bereich
ai, api, performance
Issue-Typ
Bug
Schwierigkeit
3/5
Geschätzter Aufwand
1-2 Tage
Aktivitätsstatus
Aktiv
Klarheit
Größtenteils klar
Anfängerfreundlichkeit
55/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.