mcp-server-fca-compliance

99blakeD99/mcp-server-fca-compliance

3.3

If you are the rightful owner of mcp-server-fca-compliance and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to henry@mcphub.com.

The FCA Compliance MCP Server is designed to provide AI Agent Oriented compliance intelligence specifically for the FCA Handbook, as part of the Universal_FSCompliance_MCP Project.

Tools
7
Resources
0
Prompts
0

MCP Server FCA Compliance

License: MIT Python MCP

๐Ÿš€ Professional FCA compliance intelligence for financial services Part of the Universal_FSCompliance_MCP Project

๐ŸŽฏ Overview

The mcp-server-fca-compliance implements FCAscraperUtility/EmbeddingStrategy.md and FCAscraperUtility/ToolSearchMethod.md to enable Compliance Officers and other professionals to search the FCA Handbook with AI-powered semantic intelligence.

Key Features:

  • Unified Embedding Architecture: OpenAI text-embedding-3-large for operational simplicity
  • BYOLLM Security: Zero-trust credential architecture
  • Perfect MCP Mirroring: Web interface exactly replicates MCP functionality
  • Professional Standards: Enterprise-grade security and audit compliance

๐Ÿš€ FCA Compliance Tool

โœ… Single Unified Tool

  • FCA_compliance_query - Comprehensive FCA Handbook intelligence with unified search methodology

Architecture Evolution: Moved from 7 specialized tools to 1 unified tool implementing the ToolSearchMethod.md strategy:

  • Unified Semantic Search: Single embedding model with intelligent query classification
  • Piece-Priority Weighting: Hierarchical scoring based on FCA regulatory authority structure
  • Authoritative URLs: All results include direct links to official FCA Handbook sources
  • Professional Decision Support: Balanced comprehensiveness with operational efficiency

๐Ÿ“ฆ Build Commands

Installation

# Install Poetry (dependency management)
curl -sSL https://install.python-poetry.org | python3 -

# Install dependencies
poetry install

# Activate virtual environment
poetry shell

Development

# Format code
poetry run black .

# Lint code
poetry run ruff check .

# Run tests
poetry run pytest

# Run with coverage
poetry run pytest --cov=fca_compliance

MCP Server

# Start FCA Compliance MCP server
poetry run python -m mcp_server_fca_compliance.server

# Test FCA Compliance MCP server
poetry run python -m mcp_server_fca_compliance.test_client

๐Ÿ—๏ธ Architecture

Unified Embedding Architecture (2025)

Following EmbeddingStrategy.md specifications:

  • Single Model: OpenAI text-embedding-3-large (1536 dimensions)
  • Semantic Coherence: Same embedding model for queries and FCA Handbook data
  • Operational Simplicity: API-based embeddings, no local ML dependencies
  • Memory Efficient: <200MB deployment footprint (vs >8GB with local models)

BYOLLM Security Architecture

Zero-Trust Credential Handling following professional IT standards:

  • No Server Storage: LLM credentials never stored in server memory or environment
  • Per-Request Authentication: Credentials provided with each request via user_context
  • Radical Anti-Harvesting: Architecture fundamentally excludes credential harvesting
  • Professional IT Compliance: Designed to pass enterprise security audits

Performance Characteristics

  • Response Time: <5 seconds for quick checks, <30 seconds for comprehensive analysis
  • Async Logging: <5ms overhead, never blocks tool execution
  • Concurrent Users: Designed for 50+ simultaneous connections
  • Data Retention: 7yr compliance audit, 3yr operational, 1yr research
  • GDPR Compliance: Data export, rectification, and deletion endpoints

๐Ÿณ Deployment

Docker (Essential)

FROM python:3.11-slim
COPY . /app
WORKDIR /app
RUN pip install poetry && poetry install
EXPOSE 8001
CMD ["poetry", "run", "python", "-m", "mcp_server_fca_compliance.server"]

Cloud Deployment

Memory Requirements: <200MB (unified embedding architecture) Build Time: ~3 minutes Platforms: Render, Railway, Fly.io, AWS Fargate, Google Cloud Run

Note: Docker-compose.yml under development for local testing

๐ŸŒ FCA_compliance_query_web

Purpose: Web interface providing MCP server functionality preview before enterprise integration.

Architectural Requirements:

  • Perfect MCP Mirroring: Web interface faithfully replicates MCP server functionality via Docker
  • Identical Tool Behavior: Same tools with identical responses and error handling
  • BYOLLM Consistency: Same zero-trust credential architecture
  • Docker Configuration: Single source of truth through containerized replication
  • User Experience: Seamless transition from web testing to MCP integration
  • Security Parity: Same professional IT security standards
# Run web interface
cd web
python main.py
# Visit http://localhost:10000

๐Ÿ’ฐ Usage Metering and Billing Architecture

Enterprise usage tracking aligned with Charging.md specifications:

  • Billing Categories: Map tools to categories ('basic_query', 'analysis', 'report', 'validation')
  • Complexity Tiers: Classify queries ('simple', 'medium', 'complex') for tiered pricing
  • Pricing Alignment: Record applicable rates (currently 0.00) and subscription tiers
  • Allowance Tracking: Monitor usage against subscription allowances and overages
  • Rate Limiting: Configurable quotas per organization with hourly rate limits
  • Configuration-Driven: External pricing config without code deployment

๐Ÿ” BYOLLM Architecture (Mandatory)

Supported LLM Providers:

  • OpenAI: GPT-4, GPT-3.5-turbo
  • Anthropic: Claude-3.5-sonnet, Claude-3-opus
  • Azure OpenAI: Enterprise GPT models
  • OpenAI-Compatible: LLAMA, Mistral, vLLM, Ollama, fine-tuned models
# Example: Using fine-tuned model
user_context = {
    'byollm_provider': BYOLLMProvider(
        provider_type='openai-compatible',
        api_key='optional-for-local',
        base_url='https://your-llama-server.com/v1'
    )
}

๐Ÿงช Testing

# Run all tests
poetry run pytest

# Run specific tests
poetry run pytest test_embedding_architecture.py
poetry run pytest test_byollm_security.py

๐Ÿ“„ License

MIT License - see LICENSE file for details.

๐Ÿ‘ค About

Author: Blake Dempster, Founder, CEO, Principal Architect Project: Universal_FSCompliance_MCP Architecture: Unified Embedding Strategy Security: BYOLLM Zero-Trust Design Contact: dev@jbmd.co.uk


๐Ÿš€ Generated with Claude Code