0
179
近 7 天 23
33.4
生态多维模型
14 天前
2026-09-20
快速安装与配置
opencode.json写入当前项目的 opencode.json,只对这个仓库生效。
opencode.json
{
"$schema": "https://opencode.ai/config.json",
"plugin": ["opencode-xai-extras@0.0.2"]
}写入 ~/.config/opencode/opencode.json,对所有项目生效。
~/.config/opencode/opencode.json
{
"$schema": "https://opencode.ai/config.json",
"plugin": ["opencode-xai-extras@0.0.2"]
}若你要在本地改造这个插件,先装到项目里再从本地路径引用。
shell
pnpm add -D opencode-xai-extrasOpenCode 启动时会通过内嵌运行时自动加载 npm 依赖并缓存至本地目录,无需手动在全局环境执行安装。
OpenCode V2 plugins.
| Package | Plugin id | What it adds |
|---|---|---|
| opencode-xai-extras | ferspective07.xai-extras |
xAI SuperGrok web search, X search, Grok Imagine, speech-to-text, text-to-speech |
Each package has its own README (install, /connect, tools, options).
Development
pnpm install
pnpm check
Requires pnpm. pnpm check runs typecheck (every packages/*), oxlint, oxfmt, and Vitest.
New plugin:
pnpm new-plugin session-foo
That creates packages/session-foo (npm opencode-session-foo, plugin id ferspective07.session-foo). Add a row to the table above. Each package versions and publishes independently through Changesets.
After a user-facing change, record it:
pnpm changeset
On GitHub, pushing user-facing changes to main opens a Version packages PR. CI must pass; that PR is then merged automatically. That bump updates CHANGELOG, creates git tags plus GitHub Releases (opencode-xai-extras@x.y.z), and publishes to npm via trusted publishing.
同类生态推荐
Open Grok Build
open-grok-build
Grok Build provider, OAuth, multi-account rotation, quota tracking and Imagine image generation for OpenCode v2.
Grok Imagine
opencode-grok-imagine-plugin
opencode plugin for xAI Grok Imagine image and video generation (grok-imagine-image, grok-imagine-image-quality, grok-imagine-video, grok-imagine-video-1.5-preview) via a CLIProxyAPI/OpenAI-compatible endpoint.
Feishu
opencode-feishu-plugin
Feishu/Lark plugin for OpenCode V2 — single-user topics as sessions, in-card permission approvals, streaming cards. Minimal permissions, no public endpoint.