Complete rebrand for v1.0-simple-search branch: Directory Changes: - claude_rag/ → mini_rag/ (preserving git history) Content Changes: - Updated all imports: from claude_rag → from mini_rag - Updated all file paths: .claude-rag → .mini-rag - Updated documentation and comments - Updated configuration files and examples - Updated all tests to use mini_rag imports This ensures complete independence from Claude/Anthropic branding while maintaining all functionality and git history. Simple branch contains the basic RAG system without LLM features.
1.9 KiB
1.9 KiB
RAG System - Hybrid Mode Setup
This RAG system can operate in three modes:
🚀 Mode 1: Ollama Only (Recommended - Lightweight)
pip install -r requirements-light.txt
# Requires: ollama serve running with nomic-embed-text model
- Size: ~426MB total
- Performance: Fastest (leverages Ollama)
- Network: Uses local Ollama server
🔄 Mode 2: Hybrid (Best of Both Worlds)
pip install -r requirements-full.txt
# Works with OR without Ollama
- Size: ~3GB total (includes ML fallback)
- Resilience: Automatic fallback if Ollama unavailable
- Performance: Ollama speed when available, ML fallback when needed
🛡️ Mode 3: ML Only (Maximum Compatibility)
pip install -r requirements-full.txt
# Disable Ollama fallback in config
- Size: ~3GB total
- Compatibility: Works anywhere, no external dependencies
- Use case: Offline environments, embedded systems
🔧 Configuration
Edit .mini-rag/config.json in your project:
{
"embedding": {
"provider": "hybrid", // "hybrid", "ollama", "fallback"
"model": "nomic-embed-text:latest",
"base_url": "http://localhost:11434",
"enable_fallback": true // Set to false to disable ML fallback
}
}
📊 Status Check
from mini_rag.ollama_embeddings import OllamaEmbedder
embedder = OllamaEmbedder()
status = embedder.get_status()
print(f"Mode: {status['mode']}")
print(f"Ollama: {'✅' if status['ollama_available'] else '❌'}")
print(f"ML Fallback: {'✅' if status['fallback_available'] else '❌'}")
🎯 Automatic Behavior
- Try Ollama first - fastest and most efficient
- Fall back to ML - if Ollama unavailable and ML dependencies installed
- Use hash fallback - deterministic embeddings as last resort
The system automatically detects what's available and uses the best option!