Skip to content

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

fix typo

黄伟韬b80f8c4f9ab5
diff --git a/metagpt/prompts/di/architect.py b/metagpt/prompts/di/architect.py
index 566835dac..112f040c5 100644
--- a/metagpt/prompts/di/architect.py
+++ b/metagpt/prompts/di/architect.py
@@ -73,7 +73,7 @@ Anything UNCLEAR: Mention unclear project aspects, then try to clarify it.
4.2 System Design Format example:
{system_design_example}
5. Use Editor.write to write the system design in markdown format. The file path must be "{{project}}/docs/system_design.md". Use command_name "end" when the system design is finished.
-6. If no memtion, always use Editor.write to write "Program call flow" in a new file name "{{project}}/docs/system_design-sequence-diagram.mermaid" and write "Data structures and interfaces" in a new file "{{project}}/docs/system_design-sequence-diagram.mermaid-class-diagram". Mermaid code only. Do not add "```mermaid".
+6. If not memtioned, always use Editor.write to write "Program call flow" in a new file name "{{project}}/docs/system_design-sequence-diagram.mermaid" and write "Data structures and interfaces" in a new file "{{project}}/docs/system_design-sequence-diagram.mermaid-class-diagram". Mermaid code only. Do not add "```mermaid".
""".format(
system_design_example=SYSTEM_DESIGN_EXAMPLE,
vue_template_path=VUE_TEMPLATE_PATH.absolute(),
diff --git a/metagpt/roles/architect.py b/metagpt/roles/architect.py
index f23d4d4d0..7ec937675 100644
--- a/metagpt/roles/architect.py
+++ b/metagpt/roles/architect.py
@@ -7,6 +7,8 @@
"""
from pydantic import Field
+from metagpt.actions.design_api import WriteDesign
+from metagpt.actions.write_prd import WritePRD
from metagpt.prompts.di.architect import ARCHITECT_EXAMPLE, ARCHITECT_INSTRUCTION
from metagpt.roles.di.role_zero import RoleZero
from metagpt.tools.libs.terminal import Terminal
@@ -43,6 +45,11 @@ class Architect(RoleZero):
# NOTE: The following init setting will only be effective when self.use_fixed_sop is changed to True
self.enable_memory = False
+ # Initialize actions specific to the Architect role
+ self.set_actions([WriteDesign])
+
+ # Set events or actions the Architect should watch or be aware of
+ self._watch({WritePRD})
def _retrieve_experience(self) -> str:
return ARCHITECT_EXAMPLE