personality-test-mcp
Administer personality tests and provide assessments based on user responses. Score responses according to established personality frameworks and enable personalized AI feedback.
Author

devshark
Quick Info
Actions
Tags
Personality Test MCP Server
This is a Model Context Protocol (MCP) implementation for personality testing. It allows AI models to administer personality tests, score responses, and provide personality type assessments.
Features
- Administers a personality questionnaire to users
- Scores responses according to established personality frameworks
- Returns personality type and brief descriptions
- Integrates with Ollama for personalized AI interactions
- Allows users to go back and change previous answers
Components
Server
The MCP server handles: - Serving personality test questions - Processing and scoring user responses - Determining personality types - Storing user profiles (optional)
Client
The client interface allows: - Users to take the personality test - Viewing results and personality descriptions - Integration with Ollama for personalized interactions
Personality Framework
This implementation uses a simplified version of the Myers-Briggs Type Indicator (MBTI) framework, which categorizes personalities along four dimensions:
- Extraversion (E) vs. Introversion (I): Where you focus your attention and get energy
- Sensing (S) vs. Intuition (N): How you take in information
- Thinking (T) vs. Feeling (F): How you make decisions
- Judging (J) vs. Perceiving (P): How you deal with the outer world
The combination of preferences results in 16 distinct personality types (e.g., INTJ, ESFP).
Getting Started
Prerequisites
- Python 3.8 or higher
- pip (Python package manager)
- Ollama (optional, for personalized AI interactions)
Installation and Setup
-
Clone the repository:
bash git clone https://github.com/yourusername/model-context-protocols.git cd model-context-protocols/personality-test-mcp -
Create and activate a virtual environment: ```bash python3 -m venv venv
# On macOS/Linux source venv/bin/activate
# On Windows venv\Scripts\activate ```
- Install dependencies:
bash pip install -r requirements.txt
Running the Server
- Start the MCP server:
bash cd server python app.pyThe server will start on http://localhost:8000
Running the Client
-
In a new terminal, activate the virtual environment:
bash cd personality-test-mcp source venv/bin/activate # On macOS/Linux -
Run the basic client:
bash cd client python mcp_client.py
Using Ollama Integration
If you have Ollama installed and running:
-
Make sure Ollama is running:
bash ollama serve -
Run the Ollama integration client:
bash cd client python ollama_integration.py --model llama3You can replacellama3with any model you have available in Ollama.
Using the Demo Script
For convenience, you can use the provided demo script:
-
Make the script executable:
bash chmod +x run_demo.sh -
Run the demo:
bash ./run_demo.sh
This script will: - Set up a virtual environment - Install dependencies - Start the server - Run either the basic client or Ollama integration (if Ollama is detected)
Docker Support
You can also run the server using Docker:
docker build -t personality-test-mcp .
docker run -p 8000:8000 personality-test-mcp
Usage with AI Models
AI models can use this MCP to: 1. Administer personality tests to users 2. Retrieve personality profiles for personalized interactions 3. Adjust communication style based on personality preferences
API Endpoints
POST /mcp: Main MCP endpoint for personality test interactionsGET /health: Health check endpoint
License
This project is licensed under the ISC license.
Author
© Anthony Lim
