The Local Lore MCP provides a comprehensive suite of tools for creative writing and world-building, particularly focused on novel development. Here's what you can do with it:
- View all your novels and get detailed information about specific novels
- Access and update chapter content and titles
- Get comprehensive story summaries and context
- Professional writing environment with rich text editing
- Auto-save with intelligent debouncing
- Real-time statistics and version history
- Characters: Add, view, and manage character profiles with descriptions and traits
- Places: Create and organize locations in your story world
- Events: Track important story events and link them to specific chapters
- Lore: Build rich background knowledge with categorized lore entries
- Items: Catalog important objects, artifacts, or tools in your story
- Smart Organization: Tabbed interface with search and categorization
- Outlines: Create detailed, hierarchical outlines with sections and subsections
- Manuscript Analysis: Automatically generate outlines from existing chapters
- Story Context: Get comprehensive overviews of all story elements at once
- Chapter Guide: Read-only contextual guide showing scene and beat structure
- Bi-directional Sync: Automatic synchronization between outline and chapter views
- AI Prompts: Create and manage custom writing prompts for different purposes (style, character development, genre guidelines, etc.)
- Prompt Execution: Run AI prompts with full story context to get targeted writing assistance
- Writing Context: Get comprehensive context including prompts and story elements for AI collaboration
- Claude Desktop Integration: Direct MCP (Model Context Protocol) server connection
- Context-Aware AI: Automatically provides relevant story elements as context
- Multiple AI Actions: Edit, review, continue, and replace text functionality
- Chapter Analysis: Automatically extract and add story elements (characters, places, events) from existing chapter content
- Story Summaries: Generate comprehensive summaries including plot progression and character development
- Visual Notes System: Draggable, resizable notes with color coding
- Data Integrity: SQLite database with proper relationship management
- Global Search: Search across all chapters and story elements
- Text Highlighting: In-editor search result highlighting
- Quick Navigation: Jump between chapters, characters, and places
- Cross-references: Navigate between related story elements
- Multiple Export Formats: JSON, Markdown, HTML, and plain text
- Complete Data Export: Export all story elements with metadata
- Desktop Application: Native Electron app for Windows, Mac, and Linux
- Browser Extension: Alternative integration for Claude Desktop web interface
The system is designed to help you maintain consistency across complex fictional worlds while providing AI-powered assistance that understands your specific story context. It's particularly powerful for managing long-form fiction with multiple characters, locations, and plot threads.
- Rich Text Editor: TipTap-powered editor with professional formatting tools
- Focus Mode: Distraction-free writing with customizable interface
- Auto-save: Intelligent auto-saving with debounced updates
- Real-time Statistics: Live word count, character count, and writing progress
- Version History: Complete chapter version control with restoration capabilities
- Hierarchical Outlines: Multi-level story structure (Acts β Chapters β Scenes β Beats)
- Chapter Management: Create, reorder, and manage chapters with drag-and-drop
- Bi-directional Sync: Automatic synchronization between outline and chapter views
- Chapter Guide: Read-only contextual guide showing scene and beat structure
- Characters: Detailed character profiles with traits and descriptions
- Places: Location registry with rich descriptions
- Events: Plot events linked to specific chapters
- Lore: Categorized world-building information
- Items: Story objects and artifacts
- Smart Organization: Tabbed interface with search and categorization
- Claude Desktop Integration: Direct MCP (Model Context Protocol) server connection
- Custom AI Prompts: User-defined writing assistance templates
- Context-Aware AI: Automatically provides relevant story elements as context
- Multiple AI Actions: Edit, review, continue, and replace text functionality
- Story Analysis: Generate outlines, summaries, and comprehensive story analysis
- Global Search: Search across all chapters and story elements
- Text Highlighting: In-editor search result highlighting
- Quick Navigation: Jump between chapters, characters, and places
- Cross-references: Navigate between related story elements
- Multiple Export Formats: JSON, Markdown, HTML, and plain text
- Complete Data Export: Export all story elements with metadata
- Visual Notes System: Draggable, resizable notes with color coding
- Data Integrity: SQLite database with proper relationship management
- Node.js 18+ and npm 9+
- Claude Desktop (for AI features)
- Git (for cloning)
-
Clone the repository:
git clone https://github.com/yourusername/Local-Lore.git cd Local-Lore -
Install dependencies for all components:
# Backend cd Local-Lore-App/backend npm install # Frontend cd ../frontend npm install # MCP Server cd ../mcp-server npm install cd ../../
-
Start the application:
Option A: Use batch files (Windows):
# Start backend start-backend.bat # Start frontend (in new terminal) Start-frontend.bat # Start MCP server (in new terminal) "Start MCP.bat"
Option B: Manual startup:
# Terminal 1: Backend cd Local-Lore-App/backend npm start # Terminal 2: Frontend cd Local-Lore-App/frontend npm start # Terminal 3: MCP Server cd Local-Lore-App/mcp-server npm start
-
Access the application at
http://localhost:3000
For a native desktop experience:
cd Local-Lore-App/frontend
# Development mode
npm run electron-dev
# Build for production
npm run electron-dist-
Install and configure the MCP server:
cd Local-Lore-App/mcp-server npm install -
Configure Claude Desktop:
Windows:
- Copy the contents of
claude-desktop-config.json - Paste into
%APPDATA%\Claude\claude_desktop_config.json - Create the file if it doesn't exist
Mac/Linux:
# Create or edit ~/.config/claude/claude_desktop_config.json { "mcpServers": { "local-lore": { "command": "node", "args": ["/full/path/to/Local-Lore/Local-Lore-App/mcp-server/server.js"], "env": { "LOCAL_LORE_API": "http://localhost:3001/api" } } } }
- Copy the contents of
-
Restart Claude Desktop to activate the integration
For Claude Desktop web interface integration:
- Open Chrome and navigate to
chrome://extensions/ - Enable "Developer mode"
- Click "Load unpacked"
- Select the
Local-Lore-App/frontend/public/scribber-extensiondirectory
-
Start a New Project:
- Click "New Novel" from the dashboard
- Enter title, description, genre, and POV
- Choose standalone or series format
- Click "Create" to initialize
-
Writing Interface:
- Left Sidebar: Navigate chapters and story elements
- Main Editor: Rich text editing with formatting toolbar
- Right Sidebar: Chapter Guide (when enabled)
- Bottom Status: Word count and save status
-
Chapter Management:
- Create new chapters from the sidebar
- Drag and drop to reorder chapters
- Use the outline view for hierarchical organization
-
Story Elements:
- Characters Tab: Create and manage character profiles
- Places Tab: Document locations and settings
- Events Tab: Track plot events and timeline
- Lore Tab: Build your world's history and rules
- Items Tab: Catalog important objects
-
Outline System:
- Access via the "Outline" view
- Create hierarchical story structure
- Generate outlines from existing chapters
- Sync automatically with chapter organization
-
Text Selection AI:
- Select text in the editor
- Use AI Assistant for editing, reviewing, or continuing
- AI receives relevant story context automatically
-
Custom AI Prompts:
- Create custom writing assistance prompts
- Use placeholders like
{{selectedText}}and{{character}} - Access from the AI Assistant panel
-
Story Analysis:
- Generate comprehensive story outlines
- Create character summaries
- Analyze plot structure and pacing
-
Automatic Versioning:
- Versions saved automatically on significant changes
- Manual save creates explicit version points
-
Version Management:
- View version history in the sidebar
- Compare different versions
- Restore previous versions when needed
Local-Lore/
βββ Local-Lore-App/
β βββ backend/ # Node.js/Express API server
β β βββ data/ # SQLite database and backups
β β βββ server-improved.js # Main server file
β β βββ analyzer.js # Text analysis utilities
β β βββ package.json # Backend dependencies
β β
β βββ frontend/ # React + Electron application
β β βββ electron/ # Electron main process
β β βββ public/ # Static assets and browser extension
β β βββ src/ # React application source
β β β βββ components/ # Reusable UI components
β β β βββ contexts/ # React context providers
β β βββ package.json # Frontend dependencies
β β
β βββ mcp-server/ # Claude Desktop MCP integration
β β βββ server.js # MCP server implementation
β β βββ package.json # MCP server dependencies
β β
β βββ claude-desktop-config.json # Claude Desktop configuration
β
βββ Logo.png # Application logo
βββ README.md # This file
βββ *.bat # Windows batch scripts for easy startup
Backend:
- Runtime: Node.js 18+
- Framework: Express.js
- Database: SQLite with better-sqlite3
- Additional: CORS, dotenv, markdown-it, html-to-text
Frontend:
- Framework: React 18 with Vite
- Router: React Router DOM
- Editor: TipTap (ProseMirror-based)
- Styling: Tailwind CSS
- Icons: Lucide React
- HTTP Client: Axios
Desktop:
- Platform: Electron 28+
- Builder: electron-builder
- Cross-platform: Windows, macOS, Linux support
AI Integration:
- Protocol: Model Context Protocol (MCP)
- Provider: Anthropic Claude
- SDK: @modelcontextprotocol/sdk
The application uses SQLite with the following core tables:
- novels: Project metadata (title, description, genre, POV, series info)
- chapters: Chapter content with order, word count, and timestamps
- chapter_versions: Complete version history for all chapters
- characters: Character profiles with traits and descriptions
- places: Location information with descriptions
- events: Plot events linked to specific chapters
- lore: Categorized world-building information
- items: Story objects and artifacts
- notes: Visual sticky notes with position data
- ai_prompts: Custom AI writing prompts
- outlines: Story structure outlines
- outline_sections: Hierarchical outline components
Backend (Local-Lore-App/backend):
npm start: Start the production servernpm run dev: Start with nodemon (development)npm run migrate: Migrate from JSON to SQLitenpm run add-aiisms: Add anti-AI writing guidelines
Frontend (Local-Lore-App/frontend):
npm start: Start Vite development servernpm run build: Build for productionnpm run electron: Run Electron appnpm run electron-dev: Run Electron in development modenpm run electron-dist: Build desktop application
MCP Server (Local-Lore-App/mcp-server):
npm start: Start the MCP server
Environment Variables (create .env in backend directory):
PORT=3001
NODE_ENV=development
CLIENT_URL=http://localhost:3000Customization Options:
- Theme switching (light/dark)
- Editor font and size preferences
- Sidebar width and layout
- Auto-save intervals
-
Port Conflicts:
- Backend runs on port 3001
- Frontend runs on port 3000
- Ensure ports are available
-
Database Issues:
- Database file:
Local-Lore-App/backend/data/scribber.db - Backup available in
data/json-backup/
- Database file:
-
AI Integration:
- Ensure Claude Desktop is running
- Check MCP server configuration
- Verify file paths in configuration
-
Electron App:
- Ensure backend is running before starting Electron
- Check console for backend connection errors
- Use auto-save wisely (it's debounced for performance)
- Close unused story element tabs
- Export projects regularly for backup
- Use version history judiciously
- Fork the repository
- Create a feature branch (
git checkout -b feature/AmazingFeature) - Commit your changes (
git commit -m 'Add some AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
- Inspired by professional writing tools like Scrivener and Novelcrafter
- Built with the amazing open-source community
- Special thanks to Anthropic for Claude AI integration
- Icons provided by Lucide React
π Privacy Note: Local Lore is a self-hosted application. Your writing data never leaves your machine unless you choose to export it. AI features communicate only with your local Claude Desktop installation.
β¨ Happy Writing! Create your next masterpiece with Local Lore's powerful combination of traditional writing tools and cutting-edge AI assistance.