I Found A Claude Code Feature Anthropic Hasn't Announced Yet (And It Changes How Every Agent Workflow Works)
I spent two days inside Anthropic's docs and found a Claude Code feature they quietly shipped 48 hours ago. They haven't announced it. Nobody is talking about
May 21, 2026
I Found A Claude Code Feature Anthropic Hasn’t Announced Yet (And It Changes How Every Agent Workflow Works)
I spent two days inside Anthropic’s docs and found a Claude Code feature they quietly shipped 48 hours ago. They haven’t announced it. Nobody is talking about it.
It might be how every agentic engineer works going forward.
The feature is called workflows. It’s a new slash command, /workflows, that ships hidden behind an environment variable. Off by default. No blog post. No changelog highlight. The only reason I know it exists is because I went looking.
Here is exactly what it does, why it matters, and the workflow file I’m running every night.
The problem it solves
Every time you spawned Claude sub-agents up until this week, the results dumped back into your main orchestrator session. Three things happened every single time.
- Token tax. Every sub-agent result round-tripped through the main context window. Spin up 10 agents, you paid for 10 round-trips of intermediate state through your most expensive context.
- No visibility. You saw a wall of scrolling text and had no idea which agent was doing what, how many tools it called, or whether it was about to fail.
- The orchestrator got lazy. As the context filled with intermediate results, Claude started forgetting your conditionals and acting sloppy. Workflows reliably died around agent 6 or 7.
If you have ever built a 10-agent Claude workflow and watched it collapse halfway through, this is the reason. I thought it was a “me problem” for months. It wasn’t. It was a structural problem with model-as-orchestrator.
The fix is one environment variable
You flip the workflow env variable, restart Claude Code, and a new slash command appears in the autocomplete. /workflows.
The wrapper is now code, not the model. Sub-agents pass results directly to each other in a JavaScript file and never touch the orchestrator’s context window.
This is the same primitive every backend engineer has used for years. n8n, Temporal, Airflow, LangGraph. Code-as-orchestrator. The novelty here is Anthropic shipping it natively inside Claude Code with auto-retry, live observability, and zero infrastructure setup.
What you actually build
One JavaScript file lives in .claude/workflows. Inside the file you get a small toolkit of primitives.
agent. Spawn a fresh sub-agent with a prompt and an optional schema. Each agent runs in its own context.
parallel. Fan out N agents at once. Wait for all of them to finish before moving on.
pipeline. Stream items through stages. Stage 2 starts the moment stage 1 finishes ONE item, not after all of stage 1 is done. This is the difference between batch and streaming.
schema. Force structured output from any agent. Define a type, agent returns that type, next agent uses it.
phaseLog. Live view of what’s happening at each stage. Drill into any agent and see tools, tokens, prompts.
arguments. Runtime params passed in via the slash command. Defaults defined in the file.
budget. Token cap that stops loops from running away.
Plus plain JavaScript: if, while, for, filter. Wire conditionals and loops between agents.
Three workflows I’m running
1. Sentry triage
Pull unresolved issues from Sentry. Filter to the ones affecting more than 20 users. For each, spawn a fix agent. Then a verify agent. Then a summarize agent. Output a list of merge-ready PRs.
Last night this workflow ran on its own at 2 AM. Pulled 25 issues. Filtered to 3 above the user threshold. Fixed all 3. Verified all 3. PRs ready when I woke up.
2. Dead code sweep
While loop. Find unused code in the codebase. If found, remove it agent by agent. Exit when none found, max 8 rounds. Token budget caps the run.
This is the kind of background task that used to require leaving Claude Code and hand-rolling a script. Now it’s 40 lines of JavaScript.
3. Personalized outreach
Load leads from a CSV. For each lead, research with a cheap MCP server, fall back to an expensive one only on miss. Pipeline the research into a writer agent that drafts a personalized message as soon as research finishes for that lead.
Eight leads. Eight parallel research agents. Eight writer agents streaming behind. One command.
When to reach for workflows
The structural rule is: workflows pay off when you amortize the file-writing cost across many runs.
- Anything you would run daily
- Fan-out work with N items needing the same operation
- Long jobs that might fail halfway (auto-resumable up to 3 retries per agent)
- Anything with conditionals or loops over agents
Skip it for one-off tasks. Just talk to Claude directly. The setup cost of writing the workflow file is real.
Why this is bigger than it looks
The headline framing is “Anthropic shipped a feature.” The actual story is that Claude crossed a category line.
Before workflows, Claude was a chatbot you prompted one turn at a time. You could spawn sub-agents but the orchestrator was always a model, which meant the orchestrator was always non-deterministic, always token-taxed, and always degrading.
After workflows, Claude is a deterministic workflow engine. The steps are LLM agents instead of API calls. The wrapper is code instead of a model. The runtime is provided by Anthropic instead of self-hosted.
This is the structural shift that makes multi-agent systems shippable for non-engineers and reliable for engineers. The patterns Claude can support now are the patterns Temporal and Airflow have supported for years. The fact that the “steps” are LLMs is what makes it new.
What to do this week
- Find your workflow env variable in the Claude Code docs. It’s there.
- Flip it. Restart Claude.
- Type / and look for the workflows command in the autocomplete.
- Start with the simplest possible workflow file. One phase, one agent, a schema.
- Build from there.
If you want the actual file I’m running plus 3 ready-to-paste templates (Sentry triage, dead-code sweep, personalized outreach), grab the free guide at the link in the bio.
Day 91 of building personal software with Claude.