Ops — does it run?
Brief 24

Cost Audit

Expensive queries, chatty API loops, unbounded storage, oversized resources — savings ranked by effort.

COSTS.md4 phases7 lenses~2.5k chars

Free & open · no signup · read-only — it ends by asking · nothing leaves your machine

What it does

You are working inside this repo. Mission: find where this system spends money it doesn't need to — compute, storage, third-party calls, egress — and rank the savings by effort.

Read-only pass. Your only write is the report file.

What it looks for

7 lenses it looks through

Phase 2 sweeps the codebase through every one of these, citing file and line for each finding.

1

Expensive frequent work

heavy queries or jobs on hot paths or tight schedules; recomputing what could be stored

2

Chatty loops

per-item API calls that batch endpoints could collapse; N calls where 1 would do

3

Missing caches

repeated identical fetches of slow-changing data from paid sources

4

Unbounded growth

logs, blobs, soft-deleted rows, old versions accumulating forever with no lifecycle policy

5

Oversize by config

instance sizes, provisioned capacity, always-on resources for spiky workloads

6

Telemetry volume

logging/tracing at a verbosity that costs real money to ingest and store

7

Redundant schedules

crons doing overlapping work, or work whose output nobody reads

The deliverable

What lands in your repo

One structured report at the repo root — or in reports/, if you keep one — the same shape every time, ready for a teammate — or the optional Studio — to act on.

COSTS.md
1
Cost driver map
what's paid for and what it scales with
2
Findings
each: issue · location · monthly impact estimate · fix · effort · risk
3
Savings ladder
ranked, cumulative estimate
4
Lifecycle policies to add
retention/archival rules for the unbounded growth
5
Verification plan
how to confirm each saving after the change
One file. Evidence-backed. It ends by asking before touching anything.
How it works

What it makes the agent do

Every Goal Prompt follows the same four steps, so results are consistent and repeatable — no matter which one you run.

1
Phase 1

Identify the cost drivers

From code and config.

2
Phase 2

Audit through 7 lenses

Expensive frequent work — heavy queries or jobs on hot paths or tight schedules.

3
Phase 3

Curate

Estimate monthly impact per finding — order of magnitude is fine.

4
Phase 4

Report

Create COSTS.md at repo root.

Get started

Three ways to run this Goal Prompt

01 · COPY

Paste it in

Copy it and paste it into your agent inside the repo you want checked.

02 · INSTALL

As a slash command

Install the goal plugin once — two commands — then just type /goal:cost-audit.

1/plugin marketplace add GhostlyGawd/goal-prompts
2/plugin install goal@goal-prompts

Or install only this Goal Prompt as /goal-cost-audit:

curl -fsSL https://goal-prompts.vercel.app/install | BRIEF=24 sh
03 · AGENT

From an agent (MCP)

Let an agent fetch it mid-conversation, or pull the raw Goal Prompt by URL.

https://goal-prompts.vercel.app/raw/24.md
Transparency

The exact prompt

Nothing hidden — this is the whole Goal Prompt, verbatim. Read it in a minute, edit it, or copy it as-is.

Read the full brief (2,547 characters)
# Goal: Cost Audit

You are working inside this repo. Mission: find where this system spends money it doesn't need to — compute, storage, third-party calls, egress — and rank the savings by effort.

Read-only pass. Your only write is the report file.

## Phase 1 — Identify the cost drivers
- From code and config: what does this system pay for? Compute/hosting, database, storage, third-party APIs, email/SMS, telemetry.
- Which of those scale with usage, and which are flat?
- Where are the metered calls: every paid API and the code that hits it.

## Phase 2 — Audit through 7 lenses
1. **Expensive frequent work** — heavy queries or jobs on hot paths or tight schedules; recomputing what could be stored
2. **Chatty loops** — per-item API calls that batch endpoints could collapse; N calls where 1 would do
3. **Missing caches** — repeated identical fetches of slow-changing data from paid sources
4. **Unbounded growth** — logs, blobs, soft-deleted rows, old versions accumulating forever with no lifecycle policy
5. **Oversize by config** — instance sizes, provisioned capacity, always-on resources for spiky workloads
6. **Telemetry volume** — logging/tracing at a verbosity that costs real money to ingest and store
7. **Redundant schedules** — crons doing overlapping work, or work whose output nobody reads

## Phase 3 — Curate
- Estimate monthly impact per finding — order of magnitude is fine; show the arithmetic
- Rank by savings ÷ effort; flag anything that trades reliability for pennies

## Phase 4 — Report
Create `COSTS.md` at repo root:
1. **Cost driver map** — what's paid for and what it scales with
2. **Findings** — each: issue · location · monthly impact estimate · fix · effort · risk
3. **Savings ladder** — ranked, cumulative estimate
4. **Lifecycle policies to add** — retention/archival rules for the unbounded growth
5. **Verification plan** — how to confirm each saving after the change

Start the report with today's date. If `COSTS.md` already exists from a previous run, read it first and lead with what changed since.

## Rules
- Show the arithmetic behind every estimate
- Never save money by making failures more likely — flag those tradeoffs
- No traceable infrastructure or service spend in this repo? Say so in a one-paragraph null report and stop — a null result is a valid finding.
- If a `reports/` directory exists at the repo root, write the report there instead of the root.
- Before asking, present the top findings as a ranked list in plain words
- Report only — end by asking which savings to take

House rules for this Goal Prompt

  • Show the arithmetic behind every estimate
  • Never save money by making failures more likely — flag those tradeoffs
  • No traceable infrastructure or service spend in this repo? Say so in a one-paragraph null report and stop — a null result is a valid finding.
  • If a reports/ directory exists at the repo root, write the report there instead of the root.
  • Before asking, present the top findings as a ranked list in plain words
  • Report only — end by asking which savings to take
Keep exploring

More Ops briefs

Runs inside these playbooks — curated sequences you can launch with one paste: