Slash Commands

/ocls-review

Validate current changes against the four OCLS phases and produce patch suggestions for violations.

Install

cp skills/commands/ocls-review.md <your-project>/.claude/commands/ocls-review.md

Copy this repo's file into your project and the resource activates in your Claude Code session immediately.

markdownskills/commands/ocls-review.md
---
description: Validate current changes against the four OCLS phases (OWN / CONTRACT / LAYER / SHARPEN) and produce patch suggestions for violations.
---

Review the files just changed (`git status`) through the OCLS lens. Use the project-root `GOVERNANCE.md` as the reference baseline.

**OWN**

- For any new outcomes, is the owner (human or AI) registered in GOVERNANCE.md's ownership structure?
- If the outcome is AI-owned, are all judgment conditions explicit?
- Is the escalation path defined for failure?

**CONTRACT**

- For any new modules, tools, or agents, are the input/output schema, refusal conditions, and failure modes declared in the contract?
- Is a contract violation detectable at runtime?

**LAYER**

- Are the collaboration rules intact?
- Is the context-transfer scope the minimum required?
- Is the separation of short-term state from long-term memory preserved?

**SHARPEN**

- Have measurement points (logs, metrics) been added?
- Does operational data flow into the SHARPEN loop?
- Are the evaluation criteria quantitative?

## Output format

Follow this format exactly. For every violation include (1) a file:line citation, (2) a summary of the current code, (3) a concrete patch direction.

```
## OCLS Review — <branch>

### OWN
- [ ] <violation> (src/agents/response.ts:42)
  - Current: responseAgent returns a result with no declared owner
  - Suggestion: add an owner field to AgentDefinition + update GOVERNANCE.md ownership structure
- [x] <passed item> (src/agents/intake.ts:15)

### CONTRACT
- [ ] ...

### LAYER
- [ ] ...

### SHARPEN
- [ ] ...

## Summary
- Violations: N total (OWN n, CONTRACT n, LAYER n, SHARPEN n)
- Priority actions: <1–3 High items>
- Related patterns: <names of relevant reopt skills>
```

If there are no violations, state `- no violations` in that section, but still list passing items to make clear that the review was performed.