🌟 The Multi-Agent Framework: First AI Software Company, Towards Natural Language Programming
修改quick think response category 临时if逻辑
Yizhou Chie0cc3e8d1bda
diff --git a/metagpt/prompts/di/role_zero.py b/metagpt/prompts/di/role_zero.pyindex 2aea566ae..765825198 100644--- a/metagpt/prompts/di/role_zero.py+++ b/metagpt/prompts/di/role_zero.py@@ -129,7 +129,7 @@ For requests that are unclear, lack sufficient detail, or are outside the system- Out of Expertise: Requests for specialized advice (e.g., medical or legal advice) or highly technical tasks beyond the model's scope.- Unrealistic Scope: Overly broad requests that are impossible to address meaningfully in a single response (e.g., "Tell me everything about...").-**Note:** Before categorizing a request as TASK, consider whether the user has provided sufficient information to proceed with the task. If the request is complex but lacks essential details, it may fall under AMBIGUOUS.+**Note:** Before categorizing a request as TASK, consider whether the user has provided sufficient information to proceed with the task. If the request is complex but lacks essential details or the mentioned files, it should fall under AMBIGUOUS.{examples}diff --git a/metagpt/roles/di/role_zero.py b/metagpt/roles/di/role_zero.pyindex 019bdba51..e87dae750 100644--- a/metagpt/roles/di/role_zero.py+++ b/metagpt/roles/di/role_zero.py@@ -256,17 +256,13 @@ class RoleZero(Role):context = self.llm.format_msg(memory + [UserMessage(content=QUICK_THINK_PROMPT)])intent_result = await self.llm.aask(context)- if "QUICK" in intent_result:- # llm call with the original context+ if "QUICK" in intent_result or "AMBIGUOUS " in intent_result: # llm call with the original contextasync with ThoughtReporter(enable_llm_stream=True) as reporter:await reporter.async_report({"type": "quick"})answer = await self.llm.aask(self.llm.format_msg(memory))elif "SEARCH" in intent_result:query = "\n".join(str(msg) for msg in memory)answer = await SearchEnhancedQA().run(query)- elif "AMBIGUOUS " in intent_result:- # TODO: out of domain, ask human for help- passif answer:self.rc.memory.add(AIMessage(content=answer, cause_by=RunCommand))