Files
langchain/libs/partners
bahtyar bc21045ee0 fix(ollama): prevent _convert_messages_to_ollama_messages from mutating caller list (#36567)
Fixes #36564

The method modifies messages[idx] in-place when converting v1 format
content. Add messages = list(messages) to create a shallow copy before
any mutations.

1 line change in libs/partners/ollama/langchain_ollama/chat_models.py

Co-authored-by: bahtya <bahtyar153@qq.com>
Co-authored-by: Mason Daugherty <mason@langchain.dev>
2026-04-06 21:53:16 -04:00
..

FAQ

Looking for an integration not listed here? Check out the integrations documentation and the note in the libs/ README about third-party maintained packages.

Integration docs

For full documentation, see the primary and API reference docs for integrations.