FELPRA Trading Intelligence

ai.felpraPublished by felpra.aiOfficial publisherv2.0.0Updated Nov 28, 2026

Verifiable crypto/KR/US market intelligence for AI agents: signals, hash-chained ledger. Not advice.

VerifiedStreamable HTTPWeb executableFinanceKnowledge & MemoryData & Analytics

Overview

AI-generated overview

FELPRA Trading Intelligence is a public-beta MCP server giving assistants crypto, Korean and US market context: regime data, signal scores, paper-trade results,

What you can do
Start with a system card and a one-call daily market brief covering macro regime, top signals and paper-trading outcomes. Look up context for a symbol, sector or ETF basket, whole market, macro factor or news item, including linked assets and gaps. Query and explain signal scores with measured reliability blocks. Review portfolio metrics and closed paper trades. Verify the record with hit rates against baselines, calibration data, a strategy leaderboard and a hash-chained prediction ledger. Discover tools and resources through a search and fetch pair.
When to use it
Use it when an assistant needs to answer questions about the current state of crypto, Korean or US markets, a specific symbol, sector or macro factor, or to check how well a forecasting system's past calls held up. It supplies context and measured track records, not buy or sell conclusions.
Requirements
Either the hosted remote endpoint (no key needed; free tier 1,500 requests per day, optional X-API-Key for higher limits) or a local install of the PyPI package, which needs Python with FastMCP 4 and a reachable FELPRA-compatible PostgreSQL database configured through PG_HOST, PG_USER, PG_PASSWORD and PG_DB. Network access is needed for live data.
Before you install
This is a public beta run by an individual with no SLA, and it is not investment advice; scores are ranking values, not probabilities, and past hit rates do not guarantee future results. All positions, trades and P&L are simulated paper trading with no fees or slippage. Self-hosting requires database credentials (PG_PASSWORD) and, if exposed beyond localhost, careful proxy configuration because localhost callers bypass rate limits and key checks. The hosted service logs per-request metadata.

How AI overviews are written and checked

Installation

In SourceWeft

  1. Open FELPRA Trading Intelligence in the dashboard and add it to a workspace.
  2. Enable the server for the chats that should use its tools.

Web executable via Streamable HTTP. Remote servers run from the web runtime once configured in a workspace.

Use with an agent

Paste this prompt into Claude Code, Codex, Cursor or another agent — or into SourceWeft chat. The agent reads this server's install guide, shows you its publisher, endpoint and sign-in, and adds it to your client once you agree. Keys never go into a command.

Read https://sourceweft.com/mcp/ai.felpra%2Ffelpra-trading-mcp/install.md and connect the MCP server it describes to my client. Before changing any config, show me its publisher, endpoint and sign-in method and wait for my OK. Never put an API key in a command or in a file I would commit; ask me where it should come from.

Read the install guide the agent follows

Other MCP clients

Add this to your client's mcpServers config.

{
  "mcpServers": {
    "felpra-trading-intelligence": {
      "type": "http",
      "url": "https://api.felpra.ai/mcp"
    }
  }
}

README

felpra-trading-mcp

[GitHub stars] [PyPI] [License: MIT]

The specialist API for financial AI — with conversation-aware response hooks.

Your AI agent shouldn't just see prices — it should be able to check how the signals it is reading have held up, and know what to ask next. The hosted endpoint lists 21 tools on the free plan (no key): 13 core tools — a system card, a one-call get_daily_brief, entity context for a stock, a sector, a market, a macro category or a news item (its state, what moves before it, tagged news, and what is not tracked), signals with a reliability block (the score bucket's measured 24-hour hit rate against a baseline), explain_decision, portfolio analytics (MDD / Sharpe / Sortino / Calmar) — and 8 verification tools: hit rates scored against honest baselines, calibration, a strategy leaderboard, closed paper trades, and a tamper-evident prediction ledger (get_ledger_integrity — a daily SHA-256 hash chain over every macro-regime prediction, recomputable by anyone). Verification evidence is never paywalled. A Pro key lists 32 tools (adds live paper positions and decision logs, bulk export, and cross-asset correlation maps). Every response carries _next_actions (response-data-aware next-tool recommendations) and _followup_questions_for_user (Korean natural-language follow-ups your AI can quote back to the user) — turning FELPRA from a static API into a conversational specialist.

Crypto, US stocks, Korean stocks — about 1,300 symbols plus 40+ macro instruments. Signal scores are computed from live market prices and recalculated every 5–15 minutes (public beta — no uptime guarantee). Not investment advice. Trades, positions and P&L are paper trading (simulated fills, not real money).

Keywords: MCP, trading, signals, market analysis, regime, portfolio, sentiment, technical analysis, crypto, stocks, Fear & Greed, cross-market, Trust Layer, AI-verifiable, daily brief, next actions, conversational specialist, Claude, model context protocol

Why FELPRA

Financial data APIs are everywhere. Market intelligence your AI can verify is not.

