{"id":17728137,"url":"https://github.com/usp-open-code/icmc-open-chatbot","last_synced_at":"2026-04-02T02:05:41.729Z","repository":{"id":258313765,"uuid":"870471473","full_name":"USP-Open-Code/icmc-open-chatbot","owner":"USP-Open-Code","description":"Este projeto tem como objetivo desenvolver um chatbot para ajudar alunos a navegarem pelos serviços oferecidos pela universidade. O chatbot utiliza as tecnologias LlamaIndex, Llama3 e RAG (Retrieval-Augmented Generation) para fornecer respostas precisas e contextualizadas, integrando informações institucionais de maneira eficiente.","archived":false,"fork":false,"pushed_at":"2025-05-28T23:28:08.000Z","size":195,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-05-29T00:32:41.084Z","etag":null,"topics":["icmc","llama","llm","projeto"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/USP-Open-Code.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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}},"created_at":"2024-10-10T05:30:17.000Z","updated_at":"2025-05-28T23:28:12.000Z","dependencies_parsed_at":"2024-10-18T12:13:34.209Z","dependency_job_id":"f2a175fb-d5ef-4b50-8329-f79fae98d997","html_url":"https://github.com/USP-Open-Code/icmc-open-chatbot","commit_stats":null,"previous_names":["usp-open-code/icmc-open-chatbot"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/USP-Open-Code/icmc-open-chatbot","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/USP-Open-Code%2Ficmc-open-chatbot","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/USP-Open-Code%2Ficmc-open-chatbot/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/USP-Open-Code%2Ficmc-open-chatbot/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/USP-Open-Code%2Ficmc-open-chatbot/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/USP-Open-Code","download_url":"https://codeload.github.com/USP-Open-Code/icmc-open-chatbot/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/USP-Open-Code%2Ficmc-open-chatbot/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":270065443,"owners_count":24520946,"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-08-12T02:00:09.011Z","response_time":80,"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":["icmc","llama","llm","projeto"],"created_at":"2024-10-25T19:05:38.161Z","updated_at":"2026-04-02T02:05:41.598Z","avatar_url":"https://github.com/USP-Open-Code.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Bot de Notícias\n\n![Python](https://img.shields.io/badge/Python-3776AB?style=for-the-badge\u0026logo=python\u0026logoColor=white)\n![Docker](https://img.shields.io/badge/Docker-2496ED?style=for-the-badge\u0026logo=docker\u0026logoColor=white)\n![MongoDB](https://img.shields.io/badge/MongoDB-4EA94B?style=for-the-badge\u0026logo=mongodb\u0026logoColor=white)\n![LangChain](https://img.shields.io/badge/LangChain-FF9900?style=for-the-badge\u0026logo=LangChain\u0026logoColor=white)\n![FastAPI](https://img.shields.io/badge/FastAPI-009688?style=for-the-badge\u0026logo=fastapi\u0026logoColor=white)\n![LangGraph](https://img.shields.io/badge/LangGraph-007ACC?style=for-the-badge\u0026logo=langgraph\u0026logoColor=white)\n![ChromaDB](https://img.shields.io/badge/ChromaDB-FFA500?style=for-the-badge\u0026logo=prisma\u0026logoColor=white)\n![Llama](https://img.shields.io/badge/Llama-FF6B6B?style=for-the-badge\u0026logo=meta\u0026logoColor=white)\n![OpenAI](https://img.shields.io/badge/OpenAI-412991?style=for-the-badge\u0026logo=openai\u0026logoColor=white)\n![C++](https://img.shields.io/badge/C++-00599C?style=for-the-badge\u0026logo=c%2B%2B\u0026logoColor=white)\n\n## Sobre o Projeto\n\nÉ aplicação conversacional baseada em um grafo que utiliza a técnica de Retrieval-Augmented Generation (RAG), com um nó adicional de correção. Antes de gerar uma resposta com base em um documento semanticamente semelhante, o sistema avalia seu contexto, garantindo maior precisão e coerência.\n\nO sistema adota uma arquitetura em camadas (Layered Architecture), utilizando FastAPI como framework principal para a API REST. O armazenamento é dividido entre ChromaDB, responsável pela gestão dos arquivos usados no RAG, e MongoDB, que armazena os logs da aplicação.\n\nO processamento de linguagem natural é realizado por meio do LangChain e LangGraph, que orquestram os agentes e implementam a lógica baseada em grafos. Toda a infraestrutura é containerizada com Docker e Docker Compose, garantindo facilidade de implantação e escalabilidade.\n\nA API e os containers já estão configurados. Para iniciar a aplicação, basta executar:\n\n```bash\n# BUILDAR E EXECUTAR O PROJETO\ndocker-compose -f docker/docker-compose.yml --env-file .env up --build\n```\nPS: Não se esqueça de alterar os [Prompts](src/services/crag/prompts.py).\n\n## O grafo\n\u003cpre\u003e\u003ccode\u003e```mermaid\ngraph TD\n\t__start__([\u003cp\u003e__start__\u003c/p\u003e]):::first\n\tfind_references(find_references)\n\tagent(agent)\n\ttools(tools)\n\tcrag(crag)\n\tgenerate(generate)\n\t__end__([\u003cp\u003e__end__\u003c/p\u003e]):::last\n\tcrag --\u003egenerate;\n\tfind_references --\u003e generate;\n\tgenerate --\u003e __end__;\n\ttools --\u003e crag;\n\t__start__ -. \u0026nbsp;general\u0026nbsp; .-\u003e agent;\n\t__start__ -. \u0026nbsp;specific\u0026nbsp; .-\u003e find_references;\n\tagent -.\u0026nbsp;continue\u0026nbsp; .-\u003e tools;\n\tagent -. \u0026nbsp;end\u0026nbsp; .-\u003e __end__\n```\u003c/code\u003e\u003c/pre\u003e\n\n\n\n## Autor\n\n**[@CuriousGu](https://www.github.com/CuriousGu) 🇧🇷**\n\n## Docs\n1. [Estrutura](docs/pt_br/ESTRUTURA.md)\n2. [Instalação](docs/pt_br/INSTALACAO.md)\n3. [Configurações](docs/pt_br/CONFIGURACAO.md)\n4. [API](docs/pt_br/API.md)\n5. [Contribuição](docs/pt_br/CONTRIBUICAO.md)\n\n## Licença\n\nEste projeto está sob a licença MIT, sinta-se a vontade para usar. \n\nVeja o arquivo [LICENSE](LICENSE) para mais detalhes.\n\n## Contatos\n- Email: gustavo_ortega@usp.br\n- Linkedin: [Gustavo M. Ortega](https://www.linkedin.com/in/gustavomendoncaortega/)\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fusp-open-code%2Ficmc-open-chatbot","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fusp-open-code%2Ficmc-open-chatbot","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fusp-open-code%2Ficmc-open-chatbot/lists"}