
Mcp Nsa
io.github.matematicsolutions由 GitHub 账号 matematicsolutions 发布v1.4.0更新于 Oct 24, 2026
MCP server for Polish administrative court rulings (NSA/WSA) via CBOSA with citations.
概览
让助手在 CBOSA 数据库中检索波兰行政法院(NSA 与 WSA)判例,并获取带引用的完整裁判文书。
- 可以做什么
- 通过三个工具访问波兰行政法院的 CBOSA 数据库:按关键词、案号、法院或日期范围检索;用 get_judgment 按十位十六进制文档 ID 获取完整裁判文书;用 search_by_case 作为案号查询的快捷方式。检索会返回前五份完整裁判文书,包含案号、法院、日期、合议庭、关键词、法律依据和摘录。每次响应都带有结构化引用字段(标题、CBOSA 链接、案号、法院、裁判日期、裁判类型、摘录、文档 ID)。
- 适用场景
- 当助手需要波兰行政判例时适用,例如 UODO 上诉至 WSA 的 GDPR 与数据保护裁决、税务裁定、海关与消费税、行政许可与特许,以及公共行政活动审查。它填补了 SAOS 不收录行政法院的空白。
- 运行要求
- 通过 npx 从 npm 包 @matematicsolutions/mcp-nsa 以 stdio 进程在本地运行,需要 Node.js 18 或更高版本。未声明账户、API 密钥、环境变量或请求头。需要访问 CBOSA 网站(orzeczenia.nsa.gov.pl)的网络连接。
安装
在 SourceWeft 中
- 打开 控制台中的 Mcp Nsa,将其添加到工作区。
- 为需要使用其工具的对话启用该服务。
Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。
其他 MCP 客户端
参照 仓库 中的启动说明。
README
mcp-nsa
Installation (one command)
Published on npm + the MCP Registry (io.github.matematicsolutions/mcp-nsa). Run without cloning:
MCP client configuration (stdio):
(Building from source - below.)
MCP server for the case law of the Polish administrative courts -
Naczelny Sad Administracyjny / NSA (Supreme Administrative Court) + 16 Wojewodzkie Sady Administracyjne / WSA (regional administrative courts) - via CBOSA (Centralna Baza Orzeczen Sadow Administracyjnych - the administrative courts' central case-law database)
(orzeczenia.nsa.gov.pl).
Why
SAOS (the common-courts case-law analysis system) does not index the administrative courts. Yet that is exactly where the substantive case law lives:
- GDPR / data protection - decisions of the President of UODO appealed to the WSA, cassation appeals to the NSA
- Taxes - individual tax rulings, decisions of tax authorities
- Customs and excise
- Administrative permits, concessions
- Review of public-administration activity
mcp-nsa closes this gap. Coverage: 2,390,000+ rulings (verified live 2026-07-08 across the full date range), from 1981 to today.
Tools
search(query, caseNumber?, court?, dateFrom?, dateTo?, pageNumber?)- search by keyword, case number, court, date. Fetches the top 5 full rulings (case number, court, date, panel, keywords, legal basis, excerpt).
get_judgment(doc_id)- full ruling by 10-character hex doc_id (from the CBOSA URL, e.g.7E50984BB7).search_by_case(caseNumber)- shortcut: search by case number (e.g.III OSK 1377/23,I SA/Gl 659/22).
Every response contains structuredContent.citations with the fields:
title, url (CBOSA), case_number, court, judgment_date,
decision_type, snippet, doc_id. Patron reads this field automatically
and surfaces it in the UI panel as the section "Rulings from CBOSA (NSA / WSA - administrative courts)".
Stack
- Node 18+
@modelcontextprotocol/sdk- Stdio transport
https+ regex HTML parser (zero external deps beyond the SDK)- 500 ms throttle between requests (2 req/s)
- SSL:
rejectUnauthorized: false- the CBOSA chain is sometimes incomplete on some machines; public rulings, no PII, MITM risk negligible against the benefit. See: LDH issue #167.
Build + run
Wiring into Patron
In patron/backend/mcp-servers.json (alongside mcp-saos and mcp-eu-sparql):
Smoke test
Should return ~1500 hits + the top 5 with Polish NSA/WSA case numbers + CBOSA URLs
- structuredContent.citations.
Lineage
Implementation rewritten in TypeScript on the basis of the HTTP/HTML contract from
legal-data-hunter/sources/PL/NSA
(Python + BeautifulSoup, MIT). It does not import the source code - it reproduces the
query pattern and HTML parsing.
License
MIT.
Part of MateMatic
This connector queries its source live. It is one of the Polish and EU source connectors bundled in PATRON and works with any MCP client.
- Poland, one server for all sources: prawo-pl-mcp · each source on its own: mcp-saos · mcp-nsa (this repo) · mcp-isap · mcp-krs · mcp-eureka · kio-orzeczenia-mcp
- European Union: mcp-eu-sparql (live) · mcp-eu-compliance (offline corpus)
- A prepared corpus of Polish and EU law with a citation graph: Repertorium
mcp-saos, mcp-nsa, mcp-isap, mcp-krs and mcp-eu-sparql share one structuredContent.citations
contract: each tool returns an array of {title, url, snippet?, ...metadata}
that legal agents can render directly in their citation panel.
See matematicsolutions/.github for the full org profile.
来源:README.md,提交 6a7b1a6
工具
0版本历史
2- v1.4.0最新Oct 13, 2026
- v1.3.0Sep 16, 2026
评分
已满足适用检查项的 50%
该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。
- 近 30 天内可连通25 分
请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。
- 已声明认证方式10 分
请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。
- 已列出工具15 分
请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。
- 描述必需15 分
- 图标10 分
- 文档15 分
- 许可证10 分