Skip to main content

Accessible document chat and RAG system (Ollama backend)

Project description

๐Ÿฆ™ Doc Chat AI (Llamaball)

Accessible document chat and RAG system powered by Ollama

A comprehensive toolkit for document ingestion, embedding generation, and conversational AI interactions with your local documents. Built with accessibility and local privacy as core principles.

๐Ÿš€ Quick Start with Llamaball

The project has been packaged as llamaball - an installable CLI and Python library:

# Install the package
pip install -e .

# Ingest documents
llamaball ingest .

# Start chatting
llamaball chat

๐Ÿ“ฆ What's Included

๐Ÿฆ™ Llamaball Package (llamaball/)

  • Interactive CLI with rich formatting and accessibility features
  • Python API for programmatic use
  • Comprehensive documentation with all flags and examples
  • Screen reader friendly output and navigation

๐Ÿ› ๏ธ Setup Scripts

  • quick-setup.sh - Automated model downloads and configuration
  • start-rag-system.sh - System startup
  • stop-rag-system.sh - Clean shutdown
  • test-rag-system.sh - Integration testing

๐Ÿ“‹ Model Configurations (models/)

  • Modelfile.gemma3:1b - Gemma 3 1B configuration
  • Modelfile.qwen3:0.6b - Qwen3 0.6B configuration
  • Modelfile.qwen3:1.7b - Qwen3 1.7B configuration
  • Modelfile.qwen3:4b - Qwen3 4B configuration

๐Ÿ Legacy Scripts (Transitioning)

  • doc_chat_ollama.py - Original Ollama implementation (now in llamaball.core)
  • doc_chat_openai.py - OpenAI implementation

๐ŸŽฏ Features

  • ๐Ÿ  100% Local Processing: All data stays on your machine
  • โ™ฟ Accessibility First: Screen reader support, keyboard navigation, clear structure
  • ๐Ÿ–ฅ๏ธ Rich CLI: Beautiful terminal interface with progress indicators
  • ๐Ÿ“š Smart Document Parsing: Intelligent chunking for optimal embeddings
  • ๐Ÿ” Semantic Search: Fast vector similarity search
  • ๐Ÿ’ฌ Interactive Chat: Natural conversations with your documents
  • ๐Ÿ“Š Database Management: Comprehensive statistics and file management

๐Ÿ“‹ CLI Commands

See the complete documentation in llamaball/README.md or run:

llamaball --help              # Main help
llamaball ingest --help       # Ingestion options
llamaball chat --help         # Chat configuration
llamaball stats --help        # Database statistics

๐Ÿ”ง Development Setup

# Clone and install
git clone <repository>
cd doc_chat_ai
pip install -e .

# Run setup (optional - for Ollama models)
./quick-setup.sh

# Start using llamaball
llamaball ingest .
llamaball chat

๐Ÿ Python API Usage

from llamaball import core

# Ingest documents
core.ingest_files("./docs", recursive=True)

# Search embeddings  
results = core.search_embeddings(query="search term", top_k=5)

# Chat with documents
response = core.chat(user_input="What is this about?", history=[])

๐ŸŽ›๏ธ Configuration

Environment Variables

  • CHAT_MODEL: Default chat model (default: llama3.2:1b)
  • OLLAMA_ENDPOINT: Ollama server endpoint

Supported File Types

  • Text: .txt, .md
  • Code: .py, .js, .html, .css
  • Data: .json, .csv

โ™ฟ Accessibility Features

  • Screen Reader Support: Semantic markup and clear structure
  • Keyboard Navigation: Full CLI functionality via keyboard
  • High Contrast Output: Rich terminal formatting with good contrast
  • Clear Error Messages: Descriptive feedback with suggested solutions
  • Progress Indicators: Real-time feedback during operations
  • Consistent Layout: Predictable command structure

๐Ÿ“ Project Structure

doc_chat_ai/
โ”œโ”€โ”€ llamaball/              # Main package
โ”‚   โ”œโ”€โ”€ __init__.py
โ”‚   โ”œโ”€โ”€ cli.py             # CLI interface  
โ”‚   โ”œโ”€โ”€ core.py            # Core functionality
โ”‚   โ”œโ”€โ”€ utils.py           # Utilities
โ”‚   โ””โ”€โ”€ README.md          # Package documentation
โ”œโ”€โ”€ models/                # Model configurations
โ”œโ”€โ”€ configs/               # Configuration files
โ”œโ”€โ”€ scripts/               # Utility scripts
โ”œโ”€โ”€ setup.py               # Package installation
โ””โ”€โ”€ README.md              # This file

๐Ÿค Contributing

  1. Follow accessibility-first design principles
  2. Include comprehensive docstrings and type hints
  3. Test with screen readers when possible
  4. Maintain consistent CLI patterns
  5. Update documentation for all changes

๐Ÿ“„ License

MIT License - Built with โค๏ธ for accessibility and local AI.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

llamaball-0.1.0.tar.gz (36.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

llamaball-0.1.0-py3-none-any.whl (36.7 kB view details)

Uploaded Python 3

File details

Details for the file llamaball-0.1.0.tar.gz.

File metadata

  • Download URL: llamaball-0.1.0.tar.gz
  • Upload date:
  • Size: 36.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.12

File hashes

Hashes for llamaball-0.1.0.tar.gz
Algorithm Hash digest
SHA256 9163a524b76c5799a82b674f86ce14857619209d37767dbd545a49969f9517c8
MD5 494467979e84342df14fcdec694ff88d
BLAKE2b-256 ccd37eb1135756724040e427a0f3d28f23b126903c451011d4f9bb15f784b8d4

See more details on using hashes here.

File details

Details for the file llamaball-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: llamaball-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 36.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.12

File hashes

Hashes for llamaball-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 c0014737cee329dfeb91a7a89af9b755e956a7cfaa26e7de8f4885cedce02545
MD5 e9592f4ffc0ece113146f8c6ed7bc49d
BLAKE2b-256 fbc0939faf5fd549047851a07a48725565e4ddbac33eb8e22b49b435db100ec1

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page