ai-model-web

Generate and stream AI text responses in frontend apps via CloudBase JS SDK.

72|5|Updated Jan 22, 2026
One-click install
npx skills add https://github.com/TencentCloudBase/skills --skill ai-model-web
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: ai-model-web
Source: https://github.com/TencentCloudBase/skills/tree/main/skills/ai-model-web
Command: npx skills add https://github.com/TencentCloudBase/skills --skill ai-model-web

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This skill enables frontend apps to access AI capabilities by calling models in the browser using CloudBase JS SDK, reducing backend dependencies and enabling interactive experiences.

Core Features & Use Cases

  • Text generation and streaming in frontend web apps using CloudBase JS SDK.
  • Supports built-in models like Hunyuan and DeepSeek for client-side AI tasks.
  • Use Case: Add a conversational AI assistant to a React or Vue SPA with real-time streaming responses.

Quick Start

Install the CloudBase JS SDK and initialize in your app. npm install @cloudbase/js-sdk import cloudbase from '@cloudbase/js-sdk'; const app = cloudbase.init({ env: "<YOUR_ENV_ID>", accessKey: "<YOUR_PUBLISHABLE_KEY>" }); const ai = app.ai();

Frequently Asked Questions about ai-model-web

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I stream AI text generation responses directly in a frontend web app?

To stream AI text generation in a frontend web app, initialize the CloudBase JS SDK with your environment ID and access key, then call the AI module to generate and stream responses from models like Hunyuan or DeepSeek directly in the browser.

Can I use Hunyuan and DeepSeek models for client-side AI tasks without a backend?

Yes, you can use Hunyuan and DeepSeek models for client-side AI tasks without a backend by leveraging the CloudBase JS SDK to handle authentication and model invocation directly from your browser-based UI.

What is the best way to add a conversational AI assistant to a React or Vue SPA?

The best way to add a conversational AI assistant to a React or Vue SPA is using the CloudBase JS SDK to call built-in models like Hunyuan, enabling real-time streaming responses for interactive experiences.

Do I need client-side authentication to perform AI tasks with the CloudBase JS SDK?

Yes, you need client-side authentication to perform AI tasks with the CloudBase JS SDK, requiring you to initialize the app with a publishable access key to securely call models from the browser.

Does the CloudBase JS SDK support real-time streaming for AI generated text?

Yes, the CloudBase JS SDK supports real-time streaming for AI generated text, allowing frontend apps to display progressive model outputs interactively as the response is generated.