RAG Alternative Architectures
Architectural patterns that move beyond traditional Retrieval-Augmented Generation (RAG) to create persistent, compounding knowledge systems. Most notably exemplified by the llm-wiki-pattern, these approaches prioritize knowledge building over document retrieval.
Traditional RAG Limitations
Stateless Rediscovery
Standard RAG workflow:
- User asks question
- System retrieves relevant document chunks
- LLM generates answer from retrieved context
- Process repeats from scratch for each query
Core problem: "the LLM is rediscovering knowledge from scratch on every question. There's no accumulation. Ask a subtle question that requires synthesizing five documents, and the LLM has to find and piece together the relevant fragments every time. Nothing is built up."
Retrieval Quality Bottlenecks
- Limited by chunk similarity matching
- Cannot build complex multi-source arguments
- No persistent understanding of document relationships
- Insights lost after each interaction
No Knowledge Compounding
Each query provides discrete value without strengthening the system's overall understanding or capability.
Alternative: Persistent Wiki Architecture
Knowledge Compilation Pattern
Instead of retrieve-at-query-time:
- Compile knowledge once during ingestion
- Maintain persistent synthesis across sources
- Query against structured knowledge rather than raw documents
- Compound insights through each interaction
Three-Layer Implementation
Following llm-wiki-pattern:
Raw Sources
- Immutable document storage
- Source of truth for all knowledge
- Curated by human expertise
Wiki Knowledge Layer
- LLM-maintained structured pages
- Cross-referenced entities and concepts
- Continuously updated synthesis
- Persistent relationship mapping
Schema/Convention Layer
- Workflow definitions for maintenance
- Quality standards and formats
- Cross-referencing conventions
- Update and integration protocols
Architectural Advantages
Pre-Computed Relationships
- Cross-references already established
- Contradictions already identified
- Synthesis already reflects all sources
- Complex connections preserved
Incremental Enhancement
Each new source:
- Strengthens existing understanding
- Creates new conceptual connections
- Updates relationship networks
- Compounds rather than just adds
Query Efficiency
Answers leverage:
- Pre-existing synthesis work
- Established cross-reference networks
- Previously identified patterns
- Accumulated domain expertise
Implementation Patterns
Wiki-Based Knowledge Bases
- Structured markdown pages for entities/concepts
- Automated cross-referencing systems
- Index-based navigation at small scale
- Search integration as collections grow
Version-Controlled Knowledge
- Git-based storage for complete history