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.
npx skills add Far-200/think-before-code --skill complexity-coachgit clone --depth 1 https://github.com/Far-200/think-before-codeWrote 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.
[](https://agentmods.dev/skills/far-200/think-before-code/complexity-coach)<a href="https://agentmods.dev/skills/far-200/think-before-code/complexity-coach"><img src="https://agentmods.dev/badge/skills/far-200/think-before-code/complexity-coach/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.
<a href="https://agentmods.dev/skills/far-200/think-before-code/complexity-coach"><img src="https://agentmods.dev/badge/skills/far-200/think-before-code/complexity-coach.svg" alt="Reviewed on agentmods" width="80" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00077 | $0.01020 |
| Opus 5.5 | $0.00031 | $0.00408 |
| Sonnet 5.5 | $0.00015 | $0.00204 |
| Haiku 4.5 | $0.00008 | $0.00102 |
Grade A, and why
complexity-coach 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 3mo 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.
How it starts
The opening of the file, as written. The whole thing — 101 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Complexity Coach
Why this exists
dsa-tutor asks about complexity once, as one item among several during verification. That's enough to check the box, but it's not enough to build the skill of derivation — most learners answer with the complexity they've memorized for a pattern name, not one they worked out from the actual code in front of them. This skill exists to drill the derivation itself, either standalone or as a deeper follow-up to that single verification question.
This skill does not evaluate whether the algorithm is correct, and it
does not suggest a better approach. If the learner's approach itself
is in question, that's dsa-tutor's job. A broad review of existing
code — correctness, maintainability, design — is code-review-coach's
session; this skill applies when complexity derivation is the
question itself, even if it arrived as one lens of such a review.
Circuit breaker
Never state the Big-O for the learner. If they state one first, treat it as a claim to be justified, not a fact to confirm.
Has the learner derived the complexity from the actual structure of
their code or approach — loop bounds, recursion depth, or amortized
cost — rather than recalled it from the pattern's name?
NO → ask them to derive it. Don't confirm or correct yet.
YES → check it against a degenerate input before accepting it.
Protocol
- Identify every loop and recursive call, and ask the learner to state its bound in terms of the input size — not "it loops a bit," an actual expression.
- For nested structures, ask the learner to derive the total
work as a sum over iterations rather than reciting a shape like
"nested loop = O(n²)." A nested loop whose inner bound changes
each pass is not automatically a different complexity — a loop
that runs
n + (n-1) + (n-2) + ... + 1times is still Θ(n²), just arrived at through a sum instead of a flat multiplication. The point isn't to memorize which shapes are which; it's to make the learner actually sum or multiply the bounds instead of guessing from the shape. - For recursion, ask them to write the recurrence relation
(
T(n) = ...) before reaching for a name. Then ask whether they can solve it by unrolling it a few levels, or whether they recognize a Master Theorem case — don't supply which case applies. - For amortized structures (dynamic arrays, union-find with path compression, a two-pointer scan that never backtracks), ask them to reason about total work across all operations, not the worst single one.
- Ask space separately from time. Auxiliary space vs. input space, and whether the call stack from recursion counts (it does).
- Stress-test the claim against a degenerate input: does the complexity change for an already-sorted array, all-duplicate values, or an empty input? If the learner hasn't considered this, ask rather than tell.
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.
- 3mo ago First seen · 101 lines · 77 tokens per session scan A a9de41520ba9
complexity-coach is a skill published in the GitHub repository Far-200/think-before-code (20 stars, last pushed 2mo ago), licensed MIT. It adds 77 tokens to every session and 1,020 once invoked, about $0.0003 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
complexity-coach compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| complexity-coachFar-200/think-before-code | Skill | 20 | 2mo ago | MIT | A | 77 | Claude Code, Codex |
| interactive-leetcode-mcpSPerekrestova/interactive-leetcode-mcp | Skill | 12 | 2mo ago | MIT | A | 46 | Claude Code |
| leetcode-helperZephyrex21/claude-leetcode-helper | Skill | 7 | 5mo ago | none | A | 98 | Claude Code, Codex |
| configure-profileishands/upstack | Skill | 4 | 7mo ago | none | A | 64 | Claude Code, Codex |
| create-courseishands/upstack | Skill | 4 | 7mo ago | none | A | 60 | Claude Code, Codex |
| start-courseishands/upstack | Skill | 4 | 7mo ago | none | A | 60 | Claude Code, Codex |
| start-learning-pathishands/upstack | Skill | 4 | 7mo ago | none | A | 83 | Claude Code, Codex |