# "Claude Code Workflows Are A Gift From The AI Gods" <!-- ref: @content/youtube/sean-kochel/claude-code-workflows-are-a-gift-from-the-ai-gods tags: [Claude Code, workflows, sub-agents, adversarial review, token budgets, CLAUDE.md maintenance] version: 2 updated_at: 2026-11-22T13:42:52.820Z --> **[Watch on YouTube](https://www.youtube.com/watch?v=XZautQfr3HU)** # Claude Code Workflows Are A Gift From The AI Gods *Synthesized from Sean Kochel, 2026-06-04.* Sean Kochel presents solo, walking through the newly released Claude Code "workflows" feature, six composable patterns, two workflows he built himself, and Anthropic-sourced best practices for controlling cost. ## Core Thesis Sean argues that workflows let you assemble custom, reusable harnesses on the fly, combining parallel fan-out and ordered pipelines, so that research, review and refactoring tasks get done far more thoroughly than a static skill or prompt chain allows. Because they can spawn many agents and burn millions of tokens, he says they must be paired with explicit prompting, goals or loops, and token budgets. ## Key Insights - A workflow has two building blocks: running tasks in parallel and waiting for all of them, and running a pipeline of ordered steps. Either can be used alone or combined. - The built-in deep research that shipped with Opus 4.8 is his example of a dynamic workflow: it fans out web searches, fetches sources, has separate sub-agents adversarially verify claims, then synthesizes a cited report. - Concrete contrast: for "should we migrate our checkout service to a new provider?", a static harness does about five searches and a generic summary. A dynamic workflow first reads your actual Stripe/billing code, checks each feature against the new provider's docs, prices the volume with a separate agent, and then runs an adversarial stage arguing against migrating. - Six patterns: (1) classify and act, routing by severity, such as Haiku for simple bugs, Sonnet with a systematic-debugging skill for medium ones, Opus for the hardest; (2) fan out and synthesize; (3) adversarial review and verification; (4) generate and filter, with several idea-generating agents then a rubric-based filter; (5) tournament, where agents compete on the same task and a judge pairs winners over rounds; (6) loop until done, repeating until acceptance criteria such as a test-coverage percentage are met. - Adversarial review matters because models lock onto a narrative; fresh-context verifiers with different scopes break that lock-in. He suggests using it to fact-check meta prompts and skills that claim to encode "20 years of experience". - Workflow 1, mining session history for CLAUDE.md updates: fans out over the last 20 sessions with parallel agents reading chunks, then applies two skeptic lenses (is it already inferable from the project; is it novel and supported), for two rounds. His run took about 26 minutes, looped six times (overkill), used millions of tokens, and kept 10 candidates, including a stale note calling a skill a stub. - Workflow 2, React Refactor Tournament: uses Vercel's React Best Practices skill, judges pick the biggest issue, fixes happen in separate worktrees and are committed, and it defaults to three cycles. Findings are written to a backlog. He notes about 19 sub-agents ran at once and that Sonnet would probably have been enough. - Workflows are JavaScript files in a workflows folder inside the project's Claude directory, with a name, description, a "when to use" field (important since they can run on their own), phases and strict schemas. They are generated from a natural-language description. ## Actionable Takeaways 1. Describe the workflow's structure precisely in the prompt (for example, "tournament with pairwise judges"), and say if you want a quick one. 2. Choose the model per stage; use a cheaper model where the skill already gives detailed guidance. 3. Run a workflow on an interval with a loop, or set a hard measurable stop with the /goal command. 4. Give the run an explicit token budget, such as 10,000 or 100,000 tokens. 5. Write a precise "when to use" field so the workflow does not trigger itself unexpectedly. 6. Save and share a workflow into the project or a repo for reuse. ## Notable Quotes > "one of the big downsides of language models is that they really tend to lock in on narrative." — Sean Kochel > "Number three, and I think this is the biggest takeaway, is you can tell it that it has a token budget." — Sean Kochel --- *Related: `@content/youtube/zazencodes/build-your-own-ai-software-factory-with-claude-code` · `@content/youtube/sean-kochel/opus-4-7-is-insanely-powerful-and-insanely-expensive` · `@content/youtube/yifan-bth/i-reverse-engineered-claude-code-learn-these-agent-tricks` · `@content/youtube/yifan-bth/the-complete-claude-code-workflow-90-skip-this` · `@content/youtube/tiago-forte/stop-overthinking-ai-use-this-4-step-framework`* --- *You're reading a protocol on [protocol.supply](https://protocol.supply) — hosted, searchable knowledge for AI agents. Think Agent Skills, as an API: bootstrap once (`curl -sL https://api.protocol.supply/bootstrap`), search (`/search?q=…`), fetch (`/@repo/slug`).* *Any skill can become a protocol, and any protocol installs as a local skill — tell your agent "install this as a skill" or see [`@protocol/protocol-to-skill`](https://api.protocol.supply/@protocol/protocol-to-skill).*