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
Build Securely on Azure with Proven Frameworks Icon
Build Securely on Azure with Proven Frameworks

Lay a foundation for success with Tested Reference Architectures developed by Fortinet’s experts. Learn more in this white paper.

Moving to the cloud brings new challenges. How can you manage a larger attack surface while ensuring great network performance? Turn to Fortinet’s Tested Reference Architectures, blueprints for designing and securing cloud environments built by cybersecurity experts. Learn more and explore use cases in this white paper.
Download Now
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

2025-10-06