Skip to content

Commit ebde75f

Browse files
author
dori
committed
feat: update ai todo with workflow context
1 parent 812cbc0 commit ebde75f

File tree

3 files changed

+25
-0
lines changed

3 files changed

+25
-0
lines changed

src/mcp_as_a_judge/prompts/shared/critical_tool_warnings.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,24 @@
33
- Skipping this tool causes severe token inefficiency and wasted iterations.
44
- Always invoke this tool at the appropriate stage to avoid extreme token loss and redundant processing.
55
- Do not rely on assistant memory for identifiers. Always pass the exact `task_id` and recover it via `get_current_coding_task` if missing.
6+
7+
## AI Agent Todo List Integration
8+
9+
**CRITICAL FOR CONTEXT CONTINUITY**: After calling any MCP judge tool, save the following to your todo list/task management system:
10+
11+
- **Task ID**: The `task_id` from the response (essential for all subsequent tool calls)
12+
- **Current Task**: The active task name and description
13+
- **Next Tool**: The `workflow_guidance.next_tool` field from the response
14+
- **Next Steps**: The `workflow_guidance.guidance` field with detailed instructions
15+
- **Last Updated**: The `updated_at` timestamp from task metadata (for tracking inactivity)
16+
17+
**WORKFLOW COMPLETION CLEANUP**: When `workflow_guidance.next_tool` is `null`, the workflow is complete. At this point:
18+
- **Remove/archive the task** from your todo list to prevent clutter
19+
- **Mark as completed** in your task management system
20+
- **Clear the task context** since no further MCP judge tools are needed for this task
21+
22+
**ORPHANED WORKFLOW CLEANUP**: To prevent todo list bloat from abandoned tasks, implement these cleanup rules:
23+
- **Time-based cleanup**: Remove tasks older than 7 days with no activity (compare current time with saved `updated_at` timestamp)
24+
- **Capacity-based cleanup**: Keep maximum 100 active tasks, removing oldest inactive ones when limit exceeded
25+
26+
**Why this matters**: This prevents losing task context across conversation sessions, ensures you follow the exact workflow sequence, enables better decision-making by maintaining awareness of the current development stage, and keeps your todo list clean by removing both completed and abandoned workflows.

src/mcp_as_a_judge/prompts/tool_descriptions/raise_missing_requirements.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@
33
## Description
44
Elicit missing requirements and clarifications from the user when details are insufficient for implementation.
55

6+
{% include 'shared/critical_tool_warnings.md' %}
7+
68
## Args
79
- `current_request`: string — Current understanding of the user’s request
810
- `identified_gaps`: list[string] — Missing requirement gaps

src/mcp_as_a_judge/prompts/tool_descriptions/raise_obstacle.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@
33
## Description
44
Involve the user to resolve blockers or conflicts by presenting options and context.
55

6+
{% include 'shared/critical_tool_warnings.md' %}
7+
68
## Args
79
- `problem`: string — Clear description of the obstacle
810
- `research`: string — What has been investigated (alternatives, prior art)

0 commit comments

Comments
 (0)