Boris Cherny14/ Use --agent to Give Claude Code a Custom System Prompt & Tools
Source snapshot: 2026-11-09Independent editorial note
When this pattern helps
The practical value is reducing ambiguity before implementation and making the result observable. Turn the expected behavior into checks that can pass or fail; a confident explanation is not a substitute for a reproducible test.
重点不是让提示词更长,而是先消除实现歧义,并把预期结果变成可通过或失败的检查。模型解释得很肯定,不等于测试已经通过。
Custom agents are a powerful primitive that often gets overlooked. To use it, just define a new agent in .claude/agents/, then run:
claude --agent=
- Agents can have restricted tools, custom descriptions, and specific models
- They're great for creating read-only agents, specialized review agents, or domain-specific tools
Original source on X