mnemex

mnemex

An MCP server that ingests books into a structured, cross-linked wiki of sources, entities, concepts, and syntheses, managed by an LLM.

Category
访问服务器

README

<div align="center">

🧠 mnemex

Your second brain, curated by an LLM. Books in, structured wiki out.

License: MIT Node MCP

<br>

mnemex demo

</div>


mnemex is a personal knowledge system. You tell an LLM "ingest this book", and it reads the whole thing and files it into a structured, cross-linked wiki of:

  • Sources — books, articles, papers (metadata + chapter summaries + extracted claims)
  • Entities — the people, companies, and tools mentioned
  • Concepts — ideas and frameworks, each with When to use / When NOT to use, cross-links, and a source count
  • Syntheses — multi-source theories you derive ("how do these five books on negotiation actually fit together?")

Everything is plain Markdown, version-controlled, locally hosted, and LLM-readable. It's the opposite of RAG: instead of re-discovering knowledge on every query, the wiki compiles knowledge once and keeps it current. Every ingest makes it richer.

Inspired by Karpathy's LLM Wiki idea — made real and turnkey.


Quick start (≈5 minutes)

curl -fsSL https://raw.githubusercontent.com/Daniil-Sokolskiy/mnemex/main/install.sh | bash

This installs the MCP servers + CLI, scaffolds a wiki at ~/mnemex, and prints setup instructions for your client — Claude Desktop (paste a config block) or Claude Code (run two claude mcp add commands). These are local servers, so the web app (claude.ai) can't use them directly. Wire up your client, then say:

"help me ingest my first book — Meditations by Marcus Aurelius"

Watch index.md grow as the agent reads the book and files it.

<details> <summary>Manual install</summary>

npm install -g @mnemex/library-mcp @mnemex/cli
npx playwright install chromium          # for Anna's Archive search
mnemex init ~/mnemex                  # scaffold the wiki
mnemex doctor                           # verify deps
mnemex mcp install --wiki ~/mnemex    # print setup for Desktop + Claude Code

mnemex mcp install prints copy-paste setup for both Claude Desktop and Claude Code and never edits any config file silently.

</details>


What's in the box

Package What it is
@mnemex/library-mcp MCP server to search + download books from Project Gutenberg and Anna's Archive into your wiki. Includes a Playwright-based Anna's search that works against their current client-side-rendered pages (plain HTTP scraping no longer returns results).
@mnemex/cli mnemex init / doctor / mcp install — scaffold a wiki and wire up the servers.
apps/wiki-template The starter wiki: CLAUDE.md operating manual, page templates, ingest scripts, empty structure.
search via qmd mnemex wires up qmd (local BM25 + vector engine) as the mnemex-search MCP server over your wiki. mnemex setup-search installs + indexes it; the agent then has brain.query for hybrid retrieval.

Downloading from Anna's: free vs paid

Search always works and needs no account. Downloading has two paths:

How Needs
Free The search result includes a download_page_url. Open it in your browser and use Anna's free "slow download" (a short wait timer, sometimes a check). nothing
Automated library_annas_download fetches the file directly into your wiki, no browser. a paid Anna's membership — set ANNAS_ARCHIVE_KEY (your account's secret key)

The automated path uses Anna's fast_download API, which requires a membership key — that's Anna's restriction, not mnemex's. Free downloads exist but go through the browser slow-download page (mnemex can't fully automate that: there's a wait timer and occasionally a check, and bypassing checks is out of scope). So without a key you still get every search result plus a one-click link to grab the file for free.

Project Gutenberg downloads are always free and fully automated — no key, no browser.


How it works

  you: "ingest Atomic Habits"
        │
        ▼
  library-mcp ──► search Gutenberg + Anna's ──► download ──► raw/books/<slug>/book.md
        │
        ▼
  the LLM agent reads CLAUDE.md, then the book, then:
        ├─ writes wiki/sources/Atomic-Habits-Clear-2018.md
        ├─ creates/updates wiki/entities/  (James-Clear, etc.)
        ├─ creates/updates wiki/concepts/  (Habit-Loop, Identity-Based-Habits, …)
        ├─ updates index.md  (counts + catalog)
        └─ appends log.md

The CLAUDE.md in your wiki root is the agent's operating manual — naming conventions, frontmatter schema, the ingest/query/lint workflows, and the relationship vocabulary (Builds on / Subsumes / Contrasted with …).

Methodology

The wiki structure is opinionated. The patterns that make it scale:

  • Two-phase ingest — split content writing (sub-agent) from bookkeeping (parent) to avoid timeouts on big books.
  • Cluster ingest — ingest 5 themed books together with cross-link "sibling hooks" so concepts mature fast.
  • Status lifecyclestubdraftmature (3+ sources, reviewed).

Requirements

  • Node.js ≥ 20
  • pandoc (epub/pdf → markdown)
  • Chromium via Playwright (for Anna's search)
  • An MCP-capable LLM client (Claude Desktop, Claude Code, Cowork, …)

⚠️ Legal

library-mcp includes a client for Anna's Archive, which is subject to ongoing legal action. This project hosts and distributes nothing; you are responsible for compliance with copyright law in your jurisdiction. See docs/annas-disclaimer.md. For a fully copyright-clean workflow, use only the Project Gutenberg tools (~70,000 public-domain texts).

Contributing

PRs welcome — see docs/contributing.md. The Anna's DOM parser in packages/library-mcp/src/annas.ts needs occasional updates when Anna's changes its markup; that's the most common maintenance task.

License

MIT

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选