analyze_risk
Calculate core risk metrics for a portfolio — Value at Risk (VaR), Conditional VaR (CVaR), volatility, beta, and max drawdown.
methodbenchmarkpositions必填horizon_dayslookback_daysconfidence_level
dev.quantrisk由 quantrisk.dev 發布v1.0.2更新於 Oct 24, 2026
Portfolio risk analytics — VaR, Monte Carlo, optimization, options Greeks, stress testing.
QuantRisk 讓助理取得機構級投資組合風險分析能力:VaR、蒙地卡羅、壓力測試、相關性、曝險與選擇權希臘值。
Web executable,透過 Streamable HTTP。 遠端服務在工作區中設定後即可從網頁執行環境執行。
把這段提示詞貼上到 Claude Code、Codex、Cursor 等代理程式,或 SourceWeft 對話中。代理程式會讀取該伺服器的安裝指南,先向你展示發布者、端點和登入方式,經你同意後再把它新增到你的客戶端。金鑰不會寫進任何命令。
閱讀 https://sourceweft.com/mcp/dev.quantrisk%2Fmcp-server/install.md,並按其中說明把這個 MCP 伺服器接入我的客戶端。修改任何設定之前,先告訴我它的發布者、端點和登入方式,等我確認。不要把 API 金鑰寫進命令或我會提交的檔案;問我金鑰應從哪裡取得。把它新增到你客戶端的 mcpServers 設定中。
{
"mcpServers": {
"quantrisk": {
"type": "http",
"url": "https://quantrisk-mcp.quantrisk.workers.dev/mcp"
}
}
}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.
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.
Add to ~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows):
Add to .cursor/mcp.json in your project root:
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.
Once configured, ask Claude questions like these:
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:
No data is stored. No portfolio information is retained after a request completes.
Contributions are welcome. Please open an issue first to discuss what you'd like to change.
See CONTRIBUTING.md for guidelines.
Built by the team at quantrisk.dev
Contact: [email protected]
來源:README.md,提交 df287a5
Calculate core risk metrics for a portfolio — Value at Risk (VaR), Conditional VaR (CVaR), volatility, beta, and max drawdown.
methodbenchmarkpositions必填horizon_dayslookback_daysconfidence_levelRun Monte Carlo simulation on a portfolio to model the distribution of future returns, including percentile outcomes and probability of loss.
seedmodelnum_pathspositions必填horizon_dayslookback_daysStress test a portfolio against historical crisis scenarios (GFC 2008, COVID 2020, etc.) or custom shocks (paid tier).
positions必填scenarioscustom_shocksFind the optimal portfolio allocation using mean-variance optimization. Supports max Sharpe, min variance, and target return objectives. Paid tier only.
tickers必填objectiveconstraintslookback_daystarget_returnrisk_free_rateCompute the pairwise correlation matrix for a set of assets. Identifies highly correlated pairs and diversification opportunities.
methodtickers必填lookback_daysBreak down portfolio performance into factor exposures, sector allocation, and position contributions. Computes Sharpe, Sortino, Treynor, Calmar, and Information ratios.
benchmarkpositions必填period_daysrisk_free_rateBreak down portfolio exposure by GICS sector, market cap, and asset class. Returns concentration metrics including the Herfindahl-Hirschman Index.
positions必填Fetch historical OHLCV price data for one or more tickers. Free tier: 1 ticker, 252 days. Paid tier: up to 20 tickers, 1260 days.
daystickers必填intervalCompare two or more portfolio allocations head-to-head across all key risk and return metrics. Paid tier only.
portfolios必填period_daysconfidence_levelCalculate option Greeks (delta, gamma, theta, vega, rho) for individual options or an options portfolio. Uses Black-Scholes for European, binomial for American style. Paid tier only.
options必填risk_free_rate已滿足適用檢查項的 100%
該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。
npm install -g @quantrisk/mcp-server{ "mcpServers": { "quantrisk": { "command": "quantrisk-mcp-server", "env": { "QUANTRISK_API_KEY": "your-api-key" } } }}{ "mcpServers": { "quantrisk": { "command": "quantrisk-mcp-server", "env": { "QUANTRISK_API_KEY": "your-api-key" } } }}{ "mcpServers": { "quantrisk": { "command": "quantrisk-mcp-server", "env": { "QUANTRISK_API_KEY": "your-api-key" } } }}Claude / MCP Client | MCP Protocol |QuantRisk MCP Server (local process) |QuantRisk API (Cloudflare Workers) |Yahoo Finance (market data) + risk engine (math)git clone https://github.com/78degrees/mcp-server.gitcd mcp-servernpm installnpm test