OpenTK Model Context Protocol Server

OpenTK Model Context Protocol Server

A standardized interface for LLMs to access Dutch parliamentary data.

16
Stars
3
Forks
16
Watchers
0
Issues
OpenTK Model Context Protocol Server provides a bridge between large language models and Dutch parliamentary data using the Model Context Protocol (MCP). It enables AI systems to access, search, and analyze parliamentary documents, debates, and member information from the Tweede Kamer through a unified and structured interface. By leveraging the @modelcontextprotocol/sdk, it ensures consistent context management for model interactions. Built atop the OpenTK project, it delivers streamlined access to extensive open government datasets.

Key Features

Standardized MCP interface for contextual model queries
Access to Dutch parliamentary documents, members, and debates
Integration with large language models
Search and retrieval of legislative information
Smart analysis and triage of multiple documents
Extraction of topics, keywords, and party associations
Support for scheduled activity and committee membership queries
Fast identification of relevant legislative content
Attribution and derivation from the OpenTK project
Consistent context management for AI assistants

Use Cases

Comparing party positions on specific policy topics
Researching parliamentary discussions on climate change
Analyzing an MP’s voting record and motions
Identifying recent developments in housing legislation
Triage and smart analysis of multiple parliamentary documents
Extracting main topics from legislative records
Finding MPs with overlapping committee memberships
Tracking upcoming parliamentary activities and debates
Enabling LLMs to factually ground responses on Dutch parliamentary sources
Supporting legislative and political research for journalists or policy makers

README

OpenTK Model Context Protocol Server

Important Attribution: This MCP server is built as a wrapper around the excellent OpenTK project created by Bert Hubert. The OpenTK project provides unprecedented access to Dutch parliamentary data through a user-friendly interface. Learn more about the project in Bert's article: Welkom bij OpenTK. All credit for the underlying data access and processing goes to Bert Hubert and his contributions to open government data.

A bridge between large language models (LLMs) and Dutch parliamentary data through a standardized interface. This MCP server provides access to Dutch parliamentary documents, debates, and member information from the Tweede Kamer.

Real-World Natural Language Interaction Examples

Example 1: Comparing Party Positions on AI Policies

User Query: "When comparing the activities of opposition parties PvdA, GroenLinks, and Volt with government party BBB in the Dutch House of Representatives in the field of AI, what are actions they can undertake together in the short term that align with the positions and views they have demonstrated over the past year? Please use sources from OpenTK."

Example 2: Researching Parliamentary Discussions on Climate Policy

User Query: "I'd like to analyze recent parliamentary debates on climate policy and emission reduction targets in the Netherlands. Can you help me identify key discussions and the main positions taken by different parties over the past six months?"

Example 3: Information About a Specific MP's Voting Record

User Query: "What is MP Pieter Omtzigt's voting record on healthcare reform legislation, and how does his position differ from other independent members? Has he introduced any motions on this topic?"

Example 4: Finding Recent Housing Legislation Developments

User Query: "What are the most significant parliamentary documents and debates about affordable housing legislation from the past year? I'm particularly interested in proposals addressing the rental market crisis."

Example 5: Efficiently Triaging Multiple Documents (NEW - Smart Analysis)

User Query: "I found 15 documents about climate policy from the last month. Can you quickly identify which 3 documents are most relevant to renewable energy subsidies and wind power legislation, without reading all of them in full?"

Example 6: Extracting Key Topics from Parliamentary Documents (NEW - Smart Analysis)

User Query: "What are the main topics, keywords, and political parties mentioned in document 2024D39058? I want to understand what it's about before diving into the full text."

Example 7: Finding MPs with Specific Committee Memberships

User Query: "Which MPs currently serve on both the Finance Committee and the Economic Affairs Committee? What parties do they represent, and have they recently submitted any joint initiatives?"

Example 8: Identifying Upcoming Parliamentary Activities on Digital Security

User Query: "Are there any scheduled committee meetings or debates about cybersecurity and digital infrastructure planned for the next month? Which ministers will be participating and what specific topics will be addressed?"

Project Concept

The OpenTK project is a Model Context Protocol (MCP) server that provides access to Dutch parliamentary data through a standardized interface. It serves as a bridge between large language models (LLMs) and the Dutch Parliament's information systems, allowing AI assistants to search, retrieve, and analyze parliamentary documents, debates, and member information.

The server uses the @modelcontextprotocol/sdk to implement the MCP specification, which enables structured communication between AI models and external data sources. By exposing parliamentary data through well-defined tools and endpoints, OpenTK makes it possible for AI assistants to:

  1. Search for parliamentary documents using complex queries
  2. Access information about Members of Parliament
  3. Retrieve official documents in various formats and read the full content of the documents
  4. Analyze parliamentary activities and proceedings
  5. Track legislative cases and government pledges
  6. Intelligently analyze document relevance using NLP before loading full content (NEW in v1.0.16)
  7. Extract keywords, entities, and topics for efficient document triage (NEW in v1.0.16)

The project leverages Bert Hubert's tkconv service as its primary data source, which provides a more accessible API than the official Dutch Parliament APIs.

