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

svmc-cli

v1.0.3

Published

SVMC CLI for media-center image workflows

Readme

svmc-cli

media-center-frontend 的图像/视频生成能力封装为可供 Agent 调用的命令行工具。

安装与构建

npm install
npm run build

本地调试:

npm run dev -- --help

鉴权

svmc auth

该命令会引导输入 SVMC_ACCESS_TOKEN 并写入 ~/.svmc/config.toml。 服务地址默认固定使用生产环境 https://media.sailvan.com/api/v1auth 不再询问 base_url)。

验证认证状态:

svmc auth status

获取参数规格

svmc img2img specs --provider nano-banana

仅列出 provider 列表:

svmc img2img specs

发起图生图任务

svmc img2img generate \
  --provider nano-banana \
  --input "img1.jpg" \
  --input "img2.png" \
  --prompt "cyberpunk style" \
  --ratio "16:9"

支持传递动态参数(会原样透传给后端):

svmc img2img generate ... --steps 20 --guidance_scale 7

任务轮询间隔固定 5 秒,完成后输出:

IMAGE_SAVED: /abs/path/to/file.jpg
MEDIA:/abs/path/to/file.jpg

其他任务命令

以下模块都遵循相同流程:动态获取 params、按 provider 规格校验参数、提交任务并轮询 get_task、下载结果。

  • 修图:svmc editImage specs / svmc editImage generate
  • 文生图:svmc text2img specs / svmc text2img generate
  • 图生视频:svmc img2video specs / svmc img2video generate
  • 文生视频:svmc text2video specs / svmc text2video generate

示例(修图):

svmc editImage generate \
  --provider nano-banana \
  --input "origin.jpg" \
  --prompt "remove watermark"

示例(文生视频):

svmc text2video generate \
  --provider kling \
  --prompt "a panda dancing in snowfall" \
  --ratio "16:9"

端到端验收脚本

  1. svmc auth,写入 token。
  2. svmc img2img specs --provider <provider>,确认返回规格。
  3. svmc img2img generate --provider <provider> --input <img> --prompt "..."
  4. 观察输出包含 IMAGE_SAVEDMEDIA,并确认本地文件存在。

CLI 自更新

可使用以下任一命令将 svmc-cli 自动更新到最新版本:

svmc update
# 或
svmc upgrade

命令会自动识别当前包管理器(npm/pnpm/yarn/bun)并执行全局更新。

质量命令

npm run lint:eslint
npm run type-check
npm test

npm 发布流程

发布前建议先确认当前 npm 登录账号:

npm whoami

1) 发布前检查

npm install
npm run lint:eslint
npm run type-check
npm test
npm run build

2) 更新版本号

按语义化版本选择其一:

npm version patch
# 或 npm version minor
# 或 npm version major

3) 执行发布

npm publish

如果是首次发布非 scoped 包,使用:

npm publish --access public

4) 发布后验证

npm view svmc-cli version
npm view svmc-cli dist-tags

如需快速验证安装:

npm i -g svmc-cli@latest
svmc --version