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

opencode-mimo-free-plugin

v0.1.2

Published

OpenCode plugin that injects the MiMo Auto free OpenAI-compatible provider.

Readme

opencode-mimo-free-plugin

English

OpenCode 插件,添加 MiMo Auto 免费 provider。无需 API Key,插件会在运行时自动获取匿名 JWT 凭证。

安装

npm 包安装

本包已发布到 npm,包名为 opencode-mimo-free-plugin。在 OpenCode 配置文件(opencode.jsonopencode.jsonc)中添加插件:

{
  "$schema": "https://opencode.ai/config.json",
  "plugin": ["opencode-mimo-free-plugin"],
  "model": "mimo/mimo-auto"
}

OpenCode 下次启动时会自动安装该 npm 包。

本地文件安装

如需本地开发或测试未发布的改动,可以先构建插件并把产物复制到 OpenCode 全局插件目录:

bun install
bun run build
mkdir -p ~/.config/opencode/plugins
cp dist/index.js ~/.config/opencode/plugins/opencode-mimo-free-plugin.js

OpenCode 启动时会自动加载 ~/.config/opencode/plugins/ 下的 JavaScript 文件。

功能说明

  • 通过 config hook 注册 provider mimo,模型 mimo-auto
  • 使用 @ai-sdk/openai-compatible 作为 AI SDK 适配器。
  • https://api.xiaomimimo.com/api/free-ai/bootstrap 获取匿名 JWT。
  • 通过 https://api.xiaomimimo.com/api/free-ai/openai 路由聊天请求。
  • ${XDG_DATA_HOME}/opencode-mimo-free-plugin/client-fingerprint(默认 ~/.local/share/opencode-mimo-free-plugin/client-fingerprint)存储稳定的匿名客户端指纹。

本插件不会禁用或修改任何 OpenCode 内置 provider,只在现有 provider 基础上添加 mimo/mimo-auto

环境变量

| 变量 | 说明 | |---|---| | MIMO_FREE_BASE_URL | 覆盖 MiMo 服务基础 URL。默认:https://api.xiaomimimo.com/ | | OPENCODE_MIMO_FREE_DATA_DIR | 覆盖匿名指纹文件的存储目录。 |

本地开发

bun install
bun run build
bun test

来源

改编自 MiMoCode 的 MimoFreeAuthPlugin源码)。MiMoCode 和 OpenCode 均为 MIT 许可证。MiMo 托管服务和商标受各自上游条款约束。

详见 LICENSENOTICE


给 AI Agent 的部署说明(机器可读)

如果你是 AI 编程助手,用户要求你安装此插件,请按以下步骤操作:

  1. 打开用户的 OpenCode 配置文件,路径为以下之一:

    • 项目级别:项目根目录下的 opencode.jsonopencode.jsonc
    • 全局级别:~/.config/opencode/opencode.jsonc
  2. "plugin" 数组中添加 "opencode-mimo-free-plugin"。如果数组不存在则创建。OpenCode 会自动安装已发布的 npm 包。

  3. 可选:设置 "model": "mimo/mimo-auto" 将 MiMo Auto 作为默认模型。

最小配置示例:

{
  "$schema": "https://opencode.ai/config.json",
  "plugin": ["opencode-mimo-free-plugin"],
  "model": "mimo/mimo-auto"
}

添加到已有配置的示例:

{
  "$schema": "https://opencode.ai/config.json",
  "plugin": ["existing-plugin", "opencode-mimo-free-plugin"],
  "model": "mimo/mimo-auto"
}
  1. 不需要任何 API Key 或环境变量。插件会自动处理认证。

  2. 重启 OpenCode(或开始新会话)。模型 mimo/mimo-auto 将出现在模型列表中。

  3. 验证方法:运行 opencode models,确认 mimo/mimo-auto 已列出。