🌟 The Multi-Agent Framework: First AI Software Company, Towards Natural Language Programming
update log_llm_stream in log_llm_stream.py/ollama_api.py
shenchuchengb113aa246f70
diff --git a/metagpt/provider/google_gemini_api.py b/metagpt/provider/google_gemini_api.pyindex 63a2ff687..825b0bfe3 100644--- a/metagpt/provider/google_gemini_api.py+++ b/metagpt/provider/google_gemini_api.py@@ -119,7 +119,7 @@ class GeminiGPTAPI(BaseGPTAPI):collected_content = []async for chunk in resp:content = chunk.text- log_llm_stream(content, end="")+ log_llm_stream(content)collected_content.append(content)full_content = "".join(collected_content)diff --git a/metagpt/provider/ollama_api.py b/metagpt/provider/ollama_api.pyindex d668d3af1..e913f3d0d 100644--- a/metagpt/provider/ollama_api.py+++ b/metagpt/provider/ollama_api.py@@ -127,7 +127,7 @@ class OllamaGPTAPI(BaseGPTAPI):if not chunk.get("done", False):content = self.get_choice_text(chunk)collected_content.append(content)- log_llm_stream(content, end="")+ log_llm_stream(content)else:# stream finishedusage = self.get_usage(chunk)