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