Skip to content

🌟 The Multi-Agent Framework: First AI Software Company, Towards Natural Language Programming

fix bug in multi llm

zhaoweiguo0f27029b2c55
diff --git a/metagpt/actions/action.py b/metagpt/actions/action.py
index 20c052aa9..0909ef2fc 100644
--- a/metagpt/actions/action.py
+++ b/metagpt/actions/action.py
@@ -49,6 +49,7 @@ class Action(SerializationMixin, ContextMixin, BaseModel):
llm = create_llm_instance(config)
llm.cost_manager = data.llm.cost_manager
data.llm = llm
+ data.config = config # if not set self.config, self.llm will be reset when you call Role.set_actions function
return data
@property