Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

Unable to obtain the UsageContent and FinishReason of response.incomplete

Aperta Adatta ai principianti
#7,893 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

@jaeminbird ci sta già lavorando.

Dal 29/10/2026.

  • #7895 di @jaeminbird — aperta

Valutazione

Difficoltà
2/5
Tempo stimato
1-3 ore
Idoneità per principianti
67/100
Tipo di issue
Bug
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
csharp

Direzione di ricerca

Inizia leggendo FromOpenAIStreamingResponseUpdatesAsync in OpenAIResponsesChatClient ed esamina come gestisce StreamingResponseIncompleteUpdate rispetto agli altri aggiornamenti della risposta. Segui il percorso in cui vengono raccolti UsageContent e FinishReason, poi controlla i relativi test di streaming. Il lavoro è completato quando le risposte incomplete espongono sia l’utilizzo dei token sia il motivo della terminazione e i test coprono questo caso.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

area-ai bug untriaged
Description

The FromOpenAIStreamingResponseUpdatesAsync method of the OpenAIResponsesChatClient class, when handling StreamingResponseIncompleteUpdate, does not process the UsageContent and FinishReason fields. This results in the program being unable to obtain the token consumption information for this round and also not knowing why it has ended.

Reproduction Steps

Set MaxOutputTokens to less than 8k, and set ReasoningEffort to High or above. Let the LLM execute a complex task. At this point, due to insufficient output budget, it will return a message of type response.incomplete, which is of the StreamingResponseIncompleteUpdate type.

Expected behavior

Collect the token usage and the reasons for termination in cases where the task is not completed as expected.

Actual behavior
Image
Regression?

No response

Known Workarounds

No response

Configuration
  • Microsoft.Extensions.AI 10.11.0
Other information

No response

Lingua principale
C#
Stelle
3.3k
Fork
916
Merge medio
1g 13h
PR unite (30g)
40

Preparare l'ambiente

Apri in Codespaces

Avvia il container di sviluppo del progetto nel browser, con il tuo account GitHub.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di dotnet/extensions

Tutte le issue di dotnet/extensions

Issue simili

Altre issue su C#

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.