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 agentmods add skills/fmind/dot/reduce-complexitynpx skills add fmind/dot --skill reduce-complexitygit clone --depth 1 https://github.com/fmind/dotWrote 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/fmind/dot/reduce-complexity)<a href="https://agentmods.dev/skills/fmind/dot/reduce-complexity"><img src="https://agentmods.dev/badge/skills/fmind/dot/reduce-complexity.svg" alt="Measured on agentmods" 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 | $0.00038 | $0.00678 |
| Opus 5 | $0.00019 | $0.00339 |
| Sonnet 5 | $0.00008 | $0.00136 |
| Haiku 4.5 | $0.00004 | $0.00068 |
Grade A, and why
reduce-complexity 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 yesterday.
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 — 36 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Reduce Complexity
A repeatable pass that removes accidental complexity from a codebase: measure, delete, flatten, verify. repository-review produces the candidate list read-only, project-health is the full refresh this pass belongs to, and improve-docs is the same pass for documentation.
Workflow
- Measure: largest files (
wc -lover tracked sources), duplicated blocks (rgfor repeated signatures), unused dependencies and exports, and config files nothing reads. - Use the language linters:
golangci-lint(unused,gocyclo),ruff(F401,C901),knipfor TypeScript, andmise tasksfor orphan tasks. - Sort by payoff: rank candidates by lines removed per risk; start with dead code and unused dependencies (zero behavior change), then duplication, then abstractions with a single implementation.
- Delete before abstracting: a helper used once is inlined; an interface with one implementation becomes the concrete type; a flag nobody sets is removed with its branches.
- Flatten: deep package trees become flat packages; nested conditionals become early returns; configuration replaces hard-coded branches.
- Verify each step:
mise run checkandmise run testafter every logical removal, so a regression is attributable to one change. - Report: before and after counts (files, lines, dependencies, tasks), what was removed and why, and anything intentionally kept.
Gotchas
- Behavior is the contract: public APIs, CLI flags, and on-disk formats change only with the user's agreement.
- Tests are not debt: never delete a failing test to simplify; fix or replace it per test-driven-development.
- One theme per commit: when asked to commit, group by removal theme (
refactor:orchore:) so each commit reverts cleanly.
Documentation
- golangci-lint · Ruff rules · knip
- Companion skills: project-health (full refresh), repository-review (candidate list), improve-docs (documentation pass), conventional-commit (commit messages).
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.
- yesterday First seen · 36 lines · 38 tokens per session scan A c82292bb2c63
reduce-complexity is a skill published in the GitHub repository fmind/dot (4 stars, last pushed yesterday), licensed MIT. It adds 38 tokens to every session and 678 once invoked, about $0.0002 per session on Opus 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-09-03.
Other skills, from other repositories
go-stack
Build Go projects, libraries, CLIs, TUIs, web apps, or ADK agents with the standard package layout and pinned tooling.
python-stack
Build typed Python projects with uv, Ruff, ty, pytest, Litestar, and Typer. Use for packages, CLIs, web apps, tests, typing, or API verification.
chezmoi
Manage chezmoi dotfiles: source naming, Go templates, age-encrypted secrets, and the edit-source then apply/diff workflow.
hugo
Canonical Hugo static-site stack with the Hextra docs theme — Hugo Modules, mise tasks, dprint, lefthook, and GitHub Pages deploy. Use for documentation sites, project docs, and static websites.
k8s-local
Create and manage local Kubernetes clusters (k3d or kind) and deploy to them with kubectl, helm, helmfile, and skaffold. Use for local k8s cluster setup, dev loops, and debugging.
release
Cut or verify a versioned release — bump semver, generate the changelog with git-cliff, tag and publish on GitHub, or reconcile an already-published tag and assets.