跪拜 Guibai
← All articles
Frontend · Backend · AI Programming

A 660-Token AI Coding Workflow That Grills Your Requirements Before Writing a Line of Code

By why技术 ·
Read original on juejin.cn ↗ Google Translate ↗ Alt translation

Most AI coding tools focus on generating code faster; this workflow attacks the real bottleneck—ambiguous requirements—by forcing structured interrogation before implementation. The 660-token footprint means it can run inside any LLM-powered coding agent without eating the context window needed for actual code.

Summary

The mattpocock/skills repository packages a four-step AI coding workflow—grill-with-docs, to-spec, to-tickets, and implement—that forces requirements clarity before any code is generated. Each skill is a short prompt that chains into the next: the AI interrogates the user one question at a time, resolves conflicts, writes Architecture Decision Records, and produces a structured spec with user stories, implementation decisions, and explicit out-of-scope boundaries. The entire skill set consumes only 660 tokens of context, making it one of the leanest AI coding frameworks available.

A new /wayfinder command extends the same interrogation pattern beyond code, mapping any open-ended goal—from a 10K running target to a product feature—into a dependency graph of sub-tasks and a concrete plan. The workflow treats context as a limited resource: after requirements are locked into markdown files, a /clear command wipes the chat history before /implement runs, preventing context pollution during code generation. /implement itself bundles test-driven development and code review, so the AI writes and critiques its own output in one pass.

The skills have been downloaded nearly 10 million times from skills.sh as of mid-July 2025, and the v1.1 release in early July tightened the combo sequence based on real usage. The core insight is that AI coding fails most often from underspecified requirements, not from weak code generation; a three-sentence grill prompt that asks one question at a time and records every decision produces more reliable output than a long, detailed system prompt.

Takeaways
/grill-with-docs asks exactly one question at a time, offers a recommended answer with reasoning, and flags conflicts with earlier decisions immediately.
Architecture Decision Records and a glossary of terms are written to CONTEXT.md automatically during the grilling phase, giving the AI persistent project memory.
/to-spec converts the grilling output into a structured spec covering problem statement, user stories, implementation decisions, testing strategy, and explicit out-of-scope items.
/to-tickets splits the spec into dependency-ordered tasks and marks which can run in parallel.
Clearing the chat context with /clear before /implement prevents earlier discussion from polluting code generation.
/implement bundles TDD and code-review internally, so the AI writes tests, code, and review in one invocation.
/wayfinder applies the same stepwise interrogation to non-coding goals, producing a map of sub-tasks and a concrete plan from a single vague question.
The entire skill set occupies 660 tokens—smaller than most single-purpose coding prompts.
Conclusions

The workflow's power comes from its minimalism: a three-sentence grill prompt that asks one question at a time outperforms long, prescriptive system prompts because it prevents the AI from making assumptions.

Persisting decisions to markdown files rather than keeping them in chat context is a deliberate design choice that treats context as a scarce resource, not an infinite scratchpad.

/wayfinder demonstrates that the interrogation pattern generalizes beyond code—the same skill that specs a web app can produce a 12-week marathon training plan with nutrition advice, because the underlying loop of question, record, and resolve is domain-agnostic.

The v1.0 to v1.1 evolution shows the combo sequence was tightened based on real friction: the author removed steps that users found redundant and bundled code review into implementation to reduce manual toggling.

Concepts & terms
Architecture Decision Record (ADR)
A document that captures an important architectural decision along with its context and consequences. In AI coding workflows, ADRs give the model persistent knowledge of design constraints and trade-offs that cannot be inferred from code alone.
Skills (in AI coding context)
Pre-packaged prompt templates that extend an AI coding agent with specific behaviors. Unlike one-shot prompts, skills can chain together and write persistent artifacts like specs and tickets to the filesystem.
Source: juejin.cn ↗ Google Translate ↗ Backup ↗