Ag Judge logo

Ag Judge

Community
kevinslin
ag-judge

Judge agent work as approve, reject, or escalate.

Overview

Publisherkevinslin
Repositoryagstack
Skill nameag-judge
Stars
26
Forks
1
Bundled files
3
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • 3 bundled files

    Scripts, templates, and references the model can read while it works. Files are read-only and never executed.

  • Open source

    Published by kevinslin on GitHub. Read the source before you install it.

Installation

Install the Ag Judge AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/kevinslin/agstack/tree/main/active/ag-judge
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/kevinslin/agstack.git /tmp/agstack
mkdir -p .claude/skills
cp -r /tmp/agstack/active/ag-judge .claude/skills/ag-judge
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Ag Judge in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Ag Judge on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Ag Judge is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Ag Judge

Judge AI agent work before execution. Score each judgement on impact, risk, and size, and choose a decision classification from the active judge book.

Judge Books

Judge books live at references/jb.[topic].md.

Use jb.template.md as the starting point for every new judgebook.

Available judge books:

  • references/jb.agent-optimize.md: Use when judging meta agent optimization work over its past sessions.
  • references/jb.coding.md: Use when judging code-related pull-request work.
  • references/jb.template.md: Boilerplate template for creating a new judgebook.

Concepts

ConceptMeaningMaps to Review WorkflowMaps to Create Judgebook Workflow
judgementSmallest independent decision object to score and classify.Steps 1, 4-9 and ## Judgement N output blocks.Step 4 (human escalation/reply contract) and step 5 (classification rules must reference judgement outcomes).
judge bookTopic-specific policy file (references/jb.[topic].md) that defines scoring and decision rules.Step 2 selects the active judge book.Steps 1-2 create/select topic and file structure.
evidenceDurable artifacts required before scoring.Step 3 gathers and checks sufficiency.Steps 2 and 5 require an explicit ## Evidence section.
scores (impact, risk, size)Integer profile (1-5) used to evaluate each judgement.Step 4 scoring and step 6 reasoning.Step 3 defines anchors/interpolation in ## Criteria.
decision classification (APPROVE, REJECT, ESCALATE)Threshold-rendered outcome for a judgement.Step 5 renders the classification and step 6 explains the fired rule.Step 4 defines threshold policy and escalation behavior.
human decisionHuman reply for escalated judgements via Judgement N: APPROVE or Judgement N: REJECT.Step 7 collects replies and resolves classifications.Step 4 must preserve this reply contract.
summary bucketsFinal outcome rollup categories across all judgements.Step 9 and the ## Summary output block.Step 4 and step 5 must keep decision outcomes compatible with these buckets.

Review Workflow

  1. Split the input into independent judgements.
    • Judge each judgement separately.
    • Keep judgements small enough that one decision can be applied or rejected without bundling unrelated changes.
  2. Select the judge book whose Trigger best matches the judgement.
    • If no judge book clearly matches, stop and ask for a human decision or a new judge book.
  3. Gather evidence before scoring.
    • Read the artifacts required by the active judge book's Evidence section.
    • Prefer durable artifacts such as diffs, affected files, prior failures, validation output, and the recommendation text itself.
    • If the required evidence is missing, contradictory, or too weak to justify a score, do not guess. Escalate to the human or ask for the missing artifacts.
  4. Score the judgement on impact, risk, and size.
    • Use integers only: 1, 2, 3, 4, or 5.
    • Follow the active judge book's Criteria.
    • Treat 1-2 as low, 3 as medium, and 4-5 as high unless the judge book says otherwise.
  5. Render the decision classification from the judge book's Threshold.
    • Render exactly one outcome per judgement: APPROVE, REJECT, or ESCALATE.
    • If threshold rules do not resolve cleanly, classify as ESCALATE.
  6. Explain the decision.
    • For every automatically rendered judgement, state the score reasoning and the exact threshold rule that fired.
    • For ESCALATE, state which threshold triggered escalation, give a concise recommendation, and mark the judgement as pending human input.
  7. Pause for human input when needed.
    • If one or more judgements are ESCALATE and the human has not replied yet, stop after rendering a ## Human Decisions Needed section.
    • For each pending judgement, include the judgement number, short title, recommended decision, and one-line reason.
    • Ask the human to reply using exact lines of the form Judgement N: APPROVE or Judgement N: REJECT.
    • If the human replies for only some judgements, resolve only those judgements and leave the rest pending.
  8. Stop at classification output.
    • NEVER execute Apply or Validate actions inside ag-judge.
    • Do not emit execution instructions.
    • Preserve original scores and score reasoning unless the human explicitly asks for re-judgement.
  9. End with a summary covering all judgements.
    • Judgements with outcome APPROVE
    • Judgements with outcome REJECT
    • Judgements with outcome ESCALATE
    • Judgements pending human input
    • Include none for empty buckets.

