{"id":30607184,"url":"https://github.com/pradumnasaraf/saraf-ai","last_synced_at":"2025-08-30T03:39:39.331Z","repository":{"id":306619755,"uuid":"1026745630","full_name":"Pradumnasaraf/Saraf-AI","owner":"Pradumnasaraf","description":"Saraf AI is a fully local assistant built with Next.js and Docker. It connects seamlessly to LLMs via Docker Model Runner using Docker Compose.","archived":false,"fork":false,"pushed_at":"2025-08-14T07:29:13.000Z","size":208,"stargazers_count":7,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-08-29T09:23:14.277Z","etag":null,"topics":["ai","ai-models","docker","docker-compose","docker-model-runner","javascript","llm","nextjs","openai","typescript"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Pradumnasaraf.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":"CODEOWNERS","security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null},"funding":{"github":["eddiejaoude"]}},"created_at":"2025-07-26T14:24:13.000Z","updated_at":"2025-08-24T11:08:34.000Z","dependencies_parsed_at":"2025-07-26T21:03:12.740Z","dependency_job_id":null,"html_url":"https://github.com/Pradumnasaraf/Saraf-AI","commit_stats":null,"previous_names":["pradumnasaraf/saraf-ai"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/Pradumnasaraf/Saraf-AI","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Pradumnasaraf%2FSaraf-AI","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Pradumnasaraf%2FSaraf-AI/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Pradumnasaraf%2FSaraf-AI/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Pradumnasaraf%2FSaraf-AI/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Pradumnasaraf","download_url":"https://codeload.github.com/Pradumnasaraf/Saraf-AI/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Pradumnasaraf%2FSaraf-AI/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":272800827,"owners_count":24995138,"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-30T02:00:09.474Z","response_time":77,"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":["ai","ai-models","docker","docker-compose","docker-model-runner","javascript","llm","nextjs","openai","typescript"],"created_at":"2025-08-30T03:39:36.750Z","updated_at":"2025-08-30T03:39:39.324Z","avatar_url":"https://github.com/Pradumnasaraf.png","language":"TypeScript","funding_links":["https://github.com/sponsors/eddiejaoude"],"categories":[],"sub_categories":[],"readme":"## Saraf AI\n\n**Saraf AI** is a chat assistant built with **Next.js**, using the OpenAI API framework to interface with the [Docker Model Runner](https://docs.docker.com/ai/model-runner). It runs entirely locally, ensuring your data remains private. Communication between the application and the LLM model is handled using the latest Docker Compose support for [running LLM models](https://docs.docker.com/ai/compose/models-and-compose/), enabling seamless and secure integration.\n\n## Demo\n\nhttps://github.com/user-attachments/assets/32fb49de-336b-406a-89ad-c1e9fc80fa60\n\n## Prerequisites\n\n- Docker and Docker Compose (version **2.38.0** or newer)\n\n## Getting Started\n\n1. Clone this repository.\n2. Run `docker compose up`. This launches both the LLM model and the Next.js frontend. (Yes, it's that simple :))\n3. Visit `http://localhost:3000` in your browser.\n\n## Docker Compose Configuration\n\n```yaml\nservices:\n  saraf-ai:\n    build:\n      context: .\n      dockerfile: Dockerfile\n    ports:\n      - 3000:3000\n    # Models to run\n    models:\n      - llm\n\nmodels:\n  # Model Name\n  llm:\n    # Model Image\n    model: ai/smollm2\n```\n\nThis is a standard Docker Compose setup with an additional `models` block that lets you define and run multiple AI models within the same file. You can swap out `ai/smollm2` for any other model available in the [DockerHub AI Catalog](https://hub.docker.com/catalogs/gen-ai).\n\n\u003e The `saraf-ai` service (Next.js app) requires `LLM_URL` and `LLM_MODEL` environment variables to function. These are automatically generated by Docker and injected into the Next.js environment based on the model name, in this case `llm`. The app then uses them to connect to the local LLM instance.\n\n## License\n\nThis project is licensed under the Apache-2.0 license - see the [LICENSE](LICENSE) file for details.\n\n## Security\n\nIf you discover a security vulnerability within this project, please check the [SECURITY](SECURITY.md) for more information.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpradumnasaraf%2Fsaraf-ai","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpradumnasaraf%2Fsaraf-ai","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpradumnasaraf%2Fsaraf-ai/lists"}