Hacktoberfest 2026: los issues que los mantenedores marcaron para octubre, abiertos y aptos para principiantes. Explorar issues de Hacktoberfest

[spring-ai] Bridge drops reasoning_content (thinking) — surface it as partial events and/or persist it

Abierto
#1,616 1 comentario 0 reacciones 1 asignado Ver en GitHub

Los mantenedores suelen responder en 1 día

@hemasekhar-p ya está trabajando en esto.

Desde el 5/10/2026.

Evaluación

Este issue todavía no se ha evaluado.

Descripción

needs review
Is your feature request related to a problem? Please describe.

Spring AI 2.0 already exposes reasoning content from thinking models such as DeepSeek-R1, Qwen-Thinking, and GLM via AssistantMessage metadata (reasoningContent). However, in the Spring AI bridge used by ADK, this field is not read or forwarded.

After decompiling 1.11.0, I confirmed the four core bridge classes — SpringAI, MessageConverter, StreamingResponseAggregator, and ConfigMapper — don't reference reasoningContent at all. The result is that reasoning is silently dropped: it is neither forwarded as partial events nor persisted to the session, and there is no warning. Users running thinking models through the bridge lose the entire reasoning stream.

Describe the solution you'd like

During streaming aggregation, the bridge should read reasoningContent and surface it to ADK consumers. For example:

  • emit it as dedicated reasoning parts on partial LlmResponses, persisted together with the final event; or
  • map it onto the thought flag if the Java SDK's Part supports it, similar to the Gemini path.

This would make thinking models actually usable through the bridge: UIs could render collapsible thinking panels, and session history would retain the reasoning trace for audit.

We already handle this in a production fork via a lightweight marker protocol around the reasoning text, with the frontend rendering collapsible thinking panels and per-segment timing. Happy to share the implementation or send a PR.

One thing the bridge would also need to normalize: OpenAI-compatible gateways differ in reasoning chunk semantics — some stream pure deltas, others return cumulative text per chunk. Consumers currently need prefix-detection heuristics to avoid duplication; if the bridge normalized to pure deltas once, all downstream code stays simple.

Describe alternatives you've considered

Keeping the status quo forces anyone using thinking models through the bridge to either fork it or lose reasoning entirely.

Additional context

Verified against 1.11.0 (current latest at the time of writing). No Spring AI changes are needed — the metadata is already there, waiting for the bridge to read it.

Lenguaje dominante
Java
Estrellas
1.7k
Forks
431
Merge medio
3 d 2 h
PR fusionados (30 d)
46

Preparar el entorno

Abrir en Codespaces

Inicia el contenedor de desarrollo del proyecto en tu navegador, con tu propia cuenta de GitHub.

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de google/adk-java

Todos los issues de google/adk-java

Issues similares

Más issues de Java

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.