home / mcp / grey swan mcp server
Provides tools to document and analyze Grey Swan Arena LLM safety challenges via MongoDB-backed MCP tooling.
Configuration
View docs{
"mcpServers": {
"gravityphone-swanzmcp": {
"command": "node",
"args": [
"/path/to/SwanzMCP/build/index.js"
],
"env": {
"PORT": "3000",
"MONGODB_URI": "mongodb://localhost:27017/greyswan"
}
}
}
}You have a MongoDB-integrated MCP server designed to document and analyze LLM safety challenges as part of the Grey Swan Arena. It provides structured tools to log testing sessions, document jailbreak attempts, flag potentially harmful interactions, and query collected data for analysis and comparison across techniques.
Set up and run the Grey Swan LLM Safety Challenge MCP Server in your environment, then connect to it with an MCP client to create organizational sessions, thread discussions, and messages. You can document each safety challenge, attach metadata such as tags and context, flag unsafe content, and query for specific patterns (e.g., prompt-injection or social-engineering cases). Use the provided tools to organize sessions, track the lifecycle of challenges, and analyze results across multiple threads and messages.
Typical usage flow: create an organizational identifier for a testing session, start a thread with an initial safety challenge, add user messages and model responses, and then progressively annotate with safety flags and new challenges as you analyze attempts. You can later query threads and messages to identify high-severity cases or to review historical jailbreak techniques.
Prerequisites you need before installation are: node.js v14 or higher, MongoDB v4.4 or higher, and Cursor IDE for MCP client integration.
Step-by-step setup to run the MCP server locally:
npm installThe MCP server is designed to connect to a MongoDB instance. Use a local MongoDB URI and set the port for the server. The environment example shows how to configure these values for a typical local setup.
Example environment variables to run locally can include the MongoDB connection string and the port you want the MCP server to listen on.
Document safety challenges with clear tags and detailed descriptions. Use severity levels (low, medium, high) consistently and keep status tracking up to date as you work through identified, mitigated, or unresolved challenges. Always flag potentially harmful messages to build a comprehensive safety dataset and enable focused analysis.
If you encounter connectivity issues, verify that MongoDB is running and that the MONGODB_URI in your environment matches your local instance. Ensure the server process is started using the exact command and path described in your setup. Check logs for any authentication errors or port conflicts and adjust environment values accordingly.
The server supports several MongoDB tools to manage data: creating organizational identifiers, threads, and messages, as well as querying models, threads, and messages. Use these tools in sequence to document a complete safety scenario from session creation to analysis.
Creates or updates organizational identifiers for your testing sessions
Creates or updates conversation threads with safety challenges
Creates or updates messages in threads, including safety flags
Queries organizational identifiers from the database
Queries threads from the database with various filters
Queries messages from the database