The agent engineering platform.
Python agentsaiai-agentsanthropicchatgptdeepagentsenterpriseframeworkgeminigenerative-ailangchainlanggraphllmmultiagentopen-sourceopenaipydanticpythonragtypescript
community[patch]: fix ollama astream (#16070)
Fei Wangd0e101e4e01c
diff --git a/libs/community/langchain_community/llms/ollama.py b/libs/community/langchain_community/llms/ollama.pyindex 29a724b07e..db8d661704 100644--- a/libs/community/langchain_community/llms/ollama.py+++ b/libs/community/langchain_community/llms/ollama.py@@ -468,7 +468,7 @@ class Ollama(BaseLLM, _OllamaCommon):run_manager: Optional[AsyncCallbackManagerForLLMRun] = None,**kwargs: Any,) -> AsyncIterator[GenerationChunk]:- async for stream_resp in self._acreate_stream(prompt, stop, **kwargs):+ async for stream_resp in self._acreate_generate_stream(prompt, stop, **kwargs):if stream_resp:chunk = _stream_response_to_generation_chunk(stream_resp)yield chunk