gm-skill 2.0.1151 → 2.0.1153
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/README.md +1 -1
- package/gm-plugkit/plugkit-wasm-wrapper.js +34 -0
- package/gm.json +1 -1
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -35,7 +35,7 @@ An earlier generation fanned out fifteen per-platform downstream repos (gm-cc, g
|
|
|
35
35
|
|
|
36
36
|
## Version
|
|
37
37
|
|
|
38
|
-
`2.0.
|
|
38
|
+
`2.0.1153` — auto-bumped from the canonical `gm` repo. Every push to `AnEntrypoint/gm` (or any cascading sibling crate) republishes this package.
|
|
39
39
|
|
|
40
40
|
## Source of truth
|
|
41
41
|
|
|
@@ -17,6 +17,38 @@ fs.mkdirSync(KV_DIR, { recursive: true });
|
|
|
17
17
|
const GM_LOG_ROOT = process.env.GM_LOG_DIR || path.join(os.homedir(), '.claude', 'gm-log');
|
|
18
18
|
const ORCHESTRATOR_VERBS = new Set(['instruction', 'transition', 'phase-status', 'prd-add', 'prd-resolve', 'prd-list', 'mutable-add', 'mutable-resolve', 'mutable-list', 'memorize-fire', 'residual-scan', 'auto-recall']);
|
|
19
19
|
|
|
20
|
+
const TURN_IDLE_MS = 30_000;
|
|
21
|
+
const _turns = new Map();
|
|
22
|
+
|
|
23
|
+
function turnTick(sess, verb, taskBase, phase) {
|
|
24
|
+
const key = sess || '(no-session)';
|
|
25
|
+
const now = Date.now();
|
|
26
|
+
let t = _turns.get(key);
|
|
27
|
+
if (verb === 'instruction') {
|
|
28
|
+
if (t && (now - t.lastTs) > TURN_IDLE_MS) {
|
|
29
|
+
logEvent('plugkit', 'turn.end', {
|
|
30
|
+
sess, turn_idx: t.idx, dur_ms: t.lastTs - t.startTs,
|
|
31
|
+
dispatches: t.dispatches, verbs: Object.fromEntries(t.verbs),
|
|
32
|
+
phases_walked: [...t.phases], deviations: t.deviations,
|
|
33
|
+
ended_in_phase: t.lastPhase || null,
|
|
34
|
+
});
|
|
35
|
+
t = null;
|
|
36
|
+
}
|
|
37
|
+
if (!t) {
|
|
38
|
+
const idx = ((_turns.get(key + ':lastIdx') || 0) + 1);
|
|
39
|
+
_turns.set(key + ':lastIdx', idx);
|
|
40
|
+
t = { idx, startTs: now, lastTs: now, dispatches: 0, verbs: new Map(), phases: new Set(), deviations: 0, lastPhase: phase };
|
|
41
|
+
_turns.set(key, t);
|
|
42
|
+
logEvent('plugkit', 'turn.start', { sess, turn_idx: idx, phase: phase || null });
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
if (!t) return;
|
|
46
|
+
t.lastTs = now;
|
|
47
|
+
t.dispatches++;
|
|
48
|
+
t.verbs.set(verb, (t.verbs.get(verb) || 0) + 1);
|
|
49
|
+
if (phase) { t.phases.add(phase); t.lastPhase = phase; }
|
|
50
|
+
}
|
|
51
|
+
|
|
20
52
|
function logEvent(sub, event, fields) {
|
|
21
53
|
if (process.env.GM_LOG_DISABLE) return;
|
|
22
54
|
try {
|
|
@@ -44,6 +76,8 @@ function emitOrchestratorEvents(verb, taskBase, resultStr) {
|
|
|
44
76
|
return;
|
|
45
77
|
}
|
|
46
78
|
const data = parsed.data || {};
|
|
79
|
+
const sess = process.env.CLAUDE_SESSION_ID || process.env.GM_SESSION_ID || '';
|
|
80
|
+
turnTick(sess, verb, taskBase, data.phase);
|
|
47
81
|
switch (verb) {
|
|
48
82
|
case 'transition':
|
|
49
83
|
logEvent('plugkit', 'phase.transitioned', { task: taskBase, phase: data.phase, next_skill: data.nextSkill, recall_count: Array.isArray(data.recall_hits) ? data.recall_hits.length : 0 });
|
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.1153",
|
|
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",
|
|
@@ -39,7 +39,7 @@
|
|
|
39
39
|
"gm.json"
|
|
40
40
|
],
|
|
41
41
|
"dependencies": {
|
|
42
|
-
"gm-plugkit": "^2.0.
|
|
42
|
+
"gm-plugkit": "^2.0.1153"
|
|
43
43
|
},
|
|
44
44
|
"engines": {
|
|
45
45
|
"node": ">=16.0.0"
|