agentleFS
Antonio-TresolAntonio-Tresol/daemon/.claude/skills/harness/SKILL.md

harness

Skill2 starsChanged 8 months agoMITView on GitHub

Query daemon for harness engineering improvements, failures, and timeline — then apply them to improve the codebase for agents

  • Sends data out

37 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use retro, verify and 3 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • AWSSkill

    retro

    Conduct a retrospective on a coding session.

    Also in 3 projects that use this

  • Microsoft AzureSkill

    verify

    End-to-end app testing pipeline for browser-based web apps on cloud browsers via Azure Playwright Workspaces: verify the live app, author tests for working flows, heal failing tests, then re-run with video and produce one consolidated report. Three phases (app verification, test authoring, test healing) plus a scoped final sanity run; each phase emits a sub-report. Use when asked to "verify my app", "make sure my app works and has good test coverage", "do a full QA pass", "add tests where I'm missing coverage", "fix failing tests and add new ones", "smoke test before deploy", "QA my deployment", or any combined verify-and-test ask. Requires Azure CLI (`az login`) and a Playwright Workspace resource ID — bootstraps configs on first invocation. Browser-based web apps with Playwright only — not for unit/API tests, native mobile/desktop, load/perf, or full accessibility audits.

    Also in 3 projects that use this

  • GoogleSkill

    code-review

    Adversarial systems, concurrency, memory-model, and architecture code review protocol. Use this skill whenever asked to review code, PRs, diffs, or branches in Filament.

    Also in 4 projects that use this

  • GoogleSkill

    grill-me

    A relentless interview to sharpen a plan or design.

    Also in 3 projects that use this

  • SentrySkill

    skill-creator

    Create new agent skills following the Agent Skills specification. Use when asked to "create a skill", "add a new skill", "write a skill", "make a skill", "build a skill", or scaffold a new skill with SKILL.md. Guides through requirements, writing, registration, and verification.

    Also in 3 projects that use this

The file

We split this skill into the rules it gives an agent

12 rules. 0 are common, 8 are distinctive, and 4 are very specific to this project.

  • 0

    Common

    Most of the 24 edited versions we read keep these.

  • 8

    Distinctive

    This author's own choices. Worth a look.

  • 4

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    If no active sessions, get the most recent:

    line 19
  2. Distinctive:

    Look for patterns: repeated failure types, specific tools that fail often, permission issues.

    line 52
  3. Very specific:

    Hook suggestions: Add to .claude/settings.json under the appropriate hook event

    line 68
  4. Very specific:

    Skill suggestions: Create a new .claude/skills/<name>/SKILL.md file

    line 69
  5. Very specific:

    Context suggestions: Update CLAUDE.md or create docs in docs/

    line 70
  6. Distinctive:

    Architecture suggestions: Add lints, structural tests, or hook enforcement

    line 71
  7. Distinctive:

    Subagent suggestions: Update CLAUDE.md with team strategy guidance

    line 72
  8. Distinctive:

    Tool suggestions: Add MCP server configuration or create utility scripts

    line 73
  9. Distinctive:

    Always ask the user before applying changes.

    line 75
  10. Distinctive:

    After applying improvements, verify they work:

    line 79
  11. Very specific:

    If the API returns errors, check if the server is running: curl -s localhost:3000/api/agent | jq

    line 106
  12. Distinctive:

    Always preserve existing hooks when adding new ones — merge, don't replace

    line 108

“Common” is measured: kept by at least 6 in 10 of the 24 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Harness Engineering

You are performing a harness engineering review. The Claude daemon is running at localhost:3000 and has been monitoring Claude Code sessions — capturing events, analyzing failures, and generating improvement suggestions.

Your job is to query the daemon API, understand what's working and what's not, and make concrete improvements to the codebase's agent harness.

Step 1: Discover Sessions

Find the most recent or active session:

curl -s localhost:3000/api/agent/sessions?status=active | jq '.data[0]'

If no active sessions, get the most recent:

curl -s localhost:3000/api/agent/sessions?limit=1 | jq '.data[0]'

Save the id field — you'll need it for all subsequent queries.

Step 2: Get Harness Improvements

Query the improvement suggestions:

curl -s "localhost:3000/api/agent/improvements?sessionId=SESSION_ID" | jq '.data'

These are categorized by area:

  • hooks — Pre/post tool hooks for enforcement, auto-formatting, blocking dangerous patterns
  • skills — Custom slash commands for repeatable workflows
  • subagents — Agent teams for parallel work, specialized roles
  • tools — MCP servers, custom tools, observability integrations
  • context — CLAUDE.md, docs/, design docs, architecture maps
  • architecture — Layer boundaries, dependency rules, naming conventions
  • legibility — Structured logging, error messages with remediation, self-documenting APIs

Step 3: Get Failures

Query the detected failures:

curl -s "localhost:3000/api/agent/failures?sessionId=SESSION_ID" | jq '.data'

Look for patterns: repeated failure types, specific tools that fail often, permission issues.

Step 4: Present Findings

Summarize what you found, grouped by category:

  1. Critical (severity: high) — Address these first
  2. Friction (severity: medium) — These slow agents down
  3. Nice-to-have (severity: low) — Polish items

For each suggestion that has a config field, show the ready-to-use configuration.

Step 5: Apply Improvements

For each suggestion, offer to implement it:

  • Hook suggestions: Add to .claude/settings.json under the appropriate hook event
  • Skill suggestions: Create a new .claude/skills/<name>/SKILL.md file
  • Context suggestions: Update CLAUDE.md or create docs in docs/
  • Architecture suggestions: Add lints, structural tests, or hook enforcement
  • Subagent suggestions: Update CLAUDE.md with team strategy guidance
  • Tool suggestions: Add MCP server configuration or create utility scripts

Always ask the user before applying changes. Show what you'll change and get confirmation.

Step 6: Verify

After applying improvements, verify they work:

  • For hooks: trigger the relevant tool use and check the hook fires
  • For skills: run the skill with /skillname
  • For context: read the file and verify it's correct
  • For architecture: run npx tsc --noEmit and linters

Advanced: GraphQL Queries

For complex queries, use the GraphQL endpoint:

curl -s -X POST localhost:3000/api/agent/graphql \
  -H 'Content-Type: application/json' \
  -d '{"query": "{ improvements(sessionId: \"SESSION_ID\", severity: HIGH) { area problem suggestion config effort } }"}'

Multi-level timeline:

curl -s -X POST localhost:3000/api/agent/graphql \
  -H 'Content-Type: application/json' \
  -d '{"query": "{ timeline(sessionId: \"SESSION_ID\") { plans(level: 0) { name phase tasks { name status } } } }"}'

Important

  • The daemon must be running at localhost:3000 for this skill to work
  • If the API returns errors, check if the server is running: curl -s localhost:3000/api/agent | jq
  • Prioritize high-severity improvements with trivial/small effort first — maximum impact, minimum cost
  • Always preserve existing hooks when adding new ones — merge, don't replace

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.