{"id":30020451,"url":"https://github.com/sayedgamal99/ask-ai-about-your-data","last_synced_at":"2026-04-18T07:32:36.604Z","repository":{"id":307882873,"uuid":"1029306941","full_name":"sayedgamal99/ask-ai-about-your-data","owner":"sayedgamal99","description":"End-to-end project that demonstrates how to build a conversational data analysis tool. Users can upload a CSV file and ask questions about it in natural language. The backend, powered by FastAPI and Ollama, uses an LLM to dynamically generate, execute, and interpret Python Pandas code to provide answers. Containerized using Docker.","archived":false,"fork":false,"pushed_at":"2025-08-02T19:08:15.000Z","size":73,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-08-02T20:55:28.660Z","etag":null,"topics":["fastapi","llm","ollama"],"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/sayedgamal99.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}},"created_at":"2025-07-30T20:53:29.000Z","updated_at":"2025-08-02T19:08:18.000Z","dependencies_parsed_at":"2025-08-02T20:55:32.507Z","dependency_job_id":"4ceb9f8f-8fe7-4afe-9aec-358353d12355","html_url":"https://github.com/sayedgamal99/ask-ai-about-your-data","commit_stats":null,"previous_names":["sayedgamal99/ask-ai-about-your-data"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/sayedgamal99/ask-ai-about-your-data","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sayedgamal99%2Fask-ai-about-your-data","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sayedgamal99%2Fask-ai-about-your-data/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sayedgamal99%2Fask-ai-about-your-data/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sayedgamal99%2Fask-ai-about-your-data/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sayedgamal99","download_url":"https://codeload.github.com/sayedgamal99/ask-ai-about-your-data/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sayedgamal99%2Fask-ai-about-your-data/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31961188,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-18T00:39:45.007Z","status":"online","status_checked_at":"2026-04-18T02:00:07.018Z","response_time":103,"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":["fastapi","llm","ollama"],"created_at":"2025-08-06T02:02:07.252Z","updated_at":"2026-04-18T07:32:36.580Z","avatar_url":"https://github.com/sayedgamal99.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Ask AI About Your Data\n\nA FastAPI application that allows users to upload CSV files and ask questions in natural language. The AI converts questions into executable Python code using pandas and provides intelligent answers.\n\n## Features\n\n- Upload CSV files via REST API\n- Ask questions in natural language about your data\n- AI-powered data analysis using Ollama (gemma3:4b model)\n- Web interface with Streamlit\n- Frontend HTML/JavaScript interface\n- RESTful API built with FastAPI\n\n## Quick Start\n\n### Using Docker\n\n#### If you have Ollama and gemma3:4b model:\n1. Clone the repository\n2. Copy `.env.example` to `.env` and configure if needed\n3. Run with Docker:\n\n```bash\ndocker build -t ask-ai-about-data .\ndocker run -p 9999:9999 -p 5599:5599 ask-ai-about-data\n```\n\n#### If you don't have Ollama:\n1. Clone the repository\n2. Copy `.env.example` to `.env` and configure if needed\n3. Run with Docker Compose:\n\n```bash\ndocker compose up\n```\n\n### Local Development\n1. Install dependencies: `pip install -r requirements.txt`\n2. Start Ollama service locally\n3. Run FastAPI server: `uvicorn src.main:app --host 0.0.0.0 --port 5599`\n4. Choose one of the UI options:\n   - **Streamlit UI**: `streamlit run src/streamlit_app.py` (Access at `http://localhost:8501`)\n   - **Frontend UI**: `cd src/frontend \u0026\u0026 python -m http.server 9999` (Access at `http://localhost:9999`)\n\n## Usage\n\n### Via Frontend Web Interface (HTML/JavaScript)\n1. Run `cd src/frontend \u0026\u0026 python -m http.server 8000`\n2. Open `http://localhost:8000` in your web browser\n\n\n### Via Streamlit Web Interface\n1. Open `http://localhost:8501`\n2. Upload your CSV file\n3. Ask questions in natural language like:\n   - \"What is the average age?\"\n   - \"Show me the top 5 customers by sales\"\n   - \"How many rows are in this dataset?\"\n\n### Via API\n1. Upload CSV: `POST /upload`\n2. Ask questions: `POST /answer` with file_id and question\n\n## API Endpoints\n\n- `GET /` - API information and status\n- `POST /upload` - Upload CSV file, returns file_id\n- `POST /answer` - Ask question about uploaded file\n\n## Requirements\n\n- Python 3.8+\n- Ollama service with gemma3:4b model\n- FastAPI and Streamlit\n- pandas for data processing\n\n## Configuration\n\nEnvironment variables (optional):\n- `OLLAMA_BASE_URL` - Ollama service URL (default: http://localhost:11434)\n- `OLLAMA_MODEL` - AI model to use (default: gemma3:4b)\n- `API_BASE_URL` - FastAPI base URL (default: http://localhost:5599)\n- `API_PORT` - API port (default: 5599)","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsayedgamal99%2Fask-ai-about-your-data","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsayedgamal99%2Fask-ai-about-your-data","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsayedgamal99%2Fask-ai-about-your-data/lists"}