驱动整个三层台阶(A 日常业务 · B 核心流程 · C 开发元能力)的共用引擎。它的本质是一个能自主完成 理解需求 → 规划 → 调用工具执行 → 自我验证 → 修正 闭环的工程代理,并在其上叠加协作层与可编程扩展层。The shared engine behind all three layers (A daily work · B core process · C meta-capability). At its core it's an engineering agent that runs the full understand → plan → call tools to execute → self-verify → fix loop, layered with collaboration and programmable extension on top.
每个工位(CCBots 席位)即一个能自主闭环的工程代理;在此之上叠加三层能力。Each seat (a CCBots seat) is an engineering agent that closes its own loop; three capability layers stack on top.
文件 / 搜索 / 命令 / Web / 编排,一体内置;Claude 模型原生多模态,支持图片与 PDF 理解。Files / search / commands / Web / orchestration, all built in; Claude models are natively multimodal, understanding images and PDFs.
子代理聚焦任务、节省上下文;智能体团队并行推进、成员可互通,适合多角度审查与探索。Subagents focus tasks and save context; agent teams run in parallel and members can talk to each other — ideal for multi-angle review and exploration.
Agent SDK · Hooks · Skills · MCP · Plugins 生态,把通用代理改造成贴合你业务的专属工具。The Agent SDK · Hooks · Skills · MCP · Plugins ecosystem turns a generic agent into a tool tailored to your business.
长文档、整站代码、批量产品资料一次喂进模型的能力——这是全站重构与长文档处理的关键。但「1M」要加使用场景限定,不能笼统下结论。Feeding long documents, a whole site's code, or batches of product material into the model at once — the key to whole-site refactoring and long-document work. But "1M" needs context-specific caveats, not a blanket claim.
| 使用场景Scenario | 实际可用上下文Usable context | 前提 / 状态Prerequisite / status |
|---|---|---|
| Claude API | 1M tokens | beta(需 beta header 启用)beta (enabled via beta header) |
| Claude Code | 1M tokens | 需启用按量计费(usage credits)解锁unlocked by enabling usage-based billing (usage credits) |
| Claude.ai 网页web | 500K tokens | 付费计划paid plans |
读代码、跨文件搜索、改 / 重构代码、跑命令与脚本、跑测试、git 提交、运行并截图验证 app、Web 检索与抓取——一条龙。Read code, search across files, edit / refactor code, run commands and scripts, run tests, git commit, launch and screenshot-verify an app, search and fetch the Web — end to end.
| 类别Category | 工具Tools | 用途Purpose | 关键约束Key constraints |
|---|---|---|---|
| 文件Files | Read / Write / Edit / NotebookEdit | 读(含图片 / PDF / Notebook)、新建、精确字符串替换Read (incl. images / PDF / Notebook), create, exact string replace | 编辑前必须先 Read;Edit 旧串需唯一匹配Must Read before editing; Edit's old string must match uniquely |
| 搜索Search | Grep(ripgrep)/ Glob | 内容正则搜索、文件名模式匹配Regex content search, filename pattern matching | 默认跳过 gitignoreSkips gitignore by default |
| 执行Execute | Bash / Monitor | 跑命令脚本、尾日志轮询长进程Run command scripts, tail-log poll long processes | 默认 2 分钟超时(可申请 10 分钟);env 不跨调用持久2-minute default timeout (10 min on request); env doesn't persist across calls |
| Web | WebSearch / WebFetch | 搜索、抓网页转 markdownSearch, fetch web pages to markdown | WebFetch 返回模型提取后的答案而非原文;缓存 15 分钟WebFetch returns the model's extracted answer, not the raw page; cached 15 minutes |
| 编排Orchestration | Agent / SendMessage / Task* / Cron* | 派子代理、agent 间通信、任务清单、定时任务Spawn subagents, inter-agent comms, task lists, scheduled tasks | 部分能力需实验开关Some capabilities need an experimental flag |
| 交互Interaction | AskUserQuestion / PlanMode | 澄清提问、计划审批Clarifying questions, plan approval | 阻塞式Blocking |
| 扩展Extension | Skill / MCP / ToolSearch | 调技能、读外部资源、按需加载工具Call skills, read external resources, load tools on demand | 受 allowed-tools / 权限约束Bound by allowed-tools / permissions |
CCBots 多工位的底层编排能力:既能用子代理省成本快速返回结论,也能用智能体团队并行探索。The orchestration underneath CCBots' multiple seats: use subagents to save cost and return conclusions fast, or agent teams to explore in parallel.
| 维度Dimension | 子代理 (Subagent)Subagent | 智能体团队 (Agent Teams)Agent Teams |
|---|---|---|
| 上下文Context | 独立窗口,只把摘要回主会话Separate window, returns only a summary to the main session | 每个成员完全独立的完整会话A fully independent, complete session per member |
| 通信Communication | 只向父代理汇报Reports only to the parent agent | 成员之间可直接互发消息Members can message each other directly |
| Token 成本cost | 低Low | 高(N 个完整实例并存)High (N full instances coexist) |
| 适合场景Best for | 聚焦任务、快速返回结论Focused tasks, fast conclusions | 需要讨论收敛的并行探索 / 多角度审查Parallel exploration / multi-angle review that needs discussion to converge |
| 启用Enabling | 默认可用Available by default | 需实验开关Needs an experimental flag |
run_in_background 可后台异步跑、完成回调。isolation: worktree 给后台 agent 独立 git 工作副本,多 agent 改同一仓库不互踩。自定义子代理写在 .claude/agents/<name>.md,由 description 自动委派。Parallel / isolated / custom: spawning multiple agents in one message runs them concurrently; run_in_background runs async in the background with a completion callback. isolation: worktree gives a background agent its own git working copy, so multiple agents can edit the same repo without clashing. Custom subagents live in .claude/agents/<name>.md and are auto-delegated by their description.
最新 Opus 4.8 新增 Workflow(工作流编排):用一段确定性脚本指挥几十个子代理并行干活——分解 → 并行覆盖 → 对抗式校验 → 汇总。控制流(循环 / 条件 / fan-out)由脚本决定而非模型临场发挥,所以既能放大产能,每一步又可复现、可中断恢复。The latest Opus 4.8 adds Workflow (workflow orchestration): a deterministic script directs dozens of subagents working in parallel — decompose → parallel coverage → adversarial verification → aggregate. Control flow (loops / conditionals / fan-out) is decided by the script rather than improvised by the model, so it both scales output and keeps every step reproducible and resumable.
| 编排原语Orchestration primitive | 作用What it does | 关键特性Key traits |
|---|---|---|
agent() | 派一个子代理执行子任务Dispatch one subagent for a subtask | 可强制 结构化输出(JSON Schema 在工具层校验、不合规自动重试);可指定模型 / 自定义代理 / worktree 隔离Can enforce structured output (JSON Schema validated at the tool layer, auto-retried if non-compliant); can set model / custom agent / worktree isolation |
parallel() | 一批任务并发执行Run a batch of tasks concurrently | 栅栏式:全部完成再汇总;单个失败降级为 null,不拖垮整体Barrier-style: aggregate only when all finish; a single failure degrades to null without dragging down the whole |
pipeline() | 每个条目独立穿过多个阶段Each item passes through multiple stages independently | 无阶段栅栏:整批墙钟 ≈ 最慢单条链,而非各阶段串行相加No stage barrier: total wall-clock ≈ the slowest single chain, not the sum of stages run serially |
phase() · log() | 分阶段 + 进度播报Phasing + progress reporting | 实时进度树,长任务全程可观测A live progress tree, observable throughout long tasks |
workflow() · args · budget | 嵌套调用 · 参数化 · token 预算Nested calls · parameterization · token budget | 按预算动态扩缩 agent 规模;预算为硬上限Dynamically scales agent count to the budget; the budget is a hard cap |
min(16, CPU 核心数 - 2),生命周期累计上限 1000 个 agent(防失控兜底);结构化输出由工具层校验、模型自动重试到合规;可中断恢复——journal 缓存已完成步骤,改脚本后只从「最长未变前缀」之后续跑;worktree 隔离让多个 agent 同时改同一仓库互不踩踏。Scale & reliability: per-orchestration concurrency caps at min(16, CPU 核心数 - 2), with a lifetime cumulative cap of 1000 agents (a runaway safeguard); structured output is validated at the tool layer with the model auto-retrying until compliant; it's resumable — a journal caches completed steps, and after editing the script it resumes only after the "longest unchanged prefix"; worktree isolation lets multiple agents edit the same repo at once without stepping on each other.
把上百个产品 / 品类页按 GEO 规范一次性并行生成,而不是逐页手搓。Generate hundreds of product / category pages to GEO spec all at once in parallel, instead of hand-crafting them one by one.
每条产出交给 N 个独立「审查员」投票,多数通过才算数——质量兜底,杜绝「看着对、其实错」。Each output goes to N independent "reviewers" to vote; only a majority pass counts — a quality backstop that rules out the "looks right but is actually wrong."
上百条产品资料各自独立穿过「翻译 → GEO 结构化 → 校验」,互不等待,整批最快交付。Hundreds of product entries each pass through "translate → GEO structuring → verify" independently, without waiting on one another, for the fastest delivery of the whole batch.
把通用代理改造成贴合你外贸业务的专属系统——这正是「公司自己能持续升级」的技术底座。Turn a generic agent into a system tailored to your export business — the technical foundation of "your company keeps upgrading it in-house."
| 机制Mechanism | 是什么What it is | 解决什么What it solves |
|---|---|---|
| Agent SDK | Python / TS,把 agent 能力嵌入自有应用Python / TS, embed agent capabilities into your own apps | CI/CD 与生产级自动化,无需自己实现 agent 循环CI/CD and production-grade automation, without writing the agent loop yourself |
| Hooks | 在 PreToolUse / PostToolUse / Stop 等事件挂脚本Attach scripts to events like PreToolUse / PostToolUse / Stop | 权限拦截、提交前校验、审计、上下文注入Permission gating, pre-commit checks, auditing, context injection |
| Skills | SKILL.md,靠 description 自动触发或 /name 手动调SKILL.md, auto-triggered by description or invoked manually with /name | 封装领域知识与工作流,可在独立子代理里跑Encapsulate domain knowledge and workflows, runnable in a separate subagent |
| MCP servers | 标准协议接外部工具 / 数据源A standard protocol to connect external tools / data sources | 接 GitHub / 数据库 / 第三方等;ToolSearch 按需加载省 contextConnect GitHub / databases / third parties; ToolSearch loads on demand to save context |
| Plugins | 把 skills/agents/hooks/MCP 打包分发Package and distribute skills/agents/hooks/MCP | 团队 / 社区分享,带 namespace 防冲突Team / community sharing, with namespaces to avoid clashes |
| CLAUDE.md | 项目级 / 全局持久指令记忆Project-level / global persistent instruction memory | 总是加载的「必读」约束Always-loaded "must-read" constraints |
| 模型Model | 定位Role | 定价(输入/输出,每百万 token)Pricing (in/out, per 1M tokens) |
|---|---|---|
| Opus(4.x,最新 4.8)Opus (4.x, latest 4.8) | 最强,难题 / 架构 / 跨文件重构Strongest — hard problems / architecture / cross-file refactors | 以官方定价页为准See the official pricing page |
| Sonnet 4.6 | 常规开发主力,能力够更便宜The everyday dev workhorse — capable and cheaper | $3 / $15 官方official |
| Haiku 4.5 | 改名 / 样板 / 正则等机械活Renaming / boilerplate / regex and other mechanical work | 约 $1 / $5(业界引用)about $1 / $5 (industry-cited) |
会话内 /model 可无损切换;opusplan 模式:Opus 规划、Sonnet 执行,兼顾质量与成本。Switch losslessly in-session with /model; the opusplan mode has Opus plan and Sonnet execute, balancing quality and cost.
超长会话自动压缩(context compaction):接近上限时生成摘要、丢弃更早消息。建议约 60% 容量主动 /compact,比逼近上限自动压缩保留细节更精确。Very long sessions auto-compact (context compaction): near the limit it generates a summary and drops earlier messages. Best to /compact proactively at about 60% capacity — it preserves detail more accurately than auto-compaction near the limit.
/fast 切换;使用 Claude Opus 加速输出、不降级到更小模型;仅 Opus 4.6 / 4.7 / 4.8 支持。适合交互式快迭代、实时调试等「时间成本高于 token 成本」场景。Toggle with /fast; uses Claude Opus to speed up output without downgrading to a smaller model; supported only on Opus 4.6 / 4.7 / 4.8. Best for interactive fast iteration, live debugging, and other "time costs more than tokens" scenarios.
缓存 TTL 5 分钟,命中读取仅约 0.1× 输入价。所以连续编码会话便宜(缓存持续命中),而间隔 >5 分钟的轮询 / 定时任务会丢缓存、反而变贵。静态内容放最前以最大化命中。Cache TTL is 5 minutes, and a hit reads at only about 0.1× the input price. So continuous coding sessions are cheap (the cache keeps hitting), while polling / scheduled tasks spaced >5 minutes apart lose the cache and get pricier. Put static content first to maximize hits.
default → acceptEdits → plan → dontAsk → bypassPermissions,Shift+Tab 循环切换。即便 bypassPermissions 也仍对受保护路径(仓库状态、Claude 自身配置)保留防护。Permission modes (determine how much is automated): low to high, default → acceptEdits → plan → dontAsk → bypassPermissions, cycled with Shift+Tab. Even bypassPermissions still keeps protection over protected paths (repo state, Claude's own config).
工具集与行为、子代理与团队机制、扩展生态、上下文窗口口径、模型 id、Fast mode、缓存 5 分钟 TTL、权限模式(官方文档 / 运行时实测 / 系统约束)。Toolset and behavior, subagent and team mechanics, the extension ecosystem, context-window figures, model ids, Fast mode, the 5-minute cache TTL, permission modes (official docs / runtime testing / system constraints).
Sonnet 4.6 定价 $3/$15 已由官方确认;Haiku 4.5 约 $1/$5 为业界常引值。Sonnet 4.6 pricing of $3/$15 is officially confirmed; Haiku 4.5 at about $1/$5 is a commonly cited industry figure.
第三方博客的精确百分比(如 fast mode 贵 6×/快 2.5×、SWE-bench 87.6%、并行省 15~20% 等)方向可参考但勿当事实,以 Anthropic 官方为准。Exact percentages from third-party blogs (e.g. fast mode 6× pricier / 2.5× faster, SWE-bench 87.6%, parallel saving 15~20%) are directionally useful but not facts — defer to Anthropic's official sources.
无论从哪一层入手——部门日常活、核心流程,还是某个场景——学会驾驭 Claude Code,公司就拥有了持续造工具的开发元能力。Whichever layer you start from — daily departmental work, a core process, or a single scenario — once you can wield Claude Code, your company owns the meta-capability to keep building tools.