Sponsored byOutsenseAI that finds your next clients
SponsorGROUOutbound, LinkedIn content and leads for B2B teamsSponsorOutsenseAI that finds your next clientsAd+Your tool hereSeen by people installing AI tools@Weekly picksThe best new tools, one email a week

ai-model-nodejs

Skill by LeoYeAI

Calls AI models from Node.js backends and CloudBase cloud functions using @cloudbase/node-sdk. It covers text generation, streaming text, and image generation with Hunyuan and DeepSeek models. It is for backend and serverless developers.

  • Score 85
  • 2.2k stars
  • MIT
  • Updated
Works withClaude CodeClaude apps Antigravity CLI

Install ai-model-nodejs

Built from the published package, never by AI.

git clone --depth 1 https://github.com/LeoYeAI/openclaw-master-skills /tmp/openclaw-master-skills && mkdir -p ~/.claude/skills && cp -r /tmp/openclaw-master-skills/skills/cloudbase/references/ai-model-nodejs ~/.claude/skills/ai-model-nodejs

Run in your terminal. Claude Code loads skills from ~/.claude/skills automatically.

Step-by-step: install ai-model-nodejs in Claude Code

Skills can run scripts on your machine. Some need an API key: check the README.

About

This skill guides developers who build Node.js backend services or CloudBase cloud functions that need AI features. It uses the @cloudbase/node-sdk package, version 3.16.0 or above, and covers three calls: generateText for non-streaming text, streamText for streamed output, and generateImage for images. The source lists built-in providers hunyuan-exp and deepseek, with hunyuan-2.0-instruct-20251111 and deepseek-v3.2 as recommended models, and hunyuan-image for image generation.

The skill also explains setup. It shows how to initialize the SDK inside a cloud function or on a regular Node.js server using an environment ID and credentials. It recommends longer cloud function timeouts for AI operations, with 900 seconds for image generation. It is meant for backend and serverless work such as Express, Koa, NestJS, and CloudBase cloud functions. Browser apps and WeChat Mini Programs are directed to other skills.

Written from the project's SKILL.md and checked against it.

What it can do

  • generateTextGenerates a non-streaming text response from a chosen model, with token usage and message history.
  • streamTextStreams model output as incremental text chunks or full data chunks.
  • generateImageCreates images with the hunyuan-image model and returns image URLs and revised prompts.
  • Built-in model providersOffers hunyuan-exp and deepseek providers with several named models.
  • Cloud function timeout guidanceRecommends timeout values for text, streaming, and image generation operations.

What you need

  • @cloudbase/node-sdk version 3.16.0 or above
  • A CloudBase environment ID
  • SecretId and SecretKey when running on a regular Node.js server

Try asking

  • Add a streaming AI chat endpoint to my Express backend using CloudBase.
  • Write a cloud function that generates an image with hunyuan-image.
  • Call deepseek-v3.2 from a Node.js service and return the generated text.

Good to know

  • Image generation is only available in the Node SDK, not the JS SDK for Web or WeChat Mini Programs.
  • Generated image URLs are valid for 24 hours.
  • The AI feature requires @cloudbase/node-sdk version 3.16.0 or above.
  • Not for browser apps or WeChat Mini Programs.

Security check

A

No download-and-run commands, hidden instructions or signs of sending keys out were found.

Checked automatically: skills/cloudbase/references/ai-model-nodejs/SKILL.md. This looks for known risky patterns and is not a full audit. How grades work

Inside the skill

  • SKILL.md7 KB

Alternatives to ai-model-nodejs

All alternatives →

Compare with agent-reproduce-align, google_contacts or m06-error-handling

ai-model-nodejs: common questions

Which AI models does this skill support?

The skill lists hunyuan-exp models such as hunyuan-2.0-instruct-20251111 and deepseek models such as deepseek-v3.2. It recommends hunyuan-2.0-instruct-20251111 and deepseek-v3.2 respectively.

Can it generate images?

Yes. The skill covers generateImage with the hunyuan-image model. The source says this is the only SDK that supports image generation.

Is this skill for browser or mini program apps?

No. The source says browser and Web apps should use the ai-model-web skill, and WeChat Mini Programs should use the ai-model-wechat skill.

How do I install ai-model-nodejs?

Run the command above to copy the skill into ~/.claude/skills/. Claude Code picks it up automatically.

Is ai-model-nodejs free?

The code is published under the MIT licence. The service it connects to may have its own pricing.

Is ai-model-nodejs safe to use?

It scores 85 of 100. Grades: maintenance A, licence A, quality A. Security check: grade A, no risky patterns found in the files checked. Review the code before you install. How grades work.

What are alternatives to ai-model-nodejs?

Similar skills: agent-reproduce-align, google_contacts, m06-error-handling, caveman.

ai-model-nodejs Install

Add to stack

Loading.