Skip to content

feat: carry assistant reasoning on the generation output too - #38

Merged
hassiebp merged 1 commit into
mainfrom
feat/reasoning-on-generation-output
Sep 15, 2026
Merged

hassiebp merged 1 commit into
mainfrom
feat/reasoning-on-generation-output

Conversation

@milanagm

@milanagm milanagm commented Sep 15, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Follow-up to feat: record the conversation history as each generation's input #33 (LFE-15986): reasoning was already carried in a generation's history, but the message_end output was still built from extractText + extractToolCalls only, so a type: "thinking" part never reached the output of the call that produced it.
  • Attaches extractThinking()'s result to the output as thinking, matching the shape the history side already uses.
  • Switches extractToolCalls to the nested { id, type: "function", function: { name } } shape Langfuse renders (mirrors the Claude plugin's #77); arguments stay off the generation output since the tool span already carries them.

Linear: https://linear.app/clickhouse/issue/LFE-15989/featpi-plugin-carry-assistant-reasoning-on-the-generation-output-too
Fixes LFE-15989

Verification

Not in this change

  • opencode's tool_calls are still flat ({id, name, arguments}) despite using the same ChatML thinking shape — worth its own issue, out of scope here.

@hassiebp
hassiebp merged commit 8b61f5b into main Sep 15, 2026
13 checks passed
@hassiebp
hassiebp deleted the feat/reasoning-on-generation-output branch September 15, 2026 15:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants