{"id":18319171,"url":"https://github.com/lakshaybhushan/nextjs-nvidia-chatbot","last_synced_at":"2025-04-12T21:43:17.988Z","repository":{"id":248122722,"uuid":"825905687","full_name":"lakshaybhushan/nextjs-nvidia-chatbot","owner":"lakshaybhushan","description":"An open-source AI chatbot app template built with Next.js, the Vercel AI SDK and the newly released NVIDIA NIM API Inference.","archived":false,"fork":false,"pushed_at":"2024-07-12T13:28:14.000Z","size":759,"stargazers_count":7,"open_issues_count":3,"forks_count":1,"subscribers_count":2,"default_branch":"yoda","last_synced_at":"2025-04-12T21:42:37.184Z","etag":null,"topics":["ai","nextjs14","nim-nextjs","nvidia","nvidia-nextjs","nvidia-nim","rsc","vercel-ai","vercel-ai-sdk"],"latest_commit_sha":null,"homepage":"https://nvidia-nim.vercel.app","language":"TypeScript","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/lakshaybhushan.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}},"created_at":"2024-07-08T18:18:44.000Z","updated_at":"2025-03-31T08:37:56.000Z","dependencies_parsed_at":"2024-07-12T14:56:04.966Z","dependency_job_id":"f75ee801-052e-4b5f-aa3e-bdef9d294bdd","html_url":"https://github.com/lakshaybhushan/nextjs-nvidia-chatbot","commit_stats":null,"previous_names":["lakshaybhushan/nextjs-nvidia-chatbot"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lakshaybhushan%2Fnextjs-nvidia-chatbot","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lakshaybhushan%2Fnextjs-nvidia-chatbot/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lakshaybhushan%2Fnextjs-nvidia-chatbot/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lakshaybhushan%2Fnextjs-nvidia-chatbot/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lakshaybhushan","download_url":"https://codeload.github.com/lakshaybhushan/nextjs-nvidia-chatbot/tar.gz/refs/heads/yoda","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248637833,"owners_count":21137538,"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","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","nextjs14","nim-nextjs","nvidia","nvidia-nextjs","nvidia-nim","rsc","vercel-ai","vercel-ai-sdk"],"created_at":"2024-11-05T18:12:39.949Z","updated_at":"2025-04-12T21:43:17.962Z","avatar_url":"https://github.com/lakshaybhushan.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003ch1 align=\"center\"\u003eNext.js AI Chatbot — NVIDIA NIM + Vercel AI SDK\u003c/h1\u003e\n\n\u003cp align=\"center\"\u003e\n\n\u003cimg src =\"https://img.shields.io/badge/Next.js-000000.svg?style=for-the-badge\u0026logo=nextdotjs\u0026logoColor=white\"\u003e\n\u003cimg src =\"https://img.shields.io/badge/TypeScript-3178C6.svg?style=for-the-badge\u0026logo=TypeScript\u0026logoColor=white\"\u003e\n\u003cimg src =\"https://img.shields.io/badge/NVIDIA-76B900.svg?style=for-the-badge\u0026logo=NVIDIA\u0026logoColor=white\"\u003e\n\u003cimg src =\"https://img.shields.io/badge/Vercel-000000.svg?style=for-the-badge\u0026logo=Vercel\u0026logoColor=white\"\u003e\n\n\u003c/p\u003e\n\n\u003ca href=\"https://nvidia-nim.vercel.app/\" target=\"_blank\"\u003e\n  \u003cimg src=\"https://nvidia-nim.vercel.app/og.png\" alt=\"Banner Image\" /\u003e\n\u003c/a\u003e\n\nAn open-source AI chatbot app template built with Next.js, the Vercel AI SDK and NVIDIA NIM.\n\n## Features\n\n- [Next.js](https://nextjs.org/) 14 App Router\n- React Server Components (RSCs) for better performance\n- [NVIDIA NIM](https://build.nvidia.com/explore/discover/) API Inference\n- [Vercel AI](https://sdk.vercel.ai/) SDK for streaming chat responses\n- [shadcn/ui](https://ui.shadcn.com/) for UI components\n- [Tailwind CSS](https://tailwindcss.com/) for styling and design\n- custom rate limiter for server actions\n- [Sonner](https://sonner.emilkowal.ski/) for beautiful toast notifications\n- [Vercel OG](https://vercel.com/docs/functions/og-image-generation) for open graph images\n\n## How It Works?\n\nThis template uses the NVIDIA NIM API to fetch the models and make inferences. The Vercel AI SDK is used to stream the responses from the server to the client in real-time.\n\n## Why custom rate limiter?\n\nNVIDIA NIM provides 1000 credits for free to every new user. So, I've implemented a custom rate limiter to prevent the users from exceeding the limit. The rate limiter is set to 10 request per hour per IP address. You can change the rate limiter settings in the [ratelimit.ts](lib/ratelimit.ts) file when deploying your own version of this template.\n\n## Models Available via NVIDIA NIM\n\nI've only included text-to-text models in this template. You can easily add more models by following the instructions in the [NVIDIA NIM documentation](https://build.nvidia.com/docs/nim/).\n\nThe models available in this template are:\n\n**Google**\n\n- `gemma-2b`\n- `gemma-2-9b-it`\n- `gemma-2-27b-it`\n\n**Meta**\n\n- `llama3-8b-instruct`\n- `llama3-70b-instruct`\n\n**NVIDIA**\n\n- `llama3-chatqa-1.5-8b`\n- `llama3-chatqa-1.5-70b`\n- `nemotron-4-340b-instruct`\n\n**IBM**\n\n- `granite-8b-code-instruct`\n- `granite-34b-code-instruct`\n\n\u003e `Mistral AI` and many other models available via NVIDIA NIM are not working with the Vercel AI SDK at the moment. So, I've excluded them from this template. However, you can still use them with the NVIDIA NIM API directly.\n\n## Deploy Your Own\n\nYou can deploy your own version of this template with Vercel by clicking the button below.\n\n[![Deploy with Vercel](https://vercel.com/button)](https://vercel.com/new/clone?repository-url=https%3A%2F%2Fgithub.com%2Flakshaybhushan%2Fnextjs-nvidia-chatbot\u0026env=NVIDIA_NIM_API_KEY\u0026demo-title=Next.js%20AI%20Chatbot%20%E2%80%94%20NVIDIA%20NIM%20%2B%20Vercel%20AI%20SDK\u0026demo-description=A%20chatbot%20demo%20built%20with%20Next.js%2C%20NVIDIA%20NIM%2C%20and%20Vercel%20AI%20SDK\u0026demo-url=https%3A%2F%2Fnvidia-nim.vercel.app%2F\u0026demo-image=https%3A%2F%2Fnvidia-nim.vercel.app%2Fog.png)\n\n## Local Development\n\nFirst, you will need to use the environment variables [defined in `.env.example`](.env.example) to create a `.env.local` file in the root of the project. And make sure not to commit your `.env.local` file to the repository.\n\n```bash\nNVIDIA_NIM_API_KEY=\n```\n\nTo get the NVIDIA NIM API key, you need to sign up on the [NVIDIA NIM website](https://build.nvidia.com/explore/discover/).\n\nThen clone the repository and install the dependencies. This project uses `bun` as the package manager.\n\n```bash\nbun install\n```\n\nRun the development server:\n\n```bash\nbun dev\n```\n\nNow the app should be running at [http://localhost:3000](http://localhost:3000).\n\n## Contributing\n\nContributions are welcome! Feel free to open an issue or submit a pull request if you have any ideas or suggestions.\n\n## License\n\nI don't know what to put here. I'm not a lawyer. Use this template however you want. It's open-source and free to use.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flakshaybhushan%2Fnextjs-nvidia-chatbot","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flakshaybhushan%2Fnextjs-nvidia-chatbot","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flakshaybhushan%2Fnextjs-nvidia-chatbot/lists"}