Token导航 LogoToken导航TokenDH.com
chimera (Figgiee) logo
搜索检索未说明官方级别未说明来源级核验

chimera (Figgiee)

MCP Server

CHIMERA是一个完全本地的AI助手,具备RAG、网页搜索和持久记忆功能,无需API密钥和云端服务,适用于需要隐私保护和高性能的AI应用场景。

工具数

7

提示词数

0

GitHub Stars

1

资源数

0
本地AI持久记忆JavaScript搜索隐私保护

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

作者 / 组织

figgiee

提供方

figgiee

最后核验

2026/5/17 20:23

快速接入

先看主来源和安装命令,再打开仓库或文档;下面只保留这个条目的关键接入事实。

详细介绍

奇美拉

具有RAG、网络搜索和持久内存的完全本地AI助手。

*完全在您的硬件上运行。没有API密钥。没有云。没有遥测。*

![Status](https://github.com/figgiee/chimera) ![LM Studio](https://lmstudio.ai) ](https://docker.com) ![MCP](https://modelcontextprotocol.io) ![License](LICENSE)

入门指南 · 建筑 · MCP工具 · API 参考 · 配置

______________________________________________________________________

奇美拉是什么?

奇美拉连接 LM 工作室 通过 模型上下文协议。您当地的法学硕士获得了真正的能力:

知识与搜索

  • 通过pgvector进行语义文档搜索
  • 跨11个引擎的网络搜索(SearXNG)
  • 通过Context7获取实时库文档

记忆与互动

  • 具有语义回忆的会话记忆
  • 持久知识图
  • 文件系统访问(读/写/搜索)

文档处理

  • 上传并索引PDF、DOCX、TXT、MD
  • 使用TEI批量嵌入
  • 余弦相似度排名

愿景与分析

  • 屏幕截图与分析
  • PDF文本提取
  • 多模态视觉模型
\[!重要\] 所有处理都在本地进行。文档嵌入在您的计算机上,存储在您的数据库中,永远不会离开您的网络。

建筑

                          ┌─────────────────────────────────┐
                          │         LM Studio (Host)         │
                          │     Qwen 3.5 · localhost:1234    │
                          └───────────────┬─────────────────┘
                                          │ MCP (stdio)
                 ┌────────────────────────┼────────────────────────┐
                 │                        │                        │
        ┌────────┴────────┐    ┌──────────┴──────────┐    ┌───────┴───────┐
        │   chimera-rag   │    │  searxng · filesys   │    │  memory · pdf │
        │   (custom MCP)  │    │  context7 · screenshot│    │  (stdlib MCP) │
        └────────┬────────┘    └──────────┬──────────┘    └───────────────┘
                 │                        │
                 ▼                        ▼
  ┌──────────────────────────────────────────────────────────────────┐
  │                        Docker Network                            │
  │                                                                  │
  │  ┌──────────────┐    ┌──────────────┐    ┌──────────────┐      │
  │  │  PostgreSQL   │    │     TEI      │    │   SearXNG    │      │
  │  │  + pgvector   │    │  embeddings  │    │  meta-search │      │
  │  │  port 5432    │    │  port 8001   │    │  port 8888   │      │
  │  └──────┬───────┘    └──────┬───────┘    └──────┬───────┘      │
  │         └───────────────────┼───────────────────┘               │
  │                      ┌──────┴──────┐                            │
  │                      │  RAG Server │                            │
  │                      │  FastAPI    │                            │
  │                      │  port 8080  │                            │
  │                      └─────────────┘                            │
  └──────────────────────────────────────────────────────────────────┘

back to top

入门指南

先决条件

要求最低要求建议
图形处理器8GB VRAM16GB VRAM
随机存取存储器16GB64GB
软件, LM 工作室,

第一步——克隆并启动Docker

git clone https://github.com/figgiee/chimera.git
cd chimera/rag-setup
docker compose up -d
\[!提示\] 首次启动需要大约3GB的Docker镜像,需要2-3分钟。后续启动是即时的。

等待健康检查:

docker compose ps    # all 4 services should show "healthy"

第二步——启动LM Studio

  1. 打开LM Studio并加载模型
  2. 在端口上启动服务器 1234
  3. 复制 mcp.json 到LM Studio配置(请参阅 配置)

步骤3——将Docker连接到LM Studio

LM Studio绑定到 localhost 只有。Docker容器需要一个端口代理才能访问它:

# Run once in Admin PowerShell — persists across reboots
netsh interface portproxy add v4tov4 listenport=1234 listenaddress=0.0.0.0 connectport=1234 connectaddress=127.0.0.1

步骤4——验证

curl http://localhost:8080/health
{
  "status": "ok",
  "services": {
    "database": "ok",
    "embeddings": "ok",
    "search": "ok",
    "llm_studio": "ok"
  }
}
\[!注意\] 如果 llm_studio 显示错误,请确保LM Studio正在运行并且端口代理已设置(步骤3)。

back to top

MCP工具

奇美拉提供 7台MCP服务器 通过LM Studio的插件系统,您可以访问LLM工具。

奇美拉抹布-- *定制RAG管道*

工具说明
search_documents具有可配置相似性阈值的跨索引文档的语义向量搜索
upload_document通过自动分块和嵌入上传和索引文档(PDF、DOCX、TXT、MD)
list_documents列出所有带有ID、文件名和内容预览的索引文档
delete_document从知识库中删除文档及其所有嵌入
store_conversation通过语义嵌入保存对话回合以用于长期记忆
recall_conversation使用语义相似性搜索过去的对话
rag_health检查所有RAG管道服务的健康状况

外部MCP服务器

服务器功能
搜索引擎mcp searxng跨11个引擎(DuckDuckGo、谷歌、必应、维基百科、arXiv、GitHub、Brave等)的尊重隐私的元搜索
文件系统@模型上下文协议/服务器文件系统跨配置的目录读取、写入、搜索和管理文件
记忆@模型上下文协议/服务器内存跨会话实体和关系的持久知识图
pdf阅读器mcp pdf阅读器高级PDF文本提取和结构化阅读
截图mcp屏幕截图用于视觉模型分析的屏幕截图
上下文7@upush/context7 mcp按需查找最新的图书馆文档

back to top

Docker服务

Service Image Port Description

chimera-rag-server python:3.11-slim (custom) 8080 FastAPI orchestrator — handles document upload, search, conversation memory, and LM Studio integration

chimera-postgres pgvector/pgvector:pg15 5432 PostgreSQL with pgvector extension — stores 384-dimensional embeddings with cosine similarity search

chimera-tei ghcr.io/huggingface/text-embeddings-inference 8001 HuggingFace Text Embeddings Inference — runs all-MiniLM-L6-v2 for fast vectorization

chimera-searxng searxng/searxng:latest 8888 Privacy-respecting meta-search engine — aggregates 11 search backends with no API keys

back to top

API 参考

GET /health — Service health check

curl localhost:8080/health
{
  "status": "ok",
  "timestamp": "2026-03-11T07:45:09.469968",
  "services": {
    "database": "ok",
    "embeddings": "ok",
    "search": "ok",
    "llm_studio": "ok"
  }
}

POST /api/search — Semantic document search

curl -X POST localhost:8080/api/search \
  -H "Content-Type: application/json" \
  -d '{"query": "machine learning", "limit": 5, "threshold": 0.3}'
参数类型默认值说明
query字符串*必需的*搜索查询文本
limitint5返回的最大结果
threshold浮子0.3最小余弦相似度(0-1)

POST /api/documents/upload — Upload and index a document

curl -X POST localhost:8080/api/documents/upload -F "file=@paper.pdf"

支持: .pdf, .docx, .txt, .md

文档会自动分块,通过TEI以32个为一批嵌入,并存储在pgvector中。

GET /api/documents — List indexed documents

curl localhost:8080/api/documents

返回所有文档及其ID、文件名、上传时间戳和内容预览。

DELETE /api/documents/{id} — Delete a document

curl -X DELETE localhost:8080/api/documents/{document_id}

从数据库中删除文档和所有关联的嵌入。

POST /api/conversations/store — Store a conversation turn

curl -X POST localhost:8080/api/conversations/store \
  -H "Content-Type: application/json" \
  -d '{"conversation_id": "research-1", "role": "user", "content": "What is RAG?"}'
参数类型说明
conversation_idstring唯一对话标识符
role字符串userassistant
contentstring要嵌入和存储的消息内容

POST /api/conversations/recall — Recall past conversations

curl -X POST localhost:8080/api/conversations/recall \
  -H "Content-Type: application/json" \
  -d '{"query": "RAG architecture", "limit": 5}'
参数类型默认值说明
query字符串*必需的*语义搜索查询
conversation_id字符串null仅限于特定对话
limitint5最大结果

back to top

配置

MCP服务器配置

将此复制到LM Studio MCP配置(~/.lmstudio/mcp.json),将路径替换为您的安装位置:

mcp.json

{
  "mcpServers": {
    "chimera-rag": {
      "command": "node",
      "args": ["/mcp-chimera-rag/index.js"],
      "env": { "RAG_SERVER_URL": "http://localhost:8080" }
    },
    "searxng-search": {
      "command": "node",
      "args": ["/mcp-searxng/dist/index.js"],
      "env": { "SEARXNG_URL": "http://localhost:8888" }
    },
    "filesystem": {
      "command": "npx",
      "args": ["-y", "@modelcontextprotocol/server-filesystem", "~/Desktop", "~/Documents", "~/Downloads"]
    },
    "memory": {
      "command": "npx",
      "args": ["-y", "@modelcontextprotocol/server-memory"]
    },
    "pdf-reader": {
      "command": "node",
      "args": ["/mcp-pdf-reader/dist/index.js"]
    },
    "context7": {
      "command": "npx",
      "args": ["-y", "@upstash/context7-mcp@latest"]
    },
    "screenshot": {
      "command": "node",
      "args": ["/mcp-screenshot/dist/index.js"]
    }
  }
}

系统提示

Chimera的推荐系统提示在设计上是最小的——小型模型在简洁的说明下表现更好:

Optimized system prompt (~120 tokens)

You are Chimera, a local AI assistant. Use your tools proactively. Be concise — lead with the answer.

Images, text, and code shared in chat are already in your context. Respond directly.

For dates, versions, current events, or anything time-sensitive: web_search first, then answer.

For questions that might relate to past sessions: recall_conversation to check, then answer.

After significant exchanges (research, analysis, problem-solving): store_conversation with a descriptive conversation_id.

If a tool fails, try an alternative approach. If a file path is given, read it immediately.

推荐模型

用例型号VRAM速度
每日驱动程序Qwen 3.5-9B Q4_K_M~7 GB~93 tok/s
繁重任务Qwen 3.5-35B-A3B Q4_K_M~14 GB~18 tok/s
低VRAM3.5-9B Q3_K_M~5 GB~100 tok/s

LM工作室设置(适用于35B型号)

设置注释
上下文长度16384越高=VRAM越多,速度越慢
GPU卸载25层卸载到GPU
CPU线程数24为操作系统留出空间
并发预测1避免上下文分割

back to top

项目结构

chimera/
├── rag-setup/                     # Docker infrastructure + RAG server
│   ├── docker-compose.yml         # 4-service orchestration
│   ├── Dockerfile                 # RAG server image (Python 3.11)
│   ├── app.py                     # FastAPI application
│   ├── db.py                      # SQLAlchemy models + pgvector ops
│   ├── embeddings.py              # TEI client (embed + batch)
│   ├── search.py                  # Document search + SearXNG client
│   ├── llm.py                     # LM Studio health + model detection
│   ├── init.sql                   # pgvector extension bootstrap
│   ├── requirements.txt           # Python dependencies
│   ├── searxng-settings.yml       # 11 search engine configs
│   ├── documents/                 # Uploaded document storage
│   └── scripts/
│       ├── manage.sh              # Service management CLI
│       └── ingest-documents.py    # Batch document processor
│
├── mcp-chimera-rag/               # Custom MCP server
│   ├── index.js                   # 7 tool definitions + handlers
│   └── package.json
│
├── .env.example                   # Environment template
├── .gitignore
├── LICENSE
└── README.md

back to top

管理

cd rag-setup

./scripts/manage.sh start       # Start all services
./scripts/manage.sh stop        # Stop all services
./scripts/manage.sh restart     # Restart all services
./scripts/manage.sh rebuild     # Rebuild RAG server after code changes
./scripts/manage.sh health      # Check all service endpoints
./scripts/manage.sh logs        # Tail all logs (or: logs rag-server)
./scripts/manage.sh db-backup   # Backup PostgreSQL to ./backups/
./scripts/manage.sh reset       # Nuclear reset — destroys all data

硬件要求

要求最低要求建议
随机存取存储器16gb32Gb+
GPU VRAM8 GB16 GB+
操作系统Windows 10、macOS 12或Linux--
软件Docker桌面、LM Studio、Node.js 20+--

Chimera完全在本地运行-无需云,无需API密钥。性能取决于您在LM Studio中加载的模型。

back to top

______________________________________________________________________

MIT许可证

目录标签

目录标签

本地AI持久记忆JavaScript搜索隐私保护本地部署RAG网页搜索

接入字段

传输方式(transport,传输协议)

未说明

鉴权方式(authType,认证方式)

none

工具数量(toolCount,工具数)

7

资源数量(resourceCount,资源数)

0

提示词数量(promptCount,提示词数)

0

权限和风险

未说明none部署方式未说明

接入前请确认传输方式、认证方式和部署位置,并根据实际工具能力限制访问范围。

安装前确认

不要直接授予不必要的文件、网络或账号权限;先核对安装命令和配置内容。

仍需确认:installCommand

来源信息

继续浏览同类 MCP