
Quantrisk
io.github.78degreesPublished by GitHub account 78degreesv1.0.3Updated Oct 24, 2026
Portfolio risk analytics MCP server — VaR, Monte Carlo, stress testing, and more.
Overview
A local MCP server that gives an assistant portfolio risk analytics — VaR, Monte Carlo simulation, stress testing, correlation and optimization — via the QuantR
- What you can do
- Analyze portfolios: compute VaR, CVaR, volatility, Sharpe ratio and max drawdown, and break down sector exposure and performance attribution by asset, sector and factor. Simulate and stress test: run forward-looking Monte Carlo return simulations and measure portfolio impact under historical or hypothetical scenarios. Retrieve market data: pull historical prices and returns for supported tickers and build cross-asset correlation matrices. Optimize and compare (Pro tier): run mean-variance and risk-parity optimization, compare portfolios side by side, and calculate options Greeks.
- When to use it
- Useful when you want an assistant to answer quantitative portfolio risk questions — value at risk, drawdown, stress scenarios, correlations or allocation optimization — using real market data rather than estimated figures.
- Requirements
- Runs as a local stdio process installed from the npm package @quantrisk/mcp-server, so Node.js is needed. Requires an API key supplied in the QUANTRISK_API_KEY environment variable, obtained by signing up on the vendor site. Network access to the vendor's cloud API is needed; the free tier is limited to 20 positions, 50 calls per day, 7 tools and 1,000 Monte Carlo paths.
Installation
In SourceWeft
- Open Quantrisk in the dashboard and add it to a workspace.
- Enable the server for the chats that should use its tools.
Desktop only via STDIO. STDIO servers start a local process, so they need the SourceWeft desktop host.
Other MCP clients
Follow the launch instructions in the repository.
README
QuantRisk
Institutional-grade portfolio risk analytics for Claude and any MCP client.
[npm version] [npm downloads] [License: MIT] [MCP Compatible]
VaR / Monte Carlo / Stress Testing / Portfolio Optimization / Greeks / Correlation Matrices
Real market data. Real math. Not hallucinated numbers.
Quick Start
1. Install
2. Configure (Claude Desktop — see below for Cursor)
Add to your claude_desktop_config.json:
Get your free API key at quantrisk.dev/signup.
3. Ask Claude
"What's the Value at Risk on a portfolio of 60% SPY, 25% TLT, and 15% GLD?"
That's it. Claude now has access to institutional-grade risk analytics.
Configuration
Claude Desktop
Add to ~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows):
Cursor
Add to .cursor/mcp.json in your project root:
Any MCP Client
QuantRisk works with any client that supports the Model Context Protocol. Point it at the quantrisk-mcp-server binary with your API key in the environment.
Tools
Example Queries
Once configured, ask Claude questions like these:
- "Run a Monte Carlo simulation on my portfolio: 50% AAPL, 30% MSFT, 20% NVDA. Show me the 5th percentile outcome."
- "Stress test 70% VTI / 30% BND against the 2008 financial crisis and a hypothetical 300bp rate shock."
- "What's my sector exposure if I hold equal weights in AMZN, JPM, JNJ, XOM, and NEE?"
- "Show me the correlation matrix for SPY, GLD, TLT, and BTC-USD over the last 2 years."
- "Compare the risk-adjusted returns of a 60/40 portfolio vs. an all-weather portfolio." (Pro)
- "Calculate the Greeks for a SPY 550 call expiring in 30 days." (Pro)
Why Pro?
The free tier covers core risk analytics for small portfolios. Pro unlocks the tools and scale that serious analysis demands.
What that means in practice:
- Free: "What's the VaR on my 10-stock portfolio?" — works great.
- Pro: "Optimize my 200-position portfolio for maximum Sharpe, then stress test it against 5 scenarios and compare it to my current allocation." — you need Pro for that.
How It Works
- MCP Server runs locally as a stdio process — your API key never leaves your machine except to authenticate with the QuantRisk API.
- Risk Engine runs on Cloudflare Workers. All calculations — VaR, Monte Carlo, optimization — happen server-side with real math on real market data.
- Market Data sourced from Yahoo Finance. Prices, fundamentals, and options chains are fetched in real time.
- Reports generated with pdf-lib when applicable.
No data is stored. No portfolio information is retained after a request completes.
Contributing
Contributions are welcome. Please open an issue first to discuss what you'd like to change.
See CONTRIBUTING.md for guidelines.
License
Built by the team at quantrisk.dev
Contact: [email protected]
Source: README.md at commit df287a5
Tools
0Version history
1- v1.0.3LatestSep 16, 2026
Score
50% of the applicable checks met
How complete this listing is, computed from the registry entry, the endpoint and public sources. Not a rating of the server and not a statement that it is safe or working today: reachability is a dated check, and no installs or reviews go into the score.
- Reached in the last 30 days25 pts
Keep the endpoint answering the MCP handshake; SourceWeft probes it every 30 days.
- Auth declared10 pts
Declare the credential headers in the registry entry, or keep the endpoint answering the probe so its auth can be classified.
- Tools listed15 pts
Answer tools/list without a credential, or ship a package that starts in a sandbox without one.
- DescriptionRequired15 pts
- Logo10 pts
- Documentation15 pts
- License10 pts
