The two Claude prompts from my latest video — copy them, paste them in Claude Code, and watch a multi-agent pipeline build a parametric DCF in Excel and the matching pitch deck.
Here's my video walking through the build end-to-end: the architecture, why the work is split between an analyst and an architect, why I'm running Opus on one and Haiku on the other, and where the model still needs hand-tuning. Click to play it right here on the page.
An agentic system isn't one big chat doing everything. It's a small team of specialised sub-agents, each with a narrow role, the right tools for that role, and a hard editing boundary that keeps them from stepping on each other's work. The orchestrator (the top-level Claude) decides who runs, when they run, and how their outputs get stitched back together.
It works better than a single chat for the same reason a research team beats a solo analyst on a deadline: parallelism (two agents can run at once instead of waiting in a queue), specialisation (a fast, cheap model for reading 10-Ks, a top-tier model for the parts where one wrong formula breaks the whole workbook), and isolation (the analyst can't accidentally rewrite the architect's model and vice versa).
The pattern used in the video is architect · analyst · handoff. The architect builds the Excel structure with placeholder assumptions so the workbook compiles and the balance sheet ties on its own. The analyst reads the 10-K, the earnings call, and consensus, then writes a Bull/Base/Bear driver table. The handoff swaps the architect's placeholders for the analyst's real numbers and re-validates the model. Neither agent has to know how the other one works.
These prompts are the raw build: the same multi-agent pattern, but with the rough edges still in. If you'd rather see the polished implementation running end-to-end before you copy the prompts, that's exactly what Trinity Agent is. Three specialised Claude agents (Architect, Analyst, Reporter) that produce the valuation, run scenario and sensitivity analysis, and export both the Excel model and the written reports.
Heads-up: the Trinity Agent page is a demo version. It serves cached files instead of re-running the full pipeline on every visit, so the numbers you see there may be a few days (or weeks) old and won't reflect the very latest market price or filings. Treat the output as a reference of what the system produces, not as live equity research.
Be careful with token usage. A multi-agent pipeline like this burns a lot of context, and one full company run on Opus can cost real money. The bill depends almost entirely on which model you put behind each agent, so pick the optimal model for the job rather than defaulting Opus everywhere. In this example I'm running Opus 4.7 on the architect (where one wrong formula breaks the entire workbook) and Haiku on the analyst (fast and cheap, since it is just reading filings).
To monitor it live, open claude.ai in a separate tab, click Settings → Usage, and keep that page open while the pipeline runs. You'll see your token spend climb in near real-time and can cancel if a run is getting out of hand before it finishes.
This is the prompt that builds the workbook. It launches two sub-agents in parallel. The
Analyst (Haiku, fast, cheap, reading-heavy) goes off to research the company and
produces a Bull/Base/Bear driver table from the 10-K, earnings call, and consensus. In
parallel, the Architect (Opus 4.7, the most capable model, because zero formula
or formatting errors are allowed) constructs the 11-tab parametric Excel model with
generic placeholders so the balance sheet ties on its own. When both finish, you do the
Handoff yourself: swap the placeholders for the analyst's real numbers, re-run
validate.py, and report the Bull / Base / Bear implied prices.
You're free to swap the model on any agent. Sonnet, Haiku, and Opus all work. The one combination I'd avoid is Haiku on the architect, because building a parametric workbook where the balance sheet has to tie on its own is the most complex task in the pipeline, and Haiku tends to introduce formula and formatting errors there. The other direction is fine: if you have the token budget, you can bump the analyst up to Opus for sharper research and tighter Bull/Base/Bear theses.
Replace {TICKER} and {COMPANY NAME} at the top, paste into Claude
Code from inside an empty folder, and let it run.
Build a parametric equity-research financial model for {TICKER} ({COMPANY NAME}).
Run it as a PARALLEL two-agent pipeline using sub-agents: in a SINGLE message,
launch BOTH sub-agents below in the background so they run concurrently. Launch
the ANALYST on the Haiku model (fast — it's just reading) and the ARCHITECT on
the OPUS 4.7 model (claude-opus-4-7) — it is CRITICAL that the Excel workbook has
zero formula or formatting errors, so the architect gets the most capable model.
Wait for both to finish, then do the HANDOFF yourself.
Use Python + openpyxl. Every forecast and valuation number must be a live Excel
FORMULA, never hardcoded, so the model recalculates when an assumption changes.
Keep everything lean — speed matters, don't over-engineer.
Deliverables in this folder:
data.py · scenarios.py · {TICKER}_Model.xlsx · validate.py · research.md · METHODOLOGY.md
============ VERIFICATION RULE — numbers AND formatting · architect + handoff ============
Never report or trust a workbook you haven't EVALUATED. openpyxl writes formulas
as TEXT and does not compute them — so you must re-open and evaluate the file to
know both the numbers and how it renders. Run validate.py after building or
changing ANYTHING — re-check after EVERY change, including after the analyst's
inputs are swapped in, not just at the end.
NUMBERS — all must tie, every year:
• Balance Check = 0 (Assets − Liabilities − Equity).
• Income statement foots (GP = Rev − COGS; EBIT = GP − opex; NI = Pre-tax − Tax).
• Cash-flow ending cash = Balance-sheet Cash.
• Forecast revenue reflects the Scenarios growth % (Year-1 = prior × (1+growth)).
• DCF Implied Price = Sensitivity-grid center cell (within $0.01).
• No #DIV/0!, #REF!, #VALUE!, or #NAME? anywhere.
FORMATTING — must be clean and consistent:
• Percentages display as % (e.g., 15.0%), NOT raw decimals (0.15). Dollars show
as $ with correct decimals. Share counts and $MM use thousands separators.
• No column shows "#####" (every column wide enough for its values).
• Negative numbers render consistently (parentheses or red), never a bare "-".
• Headers bold; consistent font and number formats down each column; no stray
cell showing a formula as literal text.
• Tabs named exactly as specified; rows aligned across the 8-year span.
If ANY check fails — number OR formatting — fix the formula, the cell format, or
the retained-earnings/cash plug, then re-run validate.py. NEVER hardcode a value
to force a number to match, and never leave a formatting defect. Do not proceed or
report success until validate.py passes clean. Report only computed numbers.
==================== SUB-AGENT 1 — ANALYST (Haiku · background) ======================
Tools: WebFetch, WebSearch, Read, Write, Bash. You research the company and output
the Bull/Base/Bear driver values — you do NOT build or edit the model or formulas.
Speed: cap at 6 web fetches total. Prioritize the 10-K, one recent earnings call,
and 2-3 consensus sources. Don't exhaustively browse.
4 steps:
1. Baseline — most recent 10-K (SEC EDGAR): 3-year revenue, gross margin, net
income, segment mix, share count, fiscal-year-end.
2. Recent + guidance — last earnings call: growth trajectory, margin direction,
management tone. Plus the current 10Y UST yield (one line of macro context).
3. Consensus — mean price target, high/low range, # of firms (1-2 sources).
4. Drivers — set Bull / Base / Bear for each of the 10 drivers below, one-line
rationale each. Build BASE first (research-anchored), then derive Bull
(believable upside) and Bear (believable downside) by nudging 2-3 drivers each,
kept roughly SYMMETRIC around base (no catastrophe in the driver values — that
belongs in the bear thesis text, not an 8-point growth swing).
The 10 drivers (must match the Scenarios tab exactly):
Revenue growth %, Gross margin %, R&D % of revenue, SG&A % of revenue,
Tax rate %, CapEx % of revenue, AR days, Buybacks ($MM),
Terminal growth %, Equity Risk Premium.
OUTPUT: write research.md — company snapshot · recent results & guidance · macro
(10Y UST) · consensus (table) · Bull/Base/Bear theses (one paragraph each) · key
risks · sources cited inline. END the file with the final driver table:
| Driver | Bull | Base | Bear | Rationale |
|---|---|---|---|---|
| Revenue growth % | … | … | … | … |
| ... (all 10) | | | | |
This table is the handoff to the model. Ground every value in a source; don't
invent consensus figures.
================= SUB-AGENT 2 — ARCHITECT (Opus 4.7 · background) ====================
Tools: Read, Edit, Write, Glob, Grep, Bash, WebFetch (use WebFetch ONLY to pull
the 10-K historical facts for data.py — do NOT research a thesis or consensus,
that's the analyst's job).
You own the 10-K facts and the model structure. Build with GENERIC-BUT-RATIONAL
placeholder driver values (close to the trailing 3-year historicals — modest, no
heroic assumptions) so the model compiles and the balance ties on its own. The
analyst's real values replace the placeholders at the handoff.
Files you create:
- data.py — 3-year 10-K historical FACTS (pull from SEC EDGAR), the ground truth.
- scenarios.py— Bull/Base/Bear driver values, seeded with generic placeholders.
- validate.py — re-opens the xlsx with the `formulas` library and runs every check
in the VERIFICATION RULE (numbers AND formatting); usage:
py -3 validate.py {TICKER}.
- {TICKER}_Model.xlsx — the workbook.
- METHODOLOGY.md — model structure + driver definitions.
Workbook — 11 tabs, in order, keep each lean:
1. "Background" — company, ticker, FYE, build date, 2-line description, brief disclaimer.
2. "10k Income Statement" — 3 historical (from data.py) + 5 forecast: Revenue
(1-2 segments), Total Revenue, COGS, Gross Profit, R&D, SG&A, EBIT, Tax,
Net Income, Shares, EPS. Forecasts driven by the Scenarios tab.
3. "10k Balance Sheet" — same 8-year span: Cash, Receivables, Other CA, PP&E,
Intangibles, Total Assets, Payables, Debt, Other liabilities, Total Liabilities,
Equity (APIC, Retained Earnings), Total Equity, and a "Balance Check" row
(Assets − Liab − Equity) tying to 0 every year by formula.
4. "10k Cash Flows" — Net Income, D&A, working-capital change, CFO, CapEx,
Buybacks, CFF, Free Cash Flow (by formula).
5. "Macro & Industry" — 10Y UST, ERP, Beta (input), Cost of Equity (CAPM),
Cost of Debt, WACC (formula).
6. "Operating Model" — links the 3 statements across 5 forecast years; reads the
Scenarios tab; pulls historicals from the 10k tabs.
7. "Scenarios" — Bull / Base / Bear columns, one row per driver (the 10 above),
plus a Bull/Base/Bear picker cell feeding the Operating Model.
8. "DCF" — 5 forecast FCFs discounted by WACC; TV = final FCF × (1+g)/(WACC−g);
EV = ΣPV(FCF) + PV(TV); + Cash − Debt = Equity Value; ÷ Shares = Implied Price.
9. "Scenarios + Sensitivity" — implied price for Bull/Base/Bear + a 5×5 WACC ×
terminal-growth grid (center cell = Base implied).
10. "Ratio Analysis" — gross/operating/net margin, ROE, debt/equity, revenue CAGR
(all by formula off the statement tabs).
11. "historical_returns" — small 3-year returns table + beta note (no chart).
When done: run validate.py and confirm every check (numbers AND formatting) passes
with the placeholders before finishing. Report the workbook path.
======================= HANDOFF — you do this after BOTH return =======================
- Replace the architect's placeholder values in scenarios.py with the ANALYST's
Bull/Base/Bear driver table, and rebuild the Scenarios tab.
- Run validate.py and RE-CONFIRM every check in the VERIFICATION RULE — numbers
AND formatting. The new analyst inputs must not introduce any number break
(balance still ties, implied price still computes) OR any formatting defect
(percentages still render as %, no #### columns, negatives still formatted).
- If anything fails, fix it and re-run validate.py (never hardcode a forced match).
- Report the Bull / Base / Bear implied prices, the spread vs the current market
price, and a one-line BUY / HOLD / SELL read.
FORMATTING: historicals hardcoded from data.py; forecasts are formulas. Clean
styling — bold section headers, $ and % formats, subtle fill on the Scenarios
input cells and the implied-price cell. No charts. Save as {TICKER}_Model.xlsx
and tell me the path.
Once Prompt 1 has produced {TICKER}_Model.xlsx, research.md, and
the scenario outputs, this second prompt picks them up and writes the pitch deck: cover,
thesis, drivers, valuation football-field, sensitivity, risks, recommendation. It treats
the Excel model as the single source of truth, so every number in the deck is sourced
back to a cell.
/meridian-finance-design
Using the Meridian design system above (follow all its rules — palette, action
titles, source footnotes, no gradients/shadows/emoji), build a 9-slide equity-
research pitch deck for {TICKER} ({COMPANY NAME}). The model pipeline has already
run — source ALL content from the files in this folder, the way a parametric deck
builder does.
SOURCE-OF-TRUTH MAP — pull each slide's content from the named file, cite it in the
slide footer:
• Implied prices (Bull/Base/Bear), WACC, financials → COMPUTED values from
{TICKER}_Model.xlsx via the `formulas` library (NOT the formula text).
• Scenario driver values + theses → scenarios.py.
• Peer multiples → scenarios.py (if present).
• Business description, segments, geo mix → data.py + research.md.
• Risks, moat/competitive view, conclusion → research.md.
• 3-year historicals (revenue, margins, net income) → data.py.
Footer of every slide: "Source: <file(s) that slide's numbers came from>".
If a number isn't in these files, do NOT invent it — omit it or label it N/A.
Render each slide as HTML, then export to a single PDF via Playwright Chromium at
EXACTLY 1280×720 px per page. Save as {TICKER}_Research_Deck.pdf.
SLIDE SEQUENCE:
1. Cover — company, ticker, recommendation (BUY/HOLD/SELL), current price, implied
Base price, date.
2. Business overview — segments, geographies, what it does (data.py + research.md).
3. Recent financials — 3-year revenue / margin / net income with YoY (data.py).
4. Investment thesis — Base case in 2-3 tight bullets (research.md).
5. Scenario drivers — Bull / Base / Bear driver table (scenarios.py).
6. DCF valuation — the bridge (FCF → EV → equity → implied price), computed values.
7. Sensitivity — the WACC × terminal-growth grid of implied prices (from the xlsx).
8. Football field — valuation bands (DCF Bull/Base/Bear) vs current market price.
9. Recommendation — the call, conviction, key risks, what would change the view.
LAYOUT DISCIPLINE (the skill doesn't cover PDF rendering — get these right):
- Each slide is a FIXED 1280×720 frame. Content must NEVER overflow — if too much,
cut content; don't shrink the frame or let it spill.
- Consistent inner margins (~46px top/bottom, ~64px left/right); nothing touches the edge.
- Bottom strip is the footer line ONLY (source left, page number "0X / 09" right) —
no body content there.
- Title at top, body in the middle, footer pinned at bottom with breathing room above it.
- Tables/charts fit inside the margins; consistent type scale across all 9 slides.
AFTER RENDERING — verify before reporting done:
Open the PDF and check every page for (a) footer overlap, (b) margin bleed, (c)
content running off the 720px height, (d) numbers that don't match — cross-check
implied prices, drivers, and financials against {TICKER}_Model.xlsx + scenarios.py.
Fix any failing slide, re-render, re-check. Report done only when all 9 pages are
clean and the numbers tie. Give me the PDF path and page count.