๐Ÿง  CrumbVector

Semantic Code Search with Trust Layer

Certified Code in Vector Space - nur vertrauenswรผrdiger Code wird indexiert!


๐ŸŽฏ Was ist das?

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚                                                                             โ”‚
โ”‚   CERTIFIED REPO  โ†’  CHUNKING  โ†’  EMBEDDING  โ†’  VECTOR DB  โ†’  SEARCH      โ”‚
โ”‚                                                                             โ”‚
โ”‚   โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”       โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”     โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”     โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”     โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”  โ”‚
โ”‚   โ”‚ CKL โœ“   โ”‚  โ”€โ”€โ–บ  โ”‚ Code  โ”‚ โ”€โ”€โ–บ โ”‚ Vectorโ”‚ โ”€โ”€โ–บ โ”‚ChromaDBโ”‚ โ—„โ”€โ”€โ”‚ Query  โ”‚  โ”‚
โ”‚   โ”‚ Trust:4 โ”‚       โ”‚ Chunksโ”‚     โ”‚ [768] โ”‚     โ”‚ Local  โ”‚    โ”‚ "beat" โ”‚  โ”‚
โ”‚   โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜       โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜     โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜     โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜     โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜  โ”‚
โ”‚                                                                             โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

CrumbVector ermรถglicht:
- ๐Ÿ” Semantische Suche in Code-Repositories
- ๐Ÿ” Trust-Layer: Nur zertifizierte Repos werden indexiert
- ๐Ÿ  Komplett lokal: Ollama + ChromaDB (keine Cloud!)
- ๐ŸŽต Optimiert fรผr Strudel/Music Patterns


๐Ÿš€ Quickstart

# 1. Setup
cd crumbvector
./setup.sh

# 2. Ollama starten (falls nicht lรคuft)
ollama serve &
ollama pull nomic-embed-text

# 3. CrumbMidi indexieren
./crumbvector.py ingest ../crumbmidi --local

# 4. Suchen!
./crumbvector.py search "one drop reggae beat"
./crumbvector.py search "filter house bass" --genre house
./crumbvector.py search "polyrhythm african" --lang strudel

๐Ÿ“ฆ Dependencies

# Python Packages
pip install chromadb requests pyyaml --break-system-packages

# Ollama (fรผr lokale Embeddings)
# macOS:
brew install ollama

# Linux:
curl -fsSL https://ollama.com/install.sh | sh

# Embedding Model
ollama pull nomic-embed-text

๐Ÿ” Trust System

Nur Repos mit gรผltiger .crumbvector/trust.yaml werden indexiert:

# .crumbvector/trust.yaml
certification:
  status: verified
  license: CKL-1.0
  verified_by: crumbforest
  verified_at: 2026-01-13

trust_level: 4  # 1-5 Scale

allowed_for:
  - teaching
  - code_completion
  - pattern_search
  - remix

Trust Levels

Level Beschreibung
1 Unknown (nur License-Datei)
2 Community reviewed
3 Maintainer verified
4 Foundation certified
5 Core/Official

๐Ÿ’ป CLI Commands

Ingest

# Lokales Verzeichnis
./crumbvector.py ingest ./mein-repo --local

# Git Repository
./crumbvector.py ingest https://github.com/user/repo

# Mit Mindest-Trust
./crumbvector.py ingest ./repo --local --min-trust 3

# In andere Collection
./crumbvector.py ingest ./repo --local --collection patterns

Search

# Einfache Suche
./crumbvector.py search "wie mache ich einen beat"

# Mit Filtern
./crumbvector.py search "bass line" --genre reggae
./crumbvector.py search "drum pattern" --lang strudel
./crumbvector.py search "euclid rhythm" --genre baobab

# Mehr Ergebnisse
./crumbvector.py search "filter sweep" -n 10

๐ŸŽต Beispiel: CrumbMidi Suche

$ ./crumbvector.py search "one drop beat" --genre reggae

๐Ÿ” CrumbVector - Searching
โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”
   Query: one drop beat
   Genre: reggae

โ”โ”โ” Result 1 (distance: 0.234) โ”โ”โ”
๐Ÿ“ patterns/REGGAE_DUB_75BPM.js
๐Ÿท๏ธ  strudel | pattern | reggae | ONE DROP
๐Ÿ” Trust: 4 | CKL-1.0

