{"id":49640621,"url":"https://github.com/areebahmeddd/cognito.ai","last_synced_at":"2026-05-05T19:32:23.460Z","repository":{"id":315438162,"uuid":"1059008568","full_name":"areebahmeddd/cognito.ai","owner":"areebahmeddd","description":"🔎 Natural Language Interface for Digital Forensic Evidence","archived":false,"fork":false,"pushed_at":"2025-12-01T12:42:32.000Z","size":5529,"stargazers_count":3,"open_issues_count":8,"forks_count":0,"subscribers_count":0,"default_branch":"testing","last_synced_at":"2025-12-04T01:15:05.157Z","etag":null,"topics":["agentic-ai","digital-forensics","elasticsearch","fastapi","langchain","neo4j","t3-stack","ufdr-tool"],"latest_commit_sha":null,"homepage":"https://trycognito-ai.vercel.app","language":"TypeScript","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/areebahmeddd.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"docs/CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"docs/CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"docs/SECURITY.md","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-17T21:29:43.000Z","updated_at":"2025-12-03T10:22:54.000Z","dependencies_parsed_at":"2025-09-18T17:15:34.725Z","dependency_job_id":"5bd6a765-7ed9-476d-9ffc-6916d3609fb0","html_url":"https://github.com/areebahmeddd/cognito.ai","commit_stats":null,"previous_names":["areebahmeddd/cognito.ai"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/areebahmeddd/cognito.ai","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/areebahmeddd%2Fcognito.ai","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/areebahmeddd%2Fcognito.ai/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/areebahmeddd%2Fcognito.ai/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/areebahmeddd%2Fcognito.ai/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/areebahmeddd","download_url":"https://codeload.github.com/areebahmeddd/cognito.ai/tar.gz/refs/heads/testing","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/areebahmeddd%2Fcognito.ai/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32664867,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-05T11:29:49.557Z","status":"ssl_error","status_checked_at":"2026-05-05T11:29:48.587Z","response_time":54,"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":["agentic-ai","digital-forensics","elasticsearch","fastapi","langchain","neo4j","t3-stack","ufdr-tool"],"created_at":"2026-05-05T19:32:22.594Z","updated_at":"2026-05-05T19:32:23.453Z","avatar_url":"https://github.com/areebahmeddd.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\n  \u003cimg src=\"frontend/public/logo.png\" alt=\"Project Logo\"\u003e\n\u003c/p\u003e\n\n# 🧠 Project Description\n\n**cognito.ai** is a natural‑language forensic evidence discovery engine for UFDR (Universal Forensic Extraction Device Report) data. It ingests UFDR exports, normalizes heterogeneous schemas with deterministic IDs, and indexes into Elasticsearch search engine using category‑aware mappings. [ [Project Demo](https://www.youtube.com/watch?v=nPmozZFyn9Q) | [Project Abstract](https://docs.google.com/document/d/1MFKM0IF8x_RIVlebnfSWHOk4HerEkuZhx3HQc1r5wIs/edit?usp=sharing) | [Project PPT](https://docs.google.com/presentation/d/1n7_xvl8xx3r6QOR7TCP-oiH9NknoiszoKVyfP6TVlBM/edit?usp=sharing) ]\n\n**Built for** [Smart India Hackathon - 2025](https://sih.gov.in)\n\n### Key Features\n\n- **Real-time Search**: Elasticsearch with category-aware mappings and faceted filters.\n- **UFDR Ingestion**: normalized schemas and deterministic IDs across heterogeneous exports.\n- **Natural-Language Querying**: Gemini-powered NLQ translated to Elasticsearch DSL.\n- **Secure Persistence**: MongoDB storage with JWT-based authentication.\n- **Visual Analytics**: timeline and network views, case drill-downs, exportable reports.\n- **Dev-Friendly Setup**: Docker Compose for ES + Mongo; FastAPI + Next.js local dev.\n\n**[📄 Sample AI-Generated Report](https://trycognito-ai.vercel.app/sample_report.pdf)** - See an example of our platform's comprehensive forensic analysis output.\n\n## 🗂️ Project Structure\n\n```\n.\n├── backend/\n│   ├── app/\n│   │   ├── core/                # Settings, DB/ES bootstrap\n│   │   ├── models/              # Pydantic models (UFDRDocument)\n│   │   ├── routes/              # FastAPI routes\n│   │   ├── services/            # Elasticsearch, parser, classifier, AI intent planner, auth\n│   │   ├── utils/               # Helpers\n│   │   └── main.py              # FastAPI app entrypoint\n│   ├── data/                    # Sample data (e.g., ufdr.jsonl)\n│   ├── pyproject.toml           # Python deps\n│   └── uv.lock                  # Locked dependency resolution\n├── frontend/\n│   ├── app/                     # Next.js app routes/pages\n│   ├── components/              # UI \u0026 dashboard components\n│   ├── hooks/, lib/, styles/    # Frontend utilities\n│   └── package.json             # Web deps\n├── scripts/                     # Utilities (reindex, test API)\n├── docker/                      # Docker configuration files\n├── docs/                        # Misc docs\n└── docker-compose.yaml          # Local Elasticsearch\n```\n\n## 🏗️ Project Design\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"frontend/public/architecture.png\" alt=\"System Architecture\"\u003e\n  \u003cbr\u003e\n  System Architecture\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"frontend/public/sequence.png\" alt=\"Sequence Diagram\"\u003e\n  \u003cbr\u003e\n  Sequence Diagram\n\u003c/p\u003e\n\n## 🎯 Project Milestones\n\n### Completed:\n\n- [x] Add Elasticsearch indexing support for UFDR documents ([@areeb](https://github.com/areebahmeddd))\n- [x] Define schema support in Elasticsearch for multiple file data types ([@areeb](https://github.com/areebahmeddd))\n- [x] Build Gemini-powered NLQ layer to dynamically generate Elasticsearch DSL queries ([@areeb](https://github.com/areebahmeddd))\n- [x] Integrate MongoDB ([@shivansh](https://github.com/SpaceTesla))\n- [x] Implement JWT-based authentication system ([@shivansh](https://github.com/SpaceTesla))\n- [x] Develop pipeline to extract TSV and convert to JSON from UFDR files ([@hamad](https://github.com/therealhamad))\n- [x] Add Neo4j visualization support ([@avantika](https://github.com/avii09))\n- [x] Enable report export generation ([@bhavana](https://github.com/bhaaaav))\n- [x] Design and implement web UI ([@areeb](https://github.com/areebahmeddd), [@shivansh](https://github.com/SpaceTesla))\n- [x] Set up CI/CD pipeline for DigitalOcean + Cloudflare Pages deployment ([@areeb](https://github.com/areebahmeddd))\n\n### In Progress:\n\n- [ ] Upgrade NLQ layer with Mixtral NeMo (12B SLM) support ([@anish](https://github.com/Av7danger))\n- [ ] Upgrade ETL pipeline to better sync with multiple services ([@areeb](https://github.com/areebahmeddd))\n- [ ] Develop ETL pipeline for additional file types ([@hamad](https://github.com/therealhamad))\n- [ ] Write Pytest tests ([@avantika](https://github.com/avii09))\n- [ ] Write Cypress tests ([@shivansh](https://github.com/SpaceTesla))\n- [ ] Configure NGINX ([@areeb](https://github.com/areebahmeddd))\n- [ ] Set up CI workflow to generate dynamic docs on merges to `testing` branch ([@bhavana](https://github.com/bhaaaav))\n- [ ] Add Redis caching for search results ([@avantika](https://github.com/avii09))\n\n## 🖼️ Project Preview\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"frontend/public/landing.png\" alt=\"Landing Page\"\u003e\n  \u003cbr\u003e\n  Landing Page\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"frontend/public/home.png\" alt=\"Home Page\"\u003e\n  \u003cbr\u003e\n  Home Page\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"frontend/public/cases.png\" alt=\"Your Cases Page\"\u003e\n  \u003cbr\u003e\n  Your Cases Page\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"frontend/public/upload.png\" alt=\"Create Modal\"\u003e\n  \u003cbr\u003e\n  Create Case Modal\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"frontend/public/viewer.png\" alt=\"Artifact Modal\"\u003e\n  \u003cbr\u003e\n  UFDR Artifact Inspector\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"frontend/public/results.png\" alt=\"Results Page\"\u003e\n  \u003cbr\u003e\n  Search Results Page\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"frontend/public/timeline.png\" alt=\"Timeline Page\"\u003e\n  \u003cbr\u003e\n  Timeline Analysis Page\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"frontend/public/network.png\" alt=\"Nework Page\"\u003e\n  \u003cbr\u003e\n  Network Correlation Page\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"frontend/public/summary.png\" alt=\"Summary Page\"\u003e\n  \u003cbr\u003e\n  Case Summary Page\n\u003c/p\u003e\n\n## ⚙️ Setup for Development\n\n1. Clone the repo:\n\n```bash\ngit clone https://github.com/areebahmeddd/cognito.ai.git\ncd cognito.ai\n```\n\n2. Start Elasticsearch (single-node) via Docker Compose:\n\n```bash\ndocker compose up -d\n```\n\n3. Configure environment variables:\n\nCreate a `.env` file in `backend/`:\n\n```\nELASTICSEARCH_URL=http://localhost:9200\nELASTICSEARCH_INDEX=cognito\nJWT_SECRET_KEY=\u003cyour_jwt_secret_key\u003e\nJWT_ALGORITHM=\u003cyour_jwt_algorithm\u003e\nJWT_EXPIRE_MINUTES=\u003cyour_jwt_expire_minutes\u003e\nMONGODB_CONNECTION_STRING=mongodb://localhost:27017/cognito\nGEMINI_API_KEY=\u003cyour_api_key\u003e\n```\n\nCreate a `.env` file in `frontend/`:\n\n```\nNEXTAUTH_URL=http://localhost:3000\nNEXTAUTH_SECRET=\u003cyour_nextauth_secret\u003e\nNEXT_PUBLIC_API_URL=http://127.0.0.1:8000/api/v1\n```\n\n## 🖥️ Backend (FastAPI)\n\nInstall and run API:\n\n```bash\ncd backend\nuv sync\nuv run app.main:app --host 0.0.0.0 --port 8000 --reload\n```\n\nSwagger UI: `http://localhost:8000/docs`\n\n## 🌐 Frontend (Next.js)\n\n```bash\ncd frontend\nnpm clean-install\nnpm run dev\n```\n\n## 🧰 Scripts\n\n### 1. Nuke Infra (Fresh Start)\n\nWipes Elasticsearch index (and wildcard) and then MongoDB database.\n\n- Uses env vars with these defaults:\n  - `ELASTICSEARCH_URL=http://localhost:9200`\n  - `ELASTICSEARCH_INDEX=cognito`\n  - `MONGODB_CONNECTION_STRING=mongodb://localhost:27017/cognito`\n\n```bash\npython scripts/nuke_infra.py\n```\n\n### 2. Generate Mock UFDR ZIPs (for testing)\n\nCreates synthetic UFDR-like TSV bundles as ZIPs at the project root: `Test_UFDR-1.zip`, `Test_UFDR-2.zip`, `Test_UFDR-3.zip`.\n\n```bash\npython scripts/mock_zip.py\n```\n\n## 📜 License\n\nThis project is licensed under the [MIT License](LICENSE).\n\n## 👥 Authors\n\n- [Areeb Ahmed](https://github.com/areebahmeddd)\n- [Hamad Hussain](https://github.com/therealhamad)\n- [Shivansh Karan](https://github.com/SpaceTesla)\n- [Anish Varma](https://github.com/Av7danger)\n- [Avantika Kesarwani](https://github.com/avii09)\n- [Bhavana Subramani](https://github.com/bhaaaav)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fareebahmeddd%2Fcognito.ai","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fareebahmeddd%2Fcognito.ai","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fareebahmeddd%2Fcognito.ai/lists"}