Skip to content

Conversation

@snipeship
Copy link
Contributor

@snipeship snipeship commented Dec 29, 2025

Closes #6337, #4033, #3703


Adds a new interleaved object shape to model config with tagName (required) and optional startWithReasoning.
Read ai-sdk's extractReasoningMiddleware() as a reference.

Example config:

"models": {
  "model-name": {
    "reasoning": true,
    "interleaved": {
      "tagName": "think" // or other XML tag
      // "startWithReasoning": true
    },
  }
}

Before (see issue)

After:
Screenshot 2025-12-29 at 10 14 57

@snipeship
Copy link
Contributor Author

@rekram1-node
Copy link
Collaborator

wondering if there is anyway we could avoid additional configs and just always have it on, and then default to handling which should cover 90% of users and they wont have to do configs manually?

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.

[FEATURE]: support extracting reasoning XML

2 participants