Features

Core Parliamentary Data Access

  • Search parliamentary documents with advanced query capabilities (quotes, NOT, OR, NEAR operators)
  • Access comprehensive MP information and committee memberships
  • Retrieve full document content (PDF, Word) with smart chunking
  • Track legislative cases, government activities, and voting results
  • Real-time access to parliamentary proceedings and upcoming activities

Smart Document Analysis (NEW in v1.0.16) 🎯

  • NLP-Powered Relevance Analysis: Intelligently analyze documents before loading full content
  • TF-IDF Keyword Extraction: Identify the top 10-15 most important terms in any document
  • Dutch-Optimized Entity Recognition: Automatically detect persons (MPs, ministers), political parties (VVD, PVV, CDA, D66, etc.), and organizations
  • Topic Categorization: Classify documents across 10 major political themes (Climate, Economy, Healthcare, Education, etc.)
  • Relevance Scoring: Rank documents by relevance to specific search terms (0-100 score)
  • Context-Efficient Triage: Reduce context window usage by 80-90% when evaluating multiple documents

Advanced Document Navigation

  • Find specific person occurrences with fuzzy matching
  • Find party mentions with fuzzy matching
  • Navigate large documents efficiently with character offsets
  • Sequential reading with pagination support

Available Tools

OpenTK provides 17 specialized tools for accessing Dutch parliamentary data:

Overview & Discovery

  • get_overview: Comprehensive overview of recent parliamentary activities and MP birthdays (paginated)
  • birthdays_today: List MPs celebrating birthdays today
  • list_persons: Complete directory of current MPs with party affiliations

Search & Filter

  • search_tk: Comprehensive search across all parliamentary data with advanced query syntax
  • search_tk_filtered: Search within specific categories (Document, Activiteit, Zaak)
  • search_by_category: Search for specific document types (questions, motions, all)

Document Intelligence (NEW) 🎯

  • analyze_document_relevance: NLP-powered document analysis with keyword extraction, entity recognition, and relevance scoring
  • get_document_content: Retrieve document content (PDF/DOCX) with three reading modes (targeted, sequential, full)
  • find_person_in_document: Locate all occurrences of a person in a document with fuzzy matching
  • find_party_in_document: Locate all occurrences of a political party in a document

Document Metadata

  • get_document_details: Retrieve structured metadata about documents
  • get_document_links: Convert document URLs to clickable markdown links

Parliamentary Structure

  • get_committees: List all parliamentary committees
  • get_committee_details: Detailed information about specific committees

Activities & Voting

  • get_upcoming_activities: Upcoming parliamentary debates and meetings
  • get_voting_results: Recent voting results with party positions

Media

  • get_photo: Retrieve official MP portrait photographs

Installation

1. Quick Start with NPM Package (Recommended)

The fastest way to get started is using the published npm package:

bash
npx @r-huijts/opentk-mcp

2. Using Claude Desktop with NPM Package

Update your Claude configuration file (~/Library/Application Support/Claude/claude_desktop_config.json):

json
{
  "mcpServers": {
    "opentk": {
      "command": "npx",
      "args": [
        "-y",
        "@r-huijts/opentk-mcp"
      ]
    }
  }
}

Alternative configurations:

For MultiServerMCPClient (Python):

python
mcp_client = MultiServerMCPClient({
    "opentk": {
        "command": "npx",
        "args": ["-y", "@r-huijts/opentk-mcp"],
        "transport": "stdio",
    }
})

3. From Source (Development)

If you want to modify the code or contribute to development:

Clone Repository:

bash
git clone https://github.com/r-huijts/opentk-mcp.git
cd opentk-mcp

Install Dependencies:

bash
npm install

Build the Project:

bash
npm run build

Start the Server:

bash
npm start

Configure Claude Desktop for local development:

Update your Claude configuration file:

json
{
  "mcpServers": {
    "opentk-local": {
      "command": "node",
      "args": [
        "/absolute/path/to/your/opentk-mcp/dist/index.js"
      ]
    }
  }
}

Make sure to replace /absolute/path/to/your/opentk-mcp/ with the actual path to your installation.

4. Publishing (for maintainers)

To publish a new version of the scoped package:

bash
npm run build
npm publish --access=public

Note: Scoped packages require the --access=public flag to be publicly available.

Search Functionality

The search functionality is particularly sophisticated, supporting:

  • Simple keyword searches: kunstmatige intelligentie
  • Exact phrase searches: "kunstmatige intelligentie"
  • Exclusion searches: Hubert NOT Bruls
  • Boolean operators: OR, NEAR()

The implementation handles various edge cases:

  • Preserves quotes in search queries
  • Uses proper content type headers
  • Implements fallback mechanisms for API errors
  • Provides meaningful error messages

Error Handling

The API service includes robust error handling:

  • Graceful handling of API errors (4xx, 5xx)
  • Fallback to simplified queries when complex ones fail
  • Detailed error messages for debugging
  • Proper logging to stderr (not stdout, which would break the stdio transport)

Configuration

