> ## Documentation Index
> Fetch the complete documentation index at: https://docs.costgraph.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Usage

> Ask your agent about cost, in plain language

Just ask your agent in plain language. A few prompts to start with, output is illustrative.

## Find your biggest savings

> **You:** What are my biggest cost savings this month?

Your agent calls `readRecommendations` and gets back a ranked summary, largest monthly savings first.

```text theme={null}
Top savings across your cluster:

  Workload                     Namespace    Action          Monthly saving
  ─────────────────────────────────────────────────────────────────────────
  checkout                     production   DOWNSIZE_CPU    $412
  search-indexer               production   DOWNSIZE_MEM    $287
  payments-worker              production   DOWNSIZE_CPU    $190

Estimated total: ~$889/mo. Want me to draft the change for any of these?
```

## Turn a recommendation into a change

> **You:** Rightsize the checkout deployment in the production namespace.

It pulls the detailed recommendation with `readRecommendations`, then asks `readCostGraphKnowledge` for the `executing_recommendations` knowledge to format the change. You get a diff you can apply or open as a PR.

```bash theme={null}
# checkout (production): CPU request 1000m -> 250m, memory request 1Gi -> 640Mi
kubectl set resources deployment/checkout -n production \
  --requests=cpu=250m,memory=640Mi
```

CostGraph never makes the change itself. Your agent applies it with its own access.

## Price out an instance swap

> **You:** Is there a cheaper instance than m5.xlarge for this host?

Your agent calls `readPricingApi` and compares cheaper instances that still fit the workload.

```text theme={null}
m5.xlarge today: ~$140/mo (4 vCPU, 16 GiB)

Cheaper options that fit:
  m6i.xlarge   4 vCPU / 16 GiB   ~$133/mo   save ~$7/mo
  m7g.xlarge   4 vCPU / 16 GiB   ~$117/mo   save ~$23/mo  (arm64)
```
