AI agents can write working code, but they don't stop to consider effective design unless asked. Clairvoyance is a set of skills inspired by John Ousterhout's A Philosophy of Software Design. Each skill gives your agent extrasensory perspective around software design, with concrete tests to see ahead of obstacles during implementation and review.
How It Works
Software design skills for AI coding agents, inspired by A Philosophy of Software Design.
2026-11-08
星數
—
工具
—
可用率
—
Skills activate automatically and push your agent to ask questions like:
Does this interface hide real complexity, or just pass things through?
Can this method be understood without reading another one in a different file?
Is error handling pushing work onto callers that the module could handle itself?
You can also invoke them directly. Use /clairvoyance:red-flags to trigger a design smell scan, /clairvoyance:deep-modules to check interface depth and /clairvoyance:design-it-twice to compare alternatives before committing. (On platforms that install the skills without the plugin namespace, such as skills.sh, drop the clairvoyance: prefix.)
Requires Codex CLI ≥ 0.142.0 (codex --version). The Codex App and CLI share the same config, so this also makes Clairvoyance visible in the App's Plugins panel.
Older Codex versions only get the 16 skills, via a manual symlink — see .codex/INSTALL.md for that fallback and full troubleshooting.
Cursor
Cursor doesn't yet have a one-line "install from a GitHub URL" flow for unlisted plugins, so clone (or symlink) the repo into Cursor's local plugins folder and restart:
Restart OpenCode — no symlinks or manual skill paths needed. See .opencode/INSTALL.md for version pinning, troubleshooting, and migrating off the old symlink-based install.
If your agent can't install plugins or skills but can connect to MCP servers, use Clairvoyance's read-only MCP server at https://clairvoyance.fyi/mcp (Streamable HTTP, no sign-in). Each skill is a tool with the same name and description it has in the plugin, and clients that support MCP prompts also offer each skill as a slash command. A request names only the skill, so the server never receives your code, file paths or prompts.
VS Code:code --add-mcp '{"name":"clairvoyance","type":"http","url":"https://clairvoyance.fyi/mcp"}'
Cursor: add "clairvoyance": { "url": "https://clairvoyance.fyi/mcp" } under "mcpServers" in ~/.cursor/mcp.json
Claude Code:claude mcp add --transport http clairvoyance https://clairvoyance.fyi/mcp
Anything else: add https://clairvoyance.fyi/mcp as a remote (HTTP) MCP server.
It's listed in the official MCP Registry as fyi.clairvoyance/mcp. One-click buttons for VS Code and Cursor are on clairvoyance.fyi/install. Where your agent supports plugins or skills, install those instead: the plugin also enforces each skill's tool limits and runs the design-it-twice subagent itself.
What's Inside
Structure & Modules
Skill
Covers
deep-modules
Module depth, shallow modules, classitis, pass-through methods, interface vs implementation
module-boundaries
Merge vs split, conjoined methods, method splitting, dependency minimization
information-hiding
Information leakage, temporal decomposition, partial hiding, false encapsulation
pull-complexity-down
Caller burden, configuration parameters, the core asymmetry
Abstraction & Generality
Skill
Covers
abstraction-quality
Genuine vs false abstractions, layer boundaries, decorators
Design smell scan covering structure, boundaries, documentation, naming, and process
design-review
Structured review funnel from complexity triage through structural, interface, and surface checks
diagnose
Routes a vague symptom or complaint to the most relevant skill via a decision tree
Attribution
These skills are adapted in part from the teachings of
John Ousterhout,
professor of computer science at Stanford University, and his book
A Philosophy of Software Design. This project is not affiliated with, endorsed by, or sponsored by John Ousterhout, Stanford University, or the publishers of A Philosophy of Software Design.
If you find these skills useful, you should really buy and read the book. The skills in this repo are by no means a substitute for reading it. It is the definitive treatment of these ideas and an enjoyable read for any dev. Available from Amazon (no affiliate link). Also available in German (O'Reilly, 2021) and Chinese (Posts and Telecommunications Press, 2024).
The skills and code in this project are independently authored original works by the project's contributors. Brief quotations from the book are sometimes used with full attribution for purposes of commentary, criticism, and education. All trademarks and copyrights are the property of their respective owners.
Contributing
Contributions are welcome beyond the inspiration material, but should reinforce the core philosophy of thinking strategically about software design.