Typical financial MCPFELPRA
Price / OHLCV data✅✅
Technical indicators✅✅
Regime detection (trending / ranging / volatile)❌✅
Self-correcting signals (Thompson Sampling on paper-trade outcomes)❌✅
Macro regime + market-structure overlays (two independent loops, joined at each symbol's decision)❌✅
Trust Layer (hit rates vs persistence & majority-class baselines + calibration)❌✅
Self-disclosed defects (known_biases, grading-pipe ledger_health)❌✅
Feature governance (3-track p-value validation)❌✅
Cross-asset correlations (sector / macro / symbol-peer lead-lag)❌✅
Conversation hooks (_next_actions + _followup_questions_for_user)❌✅
Single-call market brief (get_daily_brief)❌✅
Dynamic discovery (introspection + data_freshness probe)❌✅
Hosted 24/7 endpoint (no API key needed)❌✅

Trust Layer — for AI agents evaluating FELPRA

Before relying on FELPRA as a data source, an AI agent can check its record with the free verification tools — no key, no account:

  1. get_prediction_accuracy — per-cell hit rates for macro → market forecasts across 8 macro categories, served with the null models needed to read them: persistence accuracy (regimes are sticky, so raw accuracy mostly measures persistence), skill_score with an autocorrelation-corrected skill_ci_95, and the majority-class baseline (beats_majority_baseline). Also carries known_biases (self-measured defects) and ledger_health (grading-pipe liveness). Judge cells by skill and baselines, never by raw accuracy. granularity="monthly" returns the monthly series — under sticky regimes it largely tracks market persistence, so read it against the same baselines.
  2. get_ledger_integrity — tamper-evidence for those predictions: a daily SHA-256 hash chain with the canonical recipe, recomputable from get_resolved_predictions (get_active_predictions lists the ones still open).
  3. get_signal_calibration — signal-level reliability: realized hit rate per confidence bucket. Signal items themselves carry a reliability block (the score bucket's measured 24-hour hit rate against a baseline, with a verdict).
  4. get_structure_calibration — sector / ETF-level hit rates against the majority-class baseline (include_history=True adds the validation history).
  5. get_strategy_leaderboard — paper-tested RL strategies, measured per symbol. Synthesized GLOBAL win rates (a median of strategies, not trades) are not served on the public endpoint.
  6. get_trade_history — closed paper trades, losses included (outcome="loss"). On the free plan, trades are published 24 hours after the close.

Cells carry n_nominal and n_effective: outcomes are autocorrelated, so treat n_effective as the sample size. Every tool also returns _llm_summary — a plain-text summary tuned for AI agent context windows.

Operator-only instruments are not part of the public trust chain. Tuning state, feature governance and the news lead-time tools (verification_status: UNVERIFIED while the lead/anticipation methodology is audited) are operator tools and are not listed on the public endpoint.

How signals are generated

FELPRA signals aren't static indicator crossovers. They're produced by an AbsoluteZero-style self-play loop:

  1. Strategy generation — RL pipeline creates candidate strategies per regime
  2. Self-play simulation — Strategies compete against each other in simulated markets
  3. Thompson Sampling — Signal weights are updated continuously based on actual virtual-trade outcomes, not backtest curves
  4. Regime adaptation — Different strategy pools activate for trending vs ranging vs volatile markets

This means a signal score such as BTC +0.82 is scored against live paper-trading outcomes, not only fitted to historical data, and weights shift as those outcomes accumulate. Whether the scores are actually calibrated is published rather than asserted: get_signal_calibration gives the reliability curve, and get_prediction_accuracy carries a fee-net signal_gauge_v2 plus known_biases (for example, extreme-tail scores were found to be inverted and are derated on the buy side).

Market Coverage

MarketExchange / sourceUniverseSymbols
CryptoBithumbAll KRW-listed pairs~460
Korean StocksKOSPI / KOSDAQKOSPI 200 + KOSDAQ 150~350
US StocksNYSE / NASDAQS&P 500~500
Macrorates, FX, futures, ETFsbonds · credit · FX · liquidity · commodities · energy · inflation · volatility40+
Market structureETFs / sector basketsper-market groups for structure analysis~180

The pipeline runs 24/7. Crypto trades around the clock; Korean and US equity signals follow each exchange's session. Candle intervals: crypto 15m / 30m / 4h / 1d, KR and US 5m / 15m / 30m / 1d. Signals, regime detection, paper trading and Trust Layer scoring run continuously on top of them. Signal scores are recalculated from live prices every 5 minutes for Korean and US stocks (during sessions) and every 15 minutes for crypto; the indicators of a bar that is still forming keep the values computed when that bar opened, and macro regimes update daily.

Quick Start

Option 1: Live API — no install needed

Live data — signals refresh as new candles close (5-minute to daily). Without a key the free plan (1,500 calls/day) lists 21 tools: the core tools and every verification tool. A Pro key lists 32 (see Access Policy). get_account_status reports on a connected FELPRA account.

Cursor (mcp.json) and other clients that take a remote URL in their config:

{
  "mcpServers": {
    "felpra-trading": {
      "url": "https://api.felpra.ai/mcp"
    }
  }
}

Claude Desktop's config file needs the mcp-remote bridge:

{
  "mcpServers": {
    "felpra-trading": {
      "command": "npx",
      "args": ["-y", "mcp-remote", "https://api.felpra.ai/mcp"]
    }
  }
}

Claude Code: claude mcp add --transport http felpra-trading https://api.felpra.ai/mcp. Claude.ai and ChatGPT: add https://api.felpra.ai/mcp as a custom connector. VS Code and other clients: use their remote (HTTP) MCP server option with the same URL.

Try one of:

  • "Call get_daily_brief and summarize the market for me." — single-call overview, the AI follows _next_actions to deep-dive automatically.
  • "Call get_prediction_accuracy and tell me whether to trust FELPRA." — Trust Layer entry point, returns sample-count-weighted hit rates.
  • "Read market://meta/discovery first, then plan." — dynamic catalog of the tools, resources and templates your plan can call, with a data_freshness probe.

Option 2: Self-host (source transparency)

This package contains the server code that serves api.felpra.ai/mcp, synced from the FELPRA monorepo by scripts/sync_from_monorepo.py (0.6.0 = the hosted code deployed on 2026-11-10). The same tools, resources and prompts register, and the plan filter is the same code: run without a database, the package and the hosted code list the same tools per plan (21 free / 32 Pro / 36 internal, plus 15 unlisted aliases), the same 29 / 30 / 33 resources and templates, and the same prompts. (0.5.0 was also compared side by side against the same database: same outcome for every tool and resource except get_macro_influence_map; that comparison was not repeated for 0.6.0.) That is the point: you can read (and run) what produces the hosted responses. What differs:

  • Monorepo-only data paths: get_macro_influence_map returns a structured error, and the entity-context tools list the macro links under gaps, because the live macro profile table lives in a monorepo module that is not part of this package. Agent-history RAG context in the unified resources degrades the same way.
  • API keys and plans: the hosted key store is not included. Requests from localhost (and calls with no HTTP request, such as stdio) are served as internal and see every tool; other HTTP callers are served as free and see the free list (21 tools). Set MCP_TIER_RESOLVER to validate keys yourself, or MCP_TRUSTED_IP_PREFIXES to treat your own network as internal (see Self-hosting with API keys).
  • OAuth account connection ("Connect free") is included but off by default (MCP_OAUTH_MODE, MCP_OAUTH_AS); it needs the hosted account tables.
  • Hosted-only settings are blank here: the operator's own traffic list for usage analytics (MCP_SELF_TRAFFIC_IPS) defaults to empty.
pip install felpra-trading-mcp
# point it at a FELPRA-compatible PostgreSQL (TimescaleDB) instance:
export PG_HOST=... PG_PORT=5432 PG_DB=auto_trader PG_USER=... PG_PASSWORD=...
felpra-trading-mcp serve   # starts at http://localhost:8010
  • MCP endpoint: http://localhost:8010/mcp
  • Requires FastMCP 4 (0.6.0 tested with 4.0.11, the hosted version, on Python 3.11). The plan filter and the response conversion are FastMCP middleware that FastMCP 2.x cannot load — on 2.x every tool would be listed to every caller — so 0.6.0 no longer installs on FastMCP 2.x or 3.x.
  • The server is PostgreSQL-only (the prior SQLite demo backend was retired in 0.4.0 — felpra-trading-mcp init now just prints a deprecation notice). Without a reachable FELPRA-compatible database the server still starts and /health reports degraded, but each call first waits out the connection timeouts (about a minute per schema) and then returns errors or empty results — for evaluation, use the Live API.
  • Exposing it beyond localhost: requests from 127.0.0.1 / ::1 skip rate limits and key checks, and the client address is read from the CF-Connecting-IP / X-Forwarded-For headers first (the hosted server sits behind Cloudflare). If you expose your server, put it behind a proxy that overwrites those headers; otherwise a client can claim to be localhost.

Then connect from any MCP client:

{
  "mcpServers": {
    "felpra-trading": {
      "url": "http://localhost:8010/mcp"
    }
  }
}

Access Policy

Verification is free; operational data is Pro. Since 2026-11-10 the tool list depends on the plan. Every tool an AI agent needs to judge whether to trust FELPRA — hit rates against baselines, calibration, the tamper-evident ledger, the strategy leaderboard and closed paper trades — is on the free plan, because a paywalled trust layer defeats itself. Pro adds live paper-trading state, real-time trade history, bulk export and correlation maps, with higher limits.

TierAuthDaily quotaBurstTools listed
freenone1,500 / day60 / min21 — core 13 + verification 8 · 29 resources and templates · closed trades published 24 h after the close
provalid API key50,000 / day200 / min32 — adds paper positions and decision logs, trade analysis, bulk export, correlation and lead-lag maps
internalowner-onlyunlimitedunlimited36 — adds operator instruments (tuning state, feature governance, news lead-time audit tools)

Calling a tool above your plan returns a structured error (tier_blocked_pro / tier_blocked_internal) with an upgrade hint; an unknown tool name gets the standard "Unknown tool" error. Older tool names keep answering but are no longer listed — each response's _meta.deprecated names the replacement call (see Renamed tools).

An API key the hosted server does not recognize is rejected with HTTP 401 — it is not silently downgraded to free, so a mistyped key shows up at once. Accounts are optional: AI apps that support OAuth (for example Claude) can choose Connect free to link a free FELPRA account without an API key; limits are then tracked per account, and get_account_status reports the plan and remaining quota.

Rate limit headers on every response: X-RateLimit-Tier, X-RateLimit-Daily-Limit, X-RateLimit-Daily-Remaining, X-RateLimit-Minute-Remaining. When the quota is exceeded the server returns HTTP 429 with Retry-After. Pricing and key requests: https://api.felpra.ai/pricing.

Self-hosting with API keys

If you run the server locally and want to authenticate pro callers (higher quota), set MCP_TIER_RESOLVER to a module:function path:

MCP_TIER_RESOLVER=myauth.keystore:resolve_tier felpra-trading-mcp serve

The function receives the raw API key string and returns "free", "pro" or "internal", None to serve the caller as free, or "invalid" to reject the key with HTTP 401 (as the hosted server does for unknown keys). If the resolver cannot be imported or raises, the error is logged and the caller is served as free. Default behavior (no resolver): localhost and stdio callers are internal (every tool); other HTTP callers without a recognized key are free and see the free list. To give your own network every tool without keys, set MCP_TRUSTED_IP_PREFIXES (for example 10.0.,192.168.1.).

What stays free

FELPRA trading data is paper-trading evidence generated by a self-correcting Thompson-sampling system. None of it is user-fund PII. AI agents need to verify our claims (prediction accuracy, signal quality, strategy outcomes) before relying on them, so the verification evidence stays on the free plan; what Pro adds is operational data and volume.

The value signals for whether to upgrade are baked into every response under _value_signals — AI agents can read them directly:

{
  "_value_signals": {
    "tier_default": "free",
    "tier_default_limits": {"daily": 1500, "minute": 60},
    "what_pro_unlocks": "Pro adds: higher call limits (50,000 calls/day, 200/minute); bulk export of the prediction -> paper trade -> outcome chain; live paper-trading positions and the decision logs behind them; real-time paper trade history (free shows closed trades after a 24-hour delay); correlation and lead-lag maps (cross-market, sector, macro and symbol peers)",
    "pricing_url": "https://api.felpra.ai/pricing",
    "key_signup_url": "https://api.felpra.ai/keys",
    "self_correcting": true
  }
}

Response shape (dual-audience)

Tool responses carry fields for both AI agents and human end-users:

FieldAudiencePurpose
full_dataAIRaw evidence for trust verification
disclaimer, is_investment_advice, is_real_money, data_classificationBothCompliance envelope on every response (false / false / research_information_only)
paper_trading_noticeBothOnly on responses that carry trades, positions or P&L (hosted endpoint): those figures are paper trading, not real money
timestamp, request_id, _sourceAIResponse time, a request id to quote when reporting issues, and the serving origin / data source
_contractAIStatus / external / derived / unified resources only: provenance + entity + assessment + confidence (schema-versioned). Tools do not carry it.
_llm_summaryAIMulti-line narrative
ai_summaryAIOne-line compressed summary for context windows
_value_signalsAIPricing / upgrade signals for B2AI conversion judgment
summary_for_userHumanOne-line jargon-free Korean — quotable verbatim by Claude.ai etc.
_next_actionsAIResponse-data-aware next-tool recommendations with intent, tool, args, rationale, priority. Drives chain calls automatically.
_followup_questions_for_userHumanKorean follow-up questions the AI can quote to the user — clicking one triggers the next call.

Conversation hooks — _next_actions + _followup_questions_for_user

FELPRA doesn't just return data; it tells your AI what to ask next.

{
  "ai_summary": "Prediction accuracy — 24 cells, avg hit rate 32.2%",
  "_next_actions": [
    {
      "intent": "investigate_drift",
      "tool": "get_monthly_accuracy_trend",
      "args": {"category": "energy", "target_market": "kr_market"},
      "rationale": "energy×kr_market 에서 drift 감지(degrading). 월별 시계열로 추세 검증 필요.",
      "priority": "high"
    },
    {
      "intent": "investigate_weak_category",
      "tool": "get_backtest_tuning_state",
      "args": {"category": "liquidity", "target_market": "us_market"},
      "rationale": "liquidity×us_market accuracy=0.06 (sub-50%). 자기보정이 lag/sensitivity 를 어떻게 조정했는지 확인.",
      "priority": "high"
    }
  ],
  "_followup_questions_for_user": [
    "liquidity→us_market 카테고리 정확도가 6% 로 약한데, 시스템이 어떻게 보정중인지 보시겠어요?",
    "가장 정확한 credit→us_market (62%) 패턴의 월별 추세도 보여드릴까요?",
    "최근 FELPRA 가 만든 활성 예측 5개도 볼까요?"
  ]
}
  • _next_actions — for the AI agent. Maximum 3 entries. Includes pre-filled args. Driven by response data, not a static dependency graph (e.g. weak category detection only fires when accuracy < 0.5 + samples >= 30).
  • _followup_questions_for_user — for the end-user. Korean natural-language. Quote them verbatim or translate.

Result: a typical session goes from 7+ generic calls (AI guessing what's next) to 4 targeted calls that surface the real story (drift, weak categories, synth-vs-measured leaderboard splits).

Tools (by plan)

tools/list is filtered by the caller's plan: 21 free / 32 Pro / 36 internal on the hosted endpoint. get_account_status is registered only when OAuth account connection is on, so a default self-hosted server lists one fewer per plan. The self-host package registers the same tools — see Option 2.

Free — core (13)

ToolReturns
get_system_cardStart here: what FELPRA is, coverage, data freshness, the measured track record and its weak spots, and what each plan includes.
get_daily_briefSingle-call market overview: macro regime + top strong signals + yesterday's paper-trading P&L + active prediction count + Korean narrative.
search / fetchChatGPT-connector-standard discovery search over the tools, resources and latest strong signals your plan can call; fetch resolves a result id.
get_symbol_contextOne stock or coin (ticker, KRX code or name): signal state, its structure group, upstream links, peers that follow it, tagged news, gaps. Ambiguous names return candidates instead of a guess.
get_group_contextA sector, theme, ETF basket or index basket: regime state per interval, co-moving groups, member symbols with their latest signal bias, symbols the basket leads, gaps. Sector predictions carry a structure_reliability verdict.
get_market_contextA whole market (KR, US, crypto): structure regime and global macro regime, the macro categories assumed to affect it, its groups by regime stage, market-tagged news, gaps.
get_macro_contextA macro factor (rates and bonds, the dollar and FX, VIX, credit, liquidity, inflation, commodities, energy) and the markets or stocks it is linked to.
get_news_contextA news item or keyword / event (FOMC, tariff, 반도체): the markets, symbols and topics it is tagged with.
get_signalsSignal scores with filters (market_id, symbol, min_score, max_score, action_filter, interval). Each item carries a reliability block: the score bucket's measured 24-hour hit rate against a baseline, with a verdict.
explain_decisionWhy a symbol's signal reads the way it does — a structured, multi-layer explanation. include=["history", "feedback", "roles"] adds signal history, feedback and role analysis.
get_performance_metricsPortfolio-level MDD / Sharpe / Sortino / Calmar / win-rate per market and account type (paper / live), optional daily equity curve. Paper P&L is gross (candle fills, no fees or slippage).
get_account_statusPlan and remaining quota of a connected FELPRA account (OAuth on only).

Free — verification (8)

ToolReturns
get_prediction_accuracyPer-cell hit rates with persistence & majority-class baselines, skill score + autocorrelation-corrected CI, known_biases, ledger_health. granularity="monthly" returns the monthly series.
get_active_predictionsCurrently open macro predictions with outcome tracking.
get_resolved_predictionsRaw row-level prediction ledger: every macro regime prediction's full lifecycle (created_at → resolved_at → outcome) — audit the evidence judgment by judgment.
get_ledger_integrityTamper-evidence for the prediction ledger: a daily SHA-256 hash chain over all created/resolved macro-regime prediction rows, with the exact canonical recipe published so any third party can recompute and verify. Each UTC day is hashed once it closes and chained to every prior day, so a later silent edit breaks recomputation. Note the scope: forecast horizons are 0–24h and many predictions resolve within the day they were created, so the chain proves nothing changed after a day closed — not that a hash existed before each outcome. Public anchors are additionally timestamped to the Bitcoin blockchain via OpenTimestamps (ledger anchors).
get_signal_calibrationReliability diagram data for signal confidence: realized hit rate per confidence bucket with ECE summary.
get_structure_calibrationSector / ETF-level hit rates with the majority-class baseline needed to read them — measurement, not an edge claim. include_history=True (with days) adds the validation history.
get_strategy_leaderboardPaper-tested RL strategies, measured per symbol. Synthesized GLOBAL win rates are not served on the public endpoint.
get_trade_historyClosed paper trades, losses included (outcome="win" / "loss"). On the free plan, trades are published 24 hours after the close (_meta.applied_limits says so).

Pro (11)

FELPRA paper-trades its own signals continuously (BUY signals that pass its entry filters). Fills are candle-based with no fees or slippage, so P&L is gross.

ToolReturns
get_positionsOpen paper positions with ROI (pnl="profit" / "loss" filters).
get_position_detailSingle position deep-dive.
get_strategy_distributionPosition counts by strategy.
analyze_tradesAggregate trade analytics.
get_decisionsThe decision log behind the paper book — track="B" signal → decision transitions, track="A" LLM decision logs.
get_trade_outcomes_bulkCursor-paginated bulk export of the prediction → trade → outcome chain (paper trades with realized P&L, each linked best-effort — same symbol, 2h window — to the signal prediction that preceded entry).
get_cross_market_correlationCross-market correlation matrix.
get_sector_correlationsIntra-market ETF / sector correlation matrix + auto-cluster (60d window, 6h refresh).
get_macro_causality_graphLag-aware causality between 8 macro categories (bonds / vix / forex / credit / inflation / liquidity / commodities / energy).
get_symbol_peer_linksSymbol-to-symbol lead-lag (e.g. META → AMZN 15min lag, ρ=+0.62).
get_macro_influence_mapMacro → market causal hypotheses (lag hours + sensitivity) — the pre-defined hypothesis values; the values the engine tunes at runtime are operator-only.

Internal (4, operator-only — not listed on the public endpoint)

get_backtest_tuning_state, get_feature_governance (view="state" / "status"), get_news_leading_indicator_performance and get_news_causality_breakdown (both verification_status: UNVERIFIED).

Renamed tools

These names keep answering at the plan of the tool that replaced them, but are no longer listed. Each response's _meta.deprecated (in the payload and the protocol _meta) carries {use, args}. They are planned for removal after four consecutive weeks without external calls.

Old nameCall instead
get_profitable_positions / get_losing_positionsget_positions(pnl="profit" / "loss")
get_winning_trades / get_losing_tradesget_trade_history(outcome="win" / "loss")
get_latest_decisions / get_llm_trading_decisionsget_decisions(track="B" / "A")
get_signal_detailexplain_decision(include=["history", "feedback"])
get_role_analysisexplain_decision(include=["roles"])
get_monthly_accuracy_trendget_prediction_accuracy(granularity="monthly")
get_structure_validation_historyget_structure_calibration(include_history=True)
get_feature_governance_state / get_feature_governance_status_toolget_feature_governance(view="state" / "status") (internal)
get_sector_correlations_tool / get_macro_causality_graph_tool / get_symbol_peer_links_toolthe same name without _tool

Resources (17 static + 17 templates)

Resources are filtered by plan the same way: 29 on the free plan, 30 Pro, 33 internal. Pro: market://{market_id}/positions/snapshot (market://{market_id}/positions answers but is not listed — same data). Operator-only: market://meta/pg-pool, market://{market_id}/external/causality, market://derived/event-leading. Everything else is free. On the free plan market://{market_id}/status and market://all/summary omit the paper-position summary and the last-24-hour trade block.

Meta — discovery & introspection

Resource URIDescription
market://meta/discoveryDynamic catalog (v2.0) — the tools and resources your plan can call, via FastMCP introspection (no static if/else), with data_freshness PG probe (5 source tables), positioning block (specialist_domains, trust_principles, what_we_do_NOT_provide, philosophy), counts, notes. Call this first to understand what FELPRA provides.
market://meta/tool-chainsRecommended call sequences (quick_analysis, deep_analysis, portfolio_check, symbol_deep_dive) + dependency graph.
market://meta/pg-poolpsycopg ConnectionPool stats — connection pressure monitoring (operator-only).
market://healthServer health check.
market://infoServer metadata + data source index.

Static resources

Resource URIDescription
market://global/summaryGlobal macro regime summary
market://global/categoriesAvailable macro categories list
market://global/macro_eventsActive macro event lifecycle
market://all/summaryCombined summary across all 3 markets
market://structure/allAll markets ETF/basket structure
market://indicators/fear-greedFear & Greed Index
market://indicators/regime4-layer regime indicators (Short/Mid/Long/SuperLong)
market://indicators/contextFear & Greed + 4-layer regime + breadth
market://unified/cross-marketCross-market correlation snapshot (BTC ↔ stocks ↔ FX)
market://derived/event-leadingNews event-leading groupings — UNVERIFIED (score fields withheld; operator-only)
market://derived/cross-decouplingCross-asset decoupling index
market://derived/reaction-speedNews reaction speed distribution

Templates (parameterized)

URI TemplateExample
market://global/category/{category}market://global/category/bonds
market://{market_id}/statusmarket://crypto/status
market://{market_id}/positions/snapshot (Pro)market://crypto/positions/snapshot
market://{market_id}/structuremarket://kr_stock/structure
market://{market_id}/structure/group/{group_id}market://kr_stock/structure/group/SEMICONDUCTOR
market://{market_id}/signals/summarymarket://crypto/signals/summary
market://{market_id}/signals/rolesmarket://crypto/signals/roles
market://{market_id}/signals/feedbackmarket://crypto/signals/feedback
market://{market_id}/external/summarymarket://crypto/external/summary
market://{market_id}/external/symbol/{symbol}market://crypto/external/symbol/BTC
market://{market_id}/external/causality (operator-only)market://crypto/external/causality
market://{market_id}/unifiedmarket://crypto/unified
market://{market_id}/unified/symbol/{symbol}market://crypto/unified/symbol/BTC
market://{market_id}/derived/regime-transitionsmarket://crypto/derived/regime-transitions
market://{market_id}/derived/strategy-fitnessmarket://crypto/derived/strategy-fitness
market://{market_id}/derived/allmarket://crypto/derived/all

template_resources[*].example field in market://meta/discovery is copy-paste ready — the AI gets concrete URIs without having to fill placeholders manually.

Market IDs: crypto, kr_stock, us_stock (aliases: coin, kr, us)

Sample: Trust Layer query

Tested against the live endpoint with fastmcp 2.14 and 4.0 (pip install fastmcp):

import asyncio, json
from fastmcp import Client

async def main():
    async with Client("https://api.felpra.ai/mcp") as client:
        result = await client.call_tool("get_prediction_accuracy", {})
    resp = json.loads(result.content[0].text)

    print(resp["ai_summary"])
    for cat, markets in resp["full_data"]["summary"].items():
        for market, lags in markets.items():
            for lag, cell in lags.items():
                if cell.get("horizon_type") != "forecast":
                    continue  # lag 0h cells are same-cycle nowcast checks, not forecasts
                lo, hi = cell.get("skill_ci_95") or (float("nan"), float("nan"))
                print(f"{cat:12} -> {market:10} {lag:>4}  hit {cell['accuracy']:.1%}"
                      f"  persistence {cell.get('persistence_accuracy', float('nan')):.1%}"
                      f"  skill CI [{lo:+.2f}, {hi:+.2f}]"
                      f"  beats majority baseline: {cell.get('beats_majority_baseline')}")
    print("edge cells:", len(resp["full_data"]["edge_cells"]))
    print(resp["full_data"]["meta"].get("persistence_null_caveat", ""))
    print(resp["disclaimer"])

asyncio.run(main())

It prints one line per forecast cell: raw hit rate, the persistence null, the skill confidence interval, and whether the cell beats a constant "most common outcome" guess. A conservative reading treats a cell as evidence only when its skill CI lower bound is above 0 and it beats the majority baseline — and read meta.persistence_null_caveat before trusting edge_cells. ai_summary / _llm_summary state the same comparison in one line, and every response carries the disclaimer envelope.

Configuration

All configuration is via environment variables:

VariableDefaultDescription
MCP_SERVER_PORT8010Server port
MCP_SERVER_HOST0.0.0.0Bind host
MCP_LOG_LEVELINFOLog level
MCP_TIER_RESOLVERunsetmodule:function returning tier for an API key (self-host hook)
MCP_TRUSTED_IP_PREFIXESunsetComma-separated address prefixes treated like localhost (no rate limit, internal plan — every tool)
MCP_SELF_TRAFFIC_IPSunsetComma-separated addresses excluded from usage analytics (your own monitors)
MCP_LEDGER_THREAD_DISABLED01 stops the hourly prediction-ledger hash writer (use on a second instance)
MCP_OAUTH_MODE / MCP_OAUTH_ASoffOAuth account connection; needs the hosted account tables
DB_BACKENDpostgresMust be postgres (SQLite backend retired in 0.4.0); serve sets it if unset
PG_HOST / PG_PORTpostgres / 5432PostgreSQL host / port
PG_DB / PG_USER / PG_PASSWORDauto_trader / …PostgreSQL database / credentials (a read-only role is enough)
PG_POOL_MIN / PG_POOL_MAX0 / 50Per-schema connection pool bounds
PG_STATEMENT_TIMEOUT_MS30000Server-side statement timeout
MCP_COIN_DATA_DIR / MCP_KR_DATA_DIR / MCP_US_DATA_DIRautoOverride logical data-path roots (see below)
MCP_EXTERNAL_CONTEXT_DATA_DIRautoOverride external-context logical root

Docker

docker build -t felpra-trading-mcp .
docker run -p 8010:8010 -e DB_BACKEND=postgres -e PG_HOST=... -e PG_PASSWORD=... felpra-trading-mcp

Data backend (PostgreSQL)

All data lives in PostgreSQL 16 + TimescaleDB, one schema per domain (market_coin / market_kr / market_us, market_*_struct, external_context, rl_pipeline, mcp_analytics, …). The code still constructs legacy SQLite-style paths (.../coin_market/data_storage/trading_system.db) but these are logical routing keys only: connect_readonly() maps each path to its PG schema and returns a shim connection, so no .db files are read or written. This mirrors the production Wave-I "PG-only" migration — queries fail loudly instead of silently falling back.

Rate Limits

Authoritative quotas live in Access Policy above. Quick recap:

TierDaily QuotaBurstAuth
Free1,500 / day60 / minnone (an unrecognized key gets HTTP 401)
Pro (beta)50,000 / day200 / minvalid API key
Internal (owner)UnlimitedUnlimitedowner-only
Local (self-hosted)UnlimitedUnlimitedn/a

Response headers on every request:

  • X-RateLimit-Tier: resolved tier (free/pro/internal)
  • X-RateLimit-Daily-Limit: today's ceiling for the resolved tier
  • X-RateLimit-Daily-Remaining: requests left today
  • X-RateLimit-Minute-Remaining: requests left this minute
  • Exceeding limits returns HTTP 429 with Retry-After header.

Privacy

  • Hosted service (api.felpra.ai): the authoritative policy is https://api.felpra.ai/privacy. In short — no account is needed (connecting an AI app to a free FELPRA account is optional); per-request metadata (IP, user-agent, tool name, outcome, whitelisted arguments, client/protocol metadata, API-key fingerprint, and the account identifier if you connected one) is logged; IP addresses and IP-derived session keys are irreversibly replaced after 12 months; data is never sold.
  • Self-hosting: the package sends no telemetry to FELPRA, and request logs go to your PostgreSQL. Replace the bundled /privacy page with your own notice if you expose your deployment.

Details: PRIVACY.md.

Disclaimer

This software is provided for informational and educational purposes only. It is not financial advice.

  • All signals, regime analysis, and market data are generated by automated systems and may contain errors.
  • Signal scores are computed from live market prices and recalculated every 5–15 minutes; they are not tick-by-tick data.
  • Trade, position and P&L figures come from paper trading (simulated, candle-based fills with no fees, taxes or slippage). Real-money results would be lower.
  • Past hit rates and results do not guarantee future outcomes.
  • You are solely responsible for your own investment decisions. The authors and contributors are not liable for any financial losses incurred from using this software.
  • This is not a registered investment advisor, broker-dealer, or financial planner.
  • Always do your own research (DYOR) before making any investment decisions.

By using this software, you acknowledge that you understand and accept these terms.

License

MIT

Source: README.md at commit 5482f25

Tools

21

get_system_card

System Card

Purpose: Start here. One-page card for an agent meeting FELPRA for the first time: what it is (public beta, operated by an individual, SLA: none), coverage (markets, bar intervals, universe sizes), data freshness (ok / degraded per pipeline component), and the measured track record with weak spots. When to call: first, before any other FELPRA tool, or when asked how reliable FELPRA…

Takes no parameters.

get_daily_brief

Daily Market Brief

Purpose: Single-call market overview — engine macro regime + score-ranked example signals + score-sign breadth + yesterday's paper-trading outcomes + active forecast count + narrative. Use this as the first call when answering "how is the market today?". Triggers (call this even for casual questions): "how's the market?", "오늘 장 어때?", "what's the market mood / outlook?", "how's Bitcoin…

Parametersmarket

fetch

Fetch Document

Purpose: ChatGPT-connector-standard document fetch by id from `search` results. Namespaces: `tool:{name}` returns the tool's full documentation and how to call it; `resource:{uri}` returns the resource's live data (core resources resolved server-side — also the bridge for clients without MCP resource support, e.g. Gemini); `signal:{market}:{symbol}` returns the symbol's latest…

Parametersidrequired

get_symbol_context

Symbol Context

Use when the question is about one stock or coin — its current signal state, the FELPRA structure group it belongs to, and which assets have tracked lead-lag links to it. Returns self-contained headline claims first, then the symbol's observed state, upstream links (its group, macro/ETF/basket instruments and symbols that move before it), peers (symbols that follow it), tagged news, and gaps that…

Parameterslimitsymbolrequiredquestionmarket_id

get_group_context

Group Context

Use when the question is about a sector, theme, ETF basket or index basket — its structure state and its members. Returns headline claims, the group's regime state per interval, its market, groups that co-move with it, member symbols with their latest signal bias, symbols the basket leads, and gaps. Not for a single stock (use get_symbol_context) or a whole market (use get_market_context).…

Parametersgrouprequiredlimitquestionmarket_id

get_market_context

Market Context

Use when the question is about a whole market (KR, US, CRYPTO) — its structure regime and how its groups are positioned. Returns headline claims, the market's structure and global macro regime, the macro categories assumed to affect it (with tuned lags), its groups ordered by distance from the middle regime stage, market-tagged news, and gaps. Not for one sector or stock (use get_group_context or…

Parameterslimitmarketrequiredquestion

get_macro_context

Macro Context

Use when the question is about a macro factor — rates and bonds, the dollar and FX, VIX, credit, liquidity, inflation, commodities or energy — and which markets or stocks it is linked to. Returns headline claims, the macro category's regime state per interval and its instruments, macro categories with tracked lead-lag links to it, the markets the engine assumes it affects (tuned priors), symbols…

Parameterslimitmacrorequiredquestion

get_news_context

News Context

Use when the question is about a specific news item or a news keyword or event (FOMC, 반도체, tariff) — which markets, symbols and topics it is tagged with. Returns headline claims, the item (or keyword match counts), its title-similarity cluster, the market, symbol and topic tags assigned by the collection pipeline (counted across matches for a keyword), the matching items, and gaps. Not for market…

Parametersdaysnewsrequiredlimitquestion

get_signals

Trading Signals

Purpose: Query signals with dynamic filters (symbol / interval / action / score / confidence). Triggers (casual questions too): "what's the signal for BTC / AAPL / 삼성전자?", "is X bullish or bearish?", "how does X look right now?". When the user asks whether to trade X, FELPRA gives context (regime, score, measured past hit rate of similar scores), not a conclusion: pass it on as…

Parameterscoinlimitsymbolintervalmarket_idrequiredmin_scorehours_backaction_filter+1 more

explain_decision

Explain a Decision

Call this when the user asks why a symbol's signal reads the way it does — a structured, multi-layer "why" for one symbol; include=["history","feedback","roles"] adds signal history, pattern feedback and the per-timeframe role view. Purpose: Combines (1) technical score_trace from the signals store, (2) Thompson + regime scores from the virtual decision log (Thompson = Bayesian bandit…

Parameterssymbolrequiredincludemarket_idrequired

get_performance_metrics

Performance Metrics

Purpose: Portfolio-level performance metrics (MDD / Sharpe / Sortino / Calmar / monthly returns / equity curve) over a FIXED window — the single canonical computation path shared by the FELPRA blog and external clients. Triggers (casual questions too): "what's the max drawdown?", "MDD 얼마야?", "샤프 비율 보여줘", "monthly returns table?", "트랙레코드 지표", "에쿼티 커브 데이터". When to call: track-record…

Parametersbookmarketrequiredwindow_endaccount_typerequiredwindow_startinclude_daily_curve

get_account_status

Account Status

Purpose: Show which FELPRA account (or API key) this connection uses, its plan and its rate limits. Requires a connected FELPRA account — calling it without one prompts your AI app to connect (free, no API key needed; Pro users can use their key). All other tools work without an account. Triggers: "is my FELPRA account connected?", "what plan am I on?", "내 FELPRA 계정 상태", "남은 호출 한도". When…

Takes no parameters.

get_prediction_accuracy

Prediction Accuracy

Call this first when judging how FELPRA's macro calls have held up — per-cell hit rates with honest baselines; granularity="monthly" for the month-by-month trend. Purpose: Per-cell (category, target_market, lag_bucket) hit rates WITH the honest baselines (schema 1.1): persistence_accuracy (the null model — regimes are sticky, so raw accuracy mostly measures regime persistence, not…

Parameterslimitcompactcategorygranularityforecast_onlytarget_market

get_active_predictions

Active Predictions

Purpose: Currently pending predictions (outcome IS NULL). Demonstrates that FELPRA is actively publishing forecasts in real time. Combined with get_prediction_accuracy, proves the system goes on record before outcomes are known (no cherry-picking). Triggers (casual questions too): "what are you predicting right now?", "지금 어떤 예측 걸려 있어?", "current forecasts?", "예측을 미리 기록해 두는 거야?",…

Parameterslimittarget_market

get_resolved_predictions

Resolved Predictions

Purpose: Raw, row-level prediction ledger — every macro regime prediction's full lifecycle (created_at -> resolved_at -> outcome). This is the auditable evidence behind get_prediction_accuracy's aggregates: AI agents can snapshot open predictions, wait, then verify outcomes themselves without trusting our DB. Triggers: "show me the individual predictions", "prove these forecasts were…

Parametersdaylimitcursorstatustarget_marketsource_category

get_ledger_integrity

Prediction Ledger Integrity

Purpose: Tamper-evidence for the prediction ledger — a daily SHA-256 hash chain over all created/resolved prediction rows, with the exact canonical recipe published so any third party can recompute and verify. Archive a chain_hash today; if history is ever silently edited, recomputation will not match. Triggers: "how do I know these predictions weren't backfilled?", "is the track…

Parametersdays

get_signal_calibration

Signal Calibration

Purpose: Reliability diagram data for Level-1 signal confidence — realized hit rate per confidence bucket ([0.5,0.6) ... [0.9,1.0]) with ECE summary. Lets an agent verify whether a 0.9-confidence signal actually hits ~90%. Triggers (casual questions too): "is your confidence calibrated?", "confidence 0.9 믿어도 돼?", "시그널 확신도 실제 적중률 보여줘", "how reliable are signal confidences?". When…

Parametersvariantintervalmarket_id

get_structure_calibration

Structure Calibration (Level 2)

Call this to see how well sector / ETF-basket direction calls held up against a majority-class baseline; include_history=True adds the day-by-day validation trend. Purpose: Level 2 (ETF / basket / sector granularity — Level 1 is individual symbols) prediction calibration. Returns hit_rate_ema per (market, group, interval, regime_bucket) with sample counts, **plus the majority-class…

Parametersdayslimitmarket_idgroup_nameinclude_history

get_strategy_leaderboard

Strategy Leaderboard

Purpose: Top RL-learned research strategies — GLOBAL pool + per-symbol partition. Layer E evidence (Layer E = strategy-performance tier of the 5-layer trust pyramid). The GLOBAL pool may include synthesized win_rate values, so per_symbol_leaderboard is the primary measured-edge surface for trust auditing. Triggers (casual questions too): "what are the best strategies?", "제일 잘 버는 전략…

Parameterslimittop_nmarket_idmin_tradestarget_marketinclude_per_symbol

get_trade_history

Trade History

Call this to check how the paper-trading book's closed trades actually turned out — realized P&L per trade with action / P&L / time / symbol filters, and outcome="win" | "loss" for winners or losers. Triggers (casual questions too): "what trades happened lately?", "최근 거래 내역 보여줘", "how did the BTC trades go?", "승률 어때?", "show me the trade log", "어디서 잃었어?", "how many trades won this…

Parametersbooklimitsymbolmax_pnlmin_pnloutcomemarket_idrequiredhours_back+1 more

Version history

1
  1. v2.0.0LatestNov 28, 2026

Score

100% 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 daysRequired25 pts
  • Auth declaredRequired10 pts
  • Tools listedRequired15 pts
  • DescriptionRequired15 pts
  • Logo10 pts
  • Documentation15 pts
  • License10 pts

How this score is calculated