firma
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Capabilities
Features and capabilities supported by this server
| Capability | Details |
|---|---|
| tools | {
"listChanged": true
} |
| prompts | {
"listChanged": true
} |
| resources | {
"listChanged": true
} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| show_portfolioA | Current holdings derived from the user's transaction log: ticker, shares, avg cost, current price, market value, P&L (absolute and %), plus an optional risk summary (Sharpe, volatility, drawdown) from snapshot history and FX return decomposition when a non-USD display currency is requested. All monetary values are returned in |
| show_txnsA | Full transaction log (buys, sells, deposits, dividends, taxes) ordered by date ascending. Pass |
| show_balanceA | Stored balance sheet entries (assets + liabilities) by period. Each entry has type (asset|liability), sub_type (cash|investment|other|short_term|long_term), category, amount in |
| show_flowA | Stored monthly cash flow entries (income + expenses) by period. Each entry has type (income|expense), sub_type, category, amount in |
| show_concentrationA | Portfolio concentration measured by Herfindahl-Hirschman Index (HHI) across ticker, currency, sector, and country dimensions. HHI ranges 0–10000; >2500 is high, >5000 very high. Returns top contributors per dimension, plus the pairwise 90-day correlation matrix and an effective-N (correlation-adjusted holdings count): two holdings at 0.9 correlation count as roughly one for diversification. effective_n / correlation_matrix_90d are null/empty until |
| get_market_briefA | Diagnostic: ALL-IN-ONE composite read of current portfolio state. Call this FIRST for any portfolio, market, regime, or check-in question - it returns a comprehensive snapshot in a single response, so you almost never need multiple tool calls just to answer 'how am I doing today'. Returns deterministic, rule-derived facts only — no forward-looking probability distributions, no caller-supplied assumptions. For probabilistic projections (FIRE timelines, short-horizon outlooks under explicit assumptions), use |
| reportA | Aggregated wealth reports. |
| add_txnA | Insert one or more transactions in a single call. Reason capture (critical for thesis tracking): For NEW buy/sell trades — not historical bulk imports — the Each row carries its own
In both cases A single-entry call returns the inserted transaction; a multi-entry call returns a per-ticker / per-type summary. |
| edit_txnA | Update fields of an existing transaction by id. Only provided fields are changed. When Changing |
| delete_txnA | Delete a single transaction by its id. The user must confirm — never call this without explicit instruction (e.g. "delete transaction #42"). Removing a transaction recalculates all subsequent positions/avg cost since holdings are derived from the log. |
| add_balanceA | Upsert one or more balance sheet entries (also edits — same composite key overwrites). A single-entry call returns the upserted entry; a multi-entry call returns counts grouped by period. |
| add_flowA | Upsert one or more cash flow entries (also edits — same composite key overwrites). A single-entry call returns the upserted entry; a multi-entry call returns counts grouped by period. |
| add_monthlyA | Batch upsert balance and flow entries for a single period in one call. Primary tool for month-end settlement / 월말 결산. When the user says "결산", "월말 결산", "month-end closing", or "record this month" — do NOT just display data. Instead: (1) ask for each balance category and each cash flow category; (2) confirm the numbers; (3) call this tool once with the full arrays. VALID BALANCE CATEGORIES — assets: cash, savings, housing_sub, usd_cash, cash_other, domestic_stock, overseas_stock, real_estate, pension, vehicle, deposit, asset_other. Liabilities: credit_card, short_term_other, loan, long_term_other. VALID FLOW CATEGORIES — income: salary (employment), business (employment), dividends (investment), interest (investment), income_other (other). Expense: personal (consumption), insurance (fixed), phone (fixed), utilities (fixed), rent (housing), maintenance (housing), loan_repayment (debt), expense_other (other). Use ONLY these category strings and their matching sub_type — do NOT invent your own. After recording, call report with target "settle" to show the confirmed summary. |
| add_priceA | Set the current price of ONE non-stock asset (crypto / commodity / real_estate / other). These assets have no market data provider, so their market value is entered manually — unlike stocks, which are auto-priced by |
| delete_balanceA | Delete balance entries for a period. If category is provided, only that single entry is removed; otherwise all entries for the period are deleted. |
| delete_flowB | Delete flow entries for a period. If category is provided, only that single entry is removed; otherwise all entries for the period are deleted. |
| add_snapshotA | Sync latest prices from Finnhub then record a portfolio snapshot for today. Required before snapshot data is useful. |
| edit_snapshotA | Update shares, avg_price, or current_price for a holding in a snapshot. Identified by date + the asset (asset_type + market + ticker). Works for non-stock assets too — pass their asset_type; market is ignored for non-stock. |
| delete_snapshotA | Delete all portfolio snapshot rows for a given date (YYYY-MM-DD). Use only when the user explicitly asks to remove a bad snapshot — destructive. |
| show_snapshotA | Query portfolio snapshot history. Without ticker, returns daily total market value in |
| show_benchmarkA | Compare portfolio return against benchmark indices (default: SPY and QQQ). Uses daily snapshot history when available for accurate time-series comparison; falls back to cost-basis vs current value when no snapshots exist. |
| show_riskA | Portfolio risk metrics derived from snapshot history: annualized volatility, max drawdown, Sharpe ratio, Sortino ratio, win rate, and beta vs benchmark. Requires at least 10 daily snapshots — if the user has fewer, suggest running |
| show_dividendA | Estimated annual dividend income for all holdings. Returns per-ticker yield, annual DPS, and estimated income in |
| show_newsA | Recent company news from Finnhub for a single ticker — headline, summary, source, published timestamp, URL. Default lookback is 7 days, capped to |
| show_financialsB | Fetch SEC-reported financials for a ticker. Returns key income statement, cash flow, and balance sheet metrics extracted from XBRL filings. |
| show_valuationA | Valuation deep-dive for a single ticker: PEG ratio, Price/Sales, and FCF yield — computed from 8 quarters of SEC filings. Use when the user asks 'is X overvalued / cheap?', 'what's the PEG?', 'how does the valuation look?'. Requires Finnhub key. Market cap and PE come from the price cache; revenue, EPS, operating cash flow, and capex come from XBRL filings. |
| show_earningsA | Fetch earnings calendar. Without a ticker, returns upcoming earnings for all held tickers. With a ticker, returns history + upcoming. |
| show_macroA | Curated macro snapshot in one view: 8 indicators (VIX, 10Y Treasury, yield curve, USD index, HY credit spread, breakeven inflation, Fed funds, plus FX vs the requested display currency, each with current value, 30d/90d delta, and 5y average), plus an Economic Stress Index (0–100 from 5 FRED series with per-component breakdown), and a macro regime bias (Risk-on / Mixed / Risk-off from 5 binary signals). The display_currency arg drives the FX series selection (USD = no FX line). |
| show_fxA | Inspect the local FX rate cache (foreign per 1 USD). Without |
| setup_statusA | One-shot setup diagnostic. Call this at the start of every conversation, and any time the user asks for analysis but you're unsure what data is available. Returns: API key state, data counts (transactions / balance / flow / prices / snapshots / FX), profile, next_steps for onboarding, capabilities (which kinds of analysis are currently possible), and analyst_context (the persona, principles, data_gating rules, and reasoning frameworks). Treat capabilities as a hard gate — if a required capability is false, follow the matching data_gating rule instead of fabricating an answer. |
| show_profileA | Read the user's stored profile (birth year, retirement target year, target net worth, risk tolerance, free-form notes). Target net worth is returned in |
| set_profileA | Update the user's profile. Partial updates — only provided fields are changed. All fields are optional; capture only what the user volunteers, never invent values. Birth year and retirement target year are 4-digit years; |
| syncA | Refresh local caches. scope='prices' fetches latest stock prices (US via Finnhub, non-US via Yahoo, all stored in USD; requires finnhub_api_key). scope='fx' backfills the historical FX rate cache from FRED (KRW/JPY/EUR/CNY/GBP/HKD/INR/TWD per USD, increment-only; requires fred_api_key). scope='all' (default) runs prices then fx, mirroring |
| project_net_worthA | Thought experiment: forward-looking Monte Carlo projection of net worth under caller-supplied assumptions, multi-scenario. Runs monthly GBM under one or more (return, vol) pairs in parallel, adds a fixed monthly contribution, applies one-time life events, and returns P10 / P25 / P50 / P75 / P90 trajectories per scenario. |
| simulate_scenarioA | Call this for any short-horizon outlook question (1 day to 1 week). Trigger phrases: "내일", "tomorrow", "이번 주", "next week", "화요일", "수요일", "this Thursday", "how might X day look", "what if [macro event] happens", "FOMC 영향", "earnings 영향", "포트 어떻게 될까", "내 포트는 어떨까". DO NOT answer these from the brief alone — the brief is diagnostic only. This tool turns the brief's measured data into a quant answer. Thought experiment: deterministic conditional analysis. Given hypothetical market shocks, returns per-holding and portfolio P&L impact based on beta. Unlike |
| show_thesis_trackA | Review past trades that have a recorded |
| show_anti_portfolioA | Track the post-exit performance of positions the user has fully sold — the data brokerage apps deliberately don't show (because it would highlight bad sells). For each ticker the user once held but no longer does, returns the last sell date, last sell price, current price, days since exit, post-sell price change %, and a label: |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
| import-trades | Guided trade import — confirms column mapping before writing any data |
| import-balance | Guided net-worth import — bulk-upsert assets and liabilities across multiple months |
| import-flow | Guided cash-flow import — bulk-upsert income and expenses across multiple months |
| month-end | Guided month-end entry — balance snapshot and cash flow for the current period |
| setup-profile | Capture the user's goals (5 fields, every one optional) so future analysis can anchor to them |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
| portfolio | Holdings table with weights, P&L, and sector. Attach this as context when you want Claude to reason about the portfolio without an explicit tool call. |
| thesis-log | Recent trades with their recorded reasons. Attach when reviewing whether your past theses played out. |
| profile | Goals and risk tolerance. Attach when you want Claude to anchor advice to the user's actual targets. |
Latest Blog Posts
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/evan-moon/firma'
If you have feedback or need assistance with the MCP directory API, please join our Discord server