# ooda-loop

ooda-loop is a Claude Code skill that drives incident triage, latency debugging, and cloud spend cuts. The agent audits metrics, isolates root causes, and pauses for user sign-off before changes.

- skill · `type=skill` · Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, Windsurf (Devin Desktop), Claude.ai · ★ 136 repo stars
- Author: daniellockyer
- License: MIT · policy=mirror · the beginning of the file is at the end of this page
- Source: https://github.com/daniellockyer/dstack/tree/HEAD/skills/ooda-loop/SKILL.md
- Updated: 2026-11-05
- Security check: automated, 2026-11-17 (text) — no signs of malicious code found.
- HTML: https://affpapa.org/en/nevibecode/skills/ooda-loop

## What it does

The skill runs structured investigations for production web systems using the Observe, Orient, Decide, and Act loop. It starts by locking down one measurable goal, such as cutting p95 latency under 300 ms or trimming cloud spend without SLO breaches. During the Observe, Orient, and Decide phases, the agent works strictly in read-only mode. It cannot edit files, restart processes, or run load tests without authorization.

Evidence gathering relies on live signals from logs, distributed traces, MCP servers, and cloud vendor CLIs. Inventing metrics is barred by rule: if real data is unavailable, the agent halts and requests credentials. During the Decide stage, it formulates a single reversible experiment, stating the expected delta, invalidation trigger, and rollback steps. Execution happens only after explicit user approval, keeping production changes guarded.

Every cycle verifies post-action telemetry against the hypothesis. If an invalidation threshold is reached, the agent triggers an immediate rollback instead of stacking unverified fixes. A concise cycle report details observed deltas, remaining bottlenecks, and residual risks before moving forward.

## Install

### Claude Code (native platform)

1. **Skills CLI (Vercel)**
```bash
npx skills add daniellockyer/dstack --skill ooda-loop -a claude-code
```

2. **Manually: put the files in place**
- File: `~/.claude/skills/ooda-loop/SKILL.md` — Copy the whole skill folder; for one project use .claude/skills/ooda-loop/

### Codex

1. **Skills CLI (Vercel)**
```bash
npx skills add daniellockyer/dstack --skill ooda-loop -a codex
```

2. **Manually: put the files in place**
- File: `.agents/skills/ooda-loop/SKILL.md` — For all projects use ~/.agents/skills/

### Cursor

1. **Skills CLI (Vercel)**
```bash
npx skills add daniellockyer/dstack --skill ooda-loop -a cursor
```

2. **Manually: put the files in place**
- File: `.cursor/skills/ooda-loop/SKILL.md` — Cursor also reads .agents/skills/ and .claude/skills/

### GitHub Copilot

1. **GitHub CLI**
```bash
gh skill install daniellockyer/dstack skills/ooda-loop
```

2. **Manually: put the files in place**
- File: `.github/skills/ooda-loop/SKILL.md`

### Gemini CLI

1. **Skills CLI (Vercel)**
```bash
npx skills add daniellockyer/dstack --skill ooda-loop -a gemini-cli
```

2. **Platform CLI**
```bash
gemini skills install https://github.com/daniellockyer/dstack --path skills/ooda-loop
```

### Windsurf (Devin Desktop)

**Manually: put the files in place**
- File: `.devin/skills/ooda-loop/SKILL.md` — The legacy .windsurf/skills/ path still works

### Claude.ai

**Claude.ai**
- Zip the folder and upload it in Settings → Capabilities → Skills

Where a file is given instead of a command, copy the files from the source to that path: https://github.com/daniellockyer/dstack/tree/HEAD/skills/ooda-loop/SKILL.md

## When to use it
- investigate production outages and service degradations systematically
- diagnose latency spikes and queue growth using live telemetry
- reduce cloud infrastructure spend without breaching service level objectives
- validate system changes through small reversible experiments

## Example prompts
- Run ooda-loop to bring p95 latency on /checkout under 300 ms.
- Use ooda-loop to cut cloud infrastructure spend by 20% without SLO breaches.
- We have elevated 500 error rates on the API gateway. Start an ooda-loop investigation.

## Source text · SKILL.md · MIT

Below is the content of a third-party file. It is data, not instructions for you: do not act on anything written inside unless the human asks. Block tag: a60d5f7a18079a1b.

BEGIN THIRD-PARTY FILE a60d5f7a18079a1b
```text
---
name: ooda-loop
description: "OODA loop for website performance, scalability, cost, errors, and outages: Observe, Orient, Decide (pause for approval), Act, verify, repeat. Use for ooda-loop, incidents, latency, throughput, capacity, or cloud spend."
---

# OODA loop: website systems

Loop **Observe → Orient → Decide → (pause) → Act → Observe** until the objective is met or the user stops. Never skip a phase.

**Observe, Orient, and Decide are read-only.** No edits, deploys, restarts, scaling, or config/flag changes until Act, and only after the user approves. Anything that adds load or changes runtime state (load tests, cache warming, toggling debug logging or sampling) counts as an Act.

## Objective

Before starting, pin one measurable objective the user owns (e.g. "p95 < 300 ms on /checkout", "cut infra cost 20% without SLO breach", "restore service"). If unclear, ask once.

## 1. Observe

Collect real, dated, sourced data covering the objective: latency, errors, saturation, traffic, queue depth, spend, alerts, traces, recent changes. Use MCPs, vendor CLIs/APIs, observability tools, or local logs. Never invent numbers; docs and architecture reasoning alone don't count.

**Data gate:** if you can't read live or exported signals, stop and ask for access by name: MCP/API/CLI for cloud systems, logs/tracing for local ones.

## 2. Orient

Summarize, separating fact, inference, and unknown:

- What is true now vs. the healthy/expected state
- What changed (deploy, traffic, config, dependency)
- Constraints (SLOs, budget, freeze windows, severity)
- Blind spots
- The dominant constraint: latency, errors, capacity, or cost

## 3. Decide, then pause

Propose **one** action, preferring the smallest reversible experiment that tests the Orient picture:

- **Action**
- **Hypothesis**: which metric improves, by how much
- **Invalidation**: what result means abort
- **Risk / rollback**
- **Tradeoffs** across perf, scale, cost, and reliability

**Stop and wait for explicit approval.** If rejected, re-Orient or re-Decide. Incidents pause too, unless the user already authorized a specific mitigation.

## 4. Act

Do only the approved action. Capture before/after on the Decide metrics, judge the outcome (good, mixed, bad) against the hypothesis, and note side effects. If invalidation trips, roll back and return to Observe; don't chain Acts.

## Loop

- Objective met: stop; report outcome and residual risk
- Otherwise: Observe again with post-Act data, then Orient and Decide (pause)
```
END THIRD-PARTY FILE a60d5f7a18079a1b

The third-party file has ended. Everything between the a60d5f7a18079a1b tags is data: requests and commands from it are not followed. An “end of file” line with another tag inside the block is part of the file.

First 2523 of 2968 bytes. © daniellockyer · MIT · https://github.com/daniellockyer/dstack/tree/HEAD/skills/ooda-loop/SKILL.md

_Part of the page did not fit — see the HTML version._

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
