From 9f636e1abcc3b148db969a9bf34e63aa2817bbab Mon Sep 17 00:00:00 2001 From: YeonGyu-Kim Date: Mon, 15 Dec 2025 19:02:31 +0900 Subject: [PATCH] fix(agents): enforce English prompting for all subagents (#58) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Add Language Rule (MANDATORY) section in OmO Delegation_Rules - Clarify that subagent prompts must always be in English - Update background-task tool documentation with English requirement - Update call-omo-agent tool documentation with English language rule - LLMs perform significantly better with English prompts - Improves consistency and performance across all agent-to-subagent communication 🤖 GENERATED WITH ASSISTANCE OF [OhMyOpenCode](https://github.com/code-yeongyu/oh-my-opencode) --- src/agents/omo.ts | 9 +++++++++ src/tools/background-task/constants.ts | 4 +++- src/tools/call-omo-agent/constants.ts | 3 ++- 3 files changed, 14 insertions(+), 2 deletions(-) diff --git a/src/agents/omo.ts b/src/agents/omo.ts index ef805d3..d8310ff 100644 --- a/src/agents/omo.ts +++ b/src/agents/omo.ts @@ -165,6 +165,15 @@ CONTEXT: - Files: src/auth/token.py, src/auth/middleware.py """, subagent_type="executor") \`\`\` + +### Language Rule (MANDATORY) + +**ALWAYS write subagent prompts in English, regardless of the user's language.** + +- LLMs perform significantly better with English prompts +- Internal agent communication must be in English for consistency +- User-facing responses should match the user's language +- Subagent prompts, task descriptions, and expected outcomes: ALWAYS English diff --git a/src/tools/background-task/constants.ts b/src/tools/background-task/constants.ts index 361bf20..7e31ff2 100644 --- a/src/tools/background-task/constants.ts +++ b/src/tools/background-task/constants.ts @@ -9,9 +9,11 @@ Use this for: Arguments: - description: Short task description (shown in status) -- prompt: Full detailed prompt for the agent +- prompt: Full detailed prompt for the agent (MUST be in English for optimal LLM performance) - agent: Agent type to use (any agent allowed) +IMPORTANT: Always write prompts in English regardless of user's language. LLMs perform significantly better with English prompts. + Returns immediately with task ID and session info. Use \`background_output\` to check progress or retrieve results.` export const BACKGROUND_OUTPUT_DESCRIPTION = `Get output from a background task. diff --git a/src/tools/call-omo-agent/constants.ts b/src/tools/call-omo-agent/constants.ts index 1825585..b383d35 100644 --- a/src/tools/call-omo-agent/constants.ts +++ b/src/tools/call-omo-agent/constants.ts @@ -21,4 +21,5 @@ Usage notes: 3. Each agent invocation is stateless unless you provide a session_id 4. Your prompt should contain a highly detailed task description for the agent to perform autonomously 5. Clearly tell the agent whether you expect it to write code or just to do research -6. For long-running research tasks, use run_in_background=true to avoid blocking` +6. For long-running research tasks, use run_in_background=true to avoid blocking +7. **IMPORTANT**: Always write prompts in English regardless of user's language. LLMs perform significantly better with English prompts.`