gm-skill 2.0.1621 → 2.0.1623
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AGENTS.md +3 -1
- package/gm-plugkit/package.json +1 -1
- package/gm-plugkit/plugkit-wasm-wrapper.js +17 -22
- package/gm.json +1 -1
- package/package.json +1 -1
package/AGENTS.md
CHANGED
|
@@ -160,7 +160,7 @@ Orchestration state is tracked via `.gm/` marker files, not hook events; the CLI
|
|
|
160
160
|
|
|
161
161
|
**Dead-watcher recovery uses `bun x gm-plugkit@latest spool`, never direct-node boot** (mechanism in rs-learn: `recall: dead-watcher recovery bun x not direct-node`).
|
|
162
162
|
|
|
163
|
-
**Apparent tooling failure is mechanical self-recovery, NEVER a question for the user and never an a/b-test/blind-restart.**
|
|
163
|
+
**Apparent tooling failure is mechanical self-recovery, NEVER a question for the user and never an a/b-test/blind-restart.** A missing spool response / stale watcher is the agent's own job: honor a future `busy_until` else boot the watcher and re-dispatch -- the spooler is sound by construction, so asking the user to do what a verb can do is a paper-spirit violation. Recovery mechanics (atomic `.status.json`, `FailedToOpenSocket` retry, debug-via-`window.*`-globals) in rs-learn (`recall: spooler self-recovery mechanics`).
|
|
164
164
|
|
|
165
165
|
**Process-of-elimination is the debugging paradigm EVERYWHERE, and manual real-services witness is the verification paradigm EVERYWHERE.** Every debug -- code, wasm, cascade, browser, the spooler itself -- enumerates candidate causes as mutables and eliminates each by a witness read against real input (`exec_js`/`codesearch`/`Read`/`browser page.evaluate`), each elimination revealing the next, never guess-and-restart/a-b-test/shotgun. Every verification is manual labour against the real thing -- the single mock-free `test.js`, the live page, the real service, the live wasm -- never an automated unit/mock suite standing in for the real-services witness (the conventional-testing tell-tale gm replaces). Stated in `instructions/execute.md` (the served EXECUTE prose) so it reaches every LLM in-session.
|
|
166
166
|
|
|
@@ -178,5 +178,7 @@ One-shot system-state probe: dispatch `plugkit health` via the file-spool before
|
|
|
178
178
|
|
|
179
179
|
Site build + landing render is single-surface detail, fully drained to rs-learn (`recall: gm site build details`).
|
|
180
180
|
|
|
181
|
+
**The site consumes the `anentrypoint-design` SDK pro-rata, never overriding it.** `site/theme.mjs` loads the SDK at runtime (`unpkg.com/anentrypoint-design@latest`) and the local `<style>` carries ONLY render-mode plumbing (flatspace html-class toggles `article-flow`/`landing-cap`, the crumb media query) plus site article-layout rhythm that is not an SDK component -- never a themed visual component. Every graphic-design change (a token, a component's look, TOC/cli/panel/card/callout styling) is made IN the SDK repo (`../anentrypoint-design`, GitHub `AnEntrypoint/design`, npm `anentrypoint-design`) as a token-only sheet and published; the site picks it up via `@latest`. A new local CSS rule that styles a visual component is a deviation -- it belongs in the SDK. SDK component sheets are lint-gated literal-free (every color a `var(--token)`); the SDK build prefixes all selectors with the `.ds-247420` scope. Mechanism in rs-learn (`recall: design SDK pro-rata consumption`).
|
|
182
|
+
|
|
181
183
|
|
|
182
184
|
@.gm/next-step.md
|
package/gm-plugkit/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "gm-plugkit",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.1623",
|
|
4
4
|
"description": "Bootstrap and daemon-spawn tool for gm plugkit binary. Downloads the correct platform binary, verifies SHA256, and starts the spool watcher daemon. Includes plugkit-wasm-wrapper for WASM-based spool watching.",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"bin": {
|
|
@@ -2277,13 +2277,14 @@ function readInstanceVersion(instance) {
|
|
|
2277
2277
|
const result = fn();
|
|
2278
2278
|
let ptr, len;
|
|
2279
2279
|
if (typeof result === 'bigint') {
|
|
2280
|
-
|
|
2281
|
-
|
|
2280
|
+
const u = BigInt.asUintN(64, result); // normalize the i64 to unsigned before splitting (signed-ptr fix)
|
|
2281
|
+
ptr = Number(u & 0xffffffffn);
|
|
2282
|
+
len = Number(u >> 32n);
|
|
2282
2283
|
} else {
|
|
2283
|
-
ptr = Number(result)
|
|
2284
|
+
ptr = Number(result) >>> 0; // unsigned 32-bit
|
|
2284
2285
|
len = 0;
|
|
2285
2286
|
}
|
|
2286
|
-
const buf = new Uint8Array(instance.exports.memory.buffer, ptr, 64);
|
|
2287
|
+
const buf = new Uint8Array(instance.exports.memory.buffer, ptr, 64); // fresh buffer (post fn() grow)
|
|
2287
2288
|
if (len === 0) {
|
|
2288
2289
|
let end = 0;
|
|
2289
2290
|
while (end < buf.length && buf[end] !== 0) end++;
|
|
@@ -3274,20 +3275,17 @@ async function runSpoolWatcher(instance, spoolDir) {
|
|
|
3274
3275
|
}
|
|
3275
3276
|
}
|
|
3276
3277
|
|
|
3277
|
-
|
|
3278
|
-
const
|
|
3279
|
-
|
|
3280
|
-
new Uint8Array(instance.exports.memory.buffer, bodyPtr, bodyBytes.length).set(bodyBytes);
|
|
3278
|
+
// writeWasmInput re-reads memory.buffer fresh after each alloc (detached-buffer write fix).
|
|
3279
|
+
const verbPtr = writeWasmInput(instance, verbBytes, `spool-dispatch:${verb}.verb`);
|
|
3280
|
+
const bodyPtr = writeWasmInput(instance, bodyBytes, `spool-dispatch:${verb}.body`);
|
|
3281
3281
|
|
|
3282
3282
|
writeVerbActive(verb, taskBase);
|
|
3283
3283
|
const result = dispatch(verbPtr, verbBytes.length, bodyPtr, bodyBytes.length);
|
|
3284
3284
|
clearVerbActive();
|
|
3285
3285
|
|
|
3286
|
-
|
|
3287
|
-
|
|
3288
|
-
|
|
3289
|
-
const resultBytes = new Uint8Array(instance.exports.memory.buffer, ptr, len);
|
|
3290
|
-
let resultStr = new TextDecoder().decode(resultBytes);
|
|
3286
|
+
// decodeWasmResult normalizes the i64 (BigInt.asUintN), re-reads the buffer FRESH (post-grow),
|
|
3287
|
+
// guards the range, AND frees the result ptr -- so the (ptr,len) free below is dropped.
|
|
3288
|
+
let resultStr = decodeWasmResult(instance, result, `spool-dispatch:${verb}`);
|
|
3291
3289
|
|
|
3292
3290
|
if (autoRecallPayload) {
|
|
3293
3291
|
resultStr = mergeAutoRecallIntoInstructionResponse(resultStr, autoRecallPayload);
|
|
@@ -3340,7 +3338,7 @@ async function runSpoolWatcher(instance, spoolDir) {
|
|
|
3340
3338
|
|
|
3341
3339
|
try { instance.exports.plugkit_free(verbPtr, verbBytes.length); } catch (_) {}
|
|
3342
3340
|
try { instance.exports.plugkit_free(bodyPtr, bodyBytes.length); } catch (_) {}
|
|
3343
|
-
|
|
3341
|
+
// (the result ptr is freed inside decodeWasmResult above)
|
|
3344
3342
|
|
|
3345
3343
|
try { if (fs.existsSync(filePath)) fs.unlinkSync(filePath); } catch (_) {}
|
|
3346
3344
|
unmarkProcessed(key);
|
|
@@ -3988,15 +3986,12 @@ if (_isCliEntry) (async () => {
|
|
|
3988
3986
|
const dispatch = instance.exports.dispatch_verb;
|
|
3989
3987
|
const verbBytes = new TextEncoder().encode(verb);
|
|
3990
3988
|
const bodyBytes = new TextEncoder().encode(body);
|
|
3991
|
-
const verbPtr = instance
|
|
3992
|
-
const bodyPtr = instance
|
|
3993
|
-
new Uint8Array(instance.exports.memory.buffer, verbPtr, verbBytes.length).set(verbBytes);
|
|
3994
|
-
new Uint8Array(instance.exports.memory.buffer, bodyPtr, bodyBytes.length).set(bodyBytes);
|
|
3989
|
+
const verbPtr = writeWasmInput(instance, verbBytes, `cli-dispatch:${verb}.verb`);
|
|
3990
|
+
const bodyPtr = writeWasmInput(instance, bodyBytes, `cli-dispatch:${verb}.body`);
|
|
3995
3991
|
const result = dispatch(verbPtr, verbBytes.length, bodyPtr, bodyBytes.length);
|
|
3996
|
-
const
|
|
3997
|
-
|
|
3998
|
-
|
|
3999
|
-
const out = new TextDecoder().decode(new Uint8Array(instance.exports.memory.buffer, ptr, len));
|
|
3992
|
+
const out = decodeWasmResult(instance, result, `cli-dispatch:${verb}`); // normalized i64 + fresh buffer
|
|
3993
|
+
try { instance.exports.plugkit_free(verbPtr, verbBytes.length); } catch (_) {}
|
|
3994
|
+
try { instance.exports.plugkit_free(bodyPtr, bodyBytes.length); } catch (_) {}
|
|
4000
3995
|
process.stdout.write(out);
|
|
4001
3996
|
let parsed;
|
|
4002
3997
|
try { parsed = JSON.parse(out); } catch (_) { parsed = null; }
|
package/gm.json
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "gm-skill",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.1623",
|
|
4
4
|
"description": "Canonical universal harness — AI-native software engineering via skill-driven orchestration; bootstraps plugkit for task execution and session isolation. Install in any AI coding agent host.",
|
|
5
5
|
"author": "AnEntrypoint",
|
|
6
6
|
"license": "MIT",
|