Create Judgebook Workflow

Use this workflow when asked to add a new judgebook.

  1. Identify the topic and intended trigger.
    • Choose a short topic slug and name the file references/jb.[topic].md.
    • Write a one-sentence Trigger that clearly says when this book should be selected.
  2. Start from the template.
    • Copy the structure from references/jb.template.md.
    • Keep all required sections: Trigger, Evidence, Criteria, Threshold, Alignment.
  3. Fill in the scoring model.
    • Define concrete anchors for impact, risk, and size.
    • Prefer explicit 1/3/5 anchors and say how to interpolate 2 and 4.
  4. Define the decision policy.
    • State threshold rules for APPROVE, REJECT, and ESCALATE.
    • Make the escalation path compatible with the main skill:
      • render pending items under ## Human Decisions Needed
      • require replies in the form Judgement N: APPROVE or Judgement N: REJECT
      • leave unresolved items in Judgements pending human input
  5. Keep judgebooks classification-only.
    • Do not include Apply, Validate, or Delegation sections in judgebooks.
    • Judgebooks should only define how to score and classify judgements.
  6. Register the new judgebook in this skill.
    • Add one bullet under Available judge books describing when it should be used.
  7. Validate the result.
    • Re-read the new judgebook and confirm it is consistent with the Review Workflow.
    • Run python3 /Users/kevinlin/.codex/skills/sc/scripts/quick_validate.py /Users/kevinlin/code/skills-private/ag-judge.

Output Format

Render one section per judgement:

markdown
## Judgement N: <short title>
- Judge book: <path>
- Evidence: <artifacts reviewed or missing evidence that forced escalation>
- Scores: impact <1-5>/5, risk <1-5>/5, size <1-5>/5
- Decision outcome: APPROVE | REJECT | ESCALATE
- Reasoning: <why the scores and threshold produced this classification>

For escalated judgements waiting on a reply, also render:

markdown
## Human Decisions Needed
- Judgement N: recommend APPROVE | REJECT
  - Reason: <one-line threshold-based reason>
  - Reply with: `Judgement N: APPROVE` or `Judgement N: REJECT`

Then render:

markdown
## Summary
- Judgements with outcome APPROVE: ...
- Judgements with outcome REJECT: ...
- Judgements with outcome ESCALATE: ...
- Judgements pending human input: ...

Bundled files

The model reads these on demand while the skill is loaded. They are exposed as readable files and are never executed.

Frequently asked questions

What does the Ag Judge AI skill do?

Judge agent work as approve, reject, or escalate.

Why use Ag Judge on TypingMind?

Because you install it once and use it with any model. Ag Judge is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Ag Judge in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/kevinslin/agstack/tree/main/active/ag-judge. TypingMind reads its SKILL.md and bundles its files and installs it as a skill you can enable per chat.

Which AI models can use Ag Judge?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Ag Judge?

As many as you like. As long as a model supports skills, you can use Ag Judge with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Ag Judge AI skill free?

It is published on GitHub by kevinslin. Check the repository for licensing terms. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