Spaces:
Sleeping
A newer version of the Gradio SDK is available:
6.9.0
π₯ NurseLex MCP Server Setup Guide
Welcome to the NurseLex MCP Server! This server uses the Model Context Protocol (MCP) to inject the entire i.AI Lex UK legislative database directly into your favorite AI Assistant (like Claude Desktop or Cursor).
When connected, your AI assistant gains three powerful real-time tools:
search_local_nursing_cache: Instantly retrieves the exact statutory text for 1,128 critical nursing sections (Mental Health Act, Care Act, etc.).get_official_explanatory_note: Fetches the official UK Government plain English explainer for a specific Act and section.vector_search_lex_api: A semantic search engine that maps clinical, plain-English scenarios (e.g., "patient lacks capacity to consent to treatment") to relevant national laws.
π οΈ Prerequisites
- You must have Python 3.10+ installed.
- Install the required dependencies:
pip install mcp fastmcp httpx pandas
π Connecting to Claude Desktop
To let Claude Desktop use NurseLex as a knowledge tool, you need to edit your claude_desktop_config.json file.
1. Locate your Config File
- Windows:
%APPDATA%\Claude\claude_desktop_config.json - Mac:
~/Library/Application Support/Claude/claude_desktop_config.json
2. Add the NurseLex Server
Open the file in a text editor and add the following configuration to your mcpServers block.
Make sure to replace /path/to/NurseLex with the actual folder path where you downloaded the project!
{
"mcpServers": {
"nurselex": {
"command": "python",
"args": [
"/path/to/NurseLex/mcp_server.py"
]
}
}
}
3. Restart Claude
Fully close and restart the Claude Desktop app. You should now see a π¨ (hammer) icon in the chat bar indicating the tools are loaded!
π±οΈ Connecting to Cursor IDE
If you are a Nurse Citizen Developer building applications in Cursor, you can add NurseLex to help write legally compliant code!
- Open Cursor Settings (Cmd + Shift + J on Mac, Ctrl + Shift + J on Windows).
- Go to the Features -> MCP section.
- Click + Add New MCP Server.
- Set the following:
- Name:
NurseLex - Type:
command - Command:
python /path/to/NurseLex/mcp_server.py(Use the absolute path to your folder).
- Name:
- Click Save and verify the connection is green.
You can now ask Cursor Agent: "Write a Python function that uses NurseLex to find the legal requirements for Section 136 of the MHA."