diff --git a/.agents/plugins/marketplace.json b/.agents/plugins/marketplace.json new file mode 100644 index 0000000..422ba6a --- /dev/null +++ b/.agents/plugins/marketplace.json @@ -0,0 +1,32 @@ +{ + "name": "mcode-stack", + "interface": { + "displayName": "MCode Stack" + }, + "plugins": [ + { + "name": "ronny", + "source": { + "source": "local", + "path": "./stacks/ronny" + }, + "policy": { + "installation": "AVAILABLE", + "authentication": "ON_INSTALL" + }, + "category": "Developer Tools" + }, + { + "name": "jiachen", + "source": { + "source": "local", + "path": "./stacks/jiachen" + }, + "policy": { + "installation": "AVAILABLE", + "authentication": "ON_INSTALL" + }, + "category": "Productivity" + } + ] +} diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index c4cabb9..6e5c3c6 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -41,7 +41,10 @@ Whenever a PR changes anything inside a stack, raise `version` in its `.minimax-plugin/plugin.json` (for example `0.2.0` to `0.2.1`). People who installed the stack from the marketplace only get the update when the version -goes up, so CI fails a change without a bump. Run the same check locally with +goes up, so CI fails a change without a bump. When the stack also has +`.claude-plugin/plugin.json`, `.codex-plugin/plugin.json`, or a root +`plugin.json`, keep the same `name`, `version`, `description`, and author name +in those files. Run the same check locally with `CHECK_BASE=origin/main node scripts/check.mjs`. ## How we review diff --git a/CONTRIBUTING_ZH.md b/CONTRIBUTING_ZH.md index 8cca714..8fd0973 100644 --- a/CONTRIBUTING_ZH.md +++ b/CONTRIBUTING_ZH.md @@ -26,7 +26,7 @@ ## 修改已有的 stack -PR 只要改了某份 stack 里的文件,就要同时调高它 `.minimax-plugin/plugin.json` 里的 `version`(比如 `0.2.0` 改成 `0.2.1`)。从插件市场装的用户,只有版本号变高才会收到更新,所以不调版本号的改动 CI 会直接报错。本地可以用 `CHECK_BASE=origin/main node scripts/check.mjs` 跑同样的检查。 +PR 只要改了某份 stack 里的文件,就要同时调高它 `.minimax-plugin/plugin.json` 里的 `version`(比如 `0.2.0` 改成 `0.2.1`)。从插件市场装的用户,只有版本号变高才会收到更新,所以不调版本号的改动 CI 会直接报错。如果这份 stack 还有 `.claude-plugin/plugin.json`、`.codex-plugin/plugin.json` 或根目录的 `plugin.json`,里面的 `name`、`version`、`description` 和作者名要和 `.minimax-plugin/plugin.json` 保持一致。本地可以用 `CHECK_BASE=origin/main node scripts/check.mjs` 跑同样的检查。 ## 怎么审 diff --git a/README.md b/README.md index 389545a..382c474 100644 --- a/README.md +++ b/README.md @@ -30,6 +30,43 @@ checklist that installs straight into ## Quick start +**Claude Code, one command.** The command adds this marketplace and installs +a whole stack. In a shell: + +```bash +claude plugin install ronny --marketplace MiniMax-AI/mcode-stack +``` + +Inside a Claude Code session: + +```bash +/plugin install ronny --marketplace MiniMax-AI/mcode-stack +``` + +Use `jiachen` in place of `ronny` for that stack. From a clone of this +repository, `scripts/install.sh` installs `ronny` (`scripts/install.sh jiachen` +for that stack) with `claude` or `codex` when either is on `PATH`, and +otherwise copies that stack's skills into `~/.agents/skills/`. + +Older Claude Code can add the marketplace first, then install: + +```bash +/plugin marketplace add MiniMax-AI/mcode-stack +/plugin install ronny@mcode-stack +``` + +**Codex.** Add the marketplace, then install from the Plugins Directory or the +CLI: + +```bash +codex plugin marketplace add MiniMax-AI/mcode-stack +codex plugin add ronny@mcode-stack +``` + +Substitute `jiachen` the same way. To take a single skill instead of the +plugin, copy that skill's folder into `~/.agents/skills/`. Codex and MiniMax +Code both scan that directory; the copy steps are below. + **One skill, for all your projects:** ```bash @@ -52,7 +89,7 @@ Copy the whole `stacks/ronny` directory into that directory, then open installed as soon as it is in that directory; press Space in the panel to enable or disable it. -**Every stack, from the marketplace:** +**Every stack, from the MiniMax Code marketplace:** This repository is also a plugin marketplace, so you can install a stack without copying files and pick up updates later. In MiniMax Code desktop, open @@ -60,13 +97,6 @@ without copying files and pick up updates later. In MiniMax Code desktop, open stack then shows up as one plugin you can install, update or uninstall. Adding marketplaces is rolling out gradually, so your version may not have it yet. -The same catalog works in Claude Code: - -```bash -/plugin marketplace add MiniMax-AI/mcode-stack -/plugin install ronny@mcode-stack -``` -
More install options diff --git a/README_ZH.md b/README_ZH.md index d3dc6db..496818d 100644 --- a/README_ZH.md +++ b/README_ZH.md @@ -24,6 +24,36 @@ ## 快速开始 +**Claude Code,一条命令。** 这条命令会加上本仓库的插件市场,并装上一整份 stack。在 shell 里: + +```bash +claude plugin install ronny --marketplace MiniMax-AI/mcode-stack +``` + +在 Claude Code 会话里: + +```bash +/plugin install ronny --marketplace MiniMax-AI/mcode-stack +``` + +装 Jiachen 的 stack 时,把 `ronny` 换成 `jiachen`。克隆本仓库后可以跑 `scripts/install.sh`(默认 `ronny`,或 `scripts/install.sh jiachen`):`PATH` 里有 `claude` 或 `codex` 时,它会执行同样的安装,否则把该 stack 的 Skill 复制到 `~/.agents/skills/`。 + +较旧的 Claude Code 可以先加市场,再安装: + +```bash +/plugin marketplace add MiniMax-AI/mcode-stack +/plugin install ronny@mcode-stack +``` + +**Codex。** 先加上市场,再从 Plugins Directory 或 CLI 安装: + +```bash +codex plugin marketplace add MiniMax-AI/mcode-stack +codex plugin add ronny@mcode-stack +``` + +把 `ronny` 换成 `jiachen` 即可。如果只要某一个 Skill,把它的目录复制到 `~/.agents/skills/`。Codex 和 MiniMax Code 都会扫描这个目录,复制步骤见下文。 + **装一个 Skill,所有项目都能用:** ```bash @@ -42,17 +72,10 @@ mcode plugin marketplace list # 查看本地插件目录 把 `stacks/ronny` 整个目录复制到那个目录下,然后在 MiniMax Code 里打开 `/plugins`,按 `Ctrl+R` 刷新。本地插件放进去就算装好了,可以在面板里按空格启用或停用。 -**从插件市场安装:** +**从 MiniMax Code 插件市场安装:** 这个仓库本身也是一个插件市场,不用复制文件就能装,之后有更新也能直接拿到。在 MiniMax Code 桌面端打开「插件」,点「添加市场」,填入 `MiniMax-AI/mcode-stack`,每份 stack 都会显示成一个插件,可以安装、更新或卸载。添加市场的功能正在逐步开放,你的版本可能还没有。 -Claude Code 也能用同一份目录: - -```bash -/plugin marketplace add MiniMax-AI/mcode-stack -/plugin install ronny@mcode-stack -``` -
更多安装方式 diff --git a/scripts/check.mjs b/scripts/check.mjs index fd1fb79..802a2a1 100644 --- a/scripts/check.mjs +++ b/scripts/check.mjs @@ -5,6 +5,9 @@ // the directory, the icon and every referenced SKILL.md exist, every skill // directory is listed in the manifest, and every SKILL.md has frontmatter // with a `name` equal to its directory and a non-empty `description`. +// When a stack also has .claude-plugin/plugin.json, .codex-plugin/plugin.json, +// or a portable root plugin.json, those copies keep the same name, version, +// description, and author as .minimax-plugin/plugin.json. // 2. Marketplace: .claude-plugin/marketplace.json has exactly one entry per // stack under stacks/ and community/, named after its directory, with the // same description as its plugin.json and no component fields (the stack's @@ -85,6 +88,31 @@ function checkSkill(skillDir, name) { else if (fm.description.length > 1024) err(where, "description is longer than 1024 characters"); } +function authorName(value) { + if (typeof value === "string") return value; + if (value && typeof value === "object" && typeof value.name === "string") return value.name; + return undefined; +} + +function checkCompanionManifest(root, manifest, relPath) { + const file = join(root, relPath); + if (!existsSync(file)) return; + const where = relative(ROOT, file); + let doc; + try { + doc = JSON.parse(readFileSync(file, "utf8")); + } catch (e) { + return err(where, `does not parse: ${e.message}`); + } + if (doc.name !== manifest.name) err(where, `"name" must equal "${manifest.name}"`); + if (doc.version !== manifest.version) + err(where, `"version" ${JSON.stringify(doc.version)} must equal .minimax-plugin/plugin.json version ${JSON.stringify(manifest.version)}`); + if (doc.description !== manifest.description) + err(where, '"description" must equal the description in .minimax-plugin/plugin.json'); + if (authorName(doc.author) !== manifest.author) + err(where, `"author" name must equal ${JSON.stringify(manifest.author)}`); +} + function checkStack(root) { const name = root.split("/").pop(); const where = relative(ROOT, root); @@ -108,6 +136,9 @@ function checkStack(root) { if (!listed.has(ref)) err(where, `${ref} is not listed in plugin.json "skills"`); checkSkill(join(root, "skills", skill), skill); } + checkCompanionManifest(root, manifest, ".claude-plugin/plugin.json"); + checkCompanionManifest(root, manifest, ".codex-plugin/plugin.json"); + checkCompanionManifest(root, manifest, "plugin.json"); } const stacks = []; diff --git a/scripts/install.sh b/scripts/install.sh new file mode 100755 index 0000000..0a06f38 --- /dev/null +++ b/scripts/install.sh @@ -0,0 +1,77 @@ +#!/usr/bin/env bash +# Install one stack into Claude Code, Codex, or ~/.agents/skills/. +# +# Usage: scripts/install.sh [stack] +# stack defaults to ronny. Example: scripts/install.sh jiachen +# +# When claude or codex is on PATH, this runs that product's marketplace +# install. When neither is, it copies every skill directory under the stack +# into ~/.agents/skills/. + +set -euo pipefail + +STACK="${1:-ronny}" +MARKETPLACE="MiniMax-AI/mcode-stack" +MARKETPLACE_NAME="mcode-stack" + +if [[ "${STACK}" == "-h" || "${STACK}" == "--help" ]]; then + echo "Usage: scripts/install.sh [stack]" + echo " stack defaults to ronny. Example: scripts/install.sh jiachen" + exit 0 +fi + +if [[ $# -gt 1 ]]; then + echo "Usage: scripts/install.sh [stack]" >&2 + exit 1 +fi + +if [[ ! "${STACK}" =~ ^[a-z][a-z0-9-]*$ ]]; then + echo "Stack name must be lowercase letters, digits, and hyphens." >&2 + exit 1 +fi + +ROOT="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)" +SRC="${ROOT}/stacks/${STACK}/skills" + +if [[ ! -d "${SRC}" ]]; then + echo "No skills directory for stack '${STACK}' at ${SRC}" >&2 + exit 1 +fi + +copy_skills() { + local dest="${HOME}/.agents/skills" + local skill name found=0 + mkdir -p "${dest}" + shopt -s nullglob + for skill in "${SRC}"/*/; do + if [[ -f "${skill}SKILL.md" ]]; then + name="$(basename "${skill}")" + rm -rf "${dest}/${name}" + cp -R "${skill%/}" "${dest}/${name}" + found=1 + fi + done + shopt -u nullglob + if [[ "${found}" -eq 0 ]]; then + echo "No skills with SKILL.md under ${SRC}" >&2 + exit 1 + fi + echo "Copied skills from stacks/${STACK} into ${dest}/" +} + +used=0 +if command -v claude >/dev/null 2>&1; then + echo "Installing ${STACK} with Claude Code" + claude plugin install "${STACK}" --marketplace "${MARKETPLACE}" + used=1 +fi +if command -v codex >/dev/null 2>&1; then + echo "Installing ${STACK} with Codex" + codex plugin marketplace add "${MARKETPLACE}" + codex plugin add "${STACK}@${MARKETPLACE_NAME}" + used=1 +fi +if [[ "${used}" -eq 0 ]]; then + echo "claude and codex are not on PATH; copying skills into ~/.agents/skills/" + copy_skills +fi diff --git a/stacks/jiachen/.claude-plugin/plugin.json b/stacks/jiachen/.claude-plugin/plugin.json new file mode 100644 index 0000000..4aa8823 --- /dev/null +++ b/stacks/jiachen/.claude-plugin/plugin.json @@ -0,0 +1,11 @@ +{ + "name": "jiachen", + "displayName": "Jiachen's MCode Stack", + "version": "0.1.1", + "description": "Find the loops where you keep acting as a manual step for your agents (retrying, judging, approving, carrying context) and lift yourself out of them, plus a content pipeline that rewrites AI-sounding Chinese drafts and turns material into Xiaohongshu image posts and short vertical videos.", + "author": { + "name": "Jiachen (MiniMax Code team)" + }, + "homepage": "https://github.com/MiniMax-AI/mcode-stack/tree/main/stacks/jiachen", + "repository": "https://github.com/MiniMax-AI/mcode-stack" +} diff --git a/stacks/jiachen/.codex-plugin/plugin.json b/stacks/jiachen/.codex-plugin/plugin.json new file mode 100644 index 0000000..55a705b --- /dev/null +++ b/stacks/jiachen/.codex-plugin/plugin.json @@ -0,0 +1,25 @@ +{ + "name": "jiachen", + "version": "0.1.1", + "description": "Find the loops where you keep acting as a manual step for your agents (retrying, judging, approving, carrying context) and lift yourself out of them, plus a content pipeline that rewrites AI-sounding Chinese drafts and turns material into Xiaohongshu image posts and short vertical videos.", + "author": { + "name": "Jiachen (MiniMax Code team)" + }, + "homepage": "https://github.com/MiniMax-AI/mcode-stack/tree/main/stacks/jiachen", + "repository": "https://github.com/MiniMax-AI/mcode-stack", + "skills": "./skills/", + "interface": { + "displayName": "Jiachen's MCode Stack", + "shortDescription": "Find the loops where you keep acting as a manual step for your agents.", + "longDescription": "Find the loops where you keep acting as a manual step for your agents (retrying, judging, approving, carrying context) and lift yourself out of them, plus a content pipeline that rewrites AI-sounding Chinese drafts and turns material into Xiaohongshu image posts and short vertical videos.", + "developerName": "Jiachen (MiniMax Code team)", + "category": "Productivity", + "capabilities": ["Read", "Write"], + "websiteURL": "https://github.com/MiniMax-AI/mcode-stack/tree/main/stacks/jiachen", + "defaultPrompt": [ + "Look back at this session: where did I keep stepping in by hand?", + "Scan my recent agent sessions for repeated manual work", + "把这篇草稿改成我的风格,去掉 AI 味" + ] + } +} diff --git a/stacks/jiachen/.minimax-plugin/plugin.json b/stacks/jiachen/.minimax-plugin/plugin.json index 1599bc7..7e7a281 100644 --- a/stacks/jiachen/.minimax-plugin/plugin.json +++ b/stacks/jiachen/.minimax-plugin/plugin.json @@ -1,7 +1,7 @@ { "schemaVersion": 1, "name": "jiachen", - "version": "0.1.0", + "version": "0.1.1", "displayName": "Jiachen's MCode Stack", "description": "Find the loops where you keep acting as a manual step for your agents (retrying, judging, approving, carrying context) and lift yourself out of them, plus a content pipeline that rewrites AI-sounding Chinese drafts and turns material into Xiaohongshu image posts and short vertical videos.", "author": "Jiachen (MiniMax Code team)", diff --git a/stacks/jiachen/README.md b/stacks/jiachen/README.md index 04ac6f9..8c57381 100644 --- a/stacks/jiachen/README.md +++ b/stacks/jiachen/README.md @@ -4,6 +4,38 @@ The stack of Jiachen, an engineer on MiniMax Code: one skill that keeps taking the user out of the agent loop, and one that turns notes into posts and short videos. +## Install + +In Claude Code, one command installs this stack. In a shell: + +```bash +claude plugin install jiachen --marketplace MiniMax-AI/mcode-stack +``` + +Inside a session: + +```bash +/plugin install jiachen --marketplace MiniMax-AI/mcode-stack +``` + +Older Claude Code can add the marketplace first, then install: + +```bash +/plugin marketplace add MiniMax-AI/mcode-stack +/plugin install jiachen@mcode-stack +``` + +In Codex, add the marketplace, then install from the Plugins Directory or the CLI: + +```bash +codex plugin marketplace add MiniMax-AI/mcode-stack +codex plugin add jiachen@mcode-stack +``` + +In MiniMax Code, copy this whole directory into the local plugin directory +shown by `mcode plugin marketplace list`, or copy single skills into +`~/.agents/skills/`. See the [repository README](../../README.md#quick-start). + | Skill | What it does | | --- | --- | | [`lifting-loops`](skills/lifting-loops/SKILL.md) | Find the loops where you keep acting as a manual step for your agents (retrying, judging output, approving, carrying context, starting the same task by hand) and turn each one into a concrete fix: delete a stale rule, change a skill or `AGENTS.md`, add a script, a skill or a scheduled task. Reads local MiniMax Code, Claude Code and Codex sessions; keeps its ledger in a gitignored `private/` folder. | diff --git a/stacks/jiachen/plugin.json b/stacks/jiachen/plugin.json new file mode 100644 index 0000000..aaa9c52 --- /dev/null +++ b/stacks/jiachen/plugin.json @@ -0,0 +1,11 @@ +{ + "$schema": "https://agent-plugins.org/schemas/1.0.0/plugin.schema.json", + "name": "jiachen", + "version": "0.1.1", + "description": "Find the loops where you keep acting as a manual step for your agents (retrying, judging, approving, carrying context) and lift yourself out of them, plus a content pipeline that rewrites AI-sounding Chinese drafts and turns material into Xiaohongshu image posts and short vertical videos.", + "author": { + "name": "Jiachen (MiniMax Code team)" + }, + "homepage": "https://github.com/MiniMax-AI/mcode-stack/tree/main/stacks/jiachen", + "repository": "https://github.com/MiniMax-AI/mcode-stack" +} diff --git a/stacks/ronny/.claude-plugin/plugin.json b/stacks/ronny/.claude-plugin/plugin.json new file mode 100644 index 0000000..668443b --- /dev/null +++ b/stacks/ronny/.claude-plugin/plugin.json @@ -0,0 +1,11 @@ +{ + "name": "ronny", + "displayName": "Ronny's MCode Stack", + "version": "0.2.4", + "description": "Daily workflows and self-check skills from the MiniMax Code R&D lead: independent review, subagent split checks, tool and context budget audits, long sessions, long commands, harness experiments, trajectory review, plus everyday engineering practice for code review, review comments, small PRs, change descriptions and emergency changes.", + "author": { + "name": "Ronny (MiniMax Code team)" + }, + "homepage": "https://github.com/MiniMax-AI/mcode-stack/tree/main/stacks/ronny", + "repository": "https://github.com/MiniMax-AI/mcode-stack" +} diff --git a/stacks/ronny/.codex-plugin/plugin.json b/stacks/ronny/.codex-plugin/plugin.json new file mode 100644 index 0000000..203a466 --- /dev/null +++ b/stacks/ronny/.codex-plugin/plugin.json @@ -0,0 +1,25 @@ +{ + "name": "ronny", + "version": "0.2.4", + "description": "Daily workflows and self-check skills from the MiniMax Code R&D lead: independent review, subagent split checks, tool and context budget audits, long sessions, long commands, harness experiments, trajectory review, plus everyday engineering practice for code review, review comments, small PRs, change descriptions and emergency changes.", + "author": { + "name": "Ronny (MiniMax Code team)" + }, + "homepage": "https://github.com/MiniMax-AI/mcode-stack/tree/main/stacks/ronny", + "repository": "https://github.com/MiniMax-AI/mcode-stack", + "skills": "./skills/", + "interface": { + "displayName": "Ronny's MCode Stack", + "shortDescription": "Daily workflows and self-check skills from the MiniMax Code R&D lead.", + "longDescription": "Daily workflows and self-check skills from the MiniMax Code R&D lead: independent review, subagent split checks, tool and context budget audits, long sessions, long commands, harness experiments, trajectory review, plus everyday engineering practice for code review, review comments, small PRs, change descriptions and emergency changes.", + "developerName": "Ronny (MiniMax Code team)", + "category": "Developer Tools", + "capabilities": ["Read", "Write"], + "websiteURL": "https://github.com/MiniMax-AI/mcode-stack/tree/main/stacks/ronny", + "defaultPrompt": [ + "Review this diff from a clean context against the requirement", + "Audit how this agent handles long shell commands", + "Should this step go to a subagent or stay in the main loop?" + ] + } +} diff --git a/stacks/ronny/.minimax-plugin/plugin.json b/stacks/ronny/.minimax-plugin/plugin.json index 6dc8712..3919ce7 100644 --- a/stacks/ronny/.minimax-plugin/plugin.json +++ b/stacks/ronny/.minimax-plugin/plugin.json @@ -1,7 +1,7 @@ { "schemaVersion": 1, "name": "ronny", - "version": "0.2.3", + "version": "0.2.4", "displayName": "Ronny's MCode Stack", "description": "Daily workflows and self-check skills from the MiniMax Code R&D lead: independent review, subagent split checks, tool and context budget audits, long sessions, long commands, harness experiments, trajectory review, plus everyday engineering practice for code review, review comments, small PRs, change descriptions and emergency changes.", "author": "Ronny (MiniMax Code team)", diff --git a/stacks/ronny/README.md b/stacks/ronny/README.md index 567abc7..7115d84 100644 --- a/stacks/ronny/README.md +++ b/stacks/ronny/README.md @@ -6,13 +6,32 @@ Ronny, R&D lead of MiniMax Code. Most skills pair with an article in the ## Install -From the marketplace, in Claude Code: +In Claude Code, one command installs this stack. In a shell: + +```bash +claude plugin install ronny --marketplace MiniMax-AI/mcode-stack +``` + +Inside a session: + +```bash +/plugin install ronny --marketplace MiniMax-AI/mcode-stack +``` + +Older Claude Code can add the marketplace first, then install: ```bash /plugin marketplace add MiniMax-AI/mcode-stack /plugin install ronny@mcode-stack ``` +In Codex, add the marketplace, then install from the Plugins Directory or the CLI: + +```bash +codex plugin marketplace add MiniMax-AI/mcode-stack +codex plugin add ronny@mcode-stack +``` + In MiniMax Code, copy this whole directory into the local plugin directory shown by `mcode plugin marketplace list`, or copy single skills into `~/.agents/skills/`. See the [repository README](../../README.md#quick-start). diff --git a/stacks/ronny/plugin.json b/stacks/ronny/plugin.json new file mode 100644 index 0000000..88160de --- /dev/null +++ b/stacks/ronny/plugin.json @@ -0,0 +1,11 @@ +{ + "$schema": "https://agent-plugins.org/schemas/1.0.0/plugin.schema.json", + "name": "ronny", + "version": "0.2.4", + "description": "Daily workflows and self-check skills from the MiniMax Code R&D lead: independent review, subagent split checks, tool and context budget audits, long sessions, long commands, harness experiments, trajectory review, plus everyday engineering practice for code review, review comments, small PRs, change descriptions and emergency changes.", + "author": { + "name": "Ronny (MiniMax Code team)" + }, + "homepage": "https://github.com/MiniMax-AI/mcode-stack/tree/main/stacks/ronny", + "repository": "https://github.com/MiniMax-AI/mcode-stack" +}