npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

jimeng3.0-mcp-steve

v1.0.2

Published

即梦 AI MCP 服务,支持文生图、图生图、视频生成功能

Readme

即梦 AI MCP 服务

即梦 AI MCP 服务是一个基于 Model Context Protocol (MCP) 的 Node.js 包,提供即梦 AI 的文生图、图生图、视频生成功能。

功能特性

  • 🎨 文生图 3.1: 基于文本提示词生成高质量图片
  • 🖼️ 图生图 3.0: 智能参考图片进行编辑和生成
  • 🎬 视频生成 3.0 Pro: 支持文生视频和图生视频(首帧)
  • 🔧 MCP 协议: 完全兼容 MCP 标准,可直接在支持 MCP 的客户端中使用
  • 📦 NPX 支持: 支持通过 npx 直接运行,无需全局安装

快速开始

1. 安装

# 通过 npm 安装
npm install -g jimeng3.0-mcp-steve

# 或直接使用 npx(推荐)
npx jimeng3.0-mcp-steve

2. 获取 API 密钥

  1. 访问 火山引擎控制台
  2. 开通即梦 AI 服务
  3. 获取 Access Key 和 Secret Key

3. 配置环境变量

export VOLCENGINE_ACCESS_KEY="your_access_key"
export VOLCENGINE_SECRET_KEY="your_secret_key"

4. MCP 客户端配置

将以下配置添加到你的 MCP 客户端配置文件中:

{
  "mcpServers": {
    "jimeng-ai": {
      "command": "npx",
      "args": ["jimeng3.0-mcp-steve"],
      "env": {
        "VOLCENGINE_ACCESS_KEY": "your_access_key_here",
        "VOLCENGINE_SECRET_KEY": "your_secret_key_here"
      }
    }
  }
}

可用工具

1. 文生图 3.1 (text_to_image_31)

基于文本提示词生成图片。

参数:

  • prompt (必需): 图片生成提示词,建议长度 ≤ 120字符
  • use_pre_llm (可选): 是否开启文本扩写,默认 true
  • seed (可选): 随机种子,默认 -1(随机)
  • width (可选): 图片宽度
  • height (可选): 图片高度
  • add_watermark (可选): 是否添加水印,默认 false

示例:

{
  "prompt": "一只可爱的小猫在花园里玩耍,阳光明媚",
  "width": 1024,
  "height": 1024
}

2. 图生图 3.0 (image_to_image_30)

基于参考图片和文本提示词进行图片编辑。

参数:

  • prompt (必需): 编辑提示词
  • image_path (可选): 本地图片文件路径
  • image_url (可选): 图片 URL(与 image_path 二选一)
  • scale (可选): 文本影响程度 [0-1],默认 0.5
  • seed (可选): 随机种子,默认 -1
  • width (可选): 输出图片宽度
  • height (可选): 输出图片高度
  • add_watermark (可选): 是否添加水印,默认 false

示例:

{
  "prompt": "把背景改成海边",
  "image_path": "/path/to/image.jpg",
  "scale": 0.7
}

3. 文生视频 3.0 Pro (text_to_video_30_pro)

基于文本提示词生成视频。

参数:

  • prompt (必需): 视频生成提示词,建议 ≤ 400字符
  • seed (可选): 随机种子,默认 -1
  • frames (可选): 视频帧数,121(5秒)或 241(10秒),默认 121
  • aspect_ratio (可选): 长宽比,可选 16:9, 4:3, 1:1, 3:4, 9:16, 21:9

示例:

{
  "prompt": "一只小鸟在天空中自由飞翔,蓝天白云",
  "frames": 241,
  "aspect_ratio": "16:9"
}

4. 图生视频 3.0 Pro (image_to_video_30_pro)

基于首帧图片和文本提示词生成视频。

参数:

  • prompt (必需): 视频生成提示词
  • image_path (可选): 首帧图片文件路径
  • image_url (可选): 首帧图片 URL(与 image_path 二选一)
  • seed (可选): 随机种子,默认 -1
  • frames (可选): 视频帧数,121(5秒)或 241(10秒),默认 121

示例:

{
  "prompt": "人物微笑挥手",
  "image_path": "/path/to/first_frame.jpg",
  "frames": 121
}

高级用法

自定义图片尺寸

支持的标准尺寸:

文生图 3.1:

  • 标清 1K: 1328×1328 (1:1), 1472×1104 (4:3), 1584×1056 (3:2), 1664×936 (16:9), 2016×864 (21:9)
  • 高清 2K: 2048×2048 (1:1), 2304×1728 (4:3), 2496×1664 (3:2), 2560×1440 (16:9), 3024×1296 (21:9)

图生图 3.0:

  • 范围: 512-2016 像素
  • 推荐尺寸: 1328×1328 (1:1), 1472×1104 (4:3), 1584×1056 (3:2), 1664×936 (16:9), 2016×864 (21:9)

视频长宽比说明

  • 2176×928 (21:9) - 超宽屏
  • 1920×1088 (16:9) - 标准宽屏
  • 1664×1248 (4:3) - 传统电视比例
  • 1440×1440 (1:1) - 正方形
  • 1248×1664 (3:4) - 竖屏
  • 1088×1920 (9:16) - 手机竖屏

提示词最佳实践

文生图提示词建议:

主体描述 + 风格特征 + 场景环境 + 画质要求

示例: "一只优雅的白色波斯猫, 油画风格, 坐在古典书房里, 高清细腻, 柔和光线"

视频提示词建议:

【基础结构】主体 + 动作 + 场景 + 镜头运动
【多镜头】镜头1 + 主体 + 动作1 + 镜头2 + 主体 + 动作2

示例: "一位女孩在海边奔跑, 镜头跟随, 夕阳西下, 海浪轻拍沙滩"

图生图编辑建议:

  • 添加/删除实体: "添加一道彩虹"
  • 修改风格: "改成漫画风格"
  • 修改色彩: "把衣服改成红色"
  • 修改背景: "背景换成森林"

错误处理

常见错误及解决方案:

  1. 认证失败: 检查 Access Key 和 Secret Key 是否正确
  2. 图片格式错误: 仅支持 JPEG、PNG 格式
  3. 图片尺寸超限: 确保图片在支持的尺寸范围内
  4. 提示词过长: 确保提示词在字符限制内
  5. 任务超时: 视频生成需要较长时间,请耐心等待

本地开发

# 克隆项目
git clone https://github.com/yourusername/jimeng3.0-mcp-steve.git
cd jimeng3.0-mcp-steve

# 安装依赖
npm install

# 设置环境变量
export VOLCENGINE_ACCESS_KEY="your_key"
export VOLCENGINE_SECRET_KEY="your_secret"

# 运行服务
npm start

许可证

MIT License

贡献

欢迎提交 Issue 和 Pull Request!

联系方式


注意: 使用本服务需要遵守即梦 AI 的服务条款和使用规范。