# LLM Wiki: Build a Self-Maintaining, Interlinked Knowledge Base with AI

This repository profile is provided by osrepos.com, an open source repository discovery platform.

Source: osrepos.com
Repository profile: https://osrepos.com/repo/nashsu-llm_wiki
Generated for open source discovery and AI-assisted research.

LLM Wiki is a powerful cross-platform desktop application designed to transform your documents into an organized, interlinked knowledge base automatically. Unlike traditional RAG systems, it incrementally builds and maintains a persistent wiki from your sources, ensuring knowledge is compiled once and kept current. This innovative approach offers a dynamic and evolving personal knowledge management solution.

GitHub: https://github.com/nashsu/llm_wiki
OSRepos URL: https://osrepos.com/repo/nashsu-llm_wiki

## Summary

LLM Wiki is a powerful cross-platform desktop application designed to transform your documents into an organized, interlinked knowledge base automatically. Unlike traditional RAG systems, it incrementally builds and maintains a persistent wiki from your sources, ensuring knowledge is compiled once and kept current. This innovative approach offers a dynamic and evolving personal knowledge management solution.

## Topics

- LLM
- Knowledge Base
- Personal Knowledge Management
- Desktop App
- TypeScript
- Rust
- AI
- RAG

## Repository Information

Last analyzed by OSRepos: Wed Sep 23 2026 16:13:25 GMT+0100 (Western European Summer Time)
Detail views: 0
GitHub clicks: 0

## Safety Notice

OSRepos shares public repositories for knowledge and discovery only. Review source code, dependencies, licenses, and security implications before running or installing anything.

## Content

## Introduction

LLM Wiki is an innovative, cross-platform desktop application designed to transform your diverse documents into an organized, interlinked knowledge base automatically. Moving beyond traditional Retrieval Augmented Generation (RAG) systems, which retrieve and answer from scratch every time, LLM Wiki incrementally builds and maintains a persistent wiki from your sources. This ensures that knowledge is compiled once and kept current, rather than being re-derived with every query.

The project is based on Andrej Karpathy's influential LLM Wiki pattern, a methodology for constructing personal knowledge bases using Large Language Models. LLM Wiki is created and maintained by nash_su, who has implemented these core ideas as a full desktop application with significant enhancements.

## Why Use LLM Wiki and Key Features

LLM Wiki offers a comprehensive solution for personal knowledge management, distinguishing itself with a suite of powerful features:

*   **A Self-Building Personal Knowledge Base**: At its core, LLM Wiki reads your documents, constructs a structured wiki, and keeps it updated autonomously. This incremental approach saves time and ensures a consistently current knowledge repository.

*   **Full Cross-Platform Desktop Experience**: Unlike abstract patterns, LLM Wiki provides a complete desktop application with a three-column layout (Knowledge Tree/File Tree, Chat, Preview), an icon sidebar for navigation (Wiki, Sources, Search, Graph, Lint, Review, Deep Research, Settings), custom resizable panels, and an activity panel for real-time processing status. All state, including conversations and settings, is persistently saved.

*   **Advanced Document Ingestion**:
    *   **Two-Step Chain-of-Thought Ingest**: LLM Wiki first analyzes sources to identify key entities, concepts, and connections, then generates wiki pages with source traceability and incremental caching.
    *   **Multimodal and Multi-format Support**: It ingests a wide array of formats including PDF, Office documents (DOCX, PPTX, XLSX), EPUB/MOBI, Org mode, images, media, and web clips. It also features multimodal image ingestion, extracting embedded images and generating factual captions.
    *   **Intelligent Folder Import & Auto-Watch**: Recursive folder import preserves directory structure, using folder context as an LLM classification hint. It also automatically detects external changes in source folders to keep the wiki synchronized.

*   **Dynamic Knowledge Graph and Insights**:
    *   **4-Signal Relevance Model**: A robust knowledge graph visualization and relevance engine uses direct links, source overlap, Adamic-Adar, and type affinity to map connections.
    *   **Louvain Community Detection**: Automatically discovers knowledge clusters based on link topology, providing cohesion scoring and distinct visual separation.
    *   **Graph Insights**: The system analyzes graph structure to surface actionable insights, such as surprising connections and knowledge gaps (isolated pages, sparse communities, bridge nodes), with one-click Deep Research integration.

*   **Optimized Query Retrieval Pipeline**: LLM Wiki employs a multi-phase retrieval pipeline that includes tokenized search, optional vector semantic search via LanceDB, and graph expansion. It features configurable context windows and prioritizes pages by combined search and graph relevance scores, ensuring efficient and accurate answers with cited references.

