discipline

discipline is a command for Claude Code from nyldn/claude-octopus. It costs 17 tokens per session (1,090 once invoked), scanned A, a copy of octo-discipline, MIT.

A mode switch that automatically applies development checks such as planning, verification, and review.

In plain words
What is it for?
Use it to enforce a disciplined process before coding, before completion, and after substantial changes.
Why use it?
It reduces the chance of coding without a plan or declaring work complete without checking it.

Command for Claude Code

Written for Claude Code: disable-model-invocation in frontmatter. Also seen: reads .claude/ paths; mentions subagents.

Part of the octo plugin — 70 skills, 106 commands, 10 agents, 18 hooks shipped together

Good fit Use it to enforce a disciplined process before coding, before completion, and after substantial changes.

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/nyldn/claude-octopus/discipline
About the project

Claude Octopus is an orchestration project that sends research, design, and coding tasks to Claude Code and other AI model providers so their results can be compared. Developers use it for multi-model work, disagreement detection, reviews, persistent context, and an optional workflow that moves from discovery through delivery. The catalogue entries are its commands, skills, agents, instructions, hooks, plugins, and settings.

nyldn/claude-octopus · 4,062 stars · on GitHub · reddit.com

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/nyldn/claude-octopus

Made for: Claude Code.

Or install octo, the plugin that ships this one along with the rest of its 70 skills, 106 commands, 10 agents, 18 hooks.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for discipline

README.md
[![agentmods](https://agentmods.dev/badge/commands/nyldn/claude-octopus/discipline/github.svg)](https://agentmods.dev/commands/nyldn/claude-octopus/discipline)
Your own site
<a href="https://agentmods.dev/commands/nyldn/claude-octopus/discipline"><img src="https://agentmods.dev/badge/commands/nyldn/claude-octopus/discipline/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for discipline

Your own site · 80×15
<a href="https://agentmods.dev/commands/nyldn/claude-octopus/discipline"><img src="https://agentmods.dev/badge/commands/nyldn/claude-octopus/discipline.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 17 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,090 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin 97% copy Near-identical to another mod in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00017 $0.01090
Opus 5 $0.00009 $0.00545
Sonnet 5 $0.00003 $0.00218
Haiku 4.5 $0.00002 $0.00109

Measured 8d ago against content hash 49ceaee26e63, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-11, from the pricing page.

Security

Grade A, and why

discipline scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 8d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

Origin

This is a copy

97% identical to octo-discipline — 3 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

commands/discipline.md · 116 lines

How it starts

The opening of the file, as written. The whole thing — 116 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Discipline Mode

Toggle automatic skill invocation for development discipline.

Usage

/octo:discipline on     — enable auto-invoke discipline checks
/octo:discipline off    — disable (back to manual invoke only)
/octo:discipline status — show current state

What Discipline Mode Does

When on, you MUST follow these rules automatically — no user prompt needed:

Development Gates

1. Brainstorm gate — Before writing ANY code or making changes, check:

  • Has the approach been discussed/planned? If not, read and follow the skill-thought-partner or skill-writing-plans source under ${HOME}/.claude-octopus/plugin/.claude/skills/.
  • This applies even for "simple" changes

2. Verification gate — Before saying "done", "fixed", "passing", or committing, read and follow skill-verification-gate:

  • Run the actual verification command, read output, only claim success with evidence

3. Review gate — After completing any non-trivial code change, automatically:

  • Spec compliance check + code quality review via subagent

4. Response gate — When receiving code review feedback, read and follow skill-review-response:

  • Verify feedback against actual code before implementing

5. Investigation gate — When encountering ANY bug, error, or test failure, read and follow skill-debug:

  • Root cause investigation before proposing fixes

Knowledge Work Gates

6. Context gate — At the start of any task, detect dev vs knowledge work. If research, writing, design, or strategy — switch to KM mode. Use skill-context-detection.

7. Decision gate — When comparing options or evaluating trade-offs, present a structured comparison with criteria and scores — not just prose pros/cons. Use skill-decision-support.

8. Intent gate — Before any creative or writing task (README, docs, copy, design), lock in the goal and audience first. Validate output against locked goals. Use skill-intent-contract.

How It Works

When the user runs /octo:discipline on, persist the setting:

Read the full file on GitHub · 116 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 8d ago First seen · 116 lines · 17 tokens per session scan A 49ceaee26e63

Subscribe to this mod's changes

discipline is a command published in the GitHub repository nyldn/claude-octopus (4,062 stars, last pushed today), licensed MIT. It adds 17 tokens to every session and 1,090 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. It is 97% identical to octo-discipline, differing in 3 lines, and is treated as a copy.