Skip to content
Back to skills

socratic

ASecurity

This skill should be used when the user asks to "build", "design", "scaffold", "architect", or "plan" any system, feature, service, app, agent, pipeline, connector, or tool — especially when the request is short, vague, or underspecified. It should also be used when the user asks to "review this architecture", "what am I missing", "ask me the right questions", "poke holes in this", or requests a design review before implementation. The skill interrogates the design silently across the relevan...

  • 142 stars
  • 0 votes
  • 0 copies
  • 2 views
  • Added August 30, 2026
ai-agentsrustrailstestingapidatabasefrontendbackendci/cdsecurityperformance

Works with

  • cli
  • api

Security analysis

A100/100

Pro scans all 18 files and shows the line behind each finding

Scanned December 3, 2026

npx -y skills add m4vic/socratic --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of socratic?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for socratic
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/m4vic-socratic/badge)](https://www.skillsdirectory.com/skills/m4vic-socratic)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: socratic
description: This skill should be used when the user asks to "build", "design", "scaffold", "architect", or "plan" any system, feature, service, app, agent, pipeline, connector, or tool — especially when the request is short, vague, or underspecified. It should also be used when the user asks to "review this architecture", "what am I missing", "ask me the right questions", "poke holes in this", or requests a design review before implementation. The skill interrogates the design silently across the relevant engineering domains (requirements, frontend, backend, data, API, security, infra, testing, observability, AI/LLM, mobile, product, cost, compliance, maintenance), resolves what the codebase and engineering defaults can answer, and surfaces only the decisions that require the user's authority.
---


# Socratic

Question yourself till you're left with only answers.

A curated bank of 697 questions a senior engineer asks before and during a build, split by domain. **The default mode is self-interrogation, not interviewing the user.** Read the codebase, apply engineering defaults, reason through the relevant questions, and ask the user only for decisions nobody but they can make.

## Two modes

**Mode A — Self-interrogation (default).** Ask and answer the relevant questions internally, then show the resulting contract once.

**Mode B — Interactive interview (opt-in).** Ask the user one yes/no question at a time. Enter this mode only when the user asks to be interviewed, walked through the decisions, or questioned one at a time.

If unsure, use Mode A. Silence is not a request to be interviewed.

## Mode A — Self-interrogation

### 1. Build the working domain set dynamically

This is the single routing rule. The presets at the end of this file are derived from it, not a second router.

Domains are numbered by file: `00` requirements, `01` frontend, `02` backend, `03` data, `04` api, `05` security, `06` infra, `07` testing, `08` observability, `09` ai-llm, `10` mobile, `11` product-ux, `12` cost-performance, `13` compliance, `14` team-maintenance. Domain `NN` means `questions/core/NN-*.md` at Core depth and `questions/NN-*.md` at Full depth.

**Step 1 — Always include** `00` Requirements and `07` Testing for every build.

**Step 2 — Match signals.** Inspect both the request and the existing project. Every signal that matches adds all of its domains:

| Signal in the request or project | Domains |
|---|---|
| UI, page, component, dashboard, form, frontend | 01 |
| website, landing page, marketing site, redesign, visual design, look and feel | 01, 11 |
| service, endpoint, job, queue, worker, backend, business logic | 02 |
| database, schema, storage, persistence, migration, cache | 03 |
| API, SDK, webhook, connector, integration, OAuth | 04 |
| authentication, accounts, login, sessions, secrets, untrusted input, file upload | 05 |
| public exposure: public API, internet-facing, open signup | 05, 08, 12 |
| payments, billing, money movement | 02, 03, 05, 13 |
| deployment, CI/CD, containers, hosting | 06 |
| infrastructure change: cloud resources, IaC, networking, clusters | 06, 12, 14 |
| production, unattended work, cron, scheduled jobs | 08 |
| AI, LLM, agent, prompt, model, tool use | 09 |
| RAG, embeddings, vector store, document ingestion | 09, 03, 13 |
| ETL, data pipeline, batch processing | 03, 06, 08, 13 |
| mobile, iOS, Android, offline, PWA | 10 |
| human-facing workflow, onboarding, chatbot, assistant, CLI, error messages | 11 |
| scale, latency, traffic, token or cloud spend | 12 |
| personal or regulated data, health, finance, minors, licensing | 13 |
| maintained, long-lived, or team-owned work | 14 |

**Step 3 — Apply dependencies.** A selected domain also requires:

| Selected | Also add | Why |
|---|---|---|
| 04 API | 05 | Every integration crosses a trust boundary: credentials, scopes, untrusted payloads. |
| 09 AI/LLM | 05, 08, 12 | Prompt injection and tool permissions; non-deterministic output needs traces; token spend grows silently. |
| 10 Mobile | 01, 05, 11 | A device UI, on-device data and credentials, a human user. |
| 06 Infra | 08 | Anything deployed must be observable. |

Dependency targets have no dependencies of their own, so one pass is complete.

Do not stop at the first match. If answering one domain surfaces a new signal mid-build — a "simple form" turns out to accept file uploads — re-run steps 2 and 3 for that signal and continue until a complete pass adds no new domains.

### 2. Load the smallest sufficient base question depth

Keep the user-facing behavior unchanged while controlling context use:

- **Core (default):** For routine, prototype, internal, or moderately scoped work, read the matching files under `questions/core/`. Always include `questions/core/00-requirements.md` and `questions/core/07-testing.md`.
- **Full:** For production systems, external users, public APIs, authentication, money, PII, regulated data, autonomous tools, costly or irreversible actions, or an explicit deep/full/audit request, read the matching complete files directly under `questions/`. Always include the complete Requirements and Testing files.
- **Escalation:** If a core answer exposes a serious security, reliability, compliance, scale, or operational risk, replace that core domain with its complete file before building.

Treat `$socratic lite` or `$socratic quick` as an explicit Core request. Treat `$socratic deep`, `$socratic full`, and `$socratic audit` as explicit Full requests. Never load all fifteen complete files unless the system genuinely spans all fifteen domains.

Questions consume context even when asked silently. Optimize for material risks resolved, not the number of questions processed.

### 3. Add specialized knowledge packs only when they sharpen the task

Base domain files stay primary. Packs are optional overlays, not replacements.

- Use a pack when the task clearly maps to a specialized body of tradeoffs, failure modes, or heuristics that the generic domain files do not capture well enough. First consult `packs/registry.md` after selecting the base domains.
- Load `packs/<pack>/core.md` after the base domain files. A pack may also provide `full.md`; load it only when the core pack proves insufficient for the decision at hand. Most packs ship core only.
- Prefer zero to two packs per task. Too many packs recreates the same token problem the Core/Full split was added to solve.
- Treat pack content as compact decision support: question, default answer pattern, tradeoffs, anti-patterns, escalation triggers, and verification checks.
- Select a pack by the capability it adds, not by recognising a book title. Its source material is provenance, not the routing rule.
- For pack structure or naming guidance, read `references/knowledge-pack-architecture.md`.

Examples:

- Use `packs/software-design/core.md` when reviewing complexity, module boundaries, interface design, or accidental generality.
- Use `packs/domain-modeling/core.md` when carving a system into boundaries, naming concepts, or deciding what must stay consistent together.
- Use `packs/data-systems/core.md` when reviewing durable state, consistency, queues, retries, migrations, or failure recovery.
- Use `packs/operations/core.md` when the work must survive production — timeouts, retries, load shedding, rollback, or alerting.
- Use `packs/threat-modeling/core.md` when mapping trust boundaries, attacker paths, abuse cases, mitigations, or security verification.
- Use `packs/ai-engineering/core.md` when building an LLM product, RAG system, model evaluation, or tool-enabled workflow.
- Use `packs/agent-design/core.md` when building an agent or subagent, splitting work across agents, setting tool permissions, or deciding how agent output gets verified.
- Use `packs/legacy-change/core.md` when modifying code that already works, has no tests, or is being replaced incrementally.
- Use `packs/testing-design/core.md` when deciding what to test, what to mock, or why a suite is brittle or untrusted.
- Use `packs/product-discovery/core.md` when the value of the thing itself is unproven — before the engineering packs, not alongside them.
- Use `packs/interface-design/core.md` when building or reviewing anything people look at — a website, landing page, dashboard, or redesign — for hierarchy, spacing, colour, consistency, conventions, and responsive layout.

New packs follow the same overlay pattern. Consult `packs/registry.md` for pairings and for choosing between adjacent packs.

### 3b. Check whether a target grade is active

A grade is different from a pack: it does not add topic depth, it sets the target the whole run is aiming for and changes what "done" means. Load one when the user names a target explicitly — "make this production ready", "MVP is fine", "get this to production grade", `$socratic mvp`, `$socratic production` — or when the request states it ("this needs to survive real traffic", "just a prototype for now").

Consult `grades/registry.md`, load the matching grade file, and follow the domains and packs it marks mandatory in addition to whatever the dynamic scan already selected. When a grade is active, its gate — not step 5's generic sufficiency check — decides when the run stops. No grade named means no change: proceed as below.

Grades are cumulative: `enterprise` supersedes `production` supersedes `mvp`. Resolve the entire chain down to `mvp`, not only the items listed in the named grade's own file — each file states what it supersedes and does not repeat those items in different words, so there is exactly one definition of each check to satisfy, not several that could disagree.

### 4. Self-answer the selected material questions

Resolve each selected question in this order:

1. **Read first.** Use the codebase, configuration, documentation, prior conversation, and repository conventions.
2. **Apply the engineering default.** When evidence does not decide an engineering choice, take a defensible default and record consequential assumptions.
3. **Escalate only authority decisions.** Ask the user only about business priorities, budget, vendor choice, target market, legal risk tolerance, or irreversible decisions that materially change the result.

Do this silently. The user should see the resulting decisions, not the raw question bank.

### 5. Run a sufficiency check and stop deliberately

Socratic is not an instruction to exhaust a questionnaire. Its purpose is to reduce material uncertainty until the agent has a solid, evidence-backed basis to act.

**If a grade is active, skip this step's five conditions and use the grade's gate instead** — stop when every gate item is resolved, mitigated with a stated reason, or marked not applicable, not when this section's conditions happen to be met. The rest of this step applies only when no grade was named.

After each domain or decision cluster, stop expanding the review when all of the following are true:

1. The requested outcome, scope, and consequential assumptions are clear.
2. Every material risk has a mitigation, a verification step, an explicit acceptance by the appropriate authority, or a clearly stated escalation.
3. No unresolved contradiction changes the implementation plan.
4. The next plausible question would not materially change the design, risk, cost, authority decision, or verification plan.
5. The plan has a proportionate way to falsify its riskiest assumptions.

If any condition fails, add the smallest relevant domain, deeper question depth, or pack. Do not continue merely to use more questions, and do not stop merely because a token budget is low. Stop because the remaining uncertainty is immaterial to the current task.

### 6. Emit the output contract once

Before implementation, emit:

```text
Domains considered: <each selected domain and why>
Self-answered highlights: <5-10 decisions that shaped the design>
Assumed (flag if wrong): <consequential defaults>
Open questions for you: <ideally 0-3 authority decisions>
Top risks: <material risks from the selected domains>
Plan: <what will be built>
```

Batch any genuinely blocking open questions. Do not turn the interrogation into the deliverable.

### 7. Build and verify

Build after blocking decisions are resolved. Apply the Verification guidance from every loaded domain and pack, including anything added during the review. Report what passed, failed, or could not be verified without external access.

## Interactive mode

When the user explicitly requests an interview:

1. Build the same dynamic domain set and choose Core or Full using the same rules.
2. Ask one material decision at a time with a recommended default.
3. On a correction, absorb it and continue. If the user says to stop or proceed, self-answer the remainder and build.
4. Keep the interaction proportional: 0-2 questions for a one-off, 3-6 for a prototype, 8-15 for production, and 15-25 for money, PII, health, or regulated systems.
5. Emit the same output contract before building.

## Preset domain combinations

These are not a second router. Each row is the result of applying the routing rule in step 1 to a typical request, so they double as a regression check: if an edit to the signal or dependency tables changes a row here, the edit changed routing behavior and the row must be updated deliberately.

| Building | Signals that fire | Domains |
|---|---|---|
| CRUD web app | UI, backend, database, accounts | 00, 01, 02, 03, 05, 07 |
| Landing page or marketing site | website | 00, 01, 07, 11 |
| Public API or SDK | API, public exposure, endpoint | 00, 02, 04, 05, 07, 08, 12 |
| Connectors or integrations | connector (+ 04 → 05) | 00, 04, 05, 07, plus each connector's own signals |
| AI agent or chatbot | AI, chatbot (+ 09 → 05, 08, 12) | 00, 05, 07, 08, 09, 11, 12 |
| Backend AI agent, no human-facing surface | AI, worker (+ 09 → 05, 08, 12) | 00, 02, 05, 07, 08, 09, 12 |
| RAG pipeline | RAG (+ 09 → 05, 08, 12) | 00, 03, 05, 07, 08, 09, 12, 13 |
| Data pipeline or ETL | ETL (+ 06 → 08) | 00, 03, 06, 07, 08, 13 |
| Mobile app | mobile (+ 10 → 01, 05, 11) | 00, 01, 05, 07, 10, 11 |
| Infrastructure change | infrastructure change (+ 06 → 08) | 00, 06, 07, 08, 12, 14 |
| Payments feature | payments | 00, 02, 03, 05, 07, 13 |
| One-off script | none | 00, 07 |

RAG includes Security because retrieved documents are a primary indirect prompt-injection path and retrieval needs access control.

## Guardrails

- Do not ask what project inspection can answer.
- Do not expose the full question bank to the user by default.
- Do not escalate engineering decisions merely to avoid responsibility.
- Do not keep interviewing after the user asks to proceed.
- Do not claim verification without evidence.
- Do not present legal conclusions; identify matters requiring counsel.
- Do not depend on vendor-specific planning modes, memory systems, tool names, or subagent APIs.

Files in this skill

  • Contribution.md2 KB
  • PROMPT.md10.2 KB
  • PROMPT_LITE.md2.1 KB
  • SKILL.md12.2 KB
  • agents/openai.yaml193 B
  • grades/enterprise.md3.8 KB
  • grades/mvp.md2.1 KB
  • grades/production.md4.4 KB
  • grades/registry.md3.5 KB
  • packs/registry.md3.9 KB
  • questions/00-requirements.md3.5 KB
  • questions/01-frontend.md3.9 KB
  • questions/02-backend.md4 KB
  • questions/03-data.md4.4 KB
  • questions/04-api.md4.2 KB
  • questions/05-security.md5.3 KB
  • questions/06-infra.md3.8 KB
  • questions/07-testing.md3.3 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in ai-agents →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.