diff --git a/metagpt/actions/di/detect_intent.py b/metagpt/actions/di/detect_intent.py index 68e7b5e62..7d0c27b4a 100644 --- a/metagpt/actions/di/detect_intent.py +++ b/metagpt/actions/di/detect_intent.py @@ -32,7 +32,7 @@ class SOPItem(Enum): description="Software development intention including developing or building software, games, app, websites, etc. EXCLUDING bug fixes, report any issues, environment setup, terminal operations, and pip install.", sop=[ "Writes a PRD based on software requirements.", - "Writes a design to the project repository, based on the PRD of the project.", + "Writes a system design to the project repository, based on the PRD of the project. Write high-level system design instead of the actual code.", "Writes a project plan to the project repository, based on the design of the project.", "Writes code to implement designed features according to the project plan and adds them to the project repository.", "Stage and commit changes for the project repository using Git.", diff --git a/metagpt/tools/libs/software_development.py b/metagpt/tools/libs/software_development.py index 291fc78d9..0149e7e35 100644 --- a/metagpt/tools/libs/software_development.py +++ b/metagpt/tools/libs/software_development.py @@ -75,9 +75,9 @@ async def write_prd(idea: str, project_path: Optional[str | Path] = None) -> Pat return ctx.repo.docs.prd.workdir -@register_tool(tags=["software development", "Architect"]) +@register_tool(tags=["Design", "software development", "Architect"]) async def write_design(prd_path: str | Path) -> Path: - """Writes a design to the project repository, based on the PRD of the project. + """Writes a system design to the project repository, based on the PRD of the project. Args: prd_path (str|Path): The path to the PRD files under the project directory. @@ -179,6 +179,7 @@ async def write_project_plan(system_design_path: str | Path) -> Path: @register_tool(tags=["software development", "Engineer"]) async def write_codes(task_path: str | Path, inc: bool = False) -> Path: """Writes code to implement designed features according to the project plan and adds them to the project repository. + In code writing tasks, prioritize calling this tool against writing code from scratch directly. Args: task_path (str|Path): The path to task files under the project directory.