agent-harness-construction

Design agent action spaces and tool definitions with deterministic outputs.

Updated Mar 16, 2026
One-click install
npx skills add https://github.com/thmspi/claude-setup --skill agent-harness-construction-thmspi
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: agent-harness-construction
Source: https://github.com/thmspi/claude-setup/tree/main/.claude/skills/agent-harness-construction
Command: npx skills add https://github.com/thmspi/claude-setup --skill agent-harness-construction-thmspi

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Design and optimize AI agent action spaces, tool definitions, and observation formatting to improve completion rates and reliability.

Core Features & Use Cases

  • Action Space Design: Use stable, explicit tool names; inputs schema-first and narrow; return deterministic output shapes; avoid catch-all tools unless isolation is impossible.
  • Observation Design: Every tool response should include: status, summary, next_actions, artifacts.
  • Error Recovery Contract: For every error path, include root cause hint, safe retry instruction, explicit stop condition.
  • Context Budgeting: Keep system prompt minimal and invariant; move large guidance into skills loaded on demand; prefer references to files over inlining long documents; compact at phase boundaries.
  • Architecture Pattern Guidance: ReAct, Function-calling, Hybrid (recommended): planning + typed tool execution.
  • Benchmarking: Track completion rate, retries per task, pass@1 and pass@3, cost per successful task.
  • Anti-Patterns: Too many tools with overlapping semantics; opaque output with no recovery hints; error-only output without next steps; context overload with irrelevant references.

Quick Start

Provide an initial agent harness configuration that uses explicit tool names, deterministic outputs, and a minimal system prompt to begin a controlled task run.

Frequently Asked Questions about agent-harness-construction

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I optimize AI agent action spaces and tool definitions for better completion rates?

Optimize AI agent action spaces by using stable, explicit tool names, schema-first inputs, and deterministic output shapes. Avoid catch-all tools unless isolation is impossible, ensuring structured observations for higher task completion rates.

What should be included in AI agent tool observation formatting to prevent errors?

AI agent tool observation formatting should include status, summary, next_actions, and artifacts. Every tool response must explicitly provide these structured elements to guide subsequent agent steps and prevent unhandled execution errors.

How to design error recovery contracts for AI agent tool execution?

Design error recovery contracts by including a root cause hint, safe retry instruction, and explicit stop condition for every error path. This prevents opaque outputs and ensures agents converge on completion instead of looping.

What is the recommended architecture pattern for AI agent planning and tool use?

The recommended architecture pattern is a Hybrid approach combining planning with typed tool execution. This guides how agents plan, call tools, and recover from errors more reliably than standard ReAct or Function-calling alone.

Why does my AI agent fail to converge on task completion despite having multiple tools?

Agents fail to converge due to anti-patterns like too many tools with overlapping semantics or context overload with irrelevant references. Consolidate tool semantics and keep system prompts minimal to improve completion rates.

What metrics should I track when benchmarking AI agent tool use and reliability?

Benchmark AI agent reliability by tracking completion rate, retries per task, pass@1, pass@3, and cost per successful task. These metrics quantify whether your action space design and observation formatting improvements are effective.