From a19551de733f393488bfdd9ad0008792d6d04402 Mon Sep 17 00:00:00 2001 From: dazhi Date: Mon, 26 Oct 2026 19:51:07 +0800 Subject: [PATCH] docs(agents): cover package updates and changes to the checks or the contract docs AGENTS.md described only adding or updating a package, and the update path was one sentence. Two branches agents already take were missing: - Updating a package: keep the plugin ID, raise version, and call out a newly declared field that raises the minimum client version, since it drops older clients. - Changing the checks or the docs: minimum versions come from the first released client, not a preview build (#59 recorded 3.1.4 from a preview; the released 3.1.4 rejects the field, fixed in #81); contract, rule, test, and docs change together; the checker stays dependency-free; a new error must keep existing packages at zero errors because CI validates all of them; and contract changes go in their own PR. Assisted-by: Claude Opus 5.5 (OpenCode) --- AGENTS.md | 24 ++++++++++++++++++++---- 1 file changed, 20 insertions(+), 4 deletions(-) diff --git a/AGENTS.md b/AGENTS.md index 87c6bee..e15047b 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -1,14 +1,17 @@ # AGENTS.md -This repository hosts community Mini App packages for MiniMax Code. One task dominates: add or -update one package at `plugins///`. +This repository hosts community Mini App packages for MiniMax Code. Most tasks add or update one +package at `plugins///`; the rest change the checks or the docs (see +"Change the checks or the docs"). ## Add or update a Mini App 1. New package: copy `examples/hello-miniapp/` to `plugins///`, then replace `name`, `displayName`, `description`, `author`, `exampleQueries`, the ``, the README, and - the LICENSE holder. Update: open the existing package. Read `docs/package-contract.md` before - editing any manifest. + the LICENSE holder. Update: open the existing package, keep its plugin ID, and raise `version` + in `plugin.json`. A newly declared field that raises the minimum client version + (`docs/package-contract.md`) drops older clients; say so in the README and the PR. Read + `docs/package-contract.md` before editing any manifest. 2. Read `docs/runtime.md` before editing `miniapp/node/*`. Read `docs/security.md` before the Node code reads or writes files, spawns processes, or makes network requests. Read `docs/client.md` before the page calls `window.mcode` or a browser permission such as @@ -63,6 +66,19 @@ behaviour (files, network, processes, Agent turns, conversations read, tools cal use, tested environment); the package cannot damage Host or user data. Everything else is a suggestion. +## Change the checks or the docs + +`scripts/` mirrors the MiniMax Code package reader; `docs/` publishes the same contract. + +- A minimum in `FEATURE_MIN_HOST_VERSION` is the first released MiniMax Code that accepts the + field. Preview builds ship features early and are not evidence. +- Change `scripts/lib/contract.mjs`, the rule, its `test/<rule>.test.mjs`, and the matching + `docs/` page together, and update the docs' `Verified against` line. The checker stays + dependency-free. +- CI validates every package under `plugins/`. A new error must leave existing packages at zero + errors; otherwise ship it as a warning first. +- Keep contract changes in their own PR, apart from package updates. + ## Navigation - `docs/package-contract.md` — layout, the three manifests, portable paths, limits, permission