展示 HN:Atomic – 自托管、语义连接的个人知识库
Show HN: Atomic – Self-hosted, semantically-connected personal knowledge base

原始链接: https://github.com/kenforthewin/atomic

## 原子:你的 AI 驱动的个人知识库 原子是一个自托管应用程序,可以将 Markdown 笔记转换为由 AI 增强的连接知识图谱。它将信息存储为“原子”——自动分块、标记和链接的笔记,从而实现强大的语义搜索和知识发现。 主要功能包括一个空间“画布”用于可视化连接,自动生成带有引用的维基文章,以及一个代理聊天界面用于查询你的知识。原子支持基于云(OpenRouter)和本地(Ollama)的 AI 提供商,用于嵌入、标记和 LLM 功能。 你可以通过浏览器扩展、RSS 订阅源或直接输入轻松添加内容。它还提供了一个 MCP 服务器,用于与 Claude 等工具集成。原子提供桌面应用程序(Tauri)、无头服务器(Docker/Fly.io)和原生 iOS 应用程序,构建在强大的 Rust 核心之上。它专为灵活性和自托管而设计,GitHub 上提供详细的设置说明。

## 原子:自托管知识库 一个名为原子(Atomic)的新项目在Hacker News上分享,它提供了一个自托管、语义连接的个人知识库(可在GitHub上找到)。它的目标是成为笔记、文章和研究的中心枢纽,自动分类和综合信息。 用户讨论了它作为LogSeq、Roam和Obsidian等工具的潜在替代品。一个主要担忧是将AI集成时的数据隐私问题,以及对访问权限的精细控制需求。开发者承认了这一点,指出隐私和易用性之间存在权衡,并建议使用Ollama等工具本地运行模型作为一种选择。 目前处于早期阶段,macOS版本需要用户绕过安全设置才能打开,但Docker Compose设置提供了一种替代的访问方法。该项目利用RSS订阅源进行内容同步,并可以根据定义的类别生成摘要。
相关文章

原文

A personal knowledge base that turns markdown notes into a semantically-connected, AI-augmented knowledge graph.

Atomic stores knowledge as atoms — markdown notes that are automatically chunked, embedded, tagged, and linked by semantic similarity. Your atoms can be synthesized into wiki articles, explored on a spatial canvas, and queried through an agentic chat interface.

Canvas View

Wiki Synthesis

Chat Interface

  • Atoms — Markdown notes with hierarchical tagging, source URLs, and automatic chunking
  • Semantic Search — Vector search over your knowledge base using sqlite-vec
  • Canvas — Force-directed spatial visualization where semantic similarity determines layout
  • Wiki Synthesis — LLM-generated articles with inline citations, built from your notes
  • Chat — Agentic RAG interface that searches your knowledge base during conversation
  • Auto-Tagging — LLM-powered tag extraction organized into hierarchical categories
  • Multiple AI Providers — OpenRouter (cloud) or Ollama (local) for embeddings and LLMs
  • RSS Feeds — Subscribe to feeds and automatically sync new articles as atoms
  • Browser Extension — Capture web content directly into Atomic
  • MCP Server — Expose your knowledge base to Claude and other AI tools
  • Multi-Database — Multiple knowledge bases with a shared registry
  • iOS App — Native SwiftUI client for reading and writing atoms on mobile

Atomic runs as a desktop app (Tauri), a headless server (Docker/Fly.io), or both.

Download the latest release for your platform from GitHub Releases (macOS, Linux, Windows).

On first launch, the setup wizard walks you through AI provider configuration.

Self-Host with Docker Compose

git clone https://github.com/kenforthewin/atomic.git
cd atomic
docker compose up -d

This starts the API server and web frontend. Open http://localhost and claim your instance through the setup wizard.

cp fly.toml.example fly.toml
fly launch --copy-config --no-deploy
fly volumes create atomic_data --region <your-region> --size 1
fly deploy

Open https://your-app.fly.dev and claim your instance. The public URL for OAuth/MCP is auto-detected from the Fly app name.

cargo run -p atomic-server -- --data-dir ./data serve --port 8080

On first run, create an API token:

cargo run -p atomic-server -- --data-dir ./data token create --name default

Atomic needs an AI provider for embeddings, tagging, wiki generation, and chat.

  • OpenRouter (cloud) — Get an API key from openrouter.ai. Supports separate model selection for embedding, tagging, wiki, and chat.
  • Ollama (local) — Install Ollama and pull models (e.g., ollama pull nomic-embed-text). Atomic auto-discovers available models.

Configure via the setup wizard on first launch, or later in Settings.

The Atomic Web Clipper captures web content as atoms:

  1. Open Chrome/Edge/Brave and navigate to chrome://extensions
  2. Enable "Developer mode"
  3. Click "Load unpacked" and select the extension/ directory
  4. Configure your server URL and API token in the extension options

Captures are queued offline and synced when the server is available.

Atomic exposes an MCP endpoint for Claude and other AI tools to search and create atoms.

The endpoint runs at /mcp on your server (e.g., http://localhost:8080/mcp).

Claude Desktop config (~/Library/Application Support/Claude/claude_desktop_config.json):

{
  "mcpServers": {
    "atomic": {
      "url": "http://localhost:44380/mcp"
    }
  }
}

Available tools: semantic_search, read_atom, create_atom

All business logic lives in atomic-core, a standalone Rust crate with no framework dependencies. Every client is a thin wrapper adapting it to a transport:

                    +------------------+
                    |   atomic-core    |
                    |   (all logic)    |
                    +--------+---------+
              +--------------+--------------+
              v              v              v
    +-----------+    +--------------+    +----------+
    | src-tauri |    |atomic-server |    |atomic-mcp|
    | (desktop) |    | (REST + WS)  |    |  (stdio) |
    +-----+-----+    +------+-------+    +----------+
          |                 |
    +-----v-----+    +------v-------+
    |  React UI  |    | HTTP clients |
    |            |    | (iOS, web)   |
    +------------+    +--------------+
Cargo.toml                  # Workspace root
crates/atomic-core/         # All business logic
crates/atomic-server/       # REST + WebSocket + MCP server
crates/atomic-mcp/          # Standalone MCP server (stdio)
crates/mcp-bridge/          # HTTP-to-stdio MCP bridge
src-tauri/                  # Tauri desktop app
src/                        # React frontend (TypeScript)
ios/                        # Native iOS app (SwiftUI)
extension/                  # Chromium browser extension
scripts/                    # Import and utility scripts
npm install                       # Install frontend dependencies

# Desktop app
npm run tauri dev                 # Dev with hot reload
npm run tauri build               # Production build

# Server only
cargo run -p atomic-server -- serve --port 8080

# Frontend only
npm run dev                       # Vite dev server

# Checks
cargo check                       # All workspace crates
cargo test                        # All tests
npx tsc --noEmit                  # Frontend type check
Layer Technology
Core Rust, SQLite + sqlite-vec, tokio
Desktop Tauri v2
Server actix-web
Frontend React 18, TypeScript, Vite 6, Tailwind CSS v4, Zustand 5
Editor CodeMirror 6
Canvas d3-force, react-zoom-pan-pinch
iOS SwiftUI, XcodeGen
AI OpenRouter or Ollama (pluggable)

MIT

联系我们 contact @ memedata.com