*   **Rust Backend Chat Agent & Skills**: The chat functionality runs through a powerful Rust backend Agent runtime, enabling tool-using capabilities for wiki search, source search, graph search, web search, and workspace file generation. It supports skill management, allowing users to enable or disable skills and interact with generated workspace outputs.

*   **Enhanced Content Rendering and Review**:
    *   **Rich Markdown Support**: Features KaTeX rendering for mathematical formulas and Mermaid code blocks for direct diagram rendering in chat and preview.
    *   **Asynchronous Review System**: LLM flags items needing human judgment during ingest, generating predefined actions and optimized search queries for convenient user review without blocking the ingest process.

*   **Deep Research and Web Clipping**:
    *   **Deep Research**: When knowledge gaps are identified, LLM Wiki can perform web searches via Tavily, SerpApi, or SearXNG, synthesize findings into new wiki pages, and auto-ingest the results.
    *   **Chrome Web Clipper**: A dedicated Chrome Extension allows one-click web page capture with accurate article extraction and HTML to Markdown conversion, automatically ingesting clipped content into your knowledge base.

*   **Robust Document Management and Cross-Platform Compatibility**:
    *   **Intelligent Cascade Deletion**: Deleting a source file triggers a smart cleanup, removing related wiki pages and dead wikilinks while preserving shared entities.
    *   **Cross-Platform Design**: Built with Tauri v2, it ensures native desktop performance on macOS, Windows, and Linux, with careful handling of path normalization and Unicode-safe string handling.

## Installation

Getting started with LLM Wiki is straightforward, whether you prefer pre-built binaries or compiling from source.

### Pre-built Binaries

The easiest way to install is by downloading the latest release from the official GitHub Releases page:

*   **macOS**: `.dmg` (supports Apple Silicon and Intel)
*   **Windows**: `.msi`
*   **Linux**: `.deb` / `.AppImage`

You can find the releases here: [https://github.com/nashsu/llm_wiki/releases](https://github.com/nashsu/llm_wiki/releases){target="_blank"}

### Build from Source

For those who prefer to build the application themselves, follow these steps:

1.  **Prerequisites**: Ensure you have Node.js 20+, Rust 1.88+, and `protoc` installed.
    *   macOS: `brew install protobuf`
    *   Linux: `sudo apt install protobuf-compiler`
    *   Windows: `choco install protoc`
2.  **Clone the repository**:
    bash
git clone https://github.com/nashsu/llm_wiki.git
cd llm_wiki
    
3.  **Install dependencies and build MCP server**:
    bash
npm install
npm --prefix mcp-server ci && npm run mcp:build
    
4.  **Run or build**:
    bash
npm run tauri dev      # For development
npm run tauri build    # For production build
    

### Chrome Extension

To install the Web Clipper Chrome Extension:

1.  Open `chrome://extensions` in your browser.
2.  Enable "Developer mode".
3.  Click "Load unpacked".
4.  Select the `extension/` directory from the cloned repository.
5.  Customize the clipping shortcut at `chrome://extensions/shortcuts` (default: `Alt+Shift+L` or `Command+Shift+L` on macOS).

## Examples

To quickly experience LLM Wiki, follow these steps:

1.  Launch the application and create a new project, choosing from available templates.
2.  Navigate to **Settings** and configure your LLM provider, including the API key and model. Optionally, set up Web Search providers and source folder auto-watch.
3.  Go to **Sources** and import your documents, such as PDFs, DOCX files, or Markdown.
4.  Observe the **Activity Panel** as LLM Wiki automatically processes your documents and builds wiki pages.
5.  Utilize the **Chat** interface to query your newly created knowledge base.
6.  Explore the **Knowledge Graph** to visualize connections between your knowledge entries.
7.  Check the **Review** section for any items requiring your attention or judgment.
8.  Periodically run **Lint** to maintain the health and consistency of your wiki.

## Links

*   **GitHub Repository**: [https://github.com/nashsu/llm_wiki](https://github.com/nashsu/llm_wiki){target="_blank"}
*   **Releases Page**: [https://github.com/nashsu/llm_wiki/releases](https://github.com/nashsu/llm_wiki/releases){target="_blank"}
*   **Chrome Extension**: Available within the `extension/` directory of the GitHub repository.
*   **LLM Wiki Agent Skill**: [https://github.com/nashsu/llm_wiki_skill](https://github.com/nashsu/llm_wiki_skill){target="_blank"}