The server connects to Bert Hubert's tkconv service as its primary data source, which provides a more accessible API than the official Dutch Parliament APIs. This service, created by Bert Hubert, does the heavy lifting of collecting, organizing, and making available Dutch parliamentary data in a developer-friendly format. Our MCP server builds upon this foundation to create a standardized interface for AI assistants to interact with this valuable data.

License

MIT

Conclusion

The OpenTK MCP server provides a robust and well-structured interface to Dutch parliamentary data, making it accessible to AI assistants through the Model Context Protocol. Its modular design, comprehensive API, NLP-powered document analysis (v1.0.16), and thorough testing ensure reliable access to parliamentary information for AI-assisted research, analysis, and information retrieval.

Once configured, Claude will be able to access Dutch parliamentary data through the OpenTK MCP server using all 17 specialized tools for search, document analysis, MP information, committee tracking, voting results, and more.

Star History

Star History Chart

Repository Owner

r-huijts
r-huijts

User

Repository Details

Language HTML
Default Branch main
Size 1,851 KB
Contributors 2
License MIT License
MCP Verified Nov 12, 2025

Programming Languages

HTML
73.97%
TypeScript
14.32%
JavaScript
10.92%
CSS
0.78%

Join Our Newsletter

Stay updated with the latest AI tools, news, and offers by subscribing to our weekly newsletter.

We respect your privacy. Unsubscribe at any time.

Related MCPs

Discover similar Model Context Protocol servers

  • ORKL MCP Server

    ORKL MCP Server

    A Model Context Protocol server for threat intelligence queries via the ORKL API.

    ORKL MCP Server is an implementation of the Model Context Protocol (MCP) designed for seamless integration with MCP-compatible applications. It enables secure querying of the ORKL API, offering tools to fetch and analyze threat reports, threat actors, and intelligence sources. The server streamlines access to detailed cyber threat data for security operations and research.

    • 45
    • MCP
    • fr0gger/MCP_Security
  • Wanaku MCP Router

    Wanaku MCP Router

    A router connecting AI-enabled applications through the Model Context Protocol.

    Wanaku MCP Router serves as a middleware router facilitating standardized context exchange between AI-enabled applications and large language models via the Model Context Protocol (MCP). It streamlines context provisioning, allowing seamless integration and communication in multi-model AI environments. The tool aims to unify and optimize the way applications provide relevant context to LLMs, leveraging open protocol standards.

    • 87
    • MCP
    • wanaku-ai/wanaku
  • Offorte MCP Server

    Offorte MCP Server

    Bridge AI agents with Offorte proposal automation via the Model Context Protocol.

    Offorte MCP Server enables external AI models to create and send proposals through Offorte by implementing the Model Context Protocol. It facilitates automation workflows between AI agents and Offorte's proposal engine, supporting seamless integration with chat interfaces and autonomous systems. The server provides a suite of tools for managing contacts, proposals, templates, and automation sets, streamlining the proposal creation and delivery process via standardized context handling. Designed for extensibility and real-world automation, it leverages Offorte's public API to empower intelligent business proposals.

    • 4
    • MCP
    • offorte/offorte-mcp-server
  • Scrapeless MCP Server

    Scrapeless MCP Server

    A real-time web integration layer for LLMs and AI agents built on the open MCP standard.

    Scrapeless MCP Server is a powerful integration layer enabling large language models, AI agents, and applications to interact with the web in real time. Built on the open Model Context Protocol, it facilitates seamless connections between models like ChatGPT, Claude, and tools such as Cursor to external web capabilities, including Google services, browser automation, and advanced data extraction. The system supports multiple transport modes and is designed to provide dynamic, real-world context to AI workflows. Robust scraping, dynamic content handling, and flexible export formats are core parts of the feature set.

    • 57
    • MCP
    • scrapeless-ai/scrapeless-mcp-server
  • Web3 MCP

    Web3 MCP

    A Model Context Protocol server for unified blockchain data access.

    Web3 MCP is a Model Context Protocol server that provides access to blockchain data through Ankr's Advanced API. It allows large language models to interact seamlessly with multiple blockchain networks such as Ethereum, BSC, Polygon, and Avalanche. With support for NFT, token, and blockchain query APIs, it enables users and AI agents to retrieve on-chain data, statistics, and analytics efficiently within an MCP context.

    • 3
    • MCP
    • tumf/web3-mcp
  • mcp-recon

    mcp-recon

    Conversational reconnaissance interface and MCP server for HTTP and ASN analysis.

    mcp-recon acts as a conversational interface and Model Context Protocol (MCP) server, enabling seamless web domain and ASN reconnaissance through natural language prompts. It integrates powerful tooling like httpx and asnmap to conduct lightweight or full HTTP analysis and ASN lookups, exposing these capabilities to any MCP-compatible AI assistant. With predefined prompts and Docker-based deployment, it streamlines infrastructure analysis via AI interfaces such as Claude Desktop.

    • 22
    • MCP
    • nickpending/mcp-recon
  • Didn't find tool you were looking for?

    Be as detailed as possible for better results