{"id":31767687,"url":"https://github.com/theogyeezy/rag-multi-agent-template","last_synced_at":"2026-05-08T06:48:12.022Z","repository":{"id":316934781,"uuid":"1065374576","full_name":"theogyeezy/rag-multi-agent-template","owner":"theogyeezy","description":"RAG enabled multi agent template using CrewAI and WatsonxAI. Supports ChromaDB, FAISS, Pinecone with document processing for PDF/DOCX/TXT. Includes legal, technical, and customer support examples.","archived":false,"fork":false,"pushed_at":"2025-09-27T17:08:47.000Z","size":69,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-09-27T18:28:09.808Z","etag":null,"topics":["agent","ai","crewai","document-processing","knowledge-base","langchain","multi-agent","multiagent","multiagenttemplate","nlp","python","rag","ragtemplate","template","vector-database","watsonx","watsonxai"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/theogyeezy.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-09-27T15:43:38.000Z","updated_at":"2025-09-27T17:18:46.000Z","dependencies_parsed_at":"2025-09-27T18:25:04.278Z","dependency_job_id":"413a5643-43d5-4d2e-8dce-4e2523040416","html_url":"https://github.com/theogyeezy/rag-multi-agent-template","commit_stats":null,"previous_names":["theogyeezy/multi-agent-dodgers","theogyeezy/multi-agent-template"],"tags_count":2,"template":true,"template_full_name":null,"purl":"pkg:github/theogyeezy/rag-multi-agent-template","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/theogyeezy%2Frag-multi-agent-template","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/theogyeezy%2Frag-multi-agent-template/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/theogyeezy%2Frag-multi-agent-template/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/theogyeezy%2Frag-multi-agent-template/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/theogyeezy","download_url":"https://codeload.github.com/theogyeezy/rag-multi-agent-template/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/theogyeezy%2Frag-multi-agent-template/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279002397,"owners_count":26083373,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-09T02:00:07.460Z","response_time":59,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["agent","ai","crewai","document-processing","knowledge-base","langchain","multi-agent","multiagent","multiagenttemplate","nlp","python","rag","ragtemplate","template","vector-database","watsonx","watsonxai"],"created_at":"2025-10-10T01:18:53.161Z","updated_at":"2025-10-10T01:18:59.000Z","avatar_url":"https://github.com/theogyeezy.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Multi-Agent RAG Template\n\nA comprehensive template for creating RAG-enabled multi-agent systems using CrewAI and IBM WatsonxAI.\n\n## Overview\n\nThis template provides both basic multi-agent functionality and advanced RAG (Retrieval-Augmented Generation) capabilities. Choose from two implementations:\n\n### Basic Multi-Agent System (`agent.py`)\n- **Researcher Agent** - Conducts web research using search tools\n- **Writer Agent** - Creates written content based on research findings\n\n### RAG-Enabled Multi-Agent System (`rag_agent.py`)\n- **RAG-Powered Agents** - Access local knowledge bases for document-based research\n- **Configurable Vector Databases** - Support for ChromaDB, FAISS, and Pinecone\n- **Document Processing** - Handle PDF, DOCX, TXT, and Markdown files\n- **Flexible Templates** - Pre-built configurations for legal, technical, and support use cases\n\n## Quick Start\n\n### 1. Install Dependencies\n```bash\npip install -r requirements.txt\n```\n\n### 2. Configure API Keys\nSet your environment variables:\n```bash\nexport API_KEY=\"your_watsonx_api_key\"\nexport SERPER_API_KEY=\"your_serper_api_key\"  # Optional for web search\n```\n\n### 3. Choose Your Implementation\n\n#### Basic Multi-Agent System\n```bash\npython agent.py\n```\n\n#### RAG-Enabled System\n1. Configure your settings in `config/rag_config_template.py`\n2. Add documents to `data/documents/`\n3. Run the RAG system:\n```bash\npython rag_agent.py\n```\n\n## RAG Features\n\n### Vector Database Support\n- **ChromaDB** - Local vector database (default)\n- **FAISS** - High-performance similarity search\n- **Pinecone** - Cloud-based vector database\n\n### Document Processing\n- **PDF** - Extract text from PDF documents\n- **DOCX** - Process Word documents\n- **TXT/MD** - Plain text and Markdown files\n- **Chunking** - Intelligent text splitting with overlap\n\n### Embedding Models\n- **Sentence Transformers** - Local embeddings (default)\n- **OpenAI** - Cloud-based embeddings\n- **Custom** - Easy integration of other models\n\n## Configuration\n\n### RAG Configuration (`config/rag_config_template.py`)\n```python\nclass RAGConfig:\n    VECTOR_DB = \"chroma\"  # or \"faiss\", \"pinecone\"\n    EMBEDDING_MODEL = \"sentence-transformers\"\n    CHUNK_SIZE = 500\n    RETRIEVAL_K = 3\n    # ... more options\n```\n\n### Agent Templates\nPre-built templates for common use cases:\n- **Legal Research** - Legal document analysis and research\n- **Technical Documentation** - API docs and technical guides\n- **Customer Support** - FAQ and troubleshooting assistance\n- **Medical Research** - Clinical literature review\n- **Business Analysis** - Market research and intelligence\n\n## Examples\n\n### Legal Research System\n```python\n# See examples/legal_research_example.py\npython examples/legal_research_example.py\n```\n\n### Technical Documentation\n```python\n# See examples/technical_docs_example.py\npython examples/technical_docs_example.py\n```\n\n### Customer Support\n```python\n# See examples/customer_support_example.py\npython examples/customer_support_example.py\n```\n\n## Project Structure\n\n```\nMulti Agent/\n├── agent.py                 # Basic multi-agent system\n├── rag_agent.py            # RAG-enabled system\n├── config/\n│   └── rag_config_template.py\n├── rag/\n│   ├── vector_stores/       # Vector database implementations\n│   ├── document_processors/ # Document processing pipeline\n│   ├── embeddings/         # Embedding model abstractions\n│   ├── tools/              # RAG retrieval tools\n│   └── knowledge_base_manager.py\n├── templates/\n│   ├── agent_templates.py   # Pre-built agent configurations\n│   └── task_templates.py    # Pre-built task templates\n├── examples/               # Complete use case examples\n├── data/\n│   └── documents/          # Your document storage\n└── requirements.txt\n```\n\n## Customization\n\n### Creating Custom Agents\n```python\nfrom templates import AgentTemplates\n\ncustom_agent = AgentTemplates.create_custom_rag_agent(\n    llm=llm,\n    rag_tool=rag_tool,\n    role=\"Your Custom Role\",\n    goal=\"Your Custom Goal\",\n    backstory=\"Your Custom Backstory\"\n)\n```\n\n### Adding Custom Tasks\n```python\nfrom templates import TaskTemplates\n\ncustom_task = TaskTemplates.create_custom_task(\n    agent=agent,\n    description=\"Your task description\",\n    expected_output=\"Your expected output format\",\n    output_file=\"output.md\"\n)\n```\n\n### Knowledge Base Management\n```python\nfrom rag.knowledge_base_manager import KnowledgeBaseManager\n\nkb = KnowledgeBaseManager(config)\nresult = kb.add_documents_from_path(\"path/to/documents\")\nsearch_results = kb.search_knowledge_base(\"query\", k=5)\n```\n\n## Requirements\n\n### Core Dependencies\n- CrewAI \u003e= 0.28.8\n- langchain-ibm \u003e= 0.1.0\n- IBM WatsonxAI access\n\n### Vector Database Options (choose one)\n- chromadb \u003e= 0.4.15 (local)\n- faiss-cpu \u003e= 1.7.4 (local)\n- pinecone-client \u003e= 2.2.4 (cloud)\n\n### Document Processing\n- PyPDF2 \u003e= 3.0.1 (PDF support)\n- python-docx \u003e= 0.8.11 (DOCX support)\n- sentence-transformers \u003e= 2.2.2 (embeddings)\n\n## Advanced Features\n\n### Multiple Vector Databases\nSwitch between vector databases by changing configuration:\n```python\nconfig = {\"vector_db\": \"chroma\"}  # or \"faiss\", \"pinecone\"\n```\n\n### Custom Embedding Models\nImplement custom embeddings:\n```python\nfrom rag.embeddings import BaseEmbeddings\n\nclass CustomEmbeddings(BaseEmbeddings):\n    def embed_documents(self, texts):\n        # Your implementation\n        pass\n```\n\n### Batch Document Processing\nProcess multiple document types:\n```python\nfrom rag.document_processors import DocumentProcessorFactory\n\nchunks = DocumentProcessorFactory.process_documents(file_paths, config)\n```\n\n## License\n\nThis template is provided as-is for educational and development purposes.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftheogyeezy%2Frag-multi-agent-template","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftheogyeezy%2Frag-multi-agent-template","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftheogyeezy%2Frag-multi-agent-template/lists"}