let oneDrop = stack(
  sound("~ ~ bd ~").gain(1.1).lpf(150).room(0.2),
  sound("~ ~ rim ~").gain(0.7).hpf(800).room(0.15)
)
...

๐Ÿ“ Architektur

crumbvector/
โ”œโ”€โ”€ crumbvector.py      # Main script
โ”œโ”€โ”€ setup.sh            # Installation helper
โ”œโ”€โ”€ CONCEPT.md          # Detailed architecture docs
โ”œโ”€โ”€ README.md           # This file
โ””โ”€โ”€ crumbvector_db/     # ChromaDB storage (auto-created)

๐Ÿ”„ Pipeline

1. INGEST
   โ”œโ”€โ”€ Clone/Read Repository
   โ”œโ”€โ”€ Verify Trust (.crumbvector/trust.yaml)
   โ”œโ”€โ”€ Check License
   โ””โ”€โ”€ Extract Metadata

2. CHUNK
   โ”œโ”€โ”€ Strudel: By sections & let/const patterns
   โ”œโ”€โ”€ Python: By functions & classes
   โ”œโ”€โ”€ Bash: By functions
   โ””โ”€โ”€ Markdown: By headers

3. EMBED (Ollama)
   โ”œโ”€โ”€ Prepare text with metadata context
   โ”œโ”€โ”€ Generate vector (nomic-embed-text)
   โ””โ”€โ”€ 768-dimensional embeddings

4. STORE (ChromaDB)
   โ”œโ”€โ”€ Vectors + Documents + Metadata
   โ”œโ”€โ”€ Persistent local storage
   โ””โ”€โ”€ Fast similarity search

5. QUERY
   โ”œโ”€โ”€ Natural language input
   โ”œโ”€โ”€ Convert to embedding
   โ”œโ”€โ”€ Similarity search with filters
   โ””โ”€โ”€ Return ranked results

๐ŸŽ›๏ธ Chunking Strategien

Strudel Patterns (.js)

// Erkennt Sections:
// โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•
// SECTION TITLE
// โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•

// Und Pattern-Definitionen:
let patternName = stack(...)
const anotherPattern = note(...)

Python

# Chunked by:
def function_name():    # โ†’ function chunk
    ...

class ClassName:        # โ†’ class chunk
    ...

Markdown

# Header 1        โ†’ Section chunk
## Header 2       โ†’ Section chunk
### Header 3      โ†’ Section chunk

๐ŸฆŠ Integration mit Crumbforest

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚                                                                             โ”‚
โ”‚   CrumbMidi (Patterns)                                                      โ”‚
โ”‚        โ”‚                                                                    โ”‚
โ”‚        โ–ผ                                                                    โ”‚
โ”‚   CrumbVector (Index)  โ—„โ”€โ”€โ”€โ”€ Query: "wie mache ich house drums?"           โ”‚
โ”‚        โ”‚                                                                    โ”‚
โ”‚        โ–ผ                                                                    โ”‚
โ”‚   โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”          โ”‚
โ”‚   โ”‚ Result: OLDSCHOOL_HOUSE_128BPM.js                           โ”‚          โ”‚
โ”‚   โ”‚ "sound('bd bd bd bd')" + "sound('~ hh ~ hh')"               โ”‚          โ”‚
โ”‚   โ”‚ Trust: 4 | License: CKL                                     โ”‚          โ”‚
โ”‚   โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜          โ”‚
โ”‚        โ”‚                                                                    โ”‚
โ”‚        โ–ผ                                                                    โ”‚
โ”‚   Strudel (Play!)                                                          โ”‚
โ”‚                                                                             โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

๐Ÿ”ฎ Roadmap

  • [ ] FastAPI Server (crumbvector serve)
  • [ ] Web UI fรผr Suche
  • [ ] VSCode Extension
  • [ ] Multi-Repo Support
  • [ ] Trust Verification via Signatures
  • [ ] Code Completion Integration
  • [ ] Strudel REPL Integration

๐ŸฆŠ FunkFox says

"Nicht jeder Code verdient Vertrauen.
 Nicht jede Antwort ist richtig.

 CrumbVector gibt dir:
 โœ“ Verified Code
 โœ“ Licensed Content
 โœ“ No Hallucination

 Code finden. Code verstehen. Code vertrauen."

#crumbvector #rag #semantic-search #chromadb #ollama #trust

๐Ÿง ๐Ÿ”๐Ÿ“š