aienvmp 0.1.53 → 0.1.55
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/BUGFIXES.md +12 -0
- package/CHANGELOG.md +17 -0
- package/README.md +3 -2
- package/package.json +1 -1
- package/src/commands/context.js +1 -0
- package/src/commands/doctor.js +4 -2
- package/src/commands/status.js +1 -0
- package/src/commands/summary.js +9 -2
- package/src/contract.js +2 -2
- package/src/preflight.js +27 -0
- package/src/render.js +4 -0
package/BUGFIXES.md
CHANGED
|
@@ -112,6 +112,18 @@ Short record of bugs, fixes, and follow-up checks.
|
|
|
112
112
|
- Fix: `agentPointers` now appears in status/preflight, context JSON, doctor JSON, and summary markdown.
|
|
113
113
|
- Verification: regression tests cover status, context, doctor, schema, and summary outputs.
|
|
114
114
|
|
|
115
|
+
### AI continuation readiness was spread across several fields
|
|
116
|
+
|
|
117
|
+
- Issue: AI consumers had to infer readiness from status, intents, activity, follow-ups, pointer state, and SBOM risk separately.
|
|
118
|
+
- Fix: `aiReadiness` now provides one advisory ready/review signal across status, context, doctor, summary, and dashboard.
|
|
119
|
+
- Verification: regression tests cover ready/review summaries, text status output, schema metadata, and dashboard rendering.
|
|
120
|
+
|
|
121
|
+
### AI readiness was visible but not first in human review surfaces
|
|
122
|
+
|
|
123
|
+
- Issue: CI Step Summary and the dashboard showed readiness, but agents and humans still had to scan past broader status fields to find the main AI continuation signal.
|
|
124
|
+
- Fix: `.aienvmp/summary.md` now starts with `AI readiness`, `AI signals`, and `AI next`; the dashboard audit band includes readiness signals in its hint.
|
|
125
|
+
- Verification: regression tests assert the summary top block and dashboard readiness signals; Windows and macOS package smoke checks cover generated artifacts.
|
|
126
|
+
|
|
115
127
|
## Template
|
|
116
128
|
|
|
117
129
|
### Title
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,22 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 0.1.55
|
|
4
|
+
|
|
5
|
+
- Moved `AI readiness`, readiness signals, and next action to the top of `.aienvmp/summary.md`.
|
|
6
|
+
- Added `aiReadiness.signals` to the dashboard audit-band hint.
|
|
7
|
+
- Kept the CI Step Summary lightweight while making the first AI review signal easier to scan.
|
|
8
|
+
- Updated README and regression tests for the new summary/dashboard readiness surface.
|
|
9
|
+
|
|
10
|
+
## 0.1.54
|
|
11
|
+
|
|
12
|
+
- Added `aiReadiness` to the shared preflight/status contract.
|
|
13
|
+
- Added root `aiReadiness` to `context --json`.
|
|
14
|
+
- Added `aiReadiness` to `doctor --json` as advisory metadata.
|
|
15
|
+
- Printed `ai-readiness` in plain `aienvmp status` output.
|
|
16
|
+
- Added `AI readiness` to `.aienvmp/summary.md`.
|
|
17
|
+
- Added an AI readiness item to the dashboard audit band.
|
|
18
|
+
- Updated README, schema metadata, and regression tests for the ready/review signal.
|
|
19
|
+
|
|
3
20
|
## 0.1.53
|
|
4
21
|
|
|
5
22
|
- Added `agentPointers` to the shared AI preflight/status contract.
|
package/README.md
CHANGED
|
@@ -34,7 +34,7 @@ Warnings are advisory by default. Use `doctor --strict <scope>` only when you wa
|
|
|
34
34
|
```text
|
|
35
35
|
AIENV.md # Markdown env map for AI agents
|
|
36
36
|
.aienvmp/status.json # first AI read: clear/review, next command, nextAgent hint
|
|
37
|
-
.aienvmp/summary.md # compact AI/CI summary
|
|
37
|
+
.aienvmp/summary.md # compact AI/CI summary; starts with AI readiness
|
|
38
38
|
.aienvmp/manifest.json # runtime map + light SBOM
|
|
39
39
|
.aienvmp/sbom.json # standalone AI-readable light SBOM
|
|
40
40
|
.aienvmp/sbom.cdx.json # CycloneDX-lite export from project manifests
|
|
@@ -48,8 +48,9 @@ AIENV.md # Markdown env map for AI agents
|
|
|
48
48
|
|
|
49
49
|
- `status`, `context`, `plan`, and `handoff` share one preflight contract.
|
|
50
50
|
- `schema --json` prints the stable AI-readable output contract without scanning.
|
|
51
|
-
- `summary.md` is the short CI/AI handoff view.
|
|
51
|
+
- `summary.md` is the short CI/AI handoff view, with `AI readiness`, signals, and next action first.
|
|
52
52
|
- `status.json.nextAgent` tells the next AI what to read and whether to review first.
|
|
53
|
+
- `aiReadiness` gives a one-field ready/review signal for AI continuation.
|
|
53
54
|
- `dependencyReadSet` lists manifests and lockfiles before package or security changes.
|
|
54
55
|
- `sbomRisk` gives AI a compact light-SBOM risk level, signals, and next command.
|
|
55
56
|
- `coordination.conflictTargets` shows where multiple agents are planning changes.
|
package/package.json
CHANGED
package/src/commands/context.js
CHANGED
|
@@ -26,6 +26,7 @@ export async function contextWorkspace(args) {
|
|
|
26
26
|
console.log(JSON.stringify({
|
|
27
27
|
status: warnings.length ? "review-required" : "clear",
|
|
28
28
|
preflight,
|
|
29
|
+
aiReadiness: preflight.aiReadiness,
|
|
29
30
|
coordination: preflight.coordination,
|
|
30
31
|
agentPointers: preflight.agentPointers,
|
|
31
32
|
sbomRisk: preflight.sbomRisk,
|
package/src/commands/doctor.js
CHANGED
|
@@ -5,7 +5,7 @@ import { intentsPath, manifestPath, timelinePath, workspaceDir } from "../paths.
|
|
|
5
5
|
import { loadPolicy, policyWarnings } from "../policy.js";
|
|
6
6
|
import { recommendedActions } from "../actions.js";
|
|
7
7
|
import { enforcementAdvice, strictResult } from "../enforcement.js";
|
|
8
|
-
import {
|
|
8
|
+
import { buildPreflight } from "../preflight.js";
|
|
9
9
|
|
|
10
10
|
export { strictResult } from "../enforcement.js";
|
|
11
11
|
|
|
@@ -18,6 +18,7 @@ export async function doctorWorkspace(args) {
|
|
|
18
18
|
const intents = openIntents(await readJsonl(intentsPath(dir)));
|
|
19
19
|
const warnings = [...diagnose(manifest, { timeline, intents }), ...policyWarnings(manifest, policy)];
|
|
20
20
|
const actions = recommendedActions(manifest, { warnings, intents });
|
|
21
|
+
const preflight = buildPreflight(manifest, warnings, intents, timeline);
|
|
21
22
|
const strict = strictResult(warnings, args);
|
|
22
23
|
const exitBehavior = {
|
|
23
24
|
mode: strict.enabled ? "strict" : "advisory",
|
|
@@ -33,7 +34,8 @@ export async function doctorWorkspace(args) {
|
|
|
33
34
|
exitBehavior,
|
|
34
35
|
trust: manifest.trust || {},
|
|
35
36
|
policy,
|
|
36
|
-
|
|
37
|
+
aiReadiness: preflight.aiReadiness,
|
|
38
|
+
agentPointers: preflight.agentPointers,
|
|
37
39
|
openIntentCount: intents.length,
|
|
38
40
|
warnings,
|
|
39
41
|
recommendedActions: actions,
|
package/src/commands/status.js
CHANGED
|
@@ -22,6 +22,7 @@ export async function statusWorkspace(args) {
|
|
|
22
22
|
console.log(JSON.stringify(output, null, 2));
|
|
23
23
|
} else if (!args.quiet) {
|
|
24
24
|
console.log(`${output.state}: ${output.summary}`);
|
|
25
|
+
console.log(`ai-readiness: ${output.aiReadiness?.level || "unknown"} - ${output.aiReadiness?.next || "Run aienvmp context --json for details."}`);
|
|
25
26
|
console.log(`next: ${output.nextCommand}`);
|
|
26
27
|
console.log(`ai: ${output.quickstart.readFirst} -> ${output.quickstart.detailCommand}`);
|
|
27
28
|
console.log(`intent: ${output.intentTargets[0]?.command || output.commands.recordIntent}`);
|
package/src/commands/summary.js
CHANGED
|
@@ -52,18 +52,25 @@ export function renderSummary(status = {}, manifest = {}) {
|
|
|
52
52
|
const dependencyCommands = dependencyProtocol.commands || {};
|
|
53
53
|
const dependencyFiles = dependencyFilesFor(status.dependencyReadSet);
|
|
54
54
|
const agentPointers = status.agentPointers || {};
|
|
55
|
+
const aiReadiness = status.aiReadiness || {};
|
|
56
|
+
const aiSignals = toList(aiReadiness.signals).slice(0, 5);
|
|
57
|
+
const aiNext = aiReadiness.next || "Run aienvmp context --json for details.";
|
|
55
58
|
|
|
56
59
|
return [
|
|
57
60
|
"# aienvmp summary",
|
|
58
61
|
"",
|
|
62
|
+
`- AI readiness: ${aiReadiness.level || "unknown"}`,
|
|
63
|
+
`- AI signals: ${aiSignals.length ? aiSignals.join("; ") : "none"}`,
|
|
64
|
+
`- AI next: ${aiNext}`,
|
|
65
|
+
`- AI read first: ${readFirst}, then ${detail}`,
|
|
66
|
+
`- mode: advisory by default; strict is opt-in with ${strict}`,
|
|
67
|
+
"",
|
|
59
68
|
`- state: ${status.state || "unknown"}`,
|
|
60
69
|
`- workspace: ${workspace}`,
|
|
61
70
|
`- warnings: ${valueOrZero(counts.warnings)} / open intents: ${valueOrZero(counts.openIntents)}`,
|
|
62
71
|
`- runtimes: ${valueOrZero(counts.runtimes)} / dependencies: ${valueOrZero(counts.dependencies)} / vulnerabilities: ${valueOrZero(counts.vulnerabilities)}`,
|
|
63
72
|
`- light SBOM risk: ${riskLevel} (${riskScore}) / scanner: ${scanner}`,
|
|
64
73
|
`- next: ${next}`,
|
|
65
|
-
`- AI read first: ${readFirst}, then ${detail}`,
|
|
66
|
-
`- mode: advisory by default; strict is opt-in with ${strict}`,
|
|
67
74
|
"",
|
|
68
75
|
"## AI handoff",
|
|
69
76
|
"",
|
package/src/contract.js
CHANGED
|
@@ -4,7 +4,7 @@ export function preflightContract() {
|
|
|
4
4
|
version: 1,
|
|
5
5
|
stability: "additive",
|
|
6
6
|
requiredFields: ["schemaVersion", "state", "decision", "quickstart", "commands", "artifacts"],
|
|
7
|
-
aiEntryFields: ["state", "summary", "nextAgent", "coordination", "agentActivity", "agentPointers", "sbomRisk", "followUps", "dependencyReadSet", "dependencyChangeProtocol"],
|
|
7
|
+
aiEntryFields: ["state", "summary", "aiReadiness", "nextAgent", "coordination", "agentActivity", "agentPointers", "sbomRisk", "followUps", "dependencyReadSet", "dependencyChangeProtocol"],
|
|
8
8
|
rule: "Consumers should ignore unknown fields and treat missing optional fields as unavailable."
|
|
9
9
|
};
|
|
10
10
|
}
|
|
@@ -28,7 +28,7 @@ export function schemaContract() {
|
|
|
28
28
|
},
|
|
29
29
|
context: {
|
|
30
30
|
command: "aienvmp context --json",
|
|
31
|
-
rootFields: ["status", "preflight", "coordination", "agentPointers", "decision", "recommendedActions", "workspace", "dependencySnapshot", "lightSbom", "warnings"]
|
|
31
|
+
rootFields: ["status", "preflight", "aiReadiness", "coordination", "agentPointers", "decision", "recommendedActions", "workspace", "dependencySnapshot", "lightSbom", "warnings"]
|
|
32
32
|
},
|
|
33
33
|
handoff: {
|
|
34
34
|
command: "aienvmp handoff --json",
|
package/src/preflight.js
CHANGED
|
@@ -18,6 +18,7 @@ export function buildPreflight(manifest = {}, warnings = [], intents = [], timel
|
|
|
18
18
|
const agentActivity = agentActivitySummary(timeline);
|
|
19
19
|
const sbomRisk = manifest.lightSbom?.riskSummary || {};
|
|
20
20
|
const agentPointers = agentPointerSummary(manifest.agentFiles);
|
|
21
|
+
const aiReadiness = aiReadinessSummary({ state, decision, coordination, agentActivity, agentPointers, sbomRisk, followUps });
|
|
21
22
|
return {
|
|
22
23
|
schemaVersion: 1,
|
|
23
24
|
contract: preflightContract(),
|
|
@@ -60,6 +61,7 @@ export function buildPreflight(manifest = {}, warnings = [], intents = [], timel
|
|
|
60
61
|
coordination,
|
|
61
62
|
agentActivity,
|
|
62
63
|
agentPointers,
|
|
64
|
+
aiReadiness,
|
|
63
65
|
sbomRisk,
|
|
64
66
|
followUps,
|
|
65
67
|
intentTargets,
|
|
@@ -89,6 +91,31 @@ export function buildPreflight(manifest = {}, warnings = [], intents = [], timel
|
|
|
89
91
|
};
|
|
90
92
|
}
|
|
91
93
|
|
|
94
|
+
function aiReadinessSummary({ state, decision, coordination, agentActivity, agentPointers, sbomRisk, followUps }) {
|
|
95
|
+
const blockers = [];
|
|
96
|
+
const review = [];
|
|
97
|
+
if (state !== "clear") review.push("status review required");
|
|
98
|
+
if ((coordination?.conflictTargets || []).length) review.push("open intent conflicts");
|
|
99
|
+
if ((agentActivity?.multiActorTargets || []).length) review.push("multi-agent environment activity");
|
|
100
|
+
if ((followUps || []).length) review.push("pending environment follow-ups");
|
|
101
|
+
if (["urgent", "high"].includes(sbomRisk?.level)) review.push("high light SBOM risk");
|
|
102
|
+
if ((agentPointers?.targets || []).length && (agentPointers?.installedCount || 0) === 0) review.push("no agent instruction pointer installed");
|
|
103
|
+
|
|
104
|
+
const level = review.length ? "review" : "ready";
|
|
105
|
+
const next = level === "ready"
|
|
106
|
+
? "AI agents can continue project-local work; record intent before environment changes."
|
|
107
|
+
: "Review listed signals before another AI changes runtimes, dependencies, package managers, Docker, or global tools.";
|
|
108
|
+
return {
|
|
109
|
+
level,
|
|
110
|
+
projectLocalWork: decision?.canContinueProjectLocalWork ? "allowed" : "review-first",
|
|
111
|
+
environmentChanges: decision?.canChangeEnvironmentWithoutReview ? "allowed" : "intent-and-review-first",
|
|
112
|
+
signals: review,
|
|
113
|
+
blockers,
|
|
114
|
+
next,
|
|
115
|
+
mode: "advisory"
|
|
116
|
+
};
|
|
117
|
+
}
|
|
118
|
+
|
|
92
119
|
function agentActivitySummary(timeline = []) {
|
|
93
120
|
const lastHandoffAt = lastTime(timeline, (item) => item.type === "agent-handoff");
|
|
94
121
|
const envRecords = timeline
|
package/src/render.js
CHANGED
|
@@ -493,6 +493,9 @@ const nextAction=reviewRequired?'Review before environment changes':'Proceed wit
|
|
|
493
493
|
const auditItem=(key,value,hint,klass='')=>\`<div class="audit-item \${klass}"><div class="audit-k">\${key}</div><div class="audit-v">\${value}</div><div class="audit-hint">\${hint}</div></div>\`;
|
|
494
494
|
const driftLabel=warnings.length?'detected':'none';
|
|
495
495
|
const nextAgent=manifest.preflight?.nextAgent||{};
|
|
496
|
+
const aiReadiness=manifest.preflight?.aiReadiness||{};
|
|
497
|
+
const aiReadinessSignals=(aiReadiness.signals||[]).slice(0,3);
|
|
498
|
+
const aiReadinessHint=(aiReadiness.next||'Run aienvmp context --json for details.')+(aiReadinessSignals.length?' Signals: '+aiReadinessSignals.join('; '):'');
|
|
496
499
|
const coordination=manifest.preflight?.coordination||{};
|
|
497
500
|
const conflictTargets=coordination.conflictTargets||[];
|
|
498
501
|
const handoffFiles=nextAgent.dependencyFiles?.length?nextAgent.dependencyFiles:(dependencyReadSet[0]?[dependencyReadSet[0].manifest,...(dependencyReadSet[0].lockfiles||[])].filter(Boolean):[]);
|
|
@@ -509,6 +512,7 @@ document.getElementById('app').innerHTML=\`
|
|
|
509
512
|
</header>
|
|
510
513
|
<section class="audit" aria-label="Audit summary">
|
|
511
514
|
\${auditItem('AI decision',reviewRequired?'review required':'can proceed',nextAction,reviewRequired?'review':'primary')}
|
|
515
|
+
\${auditItem('AI readiness',aiReadiness.level||'unknown',aiReadinessHint,aiReadiness.level==='ready'?'primary':'review')}
|
|
512
516
|
\${auditItem('Runtime drift',driftLabel,warnings.length?'Policy, runtime, or coordination warning detected':'No drift warnings detected',warnings.length?'review':'')}
|
|
513
517
|
\${auditItem('Open env changes',String(intents.length),intents.length?'Resolve or coordinate before changes':'No pending env changes')}
|
|
514
518
|
\${auditItem('Trust',trustState,trustState==='verified'?'Human or CI verified':'Machine observed; not AI-verified')}
|