@ikon85/agent-workflow-kit 0.43.0 → 0.44.0
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/skills/grill-me/SKILL.md +3 -1
- package/.agents/skills/grill-with-docs/SKILL.md +3 -1
- package/.agents/skills/kit-update/SKILL.md +9 -11
- package/.agents/skills/orchestrate-wave/SKILL.md +8 -8
- package/.agents/skills/setup-workflow/SKILL.md +20 -18
- package/.agents/skills/setup-workflow/board-sync.md +4 -1
- package/.agents/skills/setup-workflow/workflow-advisories.md +3 -2
- package/.agents/skills/setup-workflow/worktree-lifecycle.md +36 -31
- package/.agents/skills/to-issues/SKILL.md +43 -0
- package/.agents/skills/wrapup/SKILL.md +98 -54
- package/.claude/skills/grill-me/SKILL.md +3 -1
- package/.claude/skills/grill-me-codex/SKILL.md +3 -1
- package/.claude/skills/grill-with-docs/SKILL.md +3 -1
- package/.claude/skills/grill-with-docs-codex/SKILL.md +3 -1
- package/.claude/skills/kit-update/SKILL.md +9 -11
- package/.claude/skills/orchestrate-wave/SKILL.md +8 -8
- package/.claude/skills/setup-workflow/SKILL.md +20 -18
- package/.claude/skills/setup-workflow/board-sync.md +4 -1
- package/.claude/skills/setup-workflow/workflow-advisories.md +3 -2
- package/.claude/skills/setup-workflow/worktree-lifecycle.md +36 -31
- package/.claude/skills/to-issues/SKILL.md +43 -0
- package/.claude/skills/wrapup/SKILL.md +98 -54
- package/README.md +249 -7
- package/agent-workflow-kit.package.json +42 -42
- package/package.json +16 -12
- package/scripts/marker_lib.py +3 -0
- package/scripts/profile_globs.py +26 -45
- package/scripts/release-delta-guard.mjs +26 -9
- package/scripts/worktree-lifecycle/README.md +57 -160
- package/scripts/worktree-lifecycle/capabilities.json +2 -3
- package/scripts/worktree-lifecycle/classify.py +480 -0
- package/scripts/worktree-lifecycle/cleanup.py +9 -29
- package/scripts/worktree-lifecycle/core.py +68 -1429
- package/scripts/worktree-lifecycle/ignore_seed.py +1 -1
- package/scripts/worktree-lifecycle/profile.py +46 -29
- package/scripts/worktree-lifecycle/setup.py +7 -19
- package/scripts/wrapup-land.py +1292 -545
- package/src/consumer-migrations.json +1 -16
- package/src/lib/bundle.mjs +31 -1
- package/docs/adr/0001-consumer-divergence-policy.md +0 -53
- package/docs/adr/0002-capability-gated-orchestration.md +0 -70
- package/docs/adr/0003-kit-core-and-project-extension-lifecycle.md +0 -63
- package/docs/adr/0004-release-intent-is-a-version-tag.md +0 -64
- package/docs/adr/0005-to-issues-is-the-planning-facade.md +0 -42
- package/docs/adr/0006-routing-knowledge-access-and-policy-are-separate.md +0 -95
- package/docs/adr/0007-session-teardown-requires-provenance-bound-ownership.md +0 -88
- package/docs/adr/0008-planning-ignore-rules-are-offered-never-installed.md +0 -84
- package/docs/adr/0009-teardown-authority-is-stateless-repository-classification.md +0 -101
- package/docs/adr/0010-model-roster-replaces-the-optimization-dial.md +0 -87
- package/docs/agents/board-sync.md +0 -74
- package/docs/agents/code-review.md +0 -14
- package/docs/agents/workflow-capabilities.json +0 -28
- package/docs/research/agent-task-taxonomy-benchmark-coverage.md +0 -451
- package/docs/research/benchlm-routing-source.md +0 -198
- package/docs/research/consumer-owned-protocol-files.md +0 -238
- package/docs/research/frontend-agent-benchmarks.md +0 -282
- package/docs/research/model-effort-routing-benchmarks.md +0 -261
- package/docs/research/provider-neutral-agent-routing.md +0 -207
- package/docs/research/wave-152-consumer-acceptance.md +0 -98
- package/docs/research/wave-43-script-hook-census.md +0 -128
- package/scripts/build-kit.mjs +0 -117
- package/scripts/build-kit.test.mjs +0 -207
- package/scripts/census/census.test.mjs +0 -252
- package/scripts/census/state.test.mjs +0 -15
- package/scripts/census/transaction.test.mjs +0 -103
- package/scripts/census-contract.test.mjs +0 -227
- package/scripts/check-kit-staleness.mjs +0 -45
- package/scripts/check-kit-staleness.test.mjs +0 -19
- package/scripts/codex-exec-scenarios/fake-codex.mjs +0 -165
- package/scripts/codex-exec.test.mjs +0 -871
- package/scripts/grill-census-wiring-guard.mjs +0 -87
- package/scripts/grill-census-wiring-guard.test.mjs +0 -107
- package/scripts/kit-release.test.mjs +0 -273
- package/scripts/kit-update-pr.test.mjs +0 -151
- package/scripts/lib/audit-refs.mjs +0 -146
- package/scripts/lib/scrub.mjs +0 -113
- package/scripts/lib/scrub.test.mjs +0 -187
- package/scripts/memory-lifecycle/memory-lifecycle.test.mjs +0 -170
- package/scripts/portability_profile_scan.py +0 -53
- package/scripts/release-delta-guard.test.mjs +0 -174
- package/scripts/release-parity.test.mjs +0 -90
- package/scripts/release-state.test.mjs +0 -360
- package/scripts/test_anchor_table.py +0 -69
- package/scripts/test_board_bootstrap.py +0 -348
- package/scripts/test_board_sync.py +0 -208
- package/scripts/test_board_sync_create_idempotency.py +0 -117
- package/scripts/test_board_sync_wave_title.py +0 -120
- package/scripts/test_census_backstop.py +0 -712
- package/scripts/test_census_forward_contract.py +0 -91
- package/scripts/test_census_update_contract.test.mjs +0 -454
- package/scripts/test_codex_adapter_sync_contract.py +0 -169
- package/scripts/test_dist_kit_smoke.py +0 -220
- package/scripts/test_drift_guard_diagnostics.py +0 -295
- package/scripts/test_issue_claim_contract.py +0 -169
- package/scripts/test_kit_docs_language_census.py +0 -178
- package/scripts/test_marker_lib.py +0 -162
- package/scripts/test_orchestrate_wave_contract.py +0 -381
- package/scripts/test_pr_body_check.py +0 -264
- package/scripts/test_profile_globs.py +0 -280
- package/scripts/test_program_planning_contract.py +0 -133
- package/scripts/test_release_authorization_contract.py +0 -101
- package/scripts/test_render_anchor.py +0 -267
- package/scripts/test_retro_wrapup_contract.py +0 -153
- package/scripts/test_skill_code_review_seed.py +0 -89
- package/scripts/test_skill_codex_exec_lifecycle.py +0 -123
- package/scripts/test_skill_frontmatter_lint.py +0 -234
- package/scripts/test_skill_gh_lint.py +0 -124
- package/scripts/test_skill_language_census.py +0 -254
- package/scripts/test_skill_optional_readiness.py +0 -171
- package/scripts/test_skill_portability_lint.py +0 -866
- package/scripts/test_skill_precommit_template.py +0 -30
- package/scripts/test_skill_publish_audit.py +0 -358
- package/scripts/test_skill_readiness_contract.py +0 -264
- package/scripts/test_skill_readiness_preflight.py +0 -180
- package/scripts/test_skill_required_readiness.py +0 -233
- package/scripts/test_skill_selfcontainment_lint.py +0 -255
- package/scripts/test_skill_setup_workflow_seeds.py +0 -691
- package/scripts/test_skill_stale_name_lint.py +0 -126
- package/scripts/test_skill_surface_refs.py +0 -300
- package/scripts/test_skill_trailing_artifact_lint.py +0 -71
- package/scripts/test_tdd_contract.py +0 -78
- package/scripts/test_worktree_ignore_seed.py +0 -320
- package/scripts/test_worktree_setup_base_guard.py +0 -140
- package/scripts/test_worktree_wrapup_contract.py +0 -1737
- package/scripts/test_wrapup_land.py +0 -428
- package/scripts/worktree-lifecycle/session.py +0 -1857
|
@@ -1,171 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env python3
|
|
2
|
-
"""Behavior contract for optional review and spike readiness layers."""
|
|
3
|
-
from __future__ import annotations
|
|
4
|
-
|
|
5
|
-
import json
|
|
6
|
-
import subprocess
|
|
7
|
-
import tempfile
|
|
8
|
-
import unittest
|
|
9
|
-
from pathlib import Path
|
|
10
|
-
|
|
11
|
-
ROOT = Path(__file__).resolve().parents[1]
|
|
12
|
-
READINESS = ROOT / "scripts/readiness.mjs"
|
|
13
|
-
MANIFEST = ROOT / ".claude/skills/skill-manifest.json"
|
|
14
|
-
SURFACES = (".claude/skills", ".agents/skills")
|
|
15
|
-
SKILLS = {
|
|
16
|
-
"spec-self-critique": {
|
|
17
|
-
"block": "projectEnrichment",
|
|
18
|
-
"capability": "specCritiqueLayer",
|
|
19
|
-
"path": "docs/agents/skills/spec-self-critique.md",
|
|
20
|
-
"core": ("## The 12-point checklist", "Self-Critique complete"),
|
|
21
|
-
"enrichment": ("per-point enrichment", "project-specific incidents"),
|
|
22
|
-
},
|
|
23
|
-
"code-review": {
|
|
24
|
-
"block": "projectEnrichment",
|
|
25
|
-
"capability": "codeReviewLayer",
|
|
26
|
-
"path": "docs/agents/code-review.md",
|
|
27
|
-
"core": ("## Axis 1 — Standards", "## Axis 2 — Spec"),
|
|
28
|
-
"enrichment": ("which sources count", "adjacent tools"),
|
|
29
|
-
},
|
|
30
|
-
"verify-spike": {
|
|
31
|
-
"block": "projectPlacement",
|
|
32
|
-
"capability": "verifySpikeLayer",
|
|
33
|
-
"path": "docs/agents/skills/verify-spike.md",
|
|
34
|
-
"core": ("Frame one falsifiable question", "Delete the harness"),
|
|
35
|
-
"enrichment": ("harness-placement", "import rules"),
|
|
36
|
-
},
|
|
37
|
-
}
|
|
38
|
-
PREFLIGHT_START = "<!-- readiness:optional-preflight:start -->"
|
|
39
|
-
PREFLIGHT_END = "<!-- readiness:optional-preflight:end -->"
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
def write(root: Path, relative: str, body: str) -> None:
|
|
43
|
-
path = root / relative
|
|
44
|
-
path.parent.mkdir(parents=True, exist_ok=True)
|
|
45
|
-
path.write_text(body, encoding="utf-8")
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
class OptionalReadinessTests(unittest.TestCase):
|
|
49
|
-
def setUp(self) -> None:
|
|
50
|
-
self.temp = tempfile.TemporaryDirectory()
|
|
51
|
-
self.root = Path(self.temp.name)
|
|
52
|
-
write(
|
|
53
|
-
self.root,
|
|
54
|
-
".claude/skills/skill-manifest.json",
|
|
55
|
-
MANIFEST.read_text(encoding="utf-8"),
|
|
56
|
-
)
|
|
57
|
-
self.consumer = {
|
|
58
|
-
"kitVersion": "0.0.0-test",
|
|
59
|
-
"readinessContractVersion": 1,
|
|
60
|
-
"readinessDecisions": {},
|
|
61
|
-
"installed": [],
|
|
62
|
-
}
|
|
63
|
-
self.write_consumer()
|
|
64
|
-
|
|
65
|
-
def tearDown(self) -> None:
|
|
66
|
-
self.temp.cleanup()
|
|
67
|
-
|
|
68
|
-
def write_consumer(self) -> None:
|
|
69
|
-
write(self.root, "agent-workflow-kit.json", json.dumps(self.consumer))
|
|
70
|
-
|
|
71
|
-
def check(self, skill: str) -> dict:
|
|
72
|
-
completed = subprocess.run(
|
|
73
|
-
[
|
|
74
|
-
"node",
|
|
75
|
-
str(READINESS),
|
|
76
|
-
"check",
|
|
77
|
-
"--skill",
|
|
78
|
-
skill,
|
|
79
|
-
"--json",
|
|
80
|
-
"--root",
|
|
81
|
-
str(self.root),
|
|
82
|
-
],
|
|
83
|
-
check=True,
|
|
84
|
-
capture_output=True,
|
|
85
|
-
text=True,
|
|
86
|
-
)
|
|
87
|
-
return json.loads(completed.stdout)
|
|
88
|
-
|
|
89
|
-
def test_missing_and_pending_subtract_exactly_one_optional_block(self) -> None:
|
|
90
|
-
for decision in (None, "pending"):
|
|
91
|
-
for skill, contract in SKILLS.items():
|
|
92
|
-
with self.subTest(skill=skill, decision=decision):
|
|
93
|
-
self.consumer["readinessDecisions"] = {}
|
|
94
|
-
if decision:
|
|
95
|
-
self.consumer["readinessDecisions"][contract["capability"]] = decision
|
|
96
|
-
self.write_consumer()
|
|
97
|
-
result = self.check(skill)
|
|
98
|
-
self.assertEqual(result["verdict"], "degraded")
|
|
99
|
-
self.assertEqual(
|
|
100
|
-
result["capabilities"][contract["capability"]]["state"],
|
|
101
|
-
decision or "missing",
|
|
102
|
-
)
|
|
103
|
-
self.assertEqual(result["inactiveBlocks"], [contract["block"]])
|
|
104
|
-
self.assertEqual(result["activeBlocks"], [])
|
|
105
|
-
|
|
106
|
-
def test_invalid_enrichment_is_visible_and_never_an_opt_out(self) -> None:
|
|
107
|
-
for skill, contract in SKILLS.items():
|
|
108
|
-
with self.subTest(skill=skill):
|
|
109
|
-
write(
|
|
110
|
-
self.root,
|
|
111
|
-
contract["path"],
|
|
112
|
-
"<!-- setup-workflow: state=stub -->\npartial configuration\n",
|
|
113
|
-
)
|
|
114
|
-
self.consumer["readinessDecisions"][contract["capability"]] = "pending"
|
|
115
|
-
self.write_consumer()
|
|
116
|
-
result = self.check(skill)
|
|
117
|
-
self.assertEqual(result["verdict"], "degraded")
|
|
118
|
-
self.assertEqual(
|
|
119
|
-
result["capabilities"][contract["capability"]]["state"],
|
|
120
|
-
"invalid",
|
|
121
|
-
)
|
|
122
|
-
self.assertEqual(result["inactiveBlocks"], [contract["block"]])
|
|
123
|
-
|
|
124
|
-
def test_ready_enrichment_activates_the_block(self) -> None:
|
|
125
|
-
for skill, contract in SKILLS.items():
|
|
126
|
-
with self.subTest(skill=skill):
|
|
127
|
-
write(
|
|
128
|
-
self.root,
|
|
129
|
-
contract["path"],
|
|
130
|
-
"<!-- setup-workflow: state=filled -->\nProject guidance.\n",
|
|
131
|
-
)
|
|
132
|
-
self.consumer["readinessDecisions"] = {}
|
|
133
|
-
self.write_consumer()
|
|
134
|
-
result = self.check(skill)
|
|
135
|
-
self.assertEqual(result["verdict"], "ready")
|
|
136
|
-
self.assertEqual(result["activeBlocks"], [contract["block"]])
|
|
137
|
-
self.assertEqual(result["inactiveBlocks"], [])
|
|
138
|
-
|
|
139
|
-
def test_preflight_and_exact_subtraction_match_across_both_surfaces(self) -> None:
|
|
140
|
-
for skill, contract in SKILLS.items():
|
|
141
|
-
blocks = []
|
|
142
|
-
preflights = []
|
|
143
|
-
for surface in SURFACES:
|
|
144
|
-
body = (ROOT / surface / skill / "SKILL.md").read_text(encoding="utf-8")
|
|
145
|
-
start = f"<!-- readiness:block {contract['block']} -->"
|
|
146
|
-
self.assertEqual(body.count(start), 1)
|
|
147
|
-
self.assertEqual(body.count("<!-- readiness:end -->"), 1)
|
|
148
|
-
block = body.split(start, 1)[1].split("<!-- readiness:end -->", 1)[0]
|
|
149
|
-
preflight = body.split(PREFLIGHT_START, 1)[1].split(PREFLIGHT_END, 1)[0]
|
|
150
|
-
generic = body.replace(start + block + "<!-- readiness:end -->", "")
|
|
151
|
-
for anchor in contract["core"]:
|
|
152
|
-
self.assertIn(anchor, generic)
|
|
153
|
-
for anchor in contract["enrichment"]:
|
|
154
|
-
self.assertIn(anchor, block)
|
|
155
|
-
self.assertLess(body.index(PREFLIGHT_START), body.index(start))
|
|
156
|
-
self.assertIn(
|
|
157
|
-
f"node scripts/readiness.mjs check --skill {skill} --json",
|
|
158
|
-
preflight,
|
|
159
|
-
)
|
|
160
|
-
self.assertIn(f"inactive block `{contract['block']}`", preflight)
|
|
161
|
-
self.assertIn(contract["capability"], preflight)
|
|
162
|
-
self.assertIn("Ready is silent", preflight)
|
|
163
|
-
self.assertIn("Invalid is always visible", preflight)
|
|
164
|
-
blocks.append(block)
|
|
165
|
-
preflights.append(preflight)
|
|
166
|
-
self.assertEqual(blocks[0], blocks[1])
|
|
167
|
-
self.assertEqual(preflights[0], preflights[1])
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
if __name__ == "__main__":
|
|
171
|
-
unittest.main()
|