Skip to main content
Glama
bradfair

Cline Personas MCP Server

by bradfair

Cline Personas MCP Server

An MCP server for managing .clinerules files using shared components and persona templates.

Features

  • Component Management: Create, read, update and delete reusable components

  • Persona Templates: Define persona templates with mustache-style variable substitution

  • Dependency Validation: Ensure persona templates only reference existing components

  • Activation System: Activate personas by writing to .clinerules file

  • Version Tracking: Track versions for both components and personas

  • File-based Storage: Store components and personas as JSON files

Related MCP server: Agent Factory MCP

Installation

  1. Clone the repository

  2. Install dependencies:

npm install
  1. Build the project:

npm run build

Usage

Managing Components

import { ComponentPersonaService } from './src/service';

const service = new ComponentPersonaService(process.cwd());

// Create a new component
service.setComponent('greeting', 'Welcome message', 'Hello {{name}}!', 1);

// Get a component
const component = service.getComponent('greeting');

// List all components
const components = service.listComponents();

Managing Personas

// Create a new persona
service.setPersona(
  'welcome',
  'Welcome persona',
  '{{greeting}}\nPlease enjoy your stay!',
  1
);

// Activate a persona
service.activatePersona('welcome');

// Get active persona
const active = service.getActivePersona();

File Structure

.cline-personas/
  components/
    [component-name].json
  personas/
    [persona-name].json
src/
  component.ts    # Component class and operations
  persona.ts      # Persona class and template rendering
  service.ts      # Main service implementation
  index.ts        # MCP server entry point
test/             # Unit tests

API Documentation

ComponentPersonaService

The main service class providing all operations:

  • Component Operations:

    • setComponent(name, description, text, version)

    • getComponent(name)

    • listComponents()

    • deleteComponent(name)

  • Persona Operations:

    • setPersona(name, description, template, version)

    • getPersona(name)

    • listPersonas()

    • deletePersona(name)

    • activatePersona(name)

    • getActivePersona()

    • renderPersona(name)

Development

Run tests:

npm test

Build the project:

npm run build

Run the MCP server:

npm start

Maintenance

ActivityInactive
ResponsivenessNo issues

Related MCP Connectors

Related MCP Servers

  • A
    license
    B
    quality
    F
    maintenance
    A universal MCP server that automatically discovers and registers CLI tools as AI-powered agents with persona configuration, enabling any CLI tool to be used as an MCP tool.
    4
    1
    MIT
  • A
    license
    Not graded
    quality
    D
    maintenance
    An MCP server that performs automated code reviews by analyzing git diffs against configurable review standards with custom reviewer personas.
    2
    MIT
  • A
    license
    Not graded
    quality
    A
    maintenance
    A self-hosted MCP server that maintains a registry of project rules, enabling chats to query which rules apply to them in one call. It manages rule lifecycle with scopes, expiry, approval batches, and immutable history.
    MIT