Skip to content

[FEATURE]: Mistral Provider: Support x-affinity header for session continuation #11466

Closed

Description

@machinekoder

Feature hasn't been suggested before.

  • I have verified this feature I'm about to request hasn't been suggested before.

Describe the enhancement you want to request

The official mistral-vibe CLI uses the x-affinity header to track and continue sessions. This seems to be similar to promptCaching in the OpenAI provider for example.
The session_id passed to x-affinity is a UUID4, the session id used or promptCaching in OpenCode is a based on a timestamp, so maybe it's not compatible out of the box, but worth a try.

Here is some evidence:
https://github.com/mistralai/mistral-vibe/blob/9809cfc8315049b6f02b1865306903d92428919f/vibe/core/agent_loop.py#L587
https://github.com/mistralai/mistral-vibe/blob/9809cfc8315049b6f02b1865306903d92428919f/vibe/core/agent_loop.py#L156
https://github.com/mistralai/mistral-vibe/blob/9809cfc8315049b6f02b1865306903d92428919f/vibe/cli/textual_ui/app.py#L1242

Activity

  1. added
    discussionUsed for feature requests, proposals, ideas, etc. Open discussion
    on Jan 31, 2026
  2. github-actions commented on Jan 31, 2026

    @github-actions
    Contributor

    Based on a review of existing issues, I don't see a direct duplicate of this feature request.

    However, there are some related issues worth checking:

    The x-affinity header for Mistral is a specific implementation of session continuation that differs from Anthropic's prompt caching approach. This seems like a new feature request that addresses Mistral's specific session continuation mechanism.

  3. github-actions commented on Apr 2, 2026

    @github-actions
    Contributor

    To stay organized issues are automatically closed after 90 days of no activity. If the issue is still relevant please open a new one.

  4. sdroege commented on Apr 2, 2026

    @sdroege

    This is still relevant

  5. fmflurry commented on Jun 3, 2026

    @fmflurry

    Where are we with this feature ?

  6. kostadin-damyanov-prime commented on Jul 4, 2026

    @kostadin-damyanov-prime

    @thdxr Can we reopen this issue? I believe that it is still relevant.

  7. fmflurry commented on Jul 4, 2026

    @fmflurry

    @thdxr Can we reopen this issue? I believe that it is still relevant.

    If you want to use it already, copy paste this plugin I made: fmflurry/harness-manifesto@6deeab7

  8. kostadin-damyanov-prime commented on Jul 5, 2026

    @kostadin-damyanov-prime

    Thank you @fmflurry I will try it!

  9. nanosek commented on Jul 13, 2026

    @nanosek

    I would also be interested in getting this fixed - my manual workaround is to set it in opencode.json to a hardcoded GUID to get some meaningful caching hits at all when using mistral, but that has probably other drawbacks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

discussionUsed for feature requests, proposals, ideas, etc. Open discussion

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions