MP

matematicsolutions/prawo-pl-mcp

开发工具

本页由 AI 翻译,技术细节请以原文为准。 查看原文

6 stars 3 forks 质量 78 趋势 28Apache-2.0

One MCP server for Polish legal data - courts, legislation, KRS, tax rulings, KIO, UODO behind 4 unified tools

概览

Ten independent connectors - case law, legislation, the company register, tax rulings, public procurement, data-protection decisions, plus EU extras - behind five tools. Each connector stays a separate package with its own repository; this server spawns them on demand and translates between their conventions. "Prawo" is Polish for "law"; the name follows yargi-mcp's move of naming a country server in its own language. The connectors cover Polish legal data well, but as separate MCP servers, one per database - ten installs and ten config entries before the first question. yargi-mcp showed the fix for Turkish law: 16 institutions, one server. prawo-pl-mcp does the same for Poland: - Five tools instead of 42. pl_list_sources, pl_search, pl_get_document, pl_call and pl_coverage - fewer tool schemas means less context spent before the LLM starts working. - One convention.

README

以下为原文 README 节选,完整内容请查看原文。

prawo-pl-mcp

One MCP server for Polish legal data.

Ten independent connectors - case law, legislation, the company register, tax rulings, public procurement, data-protection decisions, plus EU extras - behind five tools. Each connector stays a separate package with its own repository; this server spawns them on demand and translates between their conventions.

“Prawo” is Polish for “law”; the name follows yargi-mcp’s move of naming a country server in its own language.

Why an aggregator

The connectors cover Polish legal data well, but as separate MCP servers, one per database - ten installs and ten config entries before the first question. yargi-mcp showed the fix for Turkish law: 16 institutions, one server. prawo-pl-mcp does the same for Poland:

  • Five tools instead of 42. pl_list_sources, pl_search, pl_get_document, pl_call and pl_coverage - fewer tool schemas means less context spent before the LLM starts working.
  • One convention. The connectors grew organically: dateFrom here, date_from there, pages counted from 0 or from 1 depending on the repo. Here page is always 1-based and dates are always date_from/date_to (YYYY-MM-DD); the translation happens inside. One name per concept applies to the aggregator’s own tools too: page is the page parameter of both pl_search and pl_get_document (page_number still works as a deprecated alias), and pl_call takes arguments or its alias args.
  • Native names on the table. Every catalog entry carries native_params - the native parameter name each unified one maps to for that source, so article_number (eu-compliance) is visible without spawning the connector or reading an upstream error. pl_call checks the names it was given against the connector’s own schema and says which one it meant.
  • Nothing preinstalled. Connectors run as subprocesses via npx -y / uvx, downloaded on the first call to a given source and kept alive afterwards. A source that cannot start reports a readable error while the rest keep working.
  • Paginated documents. Full judgment and act texts are chunked at ~5000 characters per page (yargi-mcp’s pattern), so a 200-page ruling does not flood the context window. Sources that paginate server-side (isap) get the page forwarded natively and are reported as pagination: "native" - the aggregator does not re-cut an already-cut page and does not invent a total_pages it cannot know.

Coverage

Source id What Institution / database Connector Runtime
saos Case law: common courts, Supreme Court, Constitutional Tribunal + citator SAOS mcp-saos npx
在 GitHub 查看完整 README

安装

uvx prawo-pl-mcp
新手?先看 mcpskill.org 教程 →

配置

{ "mcpServers": { "pl-legal": { "command": "uvx", "args": ["prawo-pl-mcp"] } } }