Précis-MCP

Précis-MCP

Read-only MCP server for FP&A & management reporting — governed metrics, financial statements and drill-down over a SQL semantic layer. Your own financials on your own warehouse, not market data. Open core of Précis. (metric engine · ClickHouse · OIDC · Docker)

Category
访问服务器

README

precis-mcp

License: Elastic 2.0 MCP CI Docs

A read-only, self-hosted MCP server for FP&A and management reporting: governed metrics, financial statements, and row-level drill-down over a SQL semantic layer — your own warehouse, not market data. The open core of Précis, the agentic Finance Intelligence Platform.

You describe your business metrics once — KPIs, hierarchies, and financial-statement layouts in a YAML catalogue over a semantic layer of plain SQL views, versioned in git — and any MCP-capable client gets consistent, defensible numbers. The semantic views are plain SQL in your ClickHouse, so your existing BI tools can query the same views directly. This repository is complete and self-hostable — the metric engine, semantic layer and catalogue, ingestion, identity, and the MCP transport — and depends on nothing outside it.

Use this if

  • You run or support a finance function and want AI clients — Claude, ChatGPT, or any MCP-capable client — answering questions and pulling management reporting from your own numbers.
  • You need governed metrics — one agreed definition of gross margin, utilisation, or revenue by business unit — not an agent querying raw rows in the general ledger or inventing its own definitions.
  • You want it self-hosted, on infrastructure you already operate and under a security model you control — not another cloud contract.
  • You need every answer traceable: read-only by construction, no figure generated by the model, every number aggregated from semantic views you can read.

Requirements

  • Docker — Engine + Compose v2. Everything runs in containers; there is nothing else to install.
  • No warehouse to provision — the stack bundles ClickHouse (the engine's analytical store) and PostgreSQL (platform state — users, sessions, audit). A local trial runs with nothing else and loads a sample finance model.
  • Already run ClickHouse? — optionally point the engine at your own instance instead of the bundled one; see data modes.
  • An MCP-capable client — Claude (claude.ai and Desktop connectors, against a deployed instance), Claude Code, ChatGPT, or any MCP client.
  • Optional Excel access — the multi-user image also hosts the Précis Excel add-in at /excel; enable its OAuth client when you want live read-only workbook functions.

What precis-mcp looks like

Claude, connected to Précis over MCP, rendering a governed P&L with comparatives and then drilling Revenue down to cost-centre level — sample data

Every figure aggregates from the semantic views — account, cost centre, period, scenario — and the measures generic metric layers can't express (a utilisation denominator averaged across periods, re-aggregated by quarter or business unit, with subtotals in the layout) are first-class catalogue definitions.

Quickstart — single-user local trial

export MCP_DEV_KEY=$(openssl rand -hex 32)
docker compose -f deploy/docker-compose.local.yml up -d --build
docker compose -f deploy/docker-compose.local.yml exec precis-mcp \
  python -m precis_mcp.sample_data   # populate the demo model

One stack — the server plus a bundled ClickHouse and Postgres — a shared dev key, bound to 127.0.0.1. Point any MCP client at http://127.0.0.1:8768/mcp with the dev key as bearer token. For example, with Claude Code:

claude mcp add --transport http precis http://127.0.0.1:8768/mcp \
  --header "Authorization: Bearer $MCP_DEV_KEY"

Then ask a finance-specific question to prove this is not a generic SQL MCP: "Show the P&L for FY2025 with comparatives." · "Drill revenue down by cost centre." · "Show utilisation by month for the Digital Transformation team."

Full walkthrough, including the demo data and bringing your own model: docs/getting-started/quickstart.md.

Rather do this on a call? We pair with early adopters to stand precis-mcp up against their own warehouse — precis.finance or hello@precis.finance.

Multi-user deployment

deploy/docker-compose.yml runs the multi-user stack — the open server, PostgreSQL, ClickHouse, and OAuth 2.1 + PKCE sign-in. Deployment is modular along independent axes:

  • Data — bundled ClickHouse (empty or with sample data) or your own: docs/deployment/clickhouse-data-modes.md
  • Identity — local dev key, the bundled Keycloak (optionally federated to your IdP), or a direct external OIDC provider (Auth0 / Okta / Entra / Ping): docs/deployment/oauth-keycloak.md, docs/deployment/external-idp-recipes.md
  • Ingress — the bundled Caddy proxy (bundled-proxy profile, on by default) terminates TLS with automatic Let's Encrypt certificates from nothing but PRECIS_DOMAIN. The app itself is proxy-agnostic: drop the profile to front it with an ingress you already operate (reference nginx vhost in deploy/nginx/, host helper scripts/install-precis-mcp.sh --nginx)
  • Backups — additive backup compose profile: scheduled bundles (Postgres dump + ClickHouse backup + instance config) to a local volume or S3, with restore and drill commands: docs/operations/backups.md
  • Excel add-in — optional hosted workbook functions served from the same instance at /excel; enable with the bundled Keycloak client or a public client in your external IdP: docs/excel/

scripts/deploy-mcp.sh --data-mode ... --auth-mode ... is the friendly front door over the Compose profiles. Every knob is an environment variable: docs/configuration/environment-variables.md.

Configure your data model

Your model lives in an instance/ directory — metric catalogue, semantic SQL views, ingestion bindings — and the bundled demo instance shows the shape. Start at docs/configuration/catalogue-and-semantic.md, then docs/configuration/ingestion.md and docs/operations/onboarding-ingestion.md to load your data. The developer guide for adding server tools is docs/development/adding-read-tools.md.

Security and read-only posture

Start with the mechanisms, not the promise.

  • Read-only by construction — the server retrieves; it never writes to or changes your source. There is no write path back.
  • No figure is generated by the model — tools return numbers aggregated from source dimensions (account, cost centre, period, scenario), or report that the data isn't there. The client composes the question and narrates the answer; it never invents a figure.
  • Traceable to source — every number traces from response → semantic view → warehouse. The semantic views are plain SQL you can read; the catalogue is versioned in git.
  • Your own warehouse, not market data — it runs in your environment, against your warehouse, under your own access controls.
  • Identity — a local dev key, the bundled Keycloak (optionally federated to your IdP), or a direct external OIDC provider (Auth0 / Okta / Entra / Ping).
  • Operator responsibility — precis-mcp is designed to expose governed read operations; you still deploy and operate it under your own security model. Disclosure policy: SECURITY.md.

Documentation

Full documentation: docs.precis.finance.

Area Start here
Getting started quickstart
Deployment ClickHouse data modes · OAuth / Keycloak · external IdP recipes
Excel Précis for Excel · function reference
Configuration catalogue & semantic layer · ingestion · environment variables
Operations onboarding & ingestion · backups
Development adding read tools
Security SECURITY.md

precis-mcp vs Précis

The deployment and data model you build here are the foundation the full Précis platform runs on. Précis is currently pre-General Availability and adds a licensed agentic workspace over this same engine and data model. Moving from the open core to Précis is workflow configuration and adoption — not a second data-integration project. Précis prepares; the finance professional decides.

What ships — and what doesn't

Ships in precis-mcp (Elastic License 2.0): the MCP server and transport · metric engine · financial-statement layouts · semantic SQL view pattern · YAML metric catalogue · sample finance model · ingestion path · hosted read-only Excel add-in · ClickHouse analytical store · PostgreSQL platform state · local dev-key mode · multi-user OAuth 2.1 mode · Docker Compose deployment · backup & restore profile · configuration and deployment docs.

Lives in Précis, not in this repo: the workspace UI · the conversational agent · plan write-back · scenario commit workflows · scheduled Dispatch briefings · report / management-pack workflow · Excel write-back / round-trip · commercial support (unless separately agreed).

Talk about Précis — the full platform and design-partner programme: precis.finance or hello@precis.finance.

Support and services

precis-mcp is built to be self-serve, and the documentation aims to be enough. If you'd like help beyond it — configuring your data model, a guided deployment, ongoing support, or a demo environment to evaluate against realistic data — book a setup session at precis.finance or write to hello@precis.finance. The same address reaches the team behind the full Précis platform.

Contributing

This repository is a one-way mirror of the Précis monorepo: main advances by sync commits, and pull requests are applied internally with your authorship and DCO sign-off preserved, then published in the next sync. See CONTRIBUTING.md.

License

Elastic License 2.0 — source-available. Free to use, modify, self-host (including commercially), and redistribute; you may not offer it to third parties as a hosted or managed service.

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选