The Mega Brain pipeline is a semantic processing system that ingests expert materials and transforms them into structured, traceable knowledge across 5 DNA layers.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/thiagofinch/mega-brain/llms.txt
Use this file to discover all available pages before exploring further.
Pipeline Overview
Core Constraint: Process 100% of content. No summarization, no omission. Every insight must trace back to source with full lineage.
Phase 1: Initialization + Validation
Purpose
Purpose
Validate input files, extract metadata from paths, load state files, and check for duplicate processing.
Extract Path Metadata
Parse file path to extract:
SOURCE_PERSON- Folder after inbox/SOURCE_COMPANY- Content in parenthesesSOURCE_TYPE- Material type (MASTERMINDS, COURSES, etc.)SOURCE_ID- Unique hash (e.g., “CG003”)SCOPE- course | company | personalCORPUS- Derived from SOURCE_COMPANY
Load State Files
Load or create:
CHUNKS-STATE.jsonCANONICAL-MAP.jsonINSIGHTS-STATE.jsonNARRATIVES-STATE.json
Phase 2: Chunking
Purpose
Purpose
Segment content into semantic chunks (~300 words) while preserving context, timestamps, and speaker labels.
core/templates/PIPELINE/PROMPT-1.1-CHUNKING.md
Chunking Rules
- Chunk size: ~300 words (~1000 tokens)
- Preserve: Timestamps, speaker labels, formatting
- Extract: People (raw mentions), themes (raw topics)
- Generate: Sequential
chunk_idlikechunk_CG003_001
Process
Checkpoint:
count(new_chunks) > 0, each chunk has unique ID, state file saved
Phase 3: Entity Resolution
Purpose
Purpose
Normalize entity names (people, companies, themes) to canonical forms to prevent duplication.
core/templates/PIPELINE/PROMPT-1.2-ENTITY-RESOLUTION.md
Resolution Rules
- Threshold: 0.85 confidence for merging
- Prefer: Longest/most explicit form as canonical
- NEVER merge: Across different corpus
- Flag collisions: For human review
Examples
| Raw Mentions | Canonical Form |
|---|---|
| ”Cole”, “Cole G”, “Cole Gordon” | Cole Gordon |
| ”Hormozi”, “Alex H”, “Alex Hormozi” | Alex Hormozi |
| ”TSC”, “The Scalable Company” | The Scalable Company |
CANONICAL-MAP.json, review queue for ambiguous cases
Phase 4: Insight Extraction
Purpose
Purpose
Extract actionable insights from chunks, classify by priority, and detect contradictions.
core/templates/PIPELINE/PROMPT-2.1-INSIGHT-EXTRACTION.md
Insight Structure
Priority Levels
High
Immediately actionable, high-impact insights
Medium
Important context, strategic guidance
Low
Supporting details, background information
INSIGHTS-STATE.json
Phase 5: Narrative Synthesis
Purpose
Purpose
Synthesize insights into coherent narratives for each person and theme, tracking tensions and open questions.
core/templates/PIPELINE/PROMPT-3.1-NARRATIVE-SYNTHESIS.md
Narrative Structure
Merge Rules (CRITICAL)
- narrative: CONCATENATE with update separator
- insights_included[]: APPEND (never replace)
- tensions[]: APPEND new ones
- open_loops[]: APPEND new, mark RESOLVED when answered
- next_questions[]: REPLACE (only exception)
NARRATIVES-STATE.json with synthesized narratives
Phase 6: Dossier Compilation
Purpose
Purpose
Compile comprehensive dossiers for persons and themes with full source traceability.
core/templates/PIPELINE/DOSSIER-COMPILATION-PROTOCOL.md
Dossier Types
- Person Dossiers
- Theme Dossiers
knowledge/dossiers/persons/ and knowledge/dossiers/themes/
Phase 7: Agent Enrichment
Purpose
Purpose
Update agent knowledge and memory files with new insights, respecting agent boundaries.
Process
Compile Knowledge Payload
Extract frameworks, techniques, metrics, and high-priority insights discovered
Execute Updates
Update relevant agent files with new knowledge, maintaining agent voice and structure
Phase 8: Finalization
Purpose
Purpose
Execute automatic cleanup, generate execution report, and verify pipeline integrity.
Automatic Actions
Final Verification (9 Items)
Execution Report
Pipeline Commands
| Command | Description |
|---|---|
/process-jarvis | Run full pipeline on specified file |
/ingest | Add new material to inbox |
/save | Save current pipeline state |
/resume | Resume interrupted pipeline |
Next Steps
DNA Schema
Learn about the 5-layer knowledge extraction
Architecture
Understand the system architecture
