deprecated-generative-ai-js is a JavaScript/TypeScript client and example suite for interacting with Gemini generative APIs in web and Node.js environments. Though marked deprecated (likely superseded by newer SDKs), the repo shows how to wrap HTTP/WS endpoints, manage streaming responses, and interoperate with browser UI or server logic. The examples include chat widgets, prompt pipelines, and generalized inference utilities. It also deals with streaming cancellation, retries, backoff logic, and message chunk assembly to help developers handle real-world use. Because it’s JavaScript, the repo supports both ESM and CommonJS contexts, making it versatile in backend and frontend setups. The deprecation label reflects that newer or official SDKs may have replaced it, but many of its patterns still serve as a useful reference to understand how streaming, chunking, and prompt logic can be implemented by hand in JS.

Features

  • JavaScript / TypeScript client and example suite for Gemini APIs
  • Streaming token handling and incremental UI update logic
  • Support for prompt pipelines: chaining, transformations, prefix injection
  • Retry, cancellation, and backoff logic for robust request handling
  • Compatibility with ESM and CommonJS module environments
  • Example chat widgets and inference pipelines for web / Node.js use

Project Samples

Project Activity

See All Activity >

Categories

Generative AI

License

Apache License V2.0

Follow Generative AI JS

Generative AI JS Web Site

Other Useful Business Software
MongoDB Atlas runs apps anywhere Icon
MongoDB Atlas runs apps anywhere

Deploy in 115+ regions with the modern database for every enterprise.

MongoDB Atlas gives you the freedom to build and run modern applications anywhere—across AWS, Azure, and Google Cloud. With global availability in over 115 regions, Atlas lets you deploy close to your users, meet compliance needs, and scale with confidence across any geography.
Start Free
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of Generative AI JS!

Additional Project Details

Programming Language

TypeScript

Related Categories

TypeScript Generative AI

Registered

6 days ago