codex-performance-goal
Use when the user wants measurable performance optimization, latency/cost/memory/throughput improvement, benchmark-driven tuning, evaluator-gated optimization, or a goal-mode performance loop; require
SKILL.mdskills/codex-performance-goal/SKILL.md
GitHubCodex Performance Goal
Optimize performance only against an explicit evaluator. This is the native Codex adaptation of OMX $performance-goal: keep evaluator-gated progress, goal honesty, small reversible patches, and completion audit; replace .omx/goals/performance with repo-local benchmark artifacts or task/work-trace files when durable state is needed.
Contract
- Do not optimize before a baseline and pass/fail contract exist.
- Define the metric: latency, throughput, memory, cost, bundle size, accuracy/latency tradeoff, or another measurable target.
- Prefer existing project benchmarks and profiling scripts.
- Keep changes small and reversible.
- Record every measurement with command, environment, inputs, and result.
- Do not mark a goal complete until the evaluator passes and regression checks are clean.
Workflow
- Clarify objective and metric.
- Find or create the evaluator: command, benchmark script, profiling procedure, or reproducible manual measurement.
- Capture baseline before edits.
- Identify bottleneck hypotheses from evidence.
- Apply one optimization at a time.
- Rerun evaluator and regression tests.
- Keep, revert, or revise based on evidence.
- Finish with before/after results and residual risk.
Goal Mode
When Codex goal tools are active, treat the active goal as focus/accounting only. Call update_goal({status:"complete"}) only after evaluator pass plus completion audit proves the whole objective.
Output Shape
- Objective and metric
- Evaluator contract
- Baseline
- Changes tried
- Final measurement
- Regression checks
- Kept/reverted decisions
- Residual risk and follow-up
References
Read references/performance-evidence-checklist.html for measurement quality gates.