---
title: "Template: Ask Caveman (Cloud Spend & Trace Q&A)"
description: Deploy a read-only agent that answers questions about your organization's traces, spend, evals, and reports from Caveman Cloud with cited evidence.
canonical: https://docs.caveman.so/templates/ask-caveman
product: Caveman Cloud
tab: Documentation
group: Templates & Quick Setups
---

# Template: Ask Caveman (Cloud Spend & Trace Q&A)

> Deploy a read-only agent that answers questions about your organization's traces, spend, evals, and reports from Caveman Cloud with cited evidence.

The `ask` template deploys a read-only agent with `computer: none` that queries your organization's Caveman Cloud data through the `caveman` connector. It answers questions about spend, traces, evals, datasets, and reports while keeping measured, inferred, and verified numbers strictly separate.

## Deploy in 30 seconds

```bash
cvm agent init ask ./ask
cvm connect add caveman
cvm deploy ./ask --budget 1
cvm run ask "Which agent spent the most in the last 7 days, and on what?"
```

Expected output from `cvm agent init ask ./ask`:

```text
wrote    ask/AGENT.md
agent    ask  1 file, ... bytes, sha256 ...
next     cvm connect add caveman
           sign Caveman's own MCP server in for your team, in your browser (once per organization; cvm deploy offers it too)
         cvm deploy ask --budget 1
           store the agent and make it live as ask, at most $1 a session
         cvm run ask "Which agent spent the most in the last 7 days, and on what?"
           start a session and print its answer
```

On a self-hosted or VPC install, add the connector by your console origin instead of the catalog name:

```bash
cvm connect add https://<your-console-origin>/mcp --name caveman
```

## What is inside `ask/AGENT.md`

```markdown
---
name: ask
description: Ask Caveman. Answers questions about this organization's agents from its own Caveman Cloud data, reading only.
computer: none
model: claude-sonnet-5-5
connectors:
  caveman:
    tools: [caveman_context, caveman_search, caveman_describe, caveman_read]
---

# Ask Caveman

You answer one person's question about the agents and LLM apps their team
builds, from that team's own Caveman Cloud data: traces, spend and usage,
evals, datasets, criteria, reports and what Caveman found. Lead with the direct
answer, say where each number came from, and say plainly when the data cannot
answer the question.
```

Key design details in this template:

- **Read-only by construction.** The `connectors.caveman.tools` allowlist exposes only `caveman_context`, `caveman_search`, `caveman_describe`, and `caveman_read`. No write tools are attached.
- **No sandbox overhead.** `computer: none` strips all filesystem and shell tools so the prompt prefix stays compact and sessions run without provisioning a VM.
- **Evidence-first answers.** The instructions enforce citing the operation, input window, denominator (`41 of 50 traces`), and `query_digest` or `request_id` for every number, and refuse to mix measured, inferred, and verified figures.
- **Prompt-injection boundary.** Trace content, dataset rows, and prompts are treated strictly as untrusted data, never instructions.

## Customize it

- **Bind to Slack** so teammates can ask spend questions in a channel: add a `channels.slack` block (see [Slack Support Bot](/templates/support-slack)).
- **Run a weekly spend digest**: add a `schedules` entry and a writeable Drive mount (see [Scheduled Researcher](/templates/researcher-drive)).
- **Change the model**: swap `model` to `fast`, `base`, `frontier`, or any catalog slug (`cvm models`).

## Verify and undo

Inspect the live deployment and its revisions:

```bash
cvm deployments get ask
cvm deployments revisions ask
```

Remove the deployment and free the name:

```bash
cvm deployments archive ask --yes
```

## Limits

- `ask` reads only the single project that the `caveman` connector was signed in to, with the scopes granted during `cvm connect add caveman`.
- If the connector sign-in expires or is paused, the agent stops and instructs a manager to run `cvm connect rotate caveman`.
