Skip to main content

MCP Server for editing RBT documents with partial operations. Reduces token consumption by 80-95%.

Project description

RBT MCP Server

MCP Server for editing RBT documents with partial operations. Reduces token consumption by 80-95% compared to full file read/write operations.

🎯 Key Features

  • Token Optimization: 80-95% reduction in LLM token usage
  • Structured Operations: Edit specific sections/blocks without loading entire documents
  • Smart Caching: LRU + TTL cache for frequently accessed documents
  • TASK Fuzzy Search: Find TASK files by index (e.g., "001" matches "TASK-001-PathResolver.md")
  • Template-based Creation: Auto-fill placeholders (project-id, feature-id, date)
  • 13 MCP Tools: Complete CRUD operations for RBT documents

📦 Installation

Option 1: Install from source (uv)

# Clone repository
git clone https://github.com/yourusername/KnowledgeSmith.git
cd KnowledgeSmith

# Install with uv
uv pip install -e .

Option 2: Direct installation

uv pip install rbt-mcp-server

🚀 Quick Start

1. Configure Claude Desktop

Add to ~/Library/Application Support/Claude/claude_desktop_config.json:

{
  "mcpServers": {
    "rbt-document-editor": {
      "type": "stdio",
      "command": "rbt-mcp-server",
      "env": {
        "RBT_ROOT_DIR": "/path/to/your/documents"
      }
    }
  }
}

Or use full uv command:

{
  "mcpServers": {
    "rbt-document-editor": {
      "type": "stdio",
      "command": "uv",
      "args": ["run", "rbt-mcp-server"],
      "env": {
        "RBT_ROOT_DIR": "/path/to/your/documents"
      }
    }
  }
}

2. Set Environment Variable

export RBT_ROOT_DIR=/path/to/your/documents

3. Test the Server

rbt-mcp-server

📚 Available MCP Tools

  1. get_outline - Get document structure (saves 80% tokens)
  2. read_content - Read specific section/block (saves 90% tokens)
  3. update_info - Update status/dependencies
  4. update_section_summary - Update section summary
  5. create_section - Create new sub-section
  6. create_block - Create paragraph/code/list/table
  7. update_block - Update block content
  8. delete_block - Delete block
  9. append_list_item - Add item to list
  10. update_table_row - Update table row
  11. append_table_row - Add table row
  12. create_document - Create from template
  13. clear_cache - Clear document cache

See rbt_mcp_server/README.md for detailed usage.

📊 Token Savings

Operation Traditional MCP Savings
Read structure 4,000 800 80%
Update status 8,000 300 96%
Add list item 8,000 1,000 88%
Complete TASK 44,000 3,000 93%

🧪 Development

Install development dependencies:

uv sync --dev

Run tests:

RBT_ROOT_DIR=/test/root uv run pytest -v

Test coverage:

RBT_ROOT_DIR=/test/root uv run pytest --cov=rbt_mcp_server --cov-report=html

📝 License

MIT License

🤝 Contributing

Contributions welcome! Please open an issue or submit a pull request.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

rbt_mcp_server-0.1.1.tar.gz (154.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

rbt_mcp_server-0.1.1-py3-none-any.whl (39.0 kB view details)

Uploaded Python 3

File details

Details for the file rbt_mcp_server-0.1.1.tar.gz.

File metadata

  • Download URL: rbt_mcp_server-0.1.1.tar.gz
  • Upload date:
  • Size: 154.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.9

File hashes

Hashes for rbt_mcp_server-0.1.1.tar.gz
Algorithm Hash digest
SHA256 14a93d175ccb16d1f20c3b52776a67a8532e62b7a89244ada1cd90be9ae9f635
MD5 d6c9361c504d8ed096a6694e5f44be31
BLAKE2b-256 307bcd2c342a2f79e7c1a46cc4859211f5d2e32d1fe11c101a11b35c0e223dbc

See more details on using hashes here.

File details

Details for the file rbt_mcp_server-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: rbt_mcp_server-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 39.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.9

File hashes

Hashes for rbt_mcp_server-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 791148c8a8ef75451688766c621682a0c4b3b08eb3ccba2446593a045e7cccdb
MD5 44a7333a24448e0938e5d7d5d5f04a25
BLAKE2b-256 14f3264c3509af61889359e2a4fa25cc69e3f47b4933e692baf42c577a397f99

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page