Penpal

Penpal: The Write Spot

A hybrid content creation platform with a warm, pen-pal inspired experience. This monorepo hosts the Next.js 15 web client, Tauri 2 desktop shell, and Python-based MCP server.

Project layout

apps/
  web/        # Next.js 15 + shadcn/ui brand experience & workspace UI
  desktop/    # Tauri 2 wrapper for the static web build
packages/
  python-mcp/ # FastMCP server with async SQLite + LiteLLM pipeline

Prerequisites

Quick Start

1. Clone and Install:

git clone https://github.com/NoManNayeem/Penpal.git
cd "Penpal - The Write Spot"
pnpm install

2. Start the MCP Server:

cd packages/python-mcp
python -m venv .venv
# On Windows:
.venv\Scripts\activate
# On macOS/Linux:
source .venv/bin/activate

pip install -e .[dev]
cp .env.example .env
python -m penpal_mcp.server

3. Start the Web App (in a new terminal):

pnpm --filter web dev

4. Open http://localhost:3000 in your browser

5. Access the Workspace: Navigate to http://localhost:3000/workspace to start writing!

Common scripts

pnpm install                 # install workspace deps
pnpm dev                     # run all dev scripts via Turborepo
pnpm --filter web dev        # start Next.js app only (http://localhost:3000)
pnpm --filter desktop dev    # launch Tauri desktop (spawns Next dev server)

MCP server

cd packages/python-mcp
python -m venv .venv
. .venv/Scripts/Activate.ps1  # Windows example
pip install -e .[dev]
cp .env.example .env
python -m penpal_mcp.server

The MCP server exposes tools for outline generation, document storage, listing, and export. API keys for OpenAI/Anthropic/Google/xAI are optional—without them the server responds with deterministic sample data so the UI can run end-to-end during development.

MCP Environment Variables

The MCP server reads configuration from .env or environment variables with the PENPAL_ prefix:

Docker workflow

Spin up the web client and MCP server together via Docker Compose:

docker compose up --build

Services:

The compose configuration mounts the repository so code edits hot-reload inside the containers. Named volumes cache the pnpm store and node modules to keep rebuilds fast.

Note: The Tauri desktop shell is not part of the Docker stack because it requires a native windowing environment. Build it locally with Rust/Cargo once the web app is exported.

Accessing the workspace UI

Once the stack is running, open http://localhost:3000/workspace to launch the Penpal editor experience:

The web client talks to the MCP transport through /api/mcp, proxying requests to the configured NEXT_PUBLIC_MCP_URL (defaults to http://127.0.0.1:7337).

Building the desktop app

pnpm --filter web build
pnpm exec tauri build --target x86_64-pc-windows-msvc

Prerequisites: the Rust toolchain (rustup), Windows C++ build tools, and pnpm enabled via corepack. The installer and binary output live in apps/desktop/src-tauri/target/release/bundle (for example bundle/msi/penpal-desktop_*.msi). Link the “Download desktop build” CTA to that release artifact once you publish it.

Features

Rich Text Editor - TipTap-powered editor with full formatting support 📝 AI-Powered Outlines - Generate content outlines using multiple LLM providers 💾 Document Management - Save, list, and version your documents 📤 Multi-Format Export - Export to PDF, DOCX, PPTX, HTML, and Markdown 🌓 Dark Mode - System-aware theme switching 🖥️ Desktop App - Tauri-based native desktop application 🐳 Docker Support - Containerized development workflow

Technology Stack

Frontend

Backend

Desktop

Documentation

📚 Complete Architecture Guide: GitAssets/Penpal_The_Write_Spot.md - Brand system, technical architecture, and implementation details for the entire platform.

GitHub Pages Landing

A separate static landing page that mirrors the Penpal brand lives under GitAssets/. Deploy it directly to GitHub Pages by pointing the Pages build folder to /GitAssets. Preview locally with:

cd GitAssets
python -m http.server 4100
# Visit http://localhost:4100

Troubleshooting

MCP Server Connection Issues

Build Errors

Desktop App Won’t Start

Contributing

  1. Fork the repository
  2. Create a feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

License

MIT

Support

For issues and questions: