OpenChart
Claude·Codex와 함께하는 무료 데스크톱 차트 도구. 알림 설정·차트 움직임 분석·데이터 제공자 선택
아직 감지된 업데이트가 없습니다. GitHub 릴리스가 나오면 여기에 보입니다.
개인 계정의 공개 저장소 소유자는 GitHub로 로그인해 운영자를 확인하고 소개를 직접 관리할 수 있습니다. 관리자 승인은 필요하지 않습니다.
로그인한 뒤 확인 파일을 만들어 이 저장소의 기본 브랜치에 30분 안에 커밋해 주세요. 다른 브랜치나 포크의 파일은 인정하지 않습니다. 파일을 올린 뒤 아래에서 확인하면 관리자 승인 없이 관리할 수 있습니다. 자격을 유지하려면 파일을 남겨 두세요.
로그인이 필요하면 로그인 화면으로 이동합니다. 로그인 후 이곳으로 돌아와 원하는 확인 버튼을 다시 눌러 주세요.
프로젝트 폴더에서 /nomorevibe verify를 실행하면 소유권을 확인하고 소개를 직접 관리할 수 있습니다.
1분 만에 확인하기A hedge fund in your pocket with professional-grade data and an AI financial analysis desk.
저장소 README에서 가져옴
README 전체를 불러오는 중입니다.
README 전문 보기 ↗The AI deal desk that does the work, and learns how you do it.
YouBank is a financial research terminal and an email agent for people whose work is deals. It has three parts:
Production: https://youbank-nu.vercel.app until the custom domain is set (NEXT_PUBLIC_SITE_URL; see docs/launch-billing.md) · Free while in beta.
The product sits between two groups of tools:
General AI assistants. They will build a DCF for $20 a month, but not from verified data, and they do not do the follow-through. In the September 2026 update of Vals AI's Excel Modeling Benchmark, frontier models passed only 64% of numerical checks.
Platforms that sell the data. They charge thousands to tens of thousands of dollars a year:
Retail terminals (TIKR, Koyfin) cost $25–$120 a month, but they do not act on anything.
YouBank offers cited, filing-backed work plus an agent that acts on it, priced for the firms in between.
| Who | What YouBank does for them |
|---|---|
| Boutique advisors and placement agents | Comps, buyer lists and teasers without a Capital IQ budget, and an outreach desk that keeps every mandate moving |
| Emerging VC and PE managers | Form D and funding signals on the companies you track, cited diligence, and a pipeline that files itself from your inbox |
| Founders raising or selling | Cold outreach, investor and customer follow-up, and replies to your own team, with autopilot where it has been earned |
| Students recruiting into finance | Real comps and DCFs on real filings, deal walk-throughs, and the same desk they will use on the job |
The terminal and tools are tailored to eight careers:
Each career has its own research, tool pack, watchlists, prompt library and default style.
/app/terminal is a multi-panel terminal driven from the keyboard, with familiar function codes. Company
functions take a ticker (SNOW WACC); market functions do not (ECO); a few take words
(EQS profitable software companies growing over 20%, PORT AAPL 40 MSFT 30 KO 30).
Company
| Function | What it shows | Models |
|---|---|---|
DES | Description | |
FA | Financial analysis | |
GP | Price chart with 50- and 200-day averages, volume, trend and volatility regime, a price cone | GARCH(1,1) |
HP | Daily price history | |
BETA | Beta four ways, with standard errors and a rolling beta | OLS, Blume, Welch (2022) |
RISK | Volatility now and forecast, VaR and expected shortfall, drawdowns | EWMA, GARCH, Cornish-Fisher, Kupiec backtest |
COMPS | Trading comps | |
PREC | Precedent transactions | |
CAP | Capital structure | |
WACC | Cost of capital from its parts, with a range and a tornado | CAPM, implied-rating spread, Monte Carlo |
IRAT | Implied credit rating and default odds | Altman Z'', Ohlson O-score, Merton distance to default |
DDIS | Debt maturity ladder and refinancing risk | |
QUAL | Earnings quality and red flags | Beneish M, Piotroski F, Sloan accruals |
FCST | Revenue forecast against the Street | M4 combination, conformal intervals |
EE | Earnings: surprises, beat odds, the typical move | Beta-Binomial, conformal quantile |
ANR | Analyst ratings, targets and drift | |
DVD | Dividends and a safety score | |
FIL / EVT / INS / XBRL | Filings, 8-K events, Form 4 insiders, any XBRL concept | |
AI | Assistant |
Markets and economy
| Function | What it shows | Models |
|---|---|---|
WEI / FXC / CMDTY | World indices, currencies, commodities and crypto | Each move in standard deviations of its own volatility |
MOST / SECT / MA | Movers, sector performance, M&A filings | |
GC | Treasury curve against a week, a month and a year ago | Nelson-Siegel; the New York Fed recession probit |
ECO | Inflation, jobs, growth and rates, with three-month outlooks | Damped trend, conformal intervals, the Sahm rule |
EQS | A screener over every SEC filer, in plain English | A small model turns words into filters you can edit |
PORT | Portfolio risk: risk shares, correlations, a year of outcomes | Covariance attribution, bootstrap |
Crypto (no ticker needed; free public data, see Crypto)
| Function | What it shows | Models |
|---|---|---|
CRYP | The largest tokens, total market cap, bitcoin dominance, DeFi value locked, stablecoin supply | |
TOKEN <token> | One token: price, supply and float, volatility, drawdown, its protocol's fees, revenue and holders' revenue, valuation multiples, the next unlock | Beta and correlation to bitcoin |
DEFI / STBL / YLD | Value locked by chain, category and protocol with fees and revenue; stablecoin supply and net flows; the largest yield pools | |
BTCN | Bitcoin fees, mempool, hashrate, the next difficulty adjustment, pools | Hashprice, breakeven power price |
RAISE / UNLK / TRSY | Crypto venture rounds and lead investors; token unlocks in the next 60 days; companies' crypto at fair value from SEC filings | |
RWA | Tokenized treasuries, private credit, commodities and real estate | |
WALLET <address> | Read-only balances and risk of any address (0x…, name.eth, Bitcoin, Solana) | Historical-simulation VaR |
Workspace: LEARN (your mastery of each function, what to learn next, quick quizzes), PG (peer
groups), TOOLS and TOOL <id>.
What makes it more than a data screen:
Type into the command bar, for example SNOW COMPS, CCL IRAT or DDOG TOOL dcf. / or Cmd+K focuses it,
? lists every function. Each seat gets a function strip for its role. A ticker that is also a code works
with a function after it: PG DES is Procter & Gamble.
/app/tools holds 328 tools:
Both kinds render into the same 19 kinds of output block:
AI workflows. A workflow's instructions are a numbered method that names the exact data tools and search phrases to use. The model streams tool calls and returns JSON that matches the output contract.
Calculators. A calculator is a pure compute(inputs) function. It recalculates as you type and can be
prefilled from the loaded company's SEC data.
Saved runs. Every run is saved with its inputs, output, sources, model and duration. Reopen it from the
library at /app/tools/<id>?run=<n>.
How to add tools: docs/05-tool-pack-authoring.md.
MARKET_BACKUP=off turns off Nasdaq, the ECB
rates, CoinGecko and AI research (SEC filings are public domain and stay on). Operators
can check which layers answer from production at /api/market/health (Bearer CRON_SECRET)./app/vc holds a directory of 18,037 startups (snapshot of 21 September 2026). Sources:
It also lists Form D raises with amounts and officers, and crypto projects from DefiLlama's raises database (one entry per project, with every disclosed round, its investors and the total raised).
A nightly job (/api/cron/sync, 06:00 UTC) refreshes the directory:
/app/crypto (and the terminal's crypto functions) covers crypto research, crypto deals, a read-only
portfolio and on-chain records. Nothing in YouBank holds a key, trades, swaps or moves funds. The
only thing ever sent to a chain is a transaction the person signs in their own wallet (notarizing), and
the server only reads it back.
Research (free). Every figure cites its source under "Models and sources".
Deal intelligence (free).
CryptoAssetFairValue, current and noncurrent, under ASU 2023-08), newest quarter per company.Portfolio. Connect a wallet (EIP-6963 for MetaMask, Coinbase Wallet and others; the Wallet Standard for Phantom and other Solana wallets) or paste addresses: Ethereum, Base, Arbitrum, Optimism and Polygon (native coins and major tokens, read from public nodes in one multicall per chain), ENS names, Bitcoin and Solana. Holdings are priced and shown with profit and loss against what you say you paid, concentration (Herfindahl), stablecoin share, chain exposure, one-year volatility and one-day 95% value at risk at today's weights (historical simulation; crypto annualises over 365 days).
Notarizing on chain. A deal document, or a Studio model's audit trail (every change, who made it and
when, and a hash of the patches), is hashed with SHA-256 in the browser; the file never leaves the
machine. The person's own wallet then sends a zero-value transaction to their own address on Base
with the hash as readable calldata (YouBank notary v1 sha256:<hash>), costing a fraction of a cent.
The server reads the transaction back from a Base node and marks it confirmed only if it is from that
address, to itself, carries no value and records that hash. Anyone can check a file against any
transaction, and a notarized Studio model can be checked for changes since.
Mining map. Bitcoin mining sites and crypto data centres of the listed miners (Riot, MARA, Core
Scientific, Cipher, IREN, Bitdeer, Hut 8, CleanSpark and others), from their filings through mid-2025,
with stated capacity, an estimate of annual power use (85% load) and EIA's estimate that crypto mining
used 0.6% to 2.3% of U.S. electricity in 2023. Locations are to the town. Sites being converted to AI
and HPC are marked. It is a tab on /app/crypto and a layer (with its own button) on the Edge map;
the layer is self-contained in src/lib/crypto/map-layer.ts, served as GeoJSON by /api/crypto/sites.
Premium (registered in src/lib/billing/features/crypto.ts; each runs only on a click and the server
checks the plan first):
| Feature | Plan | What it does | Cost to us per use |
|---|---|---|---|
| Deep wallet analytics | Pro | Every token a wallet holds and its recent transfers and counterparties, from Alchemy (EVM) and Helius (Solana) | about $0.01 |
| Pro crypto data | Pro | CoinGecko Pro and DefiLlama Pro on TOKEN, RAISE and UNLK | about $0.001 |
| Dune queries | Deal Team | The latest results of any saved Dune query, sortable and exportable as CSV | about $0.05 |
/app/copy follows hedge funds through their 13F filings and, with Pro, copies them in your own
brokerage account. YouBank builds the orders; you approve every batch. Nothing trades without your
click, nothing trades from a schedule, and YouBank never holds your money. The full design, data
sources, rules and the compliance list are in docs/copy-trading.md.
Timing, said plainly in the product. A 13F arrives once a quarter, up to 45 days after the quarter ends. "Real time" means: the moment a new 13F or 13F/A is filed, we turn it into orders for you to review. Every backtest shows the filing lag.
Free:
Pro and up (registered in src/lib/billing/features/copytrade.ts; the server checks the plan):
| Feature | Plan | What it does | Cost to us |
|---|---|---|---|
| Copy trading with your broker | Pro | Connect about 20 brokers through SnapTrade; review and approve each batch of orders | SnapTrade's charge per connected user, about $2 a month |
| Fund blends | Deal Team | One copy of several funds, weighted as you choose | none |
| More live copies | Deal Team | Up to 10 live copies (Pro runs 2) | none |
Safety rails. Real orders need COPYTRADE_TRADING_ENABLED=1 (off by default; paper copies work
either way). Limit orders by default with a band, per-order and per-day limits, market orders refused
while the market is closed, a typed confirmation for large batches, positions you
hold outside a copy never sold unless you opt in, consents stored at first use, and an append-only
audit log of every consent, proposal, approval and order payload (downloadable as CSV).
/app/algo ("Algo trading" in the nav) runs rule-based strategies on paper or in a person's own broker
account, with an AI agent to build, test and explain them. The research (what Webull, Robinhood, SnapTrade,
Alpaca, IBKR and Tradier officially allow in 2026, how algo trading is done well, AI-agent guardrails,
regulation) and the full design are in docs/algo-trading.md.
src/lib/algo/strategy.ts): universe, signal, sizing,
schedule, capital, risk limits and execution, built in a form or as JSON. Templates: trend following with
volatility targeting, momentum rotation, RSI mean reversion, cointegration pairs, DCA and rebalancing, a
13F copy (reusing Fund copies), covered calls and cash-secured puts. Quant's signals and target portfolios
plug in through the contract in src/lib/quant/contracts.ts (src/lib/algo/signals.ts).| Feature | Plan | What it does | Cost to us |
|---|---|---|---|
Live algo trading with approval (algo.live) | Pro | Real orders after each batch is approved | About $0.10 a month of ticks; SnapTrade's fee is Fund copies' |
AI trading agent (algo.agent) | Pro | The agent chat | About one assistant answer a turn, inside the AI allowance |
Autonomous algo trading (algo.autonomous) | Deal Team | Trades within limits without asking | none beyond the ticks |
More strategies and 15-minute decisions (algo.more) | Deal Team | 25 strategies (Pro 10, Free 3) | none beyond the ticks |
Off by default. Real orders need ALGO_LIVE_ENABLED=1, which should wait for counsel's review
(docs/algo-trading.md, section 6).
/app/news is a news desk for each profile: every group of an investment bank (energy gets EIA reports,
OPEC, pipeline and LNG approvals; restructuring gets bankruptcies and missed coupons; ECM gets IPO
filings and pricings), private equity, venture, public markets, corporate finance, consulting,
accounting and students. Every ten minutes it reads about ninety free sources and turns them into
stories:
NI CRYPTO finds them.The same event from many outlets becomes one story (headline embeddings plus word and figure overlap, calibrated on live headlines), ranked for each person by desk fit, importance, watchlist, the companies where their contacts work, follows, mutes and freshness, with the reason shown. A small model reads the important stories once: bullets, key numbers, why it matters, companies (tickers checked against SEC's list) and deal terms. Deals and raises fill a tracker with the premium to the unaffected close and implied multiples from SEC figures, and advisor league tables.
/news/<story>: the summary, chart, timeline and sources for anyone, with
link previews drawn from the story's data, share buttons and a sign-up invitation; never anything
personal. In the sitemap.TOP (your desk's top stories), CN (company news), NI <topic>, and the
latest news on DES.One interface over two providers:
gpt-6-astra.You can switch the model and the reasoning depth (low, medium, high or xhigh) per run. The assistant streams its output, calls function tools, shows reasoning summaries, searches the web and returns structured output.
Thirty-two tools:
| Tool | Tool | Tool |
|---|---|---|
get_company_financials | get_trading_comps | search_companies |
search_filing | read_filing | web_research |
form_d_search | search_startups | edgar_fulltext_search |
read_document | get_recent_filings | get_xbrl_series |
get_insider_transactions | calc (exact arithmetic) | get_price_risk |
get_credit_risk | get_earnings_quality | get_revenue_forecast |
get_cost_of_capital | get_macro_outlook | screen_companies |
get_crypto_market | get_token | get_defi_overview |
get_stablecoins | get_crypto_raises | get_token_unlocks |
get_crypto_treasuries | get_bitcoin_network | get_rwa_tokenization |
get_wallet_portfolio | token_valuation |
The seven after calc are the terminal's models, so an answer about risk, credit, a forecast or the economy
names the model behind each number and gives a range. The crypto tools read free public data
(CoinGecko, DefiLlama, mempool.space, SEC XBRL, public nodes) and return source ids for every figure;
token_valuation does fee-multiple, discounted token cash flow and staking-yield arithmetic exactly.
Cost. Classification, extraction and summaries route to a small model (GPT-5.6 Luna or Claude Haiku 4.5) and drafting to a mid-sized one, which costs a fraction of the flagship; system prompts are kept stable so the providers' prompt caches apply; read-only tools run in parallel; and every call's tokens and cost are recorded and shown in Settings. See docs/research/ai-inference.md.
Allowances. Each person's model spend is capped per UTC day and per allowance month by their plan's AI allowance, from Free ($0.75 a day, $3 a month) to Enterprise ($30 a day, $130 a month per seat). The allowance month starts on the billing anniversary for subscribers and on the 1st otherwise; AI credit packs top it up. Administrators have no cap. Settings, under Plan, shows what has been used. At the cap, AI pauses and everything else keeps working. Prices and allowances: Plans and billing.
Modes: analyst, research, draft, critique, and coach (mock interviews).
Deep research (Pro). Tick "Deep research" under the chat box for a question that matters. The run
starts with a short plan, uses up to 30 tool steps (against 10) at maximum reasoning effort on the
flagship model (AI_DEEP_MODEL overrides it), checks each figure that drives the conclusion in a second
source, and ends with a "Not verified" list. It runs only when ticked; a plan without it gets the plan
message in the chat.
/app/studio is a spreadsheet and slide workspace where the agent does analyst work while you watch. You
can start in three ways:
The terminal's company page also links straight to a new DCF, valuation pack, LBO or comps model for that ticker.
The grid is built to feel like Excel:
The calculation engine (src/lib/studio/) is YouBank's own, and it runs in the browser and on the server:
Formula language. A tokenizer and parser follow Excel's rules: negation binds tighter than ^, and
^ is left-associative. They handle sheet-qualified references, whole columns and rows, defined names,
error literals and array arithmetic.
About 120 functions, including:
They are tested against the results Excel documents.
Recalculation.
Circular references. They are solved the way Excel's iterative calculation does it. Tarjan's algorithm finds each circular group, which is then solved by Gauss–Seidel substitution, ordered so a loop that is switched off settles at once. The limit is 100 iterations, stopping when nothing moves by more than 0.001. The LBO template charges interest on average debt balances, with a circuit-breaker switch.
What-if tools. Two-way data tables (the output recomputed for every pair of inputs) and goal seek.
Imported workbooks. A cell using a function YouBank does not implement shows the value the file had saved.
Each template is fully formula-driven and filled from SEC XBRL company facts and market data:
| Template | What it builds |
|---|---|
| DCF | Unlevered free cash flow over 5 years; a CAPM WACC build; mid-year convention; perpetuity-growth terminal value; implied price and upside; a live WACC × terminal-growth grid written as formulas, with its steps as inputs. For a loss-making company, the margin ramps to its margin before stock-based compensation |
| Trading comps | Peers from the saved peer group or a list you give; EV/revenue and EV/EBITDA with quartiles; the implied value range of the target |
| Valuation pack | DCF, comps and a summary sheet that feeds a football field, plus a linked 6-slide pitch deck |
| LBO | Sources and uses; a debt schedule with a cash sweep and interest on average balances; IRR and MOIC; an entry × exit IRR data table. It uses adjusted EBITDA, with a take-private entry at a 25% premium, for listed companies |
| Merger model | Accretion/dilution, breakeven synergies, and a live premium × stock-mix grid |
| Cap table | A priced round, with the option-pool top-up solved in closed form |
| Token multiples | A token's market cap and FDV over its annualised fees, revenue and holders' revenue, with the implied price from low, mid and high peer multiples |
| Token DCF | Cash flow to tokenholders over 5 years with fading growth, a terminal value, and value per token on the supply expected after unlocks; a discount rate × terminal growth data table |
| Staking yield | Nominal and real staking yield, the dilution of a holder who does not stake, and the value of fees to stakers; a staking ratio × issuance data table |
| Crypto comps | Peer tokens (named, or the top fee earners in the token's category) on market cap and FDV over fees, revenue, holders' revenue and value locked, with quartiles and the implied price |
The crypto templates take a token symbol or CoinGecko id in the ticker box and are filled from CoinGecko and DefiLlama (USD millions, supplies in millions of tokens); left blank, they open with illustrative inputs.
These are available to the agent and one click away in the toolbar:
monte_carlo draws the model's own input cells (optionally correlated through a Gaussian copula),
recomputes the whole workbook for each draw without changing it, and writes percentiles, a tornado
and each input's share of the variance to a Monte Carlo sheet slides can link to;suggest_assumptions gives data-driven ranges for growth, margin, WACC and terminal growth;forecast_series extends history with calibrated intervals;risk_check adds the implied rating and earnings-quality flags.| Direction | What happens |
|---|---|
| Export .xlsx | Formulas with their computed results, styles, widths, frozen panes, merges and defined names. Newer functions get Excel's _xlfn. prefix, and the file asks Excel to recalculate on open. Data tables are written as values with a note |
| Export .pptx | Native, editable tables and column, bar, line and pie charts. Football fields and waterfalls are drawn as precise shapes, the way think-cell does it. Sources, page numbers and confidentiality lines are included |
| Import | .xlsx and .xlsm, keeping values, formulas (shared formulas expanded), number formats, fonts, fills, borders, widths, frozen panes, merges and defined names. Also .csv |
The YouBank add-in puts Studio inside Excel and PowerPoint, on the web, Windows and Mac. Install it from
/app/office (the manifest is served at /office/manifest.xml), click YouBank on the Home tab, and
connect with a code.
Connecting. Office runs add-ins in a frame where a site's cookies are often blocked, so the add-in signs in with a device code, not a session:
ABCD-2345, with no look-alike characters)./office/connect, signed in to YouBank. That page sits outside the app, so a
first-time user can sign in and approve before the ten-minute code expires.Only hashes of the poll secret and the token are stored. Every connected install is listed at
/app/office, and disconnecting one stops its token at once. The Studio API accepts either the browser
session or the token, so the add-in uses the same routes as the browser.
Excel. A workbook links to a Studio document in one of three ways:
Once linked:
PowerPoint.
Requirements. ExcelApi 1.9 and PowerPointApi 1.3: Microsoft 365, Office 2021 or later, or Office on the web.
jsonb re-sorts object keys.Run it from Checks, from PowerPoint, or by asking the agent. It flags what gets a book sent back:
Most findings come with a fix:
Fix all applies every fix as one change. Fixes to the same element stack rather than overwrite each other.
Research behind Studio: docs/research/studio-competitive-landscape.md and docs/research/analyst-grunt-work.md.
/app/crm has eight tabs: Queue, Inbox, Pipeline, Contacts, Insights, Campaigns,
Nurture, and Agent & autopilot.
A mailbox connects in one of two ways:
GOOGLE_CLIENT_ID and GOOGLE_CLIENT_SECRET are set.
gmail.readonly and gmail.send scopes only.More than one mailbox (a work and a personal address, or a shared deal inbox) is part of the Deal Team plan; the first mailbox is open to everyone. The check runs before a second address is stored.
Threading.
X-GM-THRID). Otherwise the key is
the root Message-ID, found from References and In-Reply-To.In-Reply-To and References, so they thread in the recipient's mail client.The mode changes the triage prompts, the pipeline and the writing role.
| Mode | For | Pipeline |
|---|---|---|
| Deal flow | Investing in or advising companies | inbox → screening → diligence → partner review → term sheet → portfolio (or passed) |
| Business development | Selling, partnering, fundraising | lead → contacted → engaged → meeting → proposal → won (or lost) |
Every new thread is classified. Triage records:
Newsletters, auto-replies, no-reply senders and bulk mail are recognised and never answered.
Every draft is written as you. The draft prompt includes:
Each draft carries:
sensitive flag for money, terms and legal matters. Quoting a price exactly as you authorised it is
not sensitive.When a reply needs something only you know, such as a price, a date or a yes, the agent asks one short question in the queue.
Everything the agent writes appears in one place:
You can edit a draft before sending it, and it goes out from your mailbox.
The agent proposes next steps, each with its reasoning:
Nurture rules find relationships that have gone quiet. For each one, the agent decides whether there is an honest reason to write. When there is not, it logs why. Each rule has a daily draft cap.
Campaigns are part of the Deal Team plan: creating, launching, qualifying and drafting them, by hand or on the heartbeat and the nightly run (both skip campaigns for plans without them). Pausing, editing and archiving stay open, so nothing is stranded when a plan changes.
Cold outreach, from lead list to follow-ups:
Relationship intelligence from the mail the agent has read, each number with its method:
/api/cron/agent runs daily at 11:00 UTC. It works in this order:
It only drafts. Drafts of a kind that is on autopilot are scheduled, and the send queue sends them within your sending hours. Each person can turn the morning run off.
Autopilot is off by default. When it is on, each kind of email has its own setting: Off, Ask me or Autopilot.
Sending on its own is part of the Deal Team plan. Switching it on checks the plan, and the scheduler checks it again before every automatic send: if a plan no longer includes it, the master switch counts as off and anything already scheduled waits in the review queue with the reason. Reading, triage and drafts that wait for you stay open to every plan.
| Kind of email | Default |
|---|---|
| Replies to people outside your company | Ask me |
| Replies to your coworkers | Ask me |
| Cold email campaigns | Ask me |
| Follow-ups when nobody answers | Off |
| Reconnecting with quiet contacts | Ask me |
Other settings:
| Setting | Default | What it does |
|---|---|---|
| Hold before sending | 5 minutes | A window in which to stop any automatic email |
| Daily cap | 40 | Maximum automatic sends per rolling 24 hours, across everything |
| Sending hours | 08:00–19:00 | In your time zone |
| Weekdays only | On | No automatic sends at weekends |
| Read my mailbox every few minutes | On | Lets the heartbeat sync the mailbox |
| Company email domains | Your mailbox's domain, unless it is a public provider such as gmail.com | Who counts as a coworker |
Checks run when a draft is considered, and again just before it is sent. A draft that fails any check comes to you with the reasons written down.
pending → sending), so a draft can go only once. A send stuck in
sending is recovered from the time it was claimed.sendDraft() in src/lib/crm/send.ts is the only code that sends. It adds your signature and threading
headers, refuses an opted-out recipient, and records who sent it (you or autopilot).Vercel's Hobby plan runs cron at most once a day, which is too slow for an agent that answers email. Instead:
neon/autopilot.ts) with a schedule trigger (0,20,40 * * * *) calls
/api/cron/autopilot with a bearer secret; neon/news.ts calls /api/cron/news a minute later. Every
twenty minutes, so the free plan's compute can sleep between passes. On Supabase, scripts/db-setup.mts finish creates pg_cron jobs instead.x-neon-* header a caller sends, so
an x-neon-trigger-invocation-id that matches the body's invocation_id can only come from the trigger.Each pass, for each person with autopilot on:
Regulated mode is for FINRA and SEC registrants.
/api/crm/audit).The principle. A language model's confidence in itself is not evidence. It stays a hard gate: nothing below high confidence is sent automatically. But what to automate is decided from what the person does.
The code:
src/lib/crm/engine-rules.ts: the pure rules. The public site's live demo runs the same file in the
browser.src/lib/crm/engine.ts: the server side.src/lib/crm/learning-math.ts: dependency-free maths:
There are three learning loops per account.
Labels. Every draft the person sends is a label.
Strata. Trust is kept separately for each kind of email, audience and category. Examples:
reply:internal:colleague, reply:external:prospect, campaign:first, campaign:follow, follow_up,
nurture and compose.
The estimate. The rate of good drafts is estimated as a Beta posterior:
p(good rate) = Beta(1 + good, 1 + bad)
The prior is flat, so only the person's own labels count. Counts decay with a 90-day half-life.
Certification. A kind is offered autopilot when both conditions hold:
labels ≥ 20
10% quantile of Beta(1 + good, 1 + bad) ≥ 0.90
In words: the engine is 90% confident that at most 10% of these drafts would need your edits.
Spot checks. After graduation, some would-be automatic sends go to the person instead, so that labels keep arriving:
Demotion. Any one of these puts a kind on probation, and autopilot holds it:
An anytime-valid e-process. It tests "bad rate ≤ 10%" against "bad rate = 20%". The update is:
e ← e × 2 on a bad label
e ← e × 8/9 on a good label
A kind is demoted when e ≥ 20. By Ville's inequality, a kind whose true bad rate is at most 10% is
wrongly demoted with probability at most 5%, however long it runs. For example:
A cancel streak: three automatic sends stopped in a row.
Mostly rewritten: after at least 3 labels, the posterior mean of the good rate is below 0.5.
Arms. There are two dimensions:
| Dimension | Arms |
|---|---|
| Opening angle | Specific observation · relevant question · outcome first · very short · why now |
| Send time | Morning (7–11) · midday (11–14) · afternoon (14–19), local time, within your sending hours |
"Why now" is a sleeping arm. It is offered only for a lead whose Form D was filed in the last 90 days, and it never overstates the raise: a Form D reports the amount sold to date, not necessarily a new round.
Outcomes.
| Outcome | Counts as |
|---|---|
| A human reply within 14 days | A reward |
| An opt-out | A failure, and is also shown as an opt-out |
| An automated reply | Nothing (ignored) |
| No reply after 14 days | A failure |
Each email is settled exactly once.
Delayed feedback. A send that is still waiting counts as a fraction of a failure:
F(t) = 1 − exp(−t / 36 hours)
This assumes half of replies arrive within a day and 86% within three. The engine learns from day one instead of waiting out the reply window.
Prior. Each arm's prior is empirical Bayes, built from other accounts' settled outcomes on that arm (leaving this account out):
Beta(1 + 20r, 1 + 20(1 − r)).Choice.
0.1 / K + 0.9 × P(best), so strategies can be evaluated offline without
bias.Agent & autopilot → "What the agent has learned" shows:
Graduation offers appear at the top of the queue.
| Method | Used for | Source |
|---|---|---|
| Thompson sampling | Outreach arms | W. R. Thompson, Biometrika (1933); O. Chapelle and L. Li, NeurIPS (2011); D. Russo et al., "A Tutorial on Thompson Sampling" (2018) |
| Delayed feedback | Pending sends as partial failures | C. Vernade, O. Cappé and V. Perchet, UAI (2017), arXiv:1706.09186 |
| Certified error rates | Graduation | A. Angelopoulos et al., "Learn then Test", Annals of Applied Statistics (2025), arXiv:2110.01052; Trust-or-Escalate, ICLR (2025) |
| Strong acceptance as the label | Unchanged and no critical field changed | Ansible Lightspeed (2024) |
| E-processes and Ville's inequality | Anytime-valid demotion | Ramdas et al., survey of e-values, arXiv:2210.01948 |
| Discounting | 90-day half-life | V. Raj and S. Kalyani, discounted Thompson sampling (2017) |
| Sleeping arms | "Why now" only with a fresh Form D | Duolingo, KDD (2020) |
| Learning from edits | Lessons and own-writing examples | G. Gao et al., PRELUDE/CIPHER, NeurIPS (2024), arXiv:2404.15269; PROSE, ICML (2025), arXiv:2505.23815 |
| Prompt-injection risk in mail agents | The security veto | The Trojan Hippo and EchoLeak attacks (2025–2026) |
Every calendar a person uses, read and written, and tied to Relationships (/app/calendar, full detail in
docs/calendar.md).
src/lib/calendar/providers/.getMeetingAt, getUpcomingMeetings and GET /api/calendar/upcoming
are a stable API, documented in docs/calendar.md.The copilot listens to meetings and files what it learns into Relationships (the full design, and where a calendar plugs in, are in docs/meetings.md). Two ways to listen:
meetings.bot, about $0.65 an hour through Recall.ai): sent to a meeting
link by a click, or by an auto-join rule the person switched on; it joins as a participant and its
transcript names each speaker.Transcription uses OpenAI's speaker-labelled model when OPENAI_API_KEY is set, otherwise the ML
service's Whisper and Parakeet. During a call, the copilot window shows the rolling transcript and what
YouBank knows about the people in it (contacts, deal stage, recent emails, a listed company's numbers),
free; live suggested questions are Pro (meetings.live), on only while switched on for that meeting.
When the meeting ends, the notes (free for three meetings a month, then Pro, meetings.notes): a
summary, decisions, action items with owners and dates, open questions, each person's sentiment,
interest and signals, and follow-up drafts. They are filed the way the email agent files mail: each
participant matched to a contact (or added and marked for review), a meeting entry on each contact's and
deal's timeline carrying their topics (contact knowledge), stated deal terms as proposed changes to
accept or reject (never written over), follow-ups in the review queue (never sent by autopilot).
Relationships → Meetings lists the meetings, and each meeting's page shows the transcript, the notes,
the proposed updates as cards, and an "ask about this meeting" box.
/app/team) are shared workspaces.
/app/collab) lets two people open a tool and work on the same model.
Last-Event-ID.state || patch::jsonb, so the last write wins per field.
Keystrokes are coalesced into one patch per 250 ms.A desktop app for Windows, macOS and Linux (Tauri v2, in desktop/; its own README covers building,
releasing and signing). Download it from /download, which picks the installer for the visitor's system
from the latest desktop-v* GitHub Release and says in plain words what the app may touch.
youbank:// links (a ticker, a
deal, a Studio document, a quick ask question), one instance at a time, a remembered window, an offline
screen that retries, and updates from GitHub Releases.desktop.folders)..xlsx (or a deck as .pptx); a saved
workbook goes back to Studio as one undoable change ("Synced from desktop: 14 cells"), through the
same diff as the Excel add-in, and is refused if Studio moved on meanwhile. AI edits to a local file
(Pro, desktop.office_agent) run the Studio agent and write the result back, keeping a backup.desktop.background_ai). An AI task runs on its schedule only if the
person switched it on for that computer; the server keeps its own copy of that switch and refuses
otherwise./desktop/connect, and the app keeps a device token (ybd_…) in the system keychain. It works only on
/api/desktop/**. Connected computers are listed, and can be disconnected, in Settings → Desktop app.Edge's next round (docs/edge-next.md) adds seven features on shared foundations (an entity crosswalk, a weekly signal store with change points that state their false-alarm rate, and a forecast ledger whose probabilities are scored when their windows close, shown under Track record). All run on free public data; the paid layers follow docs/premium.md.
EDGE_BACKFILL_DAILY_USD, or the switch in
Deals); anyone can read one deal on demand from their own allowance. PREC in the Terminal shows the
engine's set with live EDGAR search as "Find more"; the deals.precedents canvas block feeds memos and Studio.PULSE in the Terminal, a strip on /app/vc
startups, and the pulse.signals canvas block.EDGE_ODDS_UNIVERSE=all widens it to
every US-listed operating company). Forecasts for watched companies and the top 200 go into the ledger and
are scored automatically. in the Terminal and the canvas block. It is a statistical
estimate from public data, not a rumour or advice, and says so wherever it appears.Quant (docs/quant-edge.md) puts the methods a quant desk uses on a person's own portfolio
and ideas, with an interval and a source on every number. It lives at /app/quant ("Quant" in the navigation,
after Fund copies), in the Terminal, in the AI assistant, on the Edge canvas and in the Edge feed. It produces
signals, target portfolios, risk budgets, cost estimates and integrity grades for the algo engine; it never
places an order. Nothing is phrased as advice: explanations come from templates in src/lib/quant/words.ts,
a test checks every template and AI tool description against a list of advice words, and results carry
"hypothetical" and "not investment advice" disclosures. The terms are accepted once (quant_consents).
BTX). Grades any backtest A to F: the deflated Sharpe ratio with the effective number of
variants tried (every backtest run is logged as a trial in quant_trials, append-only), the probability of
backtest overfitting by CSCV, minimum track record length, the Harvey-Liu haircut, cost sensitivity and the
breakeven cost, year-by-year stability, a block placebo, a lone peak among the parameters, and look-ahead,
survivorship and language-model hygiene. "Check a claim" works from typed numbers alone. Copy trading's
clone backtests are logged as trials of the fund's family and carry the grade. A D or F needs a typed,
logged override before the algo engine trades it live.FACT). A portfolio's betas to market, size, value, momentum, quality and low volatility with
95% intervals over one and three years, alpha with its t-statistic and how likely luck is, the factor share of
risk, the closest mix of index funds, and factor crowding (valuation spread, comovement, 13F ownership).
Factors are YouBank's own, built point in time from SEC filings and daily prices (Fama-French 2x3 sorts on the
top-1,000 universe); until they have enough history, ETF proxies stand in, and the screen says which.
Kenneth French's data is never shown or redistributed.PORT, with new tabs). Risk by holding and factor (Ledoit-Wolf and a factor model), one- and
ten-day value at risk and expected shortfall by filtered historical simulation with Kupiec and Christoffersen
backtests, replays of 2000, the 2007 quant crunch, 2008, 2020 and 2022 (holdings without prices then replayed
through their factors), shocks such as "market -20" with the other factors drawn conditionally, the gentlest
scenario that loses a given amount, drawdown odds and days to exit.KELLY). Kelly on the person's own numbers as a range, the growth curve, the chance of halving at
full, half and quarter Kelly, volatility targeting, risk parity, and pod-style drawdown rules simulated on a
history (with the times they de-risked near a bottom). A saved risk budget is what the algo engine reads; it
may adopt or tighten it, never loosen it.TCA). A pre-trade estimate for any symbol and size (Corwin-Schultz and Abdi-Ranaldo
spreads, square-root impact on 20-day volume), the person's own fills from a broker CSV (Schwab, Fidelity,
Robinhood, Webull, IBKR, E*TRADE) or, with Pro, a connected broker, measured against each day's bar and
projected to a year, and brokers' Rule 605 and 606 reports with the payment for order flow on the person's
own orders. Fills are never pooled across people and can be deleted.INSC). Form 4 and Schedule 13D every ten minutes of EDGAR's day: opportunistic insider clusters
(routine traders, plan trades, offerings and 10%-owner funds left out), large CEO and CFO purchases, and new
or raised activist stakes, each with the base rate of what followed similar events. Cards in the Edge feed
for watched companies (, ).Underneath: a point-in-time store (an NYSE calendar with special closures; daily bars in R2; SEC company facts
known from their acceptance time; a top-1,000 US universe rebuilt weekly, flagged survivorship-biased because
delisted history needs a vendor), a statistics kit with known-answer tests against statsmodels, NumPy and the
papers' worked examples, and an event-study engine. The nightly pass (Inngest quant-nightly, or
/api/cron/quant without Inngest) refreshes it in slices. The algo engine's entry point is
src/lib/quant/api.ts; the contract is src/lib/quant/contracts.ts. AI tools: quant_factor_exposures,
quant_risk, quant_backtest_check, quant_signals, quant_event_base_rates, quant_costs, quant_kelly;
canvas blocks: Factor Lab, Portfolio risk, Backtest check, Event base rates, Insider clusters. Free covers
the cores; Pro adds depth (200 holdings, ten years, broker holdings, full integrity reports, risk budgets,
broker sync, the full insider board and Item 4 readings); Deal Team adds team drill leaderboards.
Premium features are built and switched on per plan: the plan decides who may use one, and for the paid
data and models a key in the environment decides whether it can run at all. They spend money only when
someone whose plan includes them uses them on purpose (a click, a ticked option); crons, monitors,
prefetches and page loads always get the free method. Administrators (ADMIN_EMAILS) may use everything.
Locked features stay visible with their plan badge, and trying one shows the plan's message in line with
a link to the plans. The contract is in docs/premium.md; the registry is
src/lib/billing/features/ (one file per area), with each feature's cost per use for the pricing model.
Why each of Edge's newest features is free or premium, and on which plan, is in
docs/pricing.md.
| Feature | Plan | Where | What it adds |
|---|---|---|---|
| Premium reranking | Pro | Edge · Documents | Voyage rerank-3 (or Cohere Rerank 4) on every question, instead of the free reranker |
| Stronger answer model | Pro | Edge · Ask, "Stronger model" | EDGE_ANSWER_MODEL (e.g. gpt-5.6-sol) writes that answer |
| Exact-span citations | Pro | Edge · Ask, "Exact-span citations" | Anthropic Citations: quotes cut from the passages by the API |
| Ask across companies | Pro | Edge · Ask, "Each company separately" | One question answered from each of up to six companies' filings, side by side |
| Speaker-labelled transcripts | Pro | Edge · Library, on upload or per recording | OpenAI gpt-4o-transcribe-diarize; MP3 and WAV of any length, other formats to 24 MB |
| Hard PDFs read by LlamaParse | Pro | Edge · Library, on upload or per document | LlamaParse v2 (agentic tier) with tables kept whole |
| Sharper satellite imagery | Pro | Edge · a plant's panel | Planet's PlanetScope and SkySat scenes |
| TimesFM forecasts | Pro | Edge · Scenarios, Driver forecasts | Google's TimesFM through BigQuery, beside the free drift forecast |
| Flare volumes (Nightfire) | Enterprise | Edge · a plant's panel | VIIRS Nightfire flares with an estimated volume (licensed data) |
| GPU retraining of the deal model | Enterprise | Edge · Networks | One retraining on a Modal T4, wider and longer (the weekly one stays on CPU) |
| Re-read a deal with the stronger model | Pro | Edge · Deals, a deal's page | EDGE_REREAD_MODEL (e.g. gpt-5.6-sol) re-reads every term, re-quoted and re-checked; the earlier reading stays in the audit trail |
| Precedent exports | Pro | Edge · Deals | CSV of more than 50 precedents, with each term's quote and source (50 are free) |
| Second-provider claim check | Pro | Edge · Ask, "Cross-check" | The other provider's model judges each claim against its passages |
| Daily Pulse |
Settings → Labs → Edge premium upgrades lists each upgrade with whether YouBank has it switched on and whether your plan includes it; administrators also see its cost to us, the settings behind it (names only) and the steps to switch it on.
The landing page (/) includes:
Per-career pages at /for/<role>.
Sign-in with Google through Better Auth (self-hosted, its tables in our database), then a six-step onboarding survey: role, group, experience, focus, style and goals.
14 styles:
Components use design tokens only. scripts/gen-themes.ts regenerates src/app/themes.css from
src/lib/themes.ts.
The top bar and the sidebar. Each person pins the features they use to the top bar, in their own
order, with names or icons only (icons only on a tablet, so the bar fits); the page they are on shows as
a dashed tab when it is not pinned. The
sidebar (the button at the left, or ⌘/Ctrl+\) holds every feature, the workflows inside them
(terminal functions, Newsroom views, Relationships tabs, settings) and the tools picked for their role,
with search across all of it. It opens over the page or docks beside it. When a workflow's page is
already open, it switches view in place, so open panels stay put. Saved in profiles.extra.nav
(src/lib/nav.ts).
Built-in controls. Dropdowns (src/components/ui/Select.tsx) and confirmation and text-entry
dialogs (src/components/ui/Dialog.tsx) replace the browser's own: themed like everything else,
animated, with keyboard support, search in long lists, and type-to-confirm for deletions that
affect a whole team.
On a phone, everything works. Nothing is desktop-only; each screen is laid out again to fit.
Browser: Next.js App Router pages, React 19 Excel and PowerPoint: the add-in (Office.js)
│ │ device token, same /api/studio routes
▼ ▼
Vercel ─── Next.js 16 server: pages and route handlers under /api/*
│ Cron 06:00 UTC ─► /api/cron/sync startup directory and Form D refresh
│ Cron 11:00 UTC ─► /api/cron/agent morning agent run (drafts only)
│
├──► Neon Postgres (Drizzle ORM, postgres.js through the pooler; also runs on Supabase)
├──► OpenAI Responses API / Anthropic Messages API
├──► SEC EDGAR (submissions, XBRL company facts, full-text search) · Financial Modeling Prep
└──► Mailboxes: IMAP + SMTP (app password) or Gmail API (OAuth)
Neon Function "autopilot" ◄── schedule trigger (every 20 min)
└──► POST /api/cron/autopilot (Authorization: Bearer AUTOPILOT_SECRET)
Neon Function "news" ◄── schedule trigger (every 20 min, a minute later)
└──► POST /api/cron/news (the Newsroom: sources, stories, alerts, briefs)
The mail loop:
new mail ─► sync (Gmail history, or IMAP) ─► resolve thread ─► triage ─► draft ─► consider
├─ held ─► review queue, with the reasons
└─ scheduled ─► hold + sending hours ─► re-read live thread ─► sendDraft ─► learnFromSend (loops 1–2)
reply arrives ─► recordReplies ─► stop the sequence / record an opt-out ─► settleOutreach (loop 3)
src/lib/crm/, file by file:
| File | Role |
|---|---|
model.ts | Vocabulary: modes, stages, categories, contact and draft kinds, consent domains |
agent.ts | Triage and drafting prompts and schemas |
sync.ts · mailbox.ts · imap.ts · gmail.ts | Mailbox access, incremental changes, thread resolution, sending over SMTP or the Gmail API |
accounts.ts · crypto.ts | Connected mailboxes; AES-256-GCM encryption of credentials |
db.ts | Thread ingestion, triage processing, draft creation, reply recording, activity |
send.ts | sendDraft(), the only code that sends |
autopilot-rules.ts | Pure rules: settings, autonomy levels, sending window, send verdict, automated-mail detection |
autopilot.ts | considerDraft, the heartbeat tick, the send queue, answering questions |
engine-rules.ts · engine.ts · learning-math.ts | The adaptive engine |
knowledge.ts · settings.ts | Playbook and questions; settings, voice, per-person lock |
scan.ts · actions.ts | Pure scan rules (follow-ups, stale deals, nurture, funding signals); suggested actions |
nurture.ts · campaigns.ts · outreach.ts · contacts.ts · compose.ts | Nurture rules, campaigns and leads, contacts, new emails |
run.ts | The morning run |
All tables are in src/db/schema.ts.
| Area | Tables |
|---|---|
| Accounts and research | profiles, workflow_runs, documents, peer_groups, peer_group_members, comps_sheets, manual_inputs, footnotes, company_cache, kv_cache, startups |
| Teams | teams, team_members, team_invites |
| Live collaboration | collab_sessions, collab_events, collab_presence |
| Relationships | email_accounts, crm_contacts, crm_deals, crm_threads, crm_messages, crm_drafts, crm_questions, crm_playbook, crm_settings, crm_actions, crm_signals, crm_nurture_rules, crm_nurture_log, crm_campaigns, crm_campaign_leads |
| Adaptive engine | crm_trust (per stratum: good, bad, observations, unchanged, e-process, cancel streak), crm_arms (per arm: decayed pulls, rewards, negatives), crm_lessons, crm_learning_events (every label and outcome, for audit and offline evaluation) |
| Studio | studio_docs (workbook, deck and comments as JSON, each edit an atomic jsonb update), studio_events (every patch with its undo; the serial id is the live-stream cursor and the add-in's sync cursor), studio_runs (each agent run: instruction, status, summary, stats), studio_checkpoints (named snapshots of the workbook and deck) |
| Excel and PowerPoint | office_pairings (a code awaiting approval: the hashed poll secret and the expiry), office_devices (connected installs: the hashed token, last use, revocation) |
| Meetings | meetings (each meeting: source, consent, participants, the live switch, notes), meeting_chunks (the transcript, one row per audio chunk), meeting_links (contacts and deals), meeting_settings; a meeting's proposed changes are rows with |
Migrations.
drizzle-kit push creates every table from the schema.drizzle/, applied in order with
scripts/apply-sql.mts:
0001_teams0002_crm0003_collab0004_outreach0005_autopilot0006_adaptive0007_studio0008_office0009_ai_usage0010_contact_knowledge0016_crypto0017_desktop0018_calendar0019_meetings0023_copytrade0024_seat_cooldown0026_quantdrizzle-kit push --strict should propose nothing (answer "No" to anything it
proposes). Never run drizzle-kit push without --strict (or with --force) against an existing
database: indexes the SQL files create are not all in schema.ts, and push would drop them.| Layer | Choice |
|---|---|
| Framework | Next.js 16.3 (App Router, Turbopack), React 19.2, TypeScript 5 |
| Styling | Tailwind CSS v4 with design tokens, 14 generated themes, motion, lucide-react icons |
| Database | Neon Postgres (free plan) through postgres (postgres.js) and the pooler; portable to Supabase (scripts/db-setup.mts) |
| ORM | Drizzle ORM 0.45, drizzle-kit |
| Auth | Better Auth 1.6 (self-hosted): email and password, plus Google when configured; no emailed reset yet (an admin resets); tables auth_users, auth_sessions, auth_accounts, auth_verifications |
| AI | OpenAI Responses API (openai 7), Anthropic Messages API (@anthropic-ai/sdk), zod 4 for structured output |
| imapflow (IMAP), nodemailer (SMTP), mailparser (MIME), Gmail REST API | |
| Data | SEC EDGAR (submissions, XBRL company facts, full-text search), Financial Modeling Prep, Y Combinator, a16z, Thiel Fellows, Show HN |
| Hosting | Vercel (functions and Cron) |
| Scheduling | Vercel Cron (daily jobs) and a Neon Functions schedule trigger (the five-minute heartbeat) |
| Statistics | In-house, dependency-free: Beta CDF and quantile, Gamma and Beta sampling, Thompson sampling |
| Tests | tsx scripts: unit suites, plus end-to-end runs against a Neon branch and an Ethereal mailbox |
pnpm install
cp .env.example .env.local # fill in the keys (see below)
set -a; . ./.env.local; set +a
pnpm exec drizzle-kit push # create the tables on a fresh database
pnpm dev # http://localhost:3000
Development tips:
YOUBANK_DEV_USER=<name> signs you in as dev-<name> without Google. It is useful
for screenshots and tests against a branch.Other commands:
pnpm exec tsx scripts/gen-themes.ts # after editing themes
pnpm exec tsx --env-file=.env.local scripts/snapshot.ts # refresh the landing page's demo data
pnpm exec tsx --env-file=.env.local scripts/run-workflow.ts <id> # one live workflow run
pnpm exec tsx --env-file=.env.local scripts/backfill.ts # startup directory backfill
bash scripts/preflight.sh # everything that must pass before a deploy
| Variable | Required | Purpose |
|---|---|---|
DATABASE_URL | yes | Pooled connection string (Neon's -pooler host, or Supabase's transaction pooler); no channel_binding parameter |
DATABASE_URL_UNPOOLED | for schema pushes | Direct connection (Neon) or Supabase's session pooler; drizzle-kit push and scripts/db-setup.mts need it |
BETTER_AUTH_SECRET | yes | Signs session cookies and encrypts stored OAuth tokens (openssl rand -base64 48) |
GOOGLE_CLIENT_ID, GOOGLE_CLIENT_SECRET, NEXT_PUBLIC_GOOGLE_SIGNIN=1 | no | Google sign-in alongside email and password: an OAuth client (Web) with redirect URI <site>/api/auth/callback/google; all three or none |
BETTER_AUTH_URL | no | Sign-in's base address when it is not NEXT_PUBLIC_SITE_URL (local development) |
AUTH_SESSION_DATA_TTL | no | Seconds the session cookie is trusted before a database read (default 900) |
AI_PROVIDER | yes | openai or anthropic |
OPENAI_API_KEY or ANTHROPIC_API_KEY | yes | The key for the chosen provider |
OPENAI_MODEL, OPENAI_RESEARCH_MODEL, OPENAI_REASONING_EFFORT, ANTHROPIC_MODEL | no | Defaults: gpt-6-astra, gpt-5.4-mini, medium, claude-opus-5 |
FMP_API_KEY | yes | Prices and market caps |
MARKET_BACKUP | no | off turns off the market-data backups (Nasdaq, the ECB rates, CoinGecko, AI research); on by default |
MARKET_RESEARCH_MODEL, MARKET_RESEARCH_ESCALATION_MODEL | no | The models AI research uses; defaults gpt-5.6-luna, retrying with gpt-5.4-mini |
https://<your-domain>/api/crm/gmail/callback as an authorised redirect URI. Add the localhost
equivalent too, for local work.GOOGLE_CLIENT_ID, GOOGLE_CLIENT_SECRET and EMAIL_TOKEN_SECRET.How the OAuth connection behaves:
gmail.readonly and gmail.send only. It cannot modify or delete anything in the
mailbox.needs_reauth and gives
the reason.Settings, Calendar. The steps for each provider's developer console are in docs/calendar.md. In short:
https://<site>/api/calendar/oauth/google/callback as a redirect URI. Set GOOGLE_CALENDAR_CLIENT_ID and
_SECRET, or rely on the Gmail client.https://<site>/api/calendar/oauth/microsoft/callback. Grant Calendars.ReadWrite, User.Read and
offline_access. Set MICROSOFT_CLIENT_ID and MICROSOFT_CLIENT_SECRET.webcal:// or .ics link. It is read only.Every provider needs EMAIL_TOKEN_SECRET. Without it each shows "Not set up yet".
The production runbook is docs/production.md: which variables are required in which
Vercel environment, the first deploy, the custom-domain checklist (OAuth redirects, the Stripe webhook,
BETTER_AUTH_URL, Inngest), health checks, what to do when a dependency is down, and the Hobby plan's
limits.
The Vercel project is connected to this repository: every push to main (a merged pull request) deploys
to production, and pull requests get preview deployments. Apply new migrations before or right after the
deploy that needs them (pnpm exec tsx scripts/db-setup.mts finish replays every drizzle/*.sql).
.env.local.set -a; . ./.env.local; set +a
DATABASE_URL="$DATABASE_URL_UNPOOLED" pnpm exec tsx scripts/apply-sql.mts drizzle/0011_newsroom.sql
pnpm exec drizzle-kit push --strict # a drift check: it should propose nothing; answer "No" to any prompt
bash scripts/preflight.sh # themes, typecheck, lint, tool packs, production build
vercel --prod --yes
vercel.json schedules /api/cron/sync (06:00 UTC), /api/cron/agent (11:00 UTC),
/api/cron/calendar (06:15 UTC) and /api/cron/calendar-briefs (10:45 UTC).neon.ts, because it carries secrets:
neon functions deploy autopilot --src neon/autopilot.ts \
--env YOUBANK_URL=https://<your-domain> --env AUTOPILOT_SECRET=<secret>
neon triggers create --function-slug autopilot --name autopilot-heartbeat --cron '*/5 * * * *'
neon functions deploy news --src neon/news.ts \
--env YOUBANK_URL=https://<your-domain> --env AUTOPILOT_SECRET=<secret>
neon triggers create --function-slug news --name news-heartbeat --cron '*/10 * * * *'
The calendar heartbeat runs every fifteen minutes. It calls the free sync, then the morning briefs, which
run only for people who switched them on. Apply drizzle/0018_calendar.sql first:
neon functions deploy calendar --src neon/calendar.ts \
--env YOUBANK_URL=https://<your-domain> --env AUTOPILOT_SECRET=<secret>
neon triggers create --function-slug calendar --name calendar-heartbeat --cron '*/15 * * * *'
PLANS:
STRIPE_SECRET_KEY=sk_live_... pnpm exec tsx scripts/stripe-setup.ts --live \
--webhook https://<your-domain>/api/billing/webhook
STRIPE_* lines in Vercel.sk_test_..., no ) on a preview deployment.curl https://<your-domain>/api/health/live answers at once without touching the database (for uptime
monitors).curl https://<your-domain>/api/health should say "status":"ok". It answers degraded (200) when
the app serves but something is missing (a migration, a production setting, an optional service half
set up) and down (503) without a database, its core tables, or a setting every page needs. Operators
also see which migration is missing which tables. Anyone sees the status;
the names of missing settings and which services are on need the cron secret
(-H "Authorization: Bearer $CRON_SECRET") or an ADMIN_EMAILS session. No value is ever shown.curl -i https://<your-domain>/api/cron/autopilot should return 401 without the secret.POST /api/cron/autopilot.| Suite | Command | What it covers |
|---|---|---|
| Learning (63 tests) | pnpm exec tsx scripts/test-learning.ts | Beta CDF and quantile against exact values; certification boundaries; the e-process; scoring and critical fields; decay; Thompson sampling and propensities; delayed feedback; the security veto |
| Autopilot (62 tests) | pnpm exec tsx scripts/test-autopilot.ts | Settings normalisation, autonomy levels, sending windows and time zones, the send verdict, placeholders, automated-mail detection, the daily cap, playbook selection |
| Outreach (53 tests) | pnpm exec tsx scripts/test-outreach.ts | Follow-up, stale-deal and nurture candidate rules; funding-signal matching; company normalisation; sequence steps; the consent guard |
| Calendar (119 tests) | pnpm exec tsx scripts/test-calendar.ts | iCalendar parsing, folding and round trips; RRULE expansion (ordinals, BYSETPOS, BYWEEKNO, UNTIL, COUNT, jumping to the window); time zones and DST, including custom VTIMEZONE, Windows and Mozilla zone names and floating times; editing one occurrence (EXDATE, overrides); attendee-to-contact and deal matching; slot finding; video links; the private-network guard; the Google, Microsoft, CalDAV and ICS adapters against fixtures in scripts/fixtures/calendar/ |
| Gmail parsing (12 tests) | pnpm exec tsx scripts/test-gmail-parse.ts | Address splitting (including quoted commas), MIME bodies, headers |
| Inference (58 tests) | pnpm exec tsx scripts/test-inference.ts | The command parser; Welch beta, Kupiec, Parkinson; forecasts, seasonality and nested intervals; rating tables, the Ohlson units, left-out views; knowledge tracing and its policies; Kaplan-Meier and Poisson-binomial; relationship strength, contact knowledge, deal odds and pipeline simulation; the recession probit and Sahm rule; copula rank correlation; Monte Carlo and forecasting over a live Studio workbook |
| Newsroom (73 tests) | pnpm exec tsx scripts/test-news.ts | URL, title and ticker cleaning; RSS, Atom and RDF; EDGAR's latest-filings feed, 8-K items and 13D pairs; Federal Register, GDELT and radar items; sector radars (FERC, DOE and NRC milestones, Fed bank applications, ITC cases, trials, FDA approvals, recalls, places and the map); robots.txt precedence; article extraction and paywall markers; classification and importance; clustering thresholds, figures (rounded or not) and filings; company names against SEC's listings; ranking reasons and mutes; desks; preferences, quiet hours and brief times; budget tiers; premiums, implied multiples and league tables; alert decisions; the calendar across daylight saving; research acceptance; tidying the model's reading; the brief email |
The end-to-end scripts write rows under a throwaway user. Point them at a Neon branch, never at production.
Credentials.
Sending.
sendDraft().Prompt injection.
Excel and PowerPoint.
Crypto.
SENTRY_DSN is set). One rule decides, in src/lib/error-text.ts, shared by the server
(src/lib/errors.ts) and the browser (src/lib/client/errors.ts), which also screens whatever reaches
it some other way (a proxy's HTML page, an empty 500, "Failed to fetch") and falls back to a plain line
by status: sign in again (401), plan needed (402), no access (403), not found (404), a limit (429),
our side (5xx), offline.Scheduled endpoints.
Regulated firms.
Consent and frequency.
Your data.
Known gaps, stated plainly:
List-Unsubscribe header.
AI inference (September 2026): LLM inference techniques, financial machine learning and knowledge tracing, and Bloomberg's functions against the free data that can replace them. What was built from them, the data licences and what was left for later: docs/research/ai-inference.md.
Three earlier research reports are behind the adaptive engine, the website and the plan:
Conclusions that shaped the product:
Breadth is not a moat; the loop is. The defensible wedge is this sequence:
Incumbents are converging on data access. Affinity shipped an MCP server and agents in 2026. Crunchbase, CB Insights, Tracxn, Dealroom, Specter and Harmonic all shipped MCP connectors. Anthropic's Claude for Financial Services added low-cost data partners.
Trust has to be earned and measured. Recent work shows a model's self-graded confidence is poorly calibrated. That is why autonomy is certified on the person's own decisions, with exact bounds and anytime-valid demotion.
Pricing started in the $30–$300 per seat per month band. The cost model in docs/pricing.md moved it: model time is most of what YouBank costs, so the prices below keep at least 70% of the monthly price (65% of the yearly one) at typical use and stay positive even for someone who uses the whole AI allowance. See Plans and billing.
| Plan | Price | AI allowance per seat | For |
|---|---|---|---|
| Free | $0 | $0.75 a day, $3 a month | The terminal, filings, comps and the Newsroom, Edge's free core (precedents, Deal Radar, the Pulse, Call Desk, the LBO lab, one thesis, hold-to-talk), with a taste of the assistant |
| Campus | Free with a .edu address | $2 a day, $10 a month | Students: the full terminal and data, AI workflows, a recruiting pack |
| Pro | $59 a month, or $49 a month billed yearly | $6 a day, $25 a month | Individuals: a working AI allowance, the relationships agent and one mailbox, AI meeting briefs, and most premium features: deep research and builds, Edge's premium layers (deal re-reads, claim cross-checks, the daily Pulse, the Radar screener, the LBO refine, five theses with the weekly deep pass, live voice) |
| Deal Team | $149 per seat a month, or $125 billed yearly; three seats minimum | $12 a day, $60 a month | Teams: autopilot and campaigns, more mailboxes, the adaptive engine across the team, shared workspaces and team theses, the meeting notetaker, Planet imagery in 3D, Dune queries, Eva-4B on calls, fund blends, assignable seats |
| Enterprise | $299 per seat a month, billed yearly; five seats minimum | $30 a day, $130 a month | Firms: regulated mode and audit exports, SSO and admin controls, data residency options, bring-your-own data licences (Nightfire), GPU retraining of the deal model |
src/lib/billing/costs.ts holds the same model in code.scripts/test-billing.ts fails if a price, a cost or a new premium feature breaks the margin target.src/lib/billing/features/, one file per area,
each naming the least plan that includes it.
drizzle/0024_seat_cooldown.sql).POST /api/billing/checkout starts Checkout for a plan, monthly or yearly, with a seat count. Someone
who already pays is sent to the portal; an open checkout for the same purchase is reused, others are
expired, and the create call carries an idempotency key, so nobody ends up with two subscriptions.POST /api/billing/credits starts a one-time Checkout for a credit pack.POST /api/billing/portal opens Stripe's billing portal (plan switches, seats, cancellation at period
end, card, invoices); lists Stripe-hosted invoices and receipts.List-Unsubscribe one-click header;mcp-handler, which needs its own OAuth 2.1 authorisation server.YouBank/
.github/workflows/desktop.yml builds the desktop installers into a draft GitHub Release
desktop/ YouBank for desktop (Tauri v2): the Rust app in src-tauri/, its own pages in src/
docs/ product thinking, decisions, specs, market research
drizzle/ hand-written SQL migrations (0001–0008)
neon/autopilot.ts the five-minute heartbeat relay (Neon Function)
neon/calendar.ts the fifteen-minute calendar sync and morning-brief relay (Neon Function)
scripts/ tests, end-to-end runs, migrations, snapshot, themes, backfill, preflight
src/app/ routes: marketing, /for/<role>, /download, /onboarding, /app/*, /office/* (the add-in),
/desktop/connect, /api/*
src/components/
crm/ workspace, review queue, inbox, pipeline, contacts, meetings, campaigns,
nurture, agent settings, engine insights, mailbox bar
calendar/ the calendar view, event panel and brief, scheduler, Calendar settings,
meeting lines and Schedule buttons for contacts and deals
studio/ Studio home, workspace, grid, deck view, slide charts, state hook
office/ the add-in's task pane, and the connect and install pages
marketing/ landing page, adaptive-engine demo, terminal demo, role pages, live demos
terminal/ command bar, panels, screens (DES FA COMPS PREC CAP FIL EVT INS XBRL AI PG TOOLS,
and the crypto screens CRYP TOKEN DEFI STBL YLD BTCN RAISE UNLK TRSY RWA WALLET)
crypto/ the Crypto page, wallet connection, portfolio, notarizing, the mining map, Dune
copy/ Fund copies: fund pages, the treemap and backtest charts, copies, order review
workflows/ tool gallery, runner, form, output blocks
theme/ charts/ motion/ ui/
src/db/schema.ts every table
src/lib/
crm/ the relationships agent, autopilot and the adaptive engine (see Architecture)
calendar/ iCalendar, RRULE and time zones, the four provider adapters, sync and push,
linking, briefs, free/busy and slots, the meeting copilot API
meetings/ the meeting copilot: transcription, stitching, matching, notes, filing into
Relationships, the notetaker bot, meeting context (docs/meetings.md)
studio/ formula engine, functions, number formats, templates, audit, deck, edit
operations, persistence, .xlsx/.pptx, the Studio agent, workbook sync,
checkpoints, the brand check, reading printouts and data rooms
office/ the add-in: pairing and tokens, the Excel and PowerPoint adapters, the
manifest, its API client
desktop/ the desktop app's server side: pairing and tokens, the alerts feed,
scheduled tasks, local files, Office sync, the release lookup
ai/ models, config, agent (OpenAI Responses and Anthropic), data tools, prompts
edgar/ fmp/ vc/ SEC EDGAR and XBRL, prices, startup directory and Form D
crypto/ crypto data (CoinGecko, DefiLlama, mempool.space, public nodes, SEC frames),
addresses, portfolio risk, valuation, notarization, mining sites and the map
layer, Newsroom signals, assistant tools
copytrade/ 13F parsing and EDGAR ingestion, CUSIP mapping, clone weights, the backtest,
paper copies, the rebalance, SnapTrade, one-tap approval, the cron pass
quant/ Quant Edge: the contract and api.ts for the algo engine, the stores, the
statistics kit (stats/), point-in-time data (pit/), factors, event studies,
integrity, risk, sizing, TCA, insiders, drills, adapters, jobs, AI tools
workflows/ tool contract, prompt builder, registry, a pack per role
teams/ collab/ auth/ teams and roles, live collaboration, sign-in
themes.ts calc.ts roles.ts metrics.ts company.ts
| Doc | What |
|---|---|
| docs/production.md | Running in production: environment variables per Vercel environment, first deploy, the custom-domain checklist, health, outages, Hobby limits |
| docs/06-product-overview.md | Routes, terminal functions, the tool system, the AI layer, theming, commands |
| docs/pricing.md | What each plan costs to serve: unit costs with sources, personas, margins, and the prices and AI allowances that follow |
| docs/calendar.md | The calendar: provider setup, sync and push, the iCalendar engine, briefs, scheduling, and the meeting copilot API |
| docs/premium.md | Premium features: the plans, the feature registry, entitlements and the rules every premium feature follows |
| docs/meetings.md | The meeting copilot: desktop capture, the notetaker bot, live suggestions, notes and how they are filed into Relationships, the calendar's place, known gaps |
| docs/algo-trading.md | Algo trading: what each broker officially allows (Webull, Robinhood, SnapTrade, Alpaca, IBKR, Tradier), how algo trading is done well, AI-agent guardrails, regulation, the design, setup, known gaps and what counsel must review |
| docs/copy-trading.md | Fund copies: 13F ingestion and CUSIP mapping, the backtest, paper and live copies, SnapTrade, safety rails, and what counsel must review before real trading |
NEWS_AI_BUDGET_USDODDSodds.scoreCALL in the Terminal and the calls.read canvas block. Peer comparisons are premium; the
Eva-4B ensemble is a further premium path that stays off (EDGE_CALLS_EVA=1) until its training data's
licence is confirmed.EDGE_VOICE_REALTIME=1).quant.insider_clusterquant.activistDRILL). 90% intervals and true-or-false with a confidence (Brier score), expected-value
problems, the Kelly coin, and the person's own calls scored from prices when they close. Virtual: no money,
no prizes.QuantSignals with asOf
(when every input was public), validUntil, their base rate and calibration. A signal publishes only once
its base rate rests on at least 30 past events. signalsAsOf gives a backtest exactly what was knowable.| Pro |
| Edge · Pulse, "Refresh daily" |
| Up to 50 companies refreshed every day instead of every week |
| Deal Radar screener | Pro | Edge · Deal Radar, Screener | Every scored company filtered by odds and sector, with CSV export |
| Peer call comparison | Pro | Edge · Call Desk, Compare peers | Up to six companies' latest calls and promises side by side, with a written comparison |
| Evasion ensemble (Eva-4B) | Deal Team | Edge · Call Desk, a call's "Add Eva-4B" | A GPU classifier averaged with the free one, ten calls a day; off until its licence is confirmed (EDGE_CALLS_EVA=1) |
| LBO refine | Pro | Edge · Scenarios, LBO, "Refine: 20,000 paths" | 20,000 paths over up to seven years, 25 a day |
| More theses | Pro | Edge · Theses | Five active theses, 90-day horizons, checks twice a day |
| Weekly deep synthesis | Pro | Edge · Theses, "Weekly deep pass" | A weekly synthesis on the flagship model at maximum reasoning |
| Team theses | Deal Team | Edge · Theses | Shared with your team, who follow and add evidence |
| Live voice analyst | Pro | Edge · voice sheet, "Live conversation" | A real-time spoken conversation, up to ten minutes, three a day |
| Deep research | Pro | Terminal AI | See AI assistant |
| Deep model builds | Pro | Studio, "Deep" | See Watching the agent work |
| More mailboxes, Autopilot, Campaigns | Deal Team | Relationships | See Mailboxes, Campaigns, Autopilot |
| AI meeting briefs | Pro | Calendar · a meeting, "Write the AI brief" | Objectives, talking points, questions and watch-outs from the free assembled brief (src/lib/billing/features/calendar.ts) |
| Morning auto-briefs | Pro | Settings · Calendar | Each morning, every external meeting that day is briefed (opt-in, up to eight) |
| More than one calendar account | Pro | Settings · Calendar | Work and personal, Google and iCloud, merged |
| Smart scheduling in drafts | Pro | Relationships drafts | The email agent offers real free times from the calendar |
src/components/ui/Sheet.tsx) that drag
down to close: the Studio agent (beside the sheet it writes, so you can watch), the terminal's
watchlist, what you pick on the Edge map, the Edge canvas block palette. Dialogs become bottom sheets.
Multi-pane screens become tabs: Private markets shows the list, a startup or the assistant one at a
time (a tablet keeps the list beside the other two)..hit); actions that appear on hover elsewhere are always shown on touch. Strips of
tabs and chips scroll sideways instead of wrapping into many lines. The Relationships pipeline is a
row of stages you swipe; a Newsroom story opens full screen and closes with a swipe to the right..table-scroll), never the page, with the first column
pinned on a phone so each row keeps its name.MobileViewport publishes the height the on-screen keyboard covers as
--kb; the frame ends above it, bars and sheets ride on top of it, and the tab bar steps aside while
it is up. The page is drawn edge to edge (viewport-fit=cover) with the safe-area insets kept clear,
and the browser bar takes the style's background.MotionPrefs).crm_actionsmeeting_id| Desktop app | desktop_pairings (as for Office), desktop_devices (connected computers: the hashed token, system, app version, the scheduled-task switches, last use, revocation), desktop_files (each indexed local file: a hash of its path, its name, content hash and Edge document) |
| Crypto | crypto_addresses (addresses a person reads: own or watched, pasted or connected; never keys), crypto_cost_basis (what they say they paid, per asset), crypto_notarizations (hash, transaction, sender, chain, status, block) |
| Calendar | calendar_accounts (connected accounts; OAuth tokens and app passwords encrypted), calendar_calendars (shown or hidden, sync token, push channel), calendar_events (occurrences in the 30-days-back, 90-ahead window, with linked contact and deal ids), calendar_prefs (zone, working hours, default calendar, meeting link, the auto-brief switch), calendar_briefs (AI meeting briefs) |
| Fund copies | copy_filers (every 13F filer seen, for search), copy_filings (each 13F-HR and 13F-HR/A as read, holdings as JSON), copy_securities (CUSIP to ticker and sector, with the source), copy_cusip_overrides (the owner's corrections), copy_follows, copy_portfolios (paper and live copies), copy_brokers (the SnapTrade user, secret encrypted), copy_consents, copy_batches and copy_orders (proposals and what was sent), copy_audit (append-only by rule) |
| Algo trading | algo_strategies (spec, mode, paper account, own holdings, equity peak and day start), algo_connections (Alpaca, Webull and Robinhood Crypto credentials, encrypted), algo_decisions (target, signals, reasons), algo_batches and algo_orders (each order or TWAP slice, client order id unique, lifecycle), algo_equity (daily marks), algo_consents (per strategy for autonomy, with the typed words), algo_settings (kill switches, global under __global__), algo_agent_messages, algo_backtests, algo_audit (append-only by rule); drizzle/0025_algo.sql |
| Quant | quant_signals (QuantSignals by producer, symbol and as_of), quant_targets (versioned target portfolios), quant_trials (every backtest run, append-only), quant_runs (saved analyses, risk budgets, overrides, drills), quant_fills (a person's own fills), quant_factor_returns, quant_universe (the top-1,000 with first and last dates), quant_insider_tx, quant_events, quant_base_rates, quant_consents |
| AI and inference | ai_usage (every model call: feature, model, tokens including cached and reasoning, list-price cost); crm_messages.topics (each email's topics, tagged once, for contact knowledge tracing); terminal mastery lives in profiles.extra.skills |
EDGAR_USER_AGENT | yes | The SEC asks for a descriptive User-Agent with a contact email |
CRON_SECRET | yes | Bearer token for Vercel Cron (/api/cron/sync, /api/cron/agent) |
EMAIL_TOKEN_SECRET | to connect mail | Encrypts mailbox passwords and tokens (openssl rand -base64 32) |
AUTOPILOT_SECRET | for autopilot | Bearer token the heartbeat sends to /api/cron/autopilot (CRON_SECRET is also accepted) |
GOOGLE_CALENDAR_CLIENT_ID, GOOGLE_CALENDAR_CLIENT_SECRET, GOOGLE_CALENDAR_REDIRECT_URI | no | Google Calendar via OAuth; without them the Gmail client below is used. The redirect defaults to <site>/api/calendar/oauth/google/callback |
MICROSOFT_CLIENT_ID, MICROSOFT_CLIENT_SECRET, MICROSOFT_TENANT, MICROSOFT_REDIRECT_URI | no | Microsoft 365 and Outlook.com calendars via Graph; tenant common by default |
CALENDAR_PUSH, CALENDAR_PUSH_URL, CALENDAR_POOL | no | off turns calendar push off; a tunnel address for push during local work; sync concurrency (4) |
GOOGLE_CLIENT_ID, GOOGLE_CLIENT_SECRET, GOOGLE_REDIRECT_URI | no | Gmail API connection via OAuth; the redirect defaults to <origin>/api/crm/gmail/callback |
AUTOPILOT_SPOT_CHECK_RATE | no | Overrides the spot-check rate (tests only) |
NEWS_AI_BUDGET_USD | no | The Newsroom's monthly AI cap; default 25 |
AI_USER_DAILY_USD, AI_USER_MONTHLY_USD | no | Replace every plan's daily and monthly AI allowance (the plans' own amounts are in src/lib/billing/plans.ts) |
AI_GLOBAL_DAILY_USD | no | Everyone's AI spend per UTC day; default 200 |
STRIPE_SECRET_KEY, STRIPE_WEBHOOK_SECRET | for billing | Stripe; without them the plan page shows prices and says billing isn't switched on |
STRIPE_PRICE_PRO_MONTHLY, STRIPE_PRICE_PRO_YEARLY, STRIPE_PRICE_TEAM_MONTHLY, STRIPE_PRICE_TEAM_YEARLY, STRIPE_PRICE_ENTERPRISE_YEARLY | for billing | Stripe price ids, printed by scripts/stripe-setup.ts; a plan without its id is shown but cannot be bought |
ADMIN_EMAILS | no | Comma-separated administrators: every plan feature, no AI cap |
NEWS_RESEARCH_MODEL | no | The model for research briefs; default gpt-5.6-luna |
NEWS_VAPID_PUBLIC_KEY, NEWS_VAPID_PRIVATE_KEY, NEWS_VAPID_SUBJECT | for browser push | Web Push keys (npx web-push generate-vapid-keys) and a mailto: contact |
GITHUB_TOKEN | no | Raises GitHub's rate limit for the tech radar and the download page's release lookup |
DESKTOP_RELEASE_REPO | no | Where the desktop installers are released; default AyanBhardwaj1/YouBank |
GITHUB_TOKEN | no | Raises GitHub's rate limit for the tech radar |
ETH_RPC_URL, BASE_RPC_URL, ARBITRUM_RPC_URL, OPTIMISM_RPC_URL, POLYGON_RPC_URL, SOLANA_RPC_URL | no | Crypto: node endpoints for balances and notarization checks; public endpoints by default |
MEMPOOL_API_URL | no | Crypto: a self-hosted mempool.space API; https://mempool.space/api by default |
COINGECKO_DEMO_KEY | no | Crypto: CoinGecko's free demo key, which raises the keyless limits |
ETHERSCAN_API_KEY | no | Crypto: a free Etherscan key for recent wallet activity on Ethereum and Base |
COINGECKO_PRO_KEY, DEFILLAMA_API_KEY | for Pro crypto data | Paid feeds, used only when an entitled person clicks "Pro data" |
ALCHEMY_API_KEY, HELIUS_API_KEY | for deep wallet analytics | Paid indexers (EVM, Solana), used only on a click |
DUNE_API_KEY | for Dune queries | Reads saved queries' latest results, only on a click |
OVERPASS_URL | no | The OpenStreetMap Overpass endpoint the 3D digital twin reads; default the public overpass-api.de |
USGS_LIDAR_INDEX_URL | no | The index of USGS lidar surveys for point clouds; default Hobu's resources.geojson on GitHub |
MEETINGS_TRANSCRIBE, MEETINGS_TRANSCRIBE_MODEL | no | Meeting transcription: force openai or ml; the OpenAI model (default gpt-4o-transcribe-diarize) |
RECALL_API_KEY, RECALL_REGION, RECALL_WEBHOOK_SECRET | for the notetaker | Recall.ai's key, region (default us-west-2) and webhook signing secret; webhooks go to /api/meetings/webhook |
YOUBANK_DEV_USER | no | Development sign-in, ignored in production |
ADMIN_EMAILS | no | Comma-separated administrators: every premium feature, and admin-only screens |
AI_DEEP_MODEL | no | The model for deep research; default the flagship of the person's provider |
VOYAGE_API_KEY or COHERE_API_KEY | for premium reranking | Paid rerankers (Pro and up) |
EDGE_ANSWER_MODEL | for the stronger answer model | e.g. gpt-5.6-sol |
EDGE_CITATIONS=anthropic, ANTHROPIC_API_KEY, EDGE_CITATIONS_MODEL | for exact-span citations | The model defaults to claude-sonnet-5-5 |
EDGE_TRANSCRIBE=openai, EDGE_TRANSCRIBE_MODEL | for speaker labels | Uses OPENAI_API_KEY; the model defaults to gpt-4o-transcribe-diarize |
LLAMA_CLOUD_API_KEY, LLAMAPARSE_TIER, LLAMA_CLOUD_BASE_URL | for LlamaParse | Tier defaults to agentic; the base URL to https://api.cloud.llamaindex.ai (use the EU host for EU projects) |
PLANET_API_KEY | for Planet imagery |
NIGHTFIRE_USER, NIGHTFIRE_PASSWORD | for Nightfire | An EOG account under its data licence; NIGHTFIRE_CLIENT_SECRET, NIGHTFIRE_URL_TEMPLATE and NIGHTFIRE_TOKEN_URL only if EOG changes its download client |
GOOGLE_CLOUD_PROJECT, GOOGLE_APPLICATION_CREDENTIALS_JSON | for TimesFM | A service account key with BigQuery Job User; TIMESFM_MODEL (default TimesFM 2.5), BIGQUERY_LOCATION (default US) |
EDGE_ML_GPU=1 | for GPU retraining | After deploying the ML service's graph.train.gpu task |
SNAPTRADE_CLIENT_ID, SNAPTRADE_CONSUMER_KEY | for live copies | SnapTrade keys; without them the brokerage panel reads "Not set up yet". The SnapTrade user secret is encrypted with EMAIL_TOKEN_SECRET |
COPYTRADE_TRADING_ENABLED | for real orders | 1 lets approved batches go to brokers; anything else keeps real trading off (paper copies work regardless) |
COPYTRADE_MAX_ORDER_USD, COPYTRADE_MAX_DAY_USD | no | Server-wide ceilings per order and per person per day; defaults 25000 and 50000 |
ALGO_LIVE_ENABLED | for real algo orders | 1 lets live strategies send orders (approval and autonomous); anything else keeps backtests and paper only |
ALGO_MAX_ORDER_USD, ALGO_MAX_DAY_USD | no | Server ceilings per order and per person per day for algo trading; defaults 25000 and 50000 |
ALGO_MIN_PAPER_DAYS | no | Days on paper before a strategy may trade autonomously; default 14 |
ALGO_KILL | no | 1 stops every strategy of everyone at once (the administrators' kill switch; also POST /api/algo/admin/kill) |
ALPACA_OAUTH_CLIENT_ID, ALPACA_OAUTH_CLIENT_SECRET | for "Sign in with Alpaca" | An Alpaca Connect app; redirect https://<domain>/api/algo/connections/alpaca/callback. Paper API keys work without it |
ALGO_ALPACA_LIVE_KEYS | no | 1 accepts pasted live Alpaca keys (off: live accounts connect through OAuth) |
ALGO_WEBULL_ENABLED, WEBULL_API_BASE | for direct Webull | 1 switches on Webull's OpenAPI with a person's own App Key; the base defaults to https://api.webull.com (check the region's host and paths first) |
OPENFIGI_API_KEY | no | Raises OpenFIGI's rate limit for CUSIP-to-ticker mapping (it works without one) |
EDGE_BACKFILL_DAILY_USD | no | Switches on reading the deal database's backfill and new deals, and sets the day's ceiling in dollars (platform spend; an administrator can also switch it in Deals, at $0.50 a day) |
EDGE_REREAD_MODEL | for the deal re-read | The stronger model for "Re-read with the stronger model" (uses OPENAI_API_KEY) |
PATENTSVIEW_API_KEY | for patent counts | A free PatentsView key; without it the Pulse leaves patents out |
EDGE_WARN_TX_URL, EDGE_WARN_CA_URL, EDGE_WARN_NY_URL | no | Replace a state's WARN source when it moves (the defaults are the last known locations) |
EDGE_PULSE_TITLE_AI=1 | no | Lets the small model sort job titles the rules leave unsorted (platform spend) |
EDGE_ODDS_UNIVERSE=all | no | Scores every US-listed operating company in the Deal Radar instead of energy, technology and healthcare |
EDGE_EDITOR_EMAILS | no | People besides administrators who may confirm or correct crosswalk links |
--livedrizzle/0017_desktop.sql, then push a tag desktop-v<version>: the
Desktop workflow builds the installers into a draft GitHub Release; publish it and /download offers
it. Signing and update keys are optional secrets, listed in desktop/README.md.drizzle/0023_copytrade.sql. vercel.json runs /api/cron/copytrade daily;
for the 15-minute pass around the 13F deadlines, have a scheduler call it with the bearer secret, for
example the included Neon Functions relay:
neon functions deploy copytrade --src neon/copytrade.ts \
--env YOUBANK_URL=https://<your-domain> --env AUTOPILOT_SECRET=<secret>
neon triggers create --function-slug copytrade --name copytrade-heartbeat --cron '*/15 * * * *'
Live copies need SnapTrade keys and, for real orders, COPYTRADE_TRADING_ENABLED=1 after counsel's
review (docs/copy-trading.md lists what to review).| Crypto (122 tests) | pnpm exec tsx scripts/test-crypto.ts | Address checksums (EIP-55, Base58Check, Bech32 and Bech32m, Solana keys); notarization calldata, verification and canonical JSON; every API parser against fixtures (CoinGecko, DefiLlama, mempool.space, SEC frames, Etherscan, Alchemy, Dune); portfolio risk; valuation math; mining economics; the site data and popup escaping; Newsroom and directory converters; the four crypto Studio templates against the valuation math, the audit and their data tables |
| Billing (65 tests) | pnpm exec tsx scripts/test-billing.ts (--table prints the cost model) | Every paid plan's margin at typical use against the target, the worst case at the full AI allowance, Free and Campus cost ceilings; AI caps by plan and their overrides; the monthly-allowance message; checkout requests; the row a Stripe subscription writes and stale cancellations; webhook signatures, tampering and replay |
| Errors (151 tests) | pnpm exec tsx scripts/test-errors.ts | What may be shown to a person, against a corpus of SQL, URLs with keys and passwords, stack traces and tracebacks, HTML and XML error pages, provider, SDK and parser errors, and the plain messages that must still pass; the server's statuses and references (a provider's 401 is not the person's 401); missing tables behind Drizzle's wrapper; the browser's fallbacks by status, HTML bodies, "Failed to fetch", streamed and stored messages; the stale-deploy error page |
| 3D maps (71 tests) | pnpm exec tsx scripts/test-maps.ts | The sun's position and light; procedural tank, stack, flame and tube meshes and the glTF writer; lidar octree selection under a budget and the point cloud wire format; terrain tiles; OpenStreetMap parsing; the digital twin's merging and flame placement; change, land-use and footprint cells; the layer registry; the maps plan features |
| Copy trading (121 tests) | pnpm exec tsx scripts/test-copytrade.ts | 13F primary documents and information tables (units, amendments, confidential treatment, options, notices); CUSIP check digits, SEC's 13(f) list, share classes and OpenFIGI answers; splits and quarter-over-quarter changes; clone weights and blends; the lag-aware backtest's arithmetic; the rebalance diff (fractional and whole shares, cash limits, protected outside positions, the opt-in); one-tap approval (two simultaneous taps place each order once, unknown outcomes never retried, the daily limit, typed confirmations, market orders while closed); US market hours; SnapTrade request signatures against ones the official SDK computed; paper copies and polling |
| Algo trading (207 checks) | pnpm exec tsx scripts/test-algo.ts | Indicators and Engle–Granger; strategy validation and templates; point-in-time decisions (changing the future changes nothing); the backtester on known answers (costs, next-open fills, the kill switch, DCA); the deflated Sharpe against Bailey and López de Prado's example; PBO and bootstrap; every risk rule and the kill switches; five concurrent sends placing each order once and unknown outcomes never resent; Alpaca, Robinhood (Ed25519 verified), Webull and SnapTrade requests against fixtures; the paper fill model; the agent's gates against prompt injection and quoted or pasted orders; live sells capped at the broker's holdings; PDT; the live gate; the Quant contract's timing, budget and grade rules; TWAP, client ids and the order lifecycle; the schedule; CSV formula neutralisation |
| Tool packs | pnpm exec tsx scripts/test-pack.ts all | Schema and example validation, id collisions |
| Premium (56 tests) | pnpm exec tsx scripts/test-premium.ts | The feature registry (unique ids, plans, a cost for every metered feature, every keyed upgrade built and tied to a feature); the premium scope (nothing premium outside it, async propagation, 402 before work, the client's plan message); per-person and administrator views of the upgrades (no setting values); Citations' spans to claims; MP3 frames and WAV headers for cutting audio; diarized pieces in time; LlamaParse jobs and Markdown tables; Nightfire's CSV, grouping and volumes; weekly levels, the drift forecast and the TimesFM query |
| Autopilot end to end | see the header of scripts/e2e-autopilot.ts | A real IMAP/SMTP mailbox (Ethereal), a real database and the live model: coworker replies sent automatically and threaded; a pricing question held and asked; the answer remembered and reused; newsletters ignored; a draft withdrawn when you reply yourself |
| Studio (136 tests) | pnpm exec tsx scripts/test-studio.ts | Formula language and precedence; about 120 functions against Excel's documented results; number formats; the dependency graph, deep chains and iterative circularity; data tables and goal seek; every template; audit rules; banker formatting; edit operations with reference shifting; the linked deck and tie-out; .xlsx and .pptx round trips |
| Studio end to end | DATABASE_URL=<branch> pnpm exec tsx scripts/e2e-studio.ts | With the live model: a valuation pack with a linked deck, a custom formula-linked sheet with a waterfall slide, a turned comment, undoing a run, and exports from the stored document |
| Excel, PowerPoint and Studio tools (127 tests) | pnpm exec tsx scripts/test-office.ts | The workbook diff behind "Synced from Excel"; the Excel adapter against an in-memory Excel (scripts/mock-office.ts): every template written in and read back unchanged, and each kind of agent edit applied to Excel and to Studio side by side; a formula Excel rejects; a person's edits coming back; PowerPoint insert and in-place refresh; checkpoints and restore; every brand-check rule and stacked fixes; markup placement and data-room sheets; the manifest; pairing codes |
| Excel and PowerPoint end to end (52 checks) | see the header of scripts/e2e-office.ts | Against a running server and a Neon branch, with the live model: pairing and a single-use token; linking a workbook; a template round trip through Postgres; gzipped, partial and refused (409) syncs; an agent run applied to Excel as it streams; rebuilding an old state from undo patches; the deck's slide ids; checkpoints; the brand check; a marked-up photo read into comments; a data-room PDF read into a sheet; revoking the device |
| Engine end to end (20 checks) | DATABASE_URL=<branch> E2E_STUB_LESSONS=1 pnpm exec tsx scripts/e2e-engine.ts | Certification, a critical change, probation, spot checks, the security veto, demotion by cancels, lesson merging, settlement exactly once, pooled priors, Thompson sampling |
| Meetings (83 checks) | pnpm exec tsx scripts/test-meetings.ts | Transcript chunk stitching (overlaps, re-sent chunks, per-chunk speaker labels, "You" from the microphone levels); participant matching; the notes parser (action items, owners, dates); proposed deal changes; the notetaker's webhook signatures, events and transcripts; meeting context and auto-join; transcription answers and engine choice; the premium features |
| Desktop app (27 tests) | cd desktop && pnpm check:web && pnpm check:rust | Links, navigation rules, site addresses, settings, the scheduler's timing, which files are indexed, path hashing, the streaming parser; meeting audio (mixing, resampling, levels, WAV, overlapping chunks, silence in loopback), call detection and its parsers, never-record rules, the recording dot; the pages' scripts and that every command they call is registered and allowed |
| Production (122 tests) | pnpm exec tsx scripts/test-prod.ts | Outbound HTTP timeouts and the retry policy (bounded, jittered, Retry-After, never a POST or DELETE, deadlines); database transient errors and which statements may be repeated; the migration check; the environment and feature checks; the health verdict and what visitors see; sign-in origins on production and previews; security headers; the browser's request helper (retry a GET once, send a double-clicked write once, timeouts, a dropped stream) |
| Preflight | bash scripts/preflight.sh | Themes, the tool catalog, typecheck, lint, inference, Newsroom, tool packs, production build |
| Quant (244 checks) | pnpm exec tsx scripts/test-quant.ts | Every statistic against a known answer (PSR, DSR and the paper's example, MinTRL, effective trials, haircuts, BH and BHY, PBO, the stationary bootstrap and Politis-White, the Reality Check, purged k-fold, Ledoit-Wolf, the HMM, ADF, Engle-Granger and Johansen against statsmodels, Newey-West, Kelly and its drawdown law); the contract validators; signalsAsOf never seeing the future; the wording rules over every template and AI tool; the integrity grade's rules; the trading calendar and knownAt; bars, panels, splits and the universe; factor sorts, crowding and Factor Lab; event studies; VaR, its backtests, replays, shocks and reverse stress; Kelly, the governor and the risk budget; fill imports for seven brokers, spread and impact models, Rule 605 and 606; Form 4 and 13D parsing and the insider rules; drills; the adapters, feed cards, canvas blocks and terminal commands; the premium registry. Fixtures in scripts/fixtures/quant/ (constructed from documented formats, see its README) |
| Edge next (260 checks) | pnpm exec tsx scripts/test-edge-next.ts | The crosswalk, the change library and its placebo rate, the calibration library and ledger rules, Calibrated Claims, the Precedent Engine (number readers, section location on saved proxies, checks on hand-labelled fields, similarity, the conformal band's coverage), the Pulse (every source's parser on saved responses, title rules on 60 labelled titles, findings) and the Deal Radar (no look-ahead, labels, the model beating its baselines on synthetic data, calibration, card wording) |
| Deal Radar model (14 checks) | python ml/test_odds_core.py | LightGBM training and scoring as the ML service runs them, on a synthetic panel with a known hazard |
| Edge next evaluations | scripts/eval-precedents.ts, scripts/eval-odds.ts, scripts/eval-claims.ts | Field accuracy, recall@10 of banker-chosen precedents and interval coverage; the Deal Radar's out-of-time scorecard; claim support (against the test branch) |
| Preflight | bash scripts/preflight.sh | Themes, the tool catalog, typecheck, lint, inference, Newsroom, Edge, launch limits, errors, tool packs, production build |
GET /api/billing/invoicesGET|POST|DELETE /api/billing/seats lists, gives and takes back seats.POST /api/billing/webhook checks Stripe's signature, then rewrites the person's subscriptions row
from the subscription as Stripe holds it now, grants packs once per payment intent, and takes back
refunded credits. Retried and out-of-order events change nothing extra.POST /api/billing/confirm stores what was bought as soon as someone is back from Checkout.scripts/stripe-setup.ts creates the products, prices, webhook endpoint and portal configuration
(--live, --webhook, --tax, --dry-run) and prints every variable to set.STRIPE_SECRET_KEY, the plan page shows the prices and says billing isn't switched on yet./pricing (from PLANS and the packs), and draft /terms, /privacy and /refunds
marked for review by counsel.| docs/edge-next.md | Edge's next round: the 14 proposals, the build order and what each step delivered |
| docs/quant-edge.md | Quant Edge: how the top firms get their edge, what a small investor can reproduce, the contract with the algo engine, the features and their build status |
| docs/edge-architecture.md | Edge's parts, tables, background jobs, free-tier guards and operations |
| docs/newsroom.md | The Newsroom: sources and why each, the pipeline, clustering calibration, ranking, AI and its budget, delivery, the editions |
| docs/03-decisions.md | Every decision and its rationale, in order |
| docs/05-tool-pack-authoring.md | How to add tools for a role |
| docs/04-comps-engine-spec.md | Comps engine spec |
| docs/01-tech-ma-personas.md | The original persona study |
| docs/research/ | Market research behind the tool packs, plus the Studio competitive landscape and the analyst grunt-work study |
| docs/mobile/ | Before-and-after screenshots of the phone layouts |