co-reading-mcp
A local MCP server for low-token co-reading: import a book, split it into chapter-sized chunks, read it chunk by chunk, and keep notes so a session can resume without re-reading the whole book.
README
co-reading-mcp
A local MCP server for low-token co-reading: import a book, split it into chapter-sized chunks, read it chunk by chunk, and keep notes so a session can resume without re-reading the whole book.
Why
Sending a whole novel into the conversation burns through context immediately and has to be repeated every turn. This server keeps the book on disk and only loads the chunk currently being read, plus a small notes file to restore context between sessions.
Setup
npm install
npm start
Configure as a stdio MCP server (e.g. in Claude Desktop/Code config):
{
"mcpServers": {
"co-reading": {
"command": "node",
"args": ["/absolute/path/to/co-reading-mcp/src/server.js"]
}
}
}
Data is stored under data/ (override with CO_READING_DATA_DIR).
Remote mode (e.g. for the mobile app)
The Claude mobile app can't run a local stdio process — it needs an HTTPS endpoint added as a custom connector. Run the remote HTTP transport instead:
MCP_AUTH_TOKEN=<a long random secret> PUBLIC_BASE_URL=https://your-domain.com PORT=3000 npm run start:remote
This serves MCP over Streamable HTTP at http://<host>:3000/mcp. Requests
must include Authorization: Bearer <MCP_AUTH_TOKEN>; without a token set,
auth is disabled (fine for local testing, not for a public VPS).
The server also exposes a minimal single-user OAuth 2.0 shim
(/.well-known/oauth-authorization-server, /register, /authorize,
/token) so it can be added via Claude's official "Add custom connector" UI,
which requires an OAuth-capable remote MCP server. There's no real login —
anyone who can reach the server is handed the configured MCP_AUTH_TOKEN.
Set PUBLIC_BASE_URL to the externally-reachable HTTPS URL (no trailing
slash) so the OAuth metadata points to the right host.
To deploy on a VPS:
- Copy the repo to the VPS and
npm install. - Run
start:remotebehind a process manager (e.g.pm2 start npm --name co-reading -- run start:remote) so it survives disconnects/reboots. - Put a reverse proxy (Caddy or Nginx) in front of it for HTTPS — the mobile app requires
https://. A minimal Caddyfile:your-domain.com { reverse_proxy localhost:3000 } - In the Claude mobile app, go to Settings → Connectors → Add custom connector, and enter
https://your-domain.com/mcpwith the bearer token.
Web upload page
Besides the MCP tools, the remote server also serves a small mobile-friendly
web page at https://your-domain.com/ for uploading .txt/.epub files by
drag-and-drop or file picker (handy for adding books straight from your
phone without going through the chat). It's protected with HTTP Basic Auth
using the same MCP_AUTH_TOKEN as the password (any username works) so
strangers can't use it to fill up your VPS. Uploaded books go through the
same import pipeline as import_book and immediately show up in
list_books.
Tools
import_book— import a.txtor.epubfile (byfilePath) or rawtext, auto-split into chapters and size-bounded chunks (~6000 chars, to stay under MCP read truncation limits). EPUB chapter boundaries (spine order) are preserved; title defaults to the EPUB's own metadata title.list_books— list imported books with chunk counts and last-read position.list_chunks— list a book's chunks (chapter/part breakdown) without text.read_chunk— read one chunk; omitchunkIdto continue from the last-read position. Updates progress automatically.get_progress/set_progress— inspect or manually move the reading position.read_notes/append_notes— read/append timestamped discussion notes, used to restore context cheaply between sessions instead of re-reading the book.add_annotation/list_annotations— margin annotations anchored to a quoted passage within a chunk, tagged by author (human/claude); shown inline when reading a chunk. When both authors annotate an overlapping quote, a shared card is created automatically.list_cards— list shared cards (passages both human and claude annotated) for a book or chunk.search_book— case-insensitive substring search across all chunks, returning matches with context.
Chapter detection
Chapters are detected by heading patterns (第X章, Chapter N, numbered
headings). Text without recognizable chapter markers is imported as a single
chapter and split purely by size.
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。