{"id":31297287,"url":"https://github.com/jasoncobra3/finops-copilot","last_synced_at":"2026-04-13T14:31:59.752Z","repository":{"id":315350830,"uuid":"1059128862","full_name":"jasoncobra3/FinOps-Copilot","owner":"jasoncobra3","description":"An end-to-end AI-powered FinOps platform that ingests cloud billing data, analyzes cost trends, answers natural-language questions using a RAG pipeline (LangChain + FAISS + sentence-transformers + Groq), and provides actionable cost optimization recommendations. Includes a FastAPI backend and Streamlit dashboard UI - fully containerized with Docker","archived":false,"fork":false,"pushed_at":"2025-09-24T19:15:19.000Z","size":2113,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-09-25T10:36:39.651Z","etag":null,"topics":["ai-assistant","cloud-cost-optimization","cloud-enginee","cost-analytics","data-analysis","devops","docker","faiss","faiss-vector-database","fastapi","finops","groq","langchain","llm","pandas","rag","rag-pipeline","sentence-transformers","sqlite3","streamlit"],"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/jasoncobra3.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-18T03:24:33.000Z","updated_at":"2025-09-24T19:15:22.000Z","dependencies_parsed_at":"2025-09-18T05:42:43.792Z","dependency_job_id":"017dc8cb-5259-4267-9109-e69e9ce4e73d","html_url":"https://github.com/jasoncobra3/FinOps-Copilot","commit_stats":null,"previous_names":["jasoncobra3/finops-copilot"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/jasoncobra3/FinOps-Copilot","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jasoncobra3%2FFinOps-Copilot","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jasoncobra3%2FFinOps-Copilot/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jasoncobra3%2FFinOps-Copilot/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jasoncobra3%2FFinOps-Copilot/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jasoncobra3","download_url":"https://codeload.github.com/jasoncobra3/FinOps-Copilot/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jasoncobra3%2FFinOps-Copilot/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31757477,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-13T13:27:56.013Z","status":"ssl_error","status_checked_at":"2026-04-13T13:21:23.512Z","response_time":93,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["ai-assistant","cloud-cost-optimization","cloud-enginee","cost-analytics","data-analysis","devops","docker","faiss","faiss-vector-database","fastapi","finops","groq","langchain","llm","pandas","rag","rag-pipeline","sentence-transformers","sqlite3","streamlit"],"created_at":"2025-09-24T22:59:13.079Z","updated_at":"2026-04-13T14:31:59.718Z","avatar_url":"https://github.com/jasoncobra3.png","language":"Python","readme":"# 🌩️ AI-driven Cloud Cost Copilot (FinOps Assistant)\r\n\r\n---\r\n\r\n## 📌 Overview\r\n**The FinOps Assistant is an AI-driven cloud cost analytics platform designed to help organizations monitor, analyze, and optimize their cloud spending.**\r\nIt provides:\r\n- End-to-end pipeline: ETL → KPIs → RAG → Recommendations → API → UI\r\n- KPI dashboards to analyze cost trends\r\n- Natural-language Q\u0026A over your cost data and FinOps documentation\r\n- Actionable recommendations to reduce costs\r\n\r\n[![Ask DeepWiki](https://deepwiki.com/badge.svg)](https://deepwiki.com/jasoncobra3/FinOps-Copilot)\r\n  \r\n---\r\n\r\n## 🧩 Features\r\n\r\n- Cost Analysis — Monthly spend trends, top cost drivers, cost anomalies\r\n- RAG Q\u0026A — Ask natural questions like “Why did compute cost increase in May?”\r\n- Recommendations — Detect idle resources, tagging gaps, sudden spikes\r\n- UI + API — Interactive Streamlit dashboard + FastAPI backend\r\n- Evaluation Suite — Measure retrieval quality (Recall@k) + answer quality\r\n\r\n---\r\n\r\n## 🧠 Architecture\r\n ![](docs/Assets/updated_architecture.png) \r\n\r\n ---\r\n\r\n ## 🗂️ Directory Structure\r\n \r\n ```\r\n├── app/\r\n│   ├── main.py             # FastAPI backend entrypoint\r\n│   ├── models.py            # SQLAlchemy schema (billing, resources)\r\n│   ├── analytics.py         # KPI \u0026 trend calculations\r\n│   ├── rag.py               # RAG pipeline setup (retriever + LLM)\r\n│   ├── etl.py               # ETL piepline to validate data\r\n|   ├── reccomendations.py   # Suggestions Generation\r\n|   ├── rag_qa.py            # LangChain QA chain logic\r\n│   └── validators.py        # input validation, prompt-injection guard \r\n|                        \r\n├── docs/                     # Project documentation\r\n│   ├── finops.md             # Refernce Docs for LLM\r\n│   ├── PRD.pdf               # Product requirement Document\r\n│   ├── Technical Design doc.pdf\r\n│   ├── Assets/              \r\n|\r\n├── UI/\r\n│   └── app.py                # Streamlit frontend dashboard\r\n├── scripts/\r\n│   ├── ingest_billing.py\r\n│   ├── seed _resources.py\r\n│   ├── build_faiss_index.py\r\n│   ├── update_assignments.py\r\n|   ├── manage_data.py\r\n│   └── ...\r\n|\r\n├── tests/                    # Testing Files for evaluation\r\n│   ├── conftest.py\r\n│   ├── evaluate_rag.py\r\n│   ├── test_analytics.py\r\n│   ├── test_reccomendations.py\r\n|   ├── test_reccomendations_api.py\r\n│   └── rag_eval_results.json\r\n|\r\n|\r\n├── data/                     # SQLite DB (billing.db) \u0026 Data Files\r\n├── requirements.txt\r\n├── Dockerfile\r\n├── docker-compose.yml\r\n├── .dockerignore\r\n├── .env.example\r\n└── README.md\r\n\r\n```\r\n---\r\n\r\n## ⚙️ Tech Stack\r\n\r\n| Layer         | Technology                                                    | Purpose                       |\r\n| ------------- | ------------------------------------------------------------- | ----------------------------- |\r\n| ETL \u0026 DB      |Python, SQLAlchemy, SQLite                                     | Data ingestion + schema       |\r\n| Analytics     |     Pandas, SQL                                               | KPI \u0026 cost trend calculations |\r\n| RAG Pipeline  | sentence-transformers, FAISS, LangChain, Groq LLM             | Natural-language Q\\\u0026A         |\r\n| API Layer     |    FastAPI                                                    | Serve KPIs and Q\\\u0026A endpoints |\r\n| Frontend      |             Streamlit                                         | Interactive dashboard UI      |\r\n| Deployment    | Docker, Docker Compose                                        | Containerization              |\r\n| Observability | LangSmith                                                     | Logging + traces              |\r\n| Security      | Prompt-injection guards, keyword filters                      | Secure LLM input              |\r\n\r\n\r\n---\r\n\r\n## 🧪 Setup \u0026 Running Locally\r\n\r\n1. **Clone repo**\r\n   ```bash\r\n   git clone https://github.com/jasoncobra3/FinOps-Copilot.git\r\n   cd FinOps-Copilot\r\n\r\n2. **Create environment**\r\n   ```bash\r\n   python -m venv .venv\r\n   source venv/bin/activate  # or venv\\\\Scripts\\\\activate (Windows)\r\n\r\n3. **Install dependencies:**\r\n   ```bash\r\n   pip install -r requirements.tx\r\n\r\n4. **Initialize DB**\r\n   ```bash\r\n     python -m app.models\r\n\r\n5. **Generate Sammple Data**\r\n   ```bash\r\n   python scripts/generate_sample_data.py\r\n\r\n7. **Ingest sample data**\r\n   ```bash\r\n   python scripts/ingest.py  --input data/sample_billing.csv\r\n   python scripts/seed_resources.py\r\n   python scripts/update_assignments.py ##generate randomness in data\r\n\r\n9. **Build RAG index**\r\n   ```bash\r\n   python scripts/build_faiss_index.py\r\n\r\n10. **Run FAstAPI Backend**\r\n    ```bash\r\n    uvicorn app.main:app --reload\r\n    \r\n- FastAPI - http://localhost:8000\r\n    \r\n12. **Run Streamlit Frontend**\r\n    ```bash\r\n    streamlit run UI/app.py\r\n     \r\n- Streamlit - http://localhost:8501\r\n    \r\n---\r\n\r\n## 📊 Evaluation\r\n\r\n**Run RAG retrieval evaluation**\r\n  ```bash\r\n     python tests/eval_rag.py\r\n  ```\r\n- Outputs Recall@1/3/5 scores in CSV\r\n- Also includes answer quality scores (1–5 rubric)\r\n\r\n---\r\n## 🧠 Design Decisions \u0026 Trade-offs\r\n\r\n- SQLite chosen for local simplicity, can migrate to PostgreSQL later\r\n- FAISS is fast and lightweight for demo scale (vs hosted vector DBs)\r\n- LangChain simplifies orchestration but adds abstraction → documented clearly\r\n- Streamlit is quick to build for MVP, though not production-grade\r\n- Groq LLM chosen to avoid dependency on paid APIs\r\n\r\n---\r\n\r\n## 🚀 Future Work\r\n\r\n- Migrate to PostgreSQL for multi-user deployments\r\n- Add real billing data ingestion from cloud APIs\r\n- Implement cost optimization engine (idle resource detection, right-sizing)\r\n- Add user auth + role-based access control\r\n- Enhance Streamlit UI (filters, charts, reports)\r\n- Deploy on Railway or Render with CI/CD\r\n\r\n---\r\n\r\n## 📸 Screenshots\r\n| Dashboard KPI View| Month DropDown | Reccommendations |\r\n|----------------|------------|---------------|\r\n| ![](docs/Assets/Screenshot_1.png) | ![](docs/Assets/Screenshot_2.png) | ![](docs/Assets/Screenshot_3.png)|\r\n\r\n| Underutilized resources| AI RAG Chatbot | Response With Resource group |\r\n|----------------|------------|----------------|\r\n|![](docs/Assets/Screenshot_5.png)| ![](docs/Assets/Screenshot_7.png) | ![](docs/Assets/Screenshot_8.png) |\r\n\r\n---\r\n## 🌟 Contributing\r\n**Feel free to fork, star, or submit a pull request to contribute improvements!**\r\n\r\n\r\n\r\n\r\n\r\n\r\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjasoncobra3%2Ffinops-copilot","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjasoncobra3%2Ffinops-copilot","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjasoncobra3%2Ffinops-copilot/lists"}