prompt-optimizer

Optimize AI prompts through iterative evaluation and refinement loops.

Updated May 5, 2026
One-click install
npx skills add https://github.com/iani-kuli/harness_bro --skill prompt-optimizer-iani-kuli
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: prompt-optimizer
Source: https://github.com/iani-kuli/harness_bro/tree/main/.claude/skills/ported/prompt-optimizer
Command: npx skills add https://github.com/iani-kuli/harness_bro --skill prompt-optimizer-iani-kuli

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill addresses the challenge of creating unreliable or poorly performing AI prompts by providing a structured, evaluation-based framework for iterative refinement.

Core Features & Use Cases

  • Evaluation-Driven Optimization: Uses a systematic loop to baseline, critique, and improve prompts based on concrete test cases.
  • Model-Specific Adaptation: Provides guidance for tailoring prompts to specific model families like Claude, OpenAI, or Gemini.
  • Use Case: When a system prompt is producing inconsistent results or failing to follow constraints, use this Skill to cluster failures, generate optimized candidates, and validate them against a holdout set.

Quick Start

Use the prompt-optimizer skill to refine the system prompt for our coding agent based on the current failure logs.

Frequently Asked Questions about prompt-optimizer

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

FAQPage Schema
How do I optimize AI prompts that are producing inconsistent results?

To optimize AI prompts producing inconsistent results, use a structured evaluation loop to baseline, critique, and iteratively refine system instructions against concrete test cases. This process clusters failures and validates optimized candidates against a holdout set to ensure stable outputs.

Can I adapt a system prompt to work across different LLM model families?

Yes, you can adapt a system prompt for different LLM model families. The optimization process provides specific guidance for tailoring and porting instructions to target models like Claude, OpenAI, or Gemini, ensuring high-quality and stable outputs across distinct architectures.

What is evaluation-driven prompt engineering and when do I need it?

Evaluation-driven prompt engineering is a systematic method to baseline, critique, and improve AI instructions using defined evaluation sets. You need it when a system prompt fails to follow constraints or produces unreliable outputs, requiring causal constraint mapping to debug complex agent behaviors.

How do I debug complex agent behaviors failing to follow constraints?

You debug complex agent behaviors by applying causal constraint mapping to identify failure clusters in logs. The refinement loop generates optimized prompt candidates and validates them against a holdout set, ensuring the agent adheres to defined constraints and performs reliably.

What is the best way to refine LLM instructions using test cases?

The best way to refine LLM instructions is through an iterative evaluation loop that uses concrete test cases to baseline performance. It critiques failures, generates optimized prompt candidates, and validates them against a holdout set to ensure high-quality model outputs.