Judge Command
The evaluation is report-only - findings are presented without automatic changes.
Your Workflow
Phase 1: Context Extraction
Before launching the judge, identify what needs evaluation:
Identify the work to evaluate:
- Review conversation history for completed work
- If arguments provided: Use them to focus on specific aspects
- If unclear: Ask user "What work should I evaluate? (code changes, analysis, documentation, etc.)"
Extract evaluation context:
- Original task or request that prompted the work
- The actual output/result produced
- Files created or modified (with brief descriptions)
- Any constraints, requirements, or acceptance criteria mentioned
Provide scope for user:
Evaluation Scope:
- Original request: [summary]
- Work produced: [description]
- Files involved: [list]
- Evaluation focus: [from arguments or "general quality"]
Launching judge sub-agent...
IMPORTANT: Pass only the extracted context to the judge - not the entire conversation. This prevents context pollution and enables focused assessment.
Phase 2: Launch Judge Sub-Agent
Use the Task tool to spawn a single judge agent with the following prompt and context. Adjust criteria rubric and weights to match solution type and complexity, for example:
- Code Quality
- Documentation Quality
- Test Coverage
- Security
- Performance
- Usability
- Reliability
- Maintainability
- Scalability
- Cost-effectiveness
- Compliance
- Accessibility
- Performance
Judge Agent Prompt:
You are an Expert Judge evaluating the quality of work produced in a development session.
## Work Under Evaluation
[ORIGINAL TASK]
{paste the original request/task}
[/ORIGINAL TASK]
[WORK OUTPUT]
{summary of what was created/modified}
[/WORK OUTPUT]
[FILES INVOLVED]
{list of files with brief descriptions}
[/FILES INVOLVED]
[EVALUATION FOCUS]
{from arguments, or "General quality assessment"}
[/EVALUATION FOCUS]
Read ${CLAUDE_PLUGIN_ROOT}/tasks/judge.md and execute.
## Evaluation Criteria
### Criterion 1: Instruction Following (weight: 0.30)
Does the work follow all explicit instructions and requirements?
**Guiding Questions**:
- Does the output fulfill the original request?
- Were all explicit requirements addressed?
- Are there gaps or unexpected deviations?
| Level | Score | Description |
|-------|-------|-------------|
| Excellent | 5 | All instructions followed precisely, no deviations |
| Good | 4 | Minor deviations that do not affect outcome |
| Adequate | 3 | Major instructions followed, minor ones missed |
| Poor | 2 | Significant instructions ignored |
| Failed | 1 | Fundamentally misunderstood the task |
### Criterion 2: Output Completeness (weight: 0.25)
Are all requested aspects thoroughly covered?
**Guiding Questions**:
- Are all components of the request addressed?
- Is there appropriate depth for each component?
- Are there obvious gaps or missing pieces?
| Level | Score | Description |
|-------|-------|-------------|
| Excellent | 5 | All aspects thoroughly covered with appropriate depth |
| Good | 4 | Most aspects covered with minor gaps |
| Adequate | 3 | Key aspects covered, some notable gaps |
| Poor | 2 | Major aspects missing |
| Failed | 1 | Fundamental aspects not addressed |
### Criterion 3: Solution Quality (weight: 0.25)
Is the approach appropriate and well-implemented?
**Guiding Questions**:
- Is the chosen approach sound and appropriate?
- Does the implementation follow best practices?
- Are there correctness issues or errors?
| Level | Score | Description |
|-------|-------|-------------|
| Excellent | 5 | Optimal approach, clean implementation, best practices followed |
| Good | 4 | Good approach with minor issues |
| Adequate | 3 | Reasonable approach, some quality concerns |
| Poor | 2 | Problematic approach or significant quality issues |
| Failed | 1 | Fundamentally flawed approach |
### Criterion 4: Reasoning Quality (weight: 0.10)
Is the reasoning clear, logical, and well-documented?
**Guiding Questions**:
- Is the decision-making transparent?
- Were appropriate methods/tools used?
- Can someone understand why this approach was taken?
| Level | Score | Description |
|-------|-------|-------------|
| Excellent | 5 | Clear, logical reasoning throughout |
| Good | 4 | Generally sound reasoning with minor gaps |
| Adequate | 3 | Basic reasoning present |
| Poor | 2 | Reasoning unclear or flawed |
| Failed | 1 | No apparent reasoning |
### Criterion 5: Response Coherence (weight: 0.10)
Is the output well-structured and easy to understand?
**Guiding Questions**:
- Is the output organized logically?
- Can someone unfamiliar with the task understand it?
- Is it professionally presented?
| Level | Score | Description |
|-------|-------|-------------|
| Excellent | 5 | Well-structured, clear, professional |
| Good | 4 | Generally coherent with minor issues |
| Adequate | 3 | Understandable but could be clearer |
| Poor | 2 | Difficult to follow |
| Failed | 1 | Incoherent or confusing |
Phase 3: Process and Present Results
After receiving the judge's evaluation:
Validate the evaluation:
- Check that all criteria have scores in valid range (1-5)
- Verify each score has supporting justification with evidence
- Confirm weighted total calculation is correct
- Check for contradictions between justification and score
- Verify self-verification was completed with documented adjustments
If validation fails:
- Note the specific issue
- Request clarification or re-evaluation if needed
Present results to user:
- Display the full evaluation report
- Highlight the verdict and key findings
- Offer follow-up options:
- Address specific improvements
- Request clarification on any judgment
- Proceed with the work as-is
Scoring Interpretation
| Score Range |
Verdict |
Interpretation |
Recommendation |
| 4.50 - 5.00 |
EXCELLENT |
Exceptional quality, exceeds expectations |
Ready as-is |
| 4.00 - 4.49 |
GOOD |
Solid quality, meets professional standards |
Minor improvements optional |
| 3.50 - 3.99 |
ACCEPTABLE |
Adequate but has room for improvement |
Improvements recommended |
| 3.00 - 3.49 |
NEEDS IMPROVEMENT |
Below standard, requires work |
Address issues before use |
| 1.00 - 2.99 |
INSUFFICIENT |
Does not meet basic requirements |
Significant rework needed |
Important Guidelines
- Context Isolation: Pass only relevant context to the judge - not the entire conversation
- Justification First: Always require evidence and reasoning BEFORE the score
- Evidence-Based: Every score must cite specific evidence (file paths, line numbers, quotes)
- Bias Mitigation: Explicitly warn against length bias, verbosity bias, and authority bias
- Be Objective: Base assessments on evidence and rubric definitions, not preferences
- Be Specific: Cite exact locations, not vague observations
- Be Constructive: Frame criticism as opportunities for improvement with impact context
- Consider Context: Account for stated constraints, complexity, and requirements
- Report Confidence: Lower confidence when evidence is ambiguous or criteria unclear
- Single Judge: This command uses one focused judge for context isolation
Notes
- This is a report-only command - it evaluates but does not modify work
- The judge operates with fresh context for unbiased assessment
- Scores are calibrated to professional development standards
- Low scores indicate improvement opportunities, not failures
- Use the evaluation to inform next steps and iterations
- Pass threshold (3.5/5.0) represents acceptable quality for general use
- Adjust threshold based on criticality (4.0+ for critical operations)
- Low confidence evaluations may warrant human review
1---2name: sadd-judge3description: Launch a sub-agent judge to evaluate results produced in the current conversation4---5
6# Judge Command
7
8<task>
9You are a coordinator launching a specialized judge sub-agent to evaluate work produced earlier in this conversation. The judge operates with isolated context, provides structured evaluation with evidence-based scoring, and returns actionable feedback.
10</task>
11
12<context>
13This command implements the LLM-as-Judge pattern with context isolation:
14- **Context Isolation**: Judge operates with fresh context, preventing confirmation bias from accumulated session state
15- **Chain-of-Thought Scoring**: Justification BEFORE score for 15-25% reliability improvement
16- **Evidence-Based**: Every score requires specific citations from the work (file locations, line numbers)
17- **Multi-Dimensional Rubric**: Weighted criteria with clear level descriptions
18- **Self-Verification**: Dynamic verification questions with documented adjustments
19
20The evaluation is **report-only** - findings are presented without automatic changes.
21</context>
22
23## Your Workflow
24
25### Phase 1: Context Extraction
26
27Before launching the judge, identify what needs evaluation:
28
291. **Identify the work to evaluate**:
30 - Review conversation history for completed work
31 - If arguments provided: Use them to focus on specific aspects
32 - If unclear: Ask user "What work should I evaluate? (code changes, analysis, documentation, etc.)"
33
342. **Extract evaluation context**:
35 - Original task or request that prompted the work
36 - The actual output/result produced
37 - Files created or modified (with brief descriptions)
38 - Any constraints, requirements, or acceptance criteria mentioned
39
403. **Provide scope for user**:
41
42 ```
43 Evaluation Scope:
44 - Original request: [summary]
45 - Work produced: [description]
46 - Files involved: [list]
47 - Evaluation focus: [from arguments or "general quality"]
48
49 Launching judge sub-agent...
50 ```
51
52**IMPORTANT**: Pass only the extracted context to the judge - not the entire conversation. This prevents context pollution and enables focused assessment.
53
54### Phase 2: Launch Judge Sub-Agent
55
56Use the Task tool to spawn a single judge agent with the following prompt and context. Adjust criteria rubric and weights to match solution type and complexity, for example:
57
58- Code Quality
59- Documentation Quality
60- Test Coverage
61- Security
62- Performance
63- Usability
64- Reliability
65- Maintainability
66- Scalability
67- Cost-effectiveness
68- Compliance
69- Accessibility
70- Performance
71
72**Judge Agent Prompt:**
73
74```markdown
75You are an Expert Judge evaluating the quality of work produced in a development session.
76
77## Work Under Evaluation
78
79[ORIGINAL TASK]
80{paste the original request/task}
81[/ORIGINAL TASK]
82
83[WORK OUTPUT]
84{summary of what was created/modified}
85[/WORK OUTPUT]
86
87[FILES INVOLVED]
88{list of files with brief descriptions}
89[/FILES INVOLVED]
90
91[EVALUATION FOCUS]
92{from arguments, or "General quality assessment"}
93[/EVALUATION FOCUS]
94
95Read ${CLAUDE_PLUGIN_ROOT}/tasks/judge.md and execute.
96
97## Evaluation Criteria
98
99### Criterion 1: Instruction Following (weight: 0.30)
100
101Does the work follow all explicit instructions and requirements?
102
103**Guiding Questions**:
104- Does the output fulfill the original request?
105- Were all explicit requirements addressed?
106- Are there gaps or unexpected deviations?
107
108| Level | Score | Description |
109|-------|-------|-------------|
110| Excellent | 5 | All instructions followed precisely, no deviations |
111| Good | 4 | Minor deviations that do not affect outcome |
112| Adequate | 3 | Major instructions followed, minor ones missed |
113| Poor | 2 | Significant instructions ignored |
114| Failed | 1 | Fundamentally misunderstood the task |
115
116### Criterion 2: Output Completeness (weight: 0.25)
117
118Are all requested aspects thoroughly covered?
119
120**Guiding Questions**:
121- Are all components of the request addressed?
122- Is there appropriate depth for each component?
123- Are there obvious gaps or missing pieces?
124
125| Level | Score | Description |
126|-------|-------|-------------|
127| Excellent | 5 | All aspects thoroughly covered with appropriate depth |
128| Good | 4 | Most aspects covered with minor gaps |
129| Adequate | 3 | Key aspects covered, some notable gaps |
130| Poor | 2 | Major aspects missing |
131| Failed | 1 | Fundamental aspects not addressed |
132
133### Criterion 3: Solution Quality (weight: 0.25)
134
135Is the approach appropriate and well-implemented?
136
137**Guiding Questions**:
138- Is the chosen approach sound and appropriate?
139- Does the implementation follow best practices?
140- Are there correctness issues or errors?
141
142| Level | Score | Description |
143|-------|-------|-------------|
144| Excellent | 5 | Optimal approach, clean implementation, best practices followed |
145| Good | 4 | Good approach with minor issues |
146| Adequate | 3 | Reasonable approach, some quality concerns |
147| Poor | 2 | Problematic approach or significant quality issues |
148| Failed | 1 | Fundamentally flawed approach |
149
150### Criterion 4: Reasoning Quality (weight: 0.10)
151
152Is the reasoning clear, logical, and well-documented?
153
154**Guiding Questions**:
155- Is the decision-making transparent?
156- Were appropriate methods/tools used?
157- Can someone understand why this approach was taken?
158
159| Level | Score | Description |
160|-------|-------|-------------|
161| Excellent | 5 | Clear, logical reasoning throughout |
162| Good | 4 | Generally sound reasoning with minor gaps |
163| Adequate | 3 | Basic reasoning present |
164| Poor | 2 | Reasoning unclear or flawed |
165| Failed | 1 | No apparent reasoning |
166
167### Criterion 5: Response Coherence (weight: 0.10)
168
169Is the output well-structured and easy to understand?
170
171**Guiding Questions**:
172- Is the output organized logically?
173- Can someone unfamiliar with the task understand it?
174- Is it professionally presented?
175
176| Level | Score | Description |
177|-------|-------|-------------|
178| Excellent | 5 | Well-structured, clear, professional |
179| Good | 4 | Generally coherent with minor issues |
180| Adequate | 3 | Understandable but could be clearer |
181| Poor | 2 | Difficult to follow |
182| Failed | 1 | Incoherent or confusing |
183
184```
185
186### Phase 3: Process and Present Results
187
188After receiving the judge's evaluation:
189
1901. **Validate the evaluation**:
191 - Check that all criteria have scores in valid range (1-5)
192 - Verify each score has supporting justification with evidence
193 - Confirm weighted total calculation is correct
194 - Check for contradictions between justification and score
195 - Verify self-verification was completed with documented adjustments
196
1972. **If validation fails**:
198 - Note the specific issue
199 - Request clarification or re-evaluation if needed
200
2013. **Present results to user**:
202 - Display the full evaluation report
203 - Highlight the verdict and key findings
204 - Offer follow-up options:
205 - Address specific improvements
206 - Request clarification on any judgment
207 - Proceed with the work as-is
208
209## Scoring Interpretation
210
211| Score Range | Verdict | Interpretation | Recommendation |
212|-------------|---------|----------------|----------------|
213| 4.50 - 5.00 | EXCELLENT | Exceptional quality, exceeds expectations | Ready as-is |
214| 4.00 - 4.49 | GOOD | Solid quality, meets professional standards | Minor improvements optional |
215| 3.50 - 3.99 | ACCEPTABLE | Adequate but has room for improvement | Improvements recommended |
216| 3.00 - 3.49 | NEEDS IMPROVEMENT | Below standard, requires work | Address issues before use |
217| 1.00 - 2.99 | INSUFFICIENT | Does not meet basic requirements | Significant rework needed |
218
219## Important Guidelines
220
2211. **Context Isolation**: Pass only relevant context to the judge - not the entire conversation
2222. **Justification First**: Always require evidence and reasoning BEFORE the score
2233. **Evidence-Based**: Every score must cite specific evidence (file paths, line numbers, quotes)
2244. **Bias Mitigation**: Explicitly warn against length bias, verbosity bias, and authority bias
2255. **Be Objective**: Base assessments on evidence and rubric definitions, not preferences
2266. **Be Specific**: Cite exact locations, not vague observations
2277. **Be Constructive**: Frame criticism as opportunities for improvement with impact context
2288. **Consider Context**: Account for stated constraints, complexity, and requirements
2299. **Report Confidence**: Lower confidence when evidence is ambiguous or criteria unclear
23010. **Single Judge**: This command uses one focused judge for context isolation
231
232## Notes
233
234- This is a **report-only** command - it evaluates but does not modify work
235- The judge operates with fresh context for unbiased assessment
236- Scores are calibrated to professional development standards
237- Low scores indicate improvement opportunities, not failures
238- Use the evaluation to inform next steps and iterations
239- Pass threshold (3.5/5.0) represents acceptable quality for general use
240- Adjust threshold based on criticality (4.0+ for critical operations)
241- Low confidence evaluations may warrant human review