Claude API / SDK + ant — capability map → RDCO use cases
Built 2026-06-03 after founder asked to explore ant use cases / learn the Claude API/SDK surface in general. Each capability gets a one-line "what it is" + the concrete RDCO use case (the part that makes it worth knowing for us, not generic). ant is just the terminal/script front-end to all of this; the capabilities below are the actual substance.
The capability surface (12 clusters)
| # | Capability | What it is | Concrete RDCO use case |
|---|---|---|---|
| 1 | Messages + tool use | The core call. Model can call functions you define and you feed results back. | The backbone of everything Ray already does. |
| 2 | Structured outputs | Force the model to return data matching a JSON schema (tool-forced output). | The clean way to do any "parse/classify into a schema" job: newsletter format/sponsor classifier, investing-thesis field extraction, dbt-test generation. (Workflows' StructuredOutput is this.) |
| 3 | Prompt caching | Cache long, stable context (system prompt, vault docs) so repeat calls are far cheaper + faster. | Biggest cost lever. The COO agent re-sends huge stable context (CLAUDE.md, vault). Directly relevant to the phData $100/mo budget — cache the stable prefix, pay only for the delta. |
| 4 | Batch API | Submit bulk jobs asynchronously at ~50% cost; results within a window. | The cost-efficient way to run big backfills: newsletter/YouTube history, bulk classification, investing-universe screening, eval runs. Not interactive, but half price. |
| 5 | Files API | Upload a file once, reference it across many calls. | Vault docs, PDFs (memos, lead magnets), SEC filings for investing — upload once, reuse. |
| 6 | Vision / PDF input | Feed images and PDFs directly into a message. | Process the PDFs/screenshots the founder shares (e.g. the OpenAI report), Squarely design review, chart/figure reading. |
| 7 | Extended thinking | Give the model a larger reasoning budget for hard problems. | Investing theses, strategic analysis, backtest interpretation — the deep-reasoning surfaces. |
| 8 | Citations | Model cites which source span each claim came from. | deep-research, vault-grounded answers, and the verify-before-assert discipline — grounding made mechanical. |
| 9 | Agent SDK | Build your own agentic loop (the same machinery Claude Code is built on). | Bespoke agents beyond Claude Code: the phData work-agent, the multi-agent pipeline seats, any headless RDCO agent. |
| 10 | MCP | Standard protocol to expose tools/data to any model client. | Ray is already a heavy MCP consumer (Notion, Gmail, Calendar, iMessage…). The unlock: build an RDCO MCP server that exposes the vault + task board, so any client (Claude Code, ant, desktop) can reach RDCO state. |
| 11 | Managed Agents (ant beta: — agents/sessions/environments/deployments/skills) |
Anthropic-hosted agents that run in cloud sandboxes, defined + version-controlled as YAML. | The "deploy a persistent agent without self-hosting" path. Candidate substrate for the phData work-agent or always-on RDCO agents; agents/skills become checked-in, reproducible artifacts. |
| 12 | ant CLI |
Terminal/script front-end to all of the above (typed flags, YAML in, --transform out, auto-pagination). |
Glue Claude API calls into data pipelines / CI; version-control Managed Agents + skills as YAML. See [[2026-06-03-anthropic-ant-cli-api-command-line-tool]]. |
Start here — the 4 highest-leverage for the founder's context
Given: data engineer, uses Claude Code daily, hard phData token budget, runs the RDCO COO agent + automated-investing + content surfaces.
- Prompt caching + Batch API — the two cost levers. Caching matters immediately under the phData $100/mo cap; Batch halves the cost of every RDCO backfill. Learn these first; they pay for themselves.
- Structured outputs — the cleanest data-engineering win. Any "turn messy input into a typed row" task (classification, extraction, test-gen) becomes reliable instead of regex-and-pray.
- Managed Agents via
ant— the version-controlled, cloud-hosted agent path. Directly informs the open phData work-agent decision (a third option beside Gmail-MCP and a local script) — and the YAML-in-a-repo model fits how a data engineer already thinks. - An RDCO MCP server — expose the vault + task board over MCP once, reach it from every client. This is an instrumentation-layer unlock for the COO agent (L5 direction).
How to actually go deeper (cheap experiments)
- One-liner to feel the API:
ant messages create --model claude-opus-4-8 --max-tokens 1024 --message '{role: user, content: "..."}' - Try structured output on a real RDCO task (e.g. classify 5 newsletter subjects into format+sponsor) and compare to the current skill.
- Spin up a throwaway Managed Agent from a YAML file (
ant beta:agents create < agent.yaml) to see the version-control loop. - Each is a 10-minute experiment; none commit RDCO to anything.
Related
- [[2026-06-03-anthropic-ant-cli-api-command-line-tool]] — the
antreference - [[2026-06-02-thariq-dynamic-workflows-harness-for-every-task]] — the agentic-harness layer (Claude Code) these capabilities sit under
- phData work-agent plan:
~/rdco-vault/08-tooling/2026-05-30-phdata-work-agent-setup-plan.md(Managed Agents + Agent SDK are candidate substrates) - [[project_l5_north_star_strategic_direction]] — unhobbling the COO agent (instrumentation/tools layer)