@rt-tools/agent-kit 0.24.0 → 0.27.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/assets/agents/business-analyst.md +51 -50
- package/assets/agents/cargo-writer.md +54 -0
- package/assets/agents/conscience.md +37 -35
- package/assets/agents/project-manager.md +49 -48
- package/assets/agents/prose-editor.md +31 -29
- package/assets/agents/qa-engineer.md +50 -48
- package/assets/agents/rules-reviewer.md +63 -58
- package/assets/agents/skill-curator.md +83 -78
- package/assets/agents/spec-critic.md +34 -29
- package/assets/agents/spec-writer.md +35 -32
- package/assets/agents/strict-teacher.md +39 -37
- package/assets/checks/archive-age.mjs +48 -28
- package/assets/checks/archive-prune.mjs +16 -14
- package/assets/checks/board-epic-link.github.mjs +29 -0
- package/assets/checks/board-epics.github.mjs +286 -49
- package/assets/checks/board-folders.mjs +61 -0
- package/assets/checks/board-gh.github.mjs +35 -26
- package/assets/checks/board-long-work.github.mjs +29 -25
- package/assets/checks/board-paths.github.mjs +21 -16
- package/assets/checks/board-pull-state.github.mjs +168 -0
- package/assets/checks/board-runs.github.mjs +45 -43
- package/assets/checks/board-task-dirs.github.mjs +98 -0
- package/assets/checks/board-titles.github.mjs +19 -17
- package/assets/checks/board.github.mjs +133 -194
- package/assets/checks/check-archive-age.mjs +23 -19
- package/assets/checks/check-board.github.mjs +131 -263
- package/assets/checks/check-descriptions.mjs +30 -29
- package/assets/checks/check-doc-paths.mjs +91 -88
- package/assets/checks/check-dupes.mjs +84 -80
- package/assets/checks/check-file-size.mjs +74 -71
- package/assets/checks/check-glossary.mjs +47 -37
- package/assets/checks/check-hook-scope.mjs +30 -27
- package/assets/checks/check-lib-layers.mjs +22 -21
- package/assets/checks/check-profile-drift.mjs +48 -43
- package/assets/checks/check-prose-style.mjs +138 -39
- package/assets/checks/check-push-gate.mjs +53 -50
- package/assets/checks/check-reuse.mjs +50 -40
- package/assets/checks/check-schema-drift.mjs +104 -84
- package/assets/checks/check-specs.mjs +155 -134
- package/assets/checks/check-state-next.mjs +66 -52
- package/assets/checks/check-states.mjs +32 -30
- package/assets/checks/check-styles.mjs +52 -51
- package/assets/checks/check-turn-map.mjs +54 -46
- package/assets/checks/epic-table.github.mjs +268 -0
- package/assets/checks/lib-boundaries.mjs +32 -30
- package/assets/checks/lib-common.mjs +30 -29
- package/assets/checks/lib-domains.mjs +34 -34
- package/assets/checks/lib-manifests.mjs +17 -15
- package/assets/checks/lib-reexports.mjs +18 -18
- package/assets/checks/rt-kit-checks.config.mjs +187 -142
- package/assets/checks/signals.mjs +43 -39
- package/assets/checks/spec-anchors.mjs +114 -87
- package/assets/checks/spec-common.mjs +128 -84
- package/assets/checks/spec-contract.mjs +30 -30
- package/assets/checks/spec-proposed.mjs +27 -24
- package/assets/checks/spec-scenarios.mjs +51 -28
- package/assets/checks/specs-for.mjs +214 -0
- package/assets/checks/task-new.github.mjs +315 -61
- package/assets/commands/feedback.md +65 -59
- package/assets/commands/next-session.md +64 -57
- package/assets/commands/night.md +115 -0
- package/assets/commands/skill-curator.md +83 -79
- package/assets/defaults/gate-map.sh +108 -97
- package/assets/defaults/project.sh +232 -185
- package/assets/defaults/shell.sh +73 -68
- package/assets/defaults/turn-map.md +47 -44
- package/assets/docs/GLOSSARY.md +142 -65
- package/assets/hooks/browser-device-id.sh +16 -12
- package/assets/hooks/browser-guard-device-id.sh +34 -28
- package/assets/hooks/browser-guard-no-asking.sh +5 -4
- package/assets/hooks/browser-guard-no-listing.sh +12 -11
- package/assets/hooks/browser-guard-no-other-drivers.sh +48 -42
- package/assets/hooks/browser-guard-require-select.sh +34 -23
- package/assets/hooks/claim-guard.sh +62 -56
- package/assets/hooks/commit-msg.sh +14 -10
- package/assets/hooks/conscience-guard.sh +91 -45
- package/assets/hooks/constitution-index.sh +16 -16
- package/assets/hooks/deny-tail.sh +28 -26
- package/assets/hooks/dev-server-guard.sh +50 -43
- package/assets/hooks/dispatch.sh +60 -46
- package/assets/hooks/docs-guard.sh +100 -91
- package/assets/hooks/epic-over.sh +49 -0
- package/assets/hooks/epic-stop-guard.sh +108 -0
- package/assets/hooks/exam-guard.sh +105 -93
- package/assets/hooks/git-guard-delivery-conflict.sh +41 -36
- package/assets/hooks/git-guard-delivery-draft.sh +48 -38
- package/assets/hooks/git-guard-delivery-epic.sh +167 -0
- package/assets/hooks/git-guard-delivery-folder.sh +50 -43
- package/assets/hooks/git-guard-delivery-signature.sh +119 -53
- package/assets/hooks/git-guard-delivery.sh +223 -183
- package/assets/hooks/git-guard-main.sh +38 -34
- package/assets/hooks/git-guard-push-tests.sh +99 -87
- package/assets/hooks/glossary-load.sh +23 -22
- package/assets/hooks/grill-gate-ask.sh +12 -11
- package/assets/hooks/grill-gate.sh +94 -87
- package/assets/hooks/guard-note.sh +20 -19
- package/assets/hooks/handoff-entry-guard.sh +45 -25
- package/assets/hooks/handoff-write.sh +74 -67
- package/assets/hooks/hook-input.sh +67 -58
- package/assets/hooks/lint-after-edit.sh +95 -61
- package/assets/hooks/observe.sh +28 -26
- package/assets/hooks/override-write-guard.sh +23 -21
- package/assets/hooks/postmortem-guard.sh +42 -39
- package/assets/hooks/profile-check.sh +22 -20
- package/assets/hooks/proposal-guard.sh +57 -49
- package/assets/hooks/prose-style-guard.sh +49 -24
- package/assets/hooks/qa-dataid-guard.sh +83 -58
- package/assets/hooks/rerun-guard.sh +31 -30
- package/assets/hooks/reuse-first-guard.sh +108 -87
- package/assets/hooks/roles.sh +14 -14
- package/assets/hooks/rule-article.sh +39 -34
- package/assets/hooks/rule-source-guard.sh +47 -42
- package/assets/hooks/skill-gate-layers.sh +63 -57
- package/assets/hooks/skill-gate-rearm.sh +15 -8
- package/assets/hooks/skill-gate.sh +89 -81
- package/assets/hooks/skill-loaded.sh +10 -6
- package/assets/hooks/sql-guard-parse.sh +71 -66
- package/assets/hooks/sql-guard-request.sh +51 -46
- package/assets/hooks/sql-guard-target.sh +60 -51
- package/assets/hooks/sql-guard-write.sh +87 -79
- package/assets/hooks/sql-guard.sh +52 -47
- package/assets/hooks/stand-login-guard.sh +43 -37
- package/assets/hooks/task-context-load.sh +60 -55
- package/assets/hooks/task-flow-context.sh +87 -69
- package/assets/hooks/task-flow-draft-guard.sh +55 -48
- package/assets/hooks/task-flow-guard.sh +67 -64
- package/assets/hooks/turn-entry-load.sh +39 -32
- package/assets/hooks/turn-exit-guard.sh +260 -204
- package/assets/hooks/turn-exit-patterns.sh +63 -0
- package/assets/hooks/utf8.sh +14 -11
- package/assets/hooks/waiting-turn-guard.sh +104 -94
- package/assets/hooks/window-fill-guard.sh +70 -62
- package/assets/hooks/work-start-guard.sh +52 -49
- package/assets/hooks/write-targets.sh +99 -44
- package/assets/laws/autonomous-work.md +29 -27
- package/assets/laws/code-structure.md +31 -30
- package/assets/laws/delivery.md +170 -137
- package/assets/laws/entity-editing.md +52 -50
- package/assets/laws/entity-models.md +14 -13
- package/assets/laws/frontend-application.md +39 -38
- package/assets/laws/lib-imports.md +27 -27
- package/assets/laws/lists.md +31 -29
- package/assets/laws/navigation.md +37 -37
- package/assets/laws/observability.md +41 -40
- package/assets/laws/project-documentation.md +106 -99
- package/assets/laws/reuse-first.md +31 -29
- package/assets/laws/shared-code.md +27 -27
- package/assets/laws/verifiability.md +131 -124
- package/assets/laws/work-conduct.md +250 -244
- package/assets/patterns/admin-lists-screen.md +72 -69
- package/assets/patterns/admin-nav-item.md +51 -46
- package/assets/patterns/angular-patterns-state.md +32 -31
- package/assets/patterns/api-layer-pair.md +33 -31
- package/assets/patterns/autonomous-work-run.md +50 -49
- package/assets/patterns/browser-verification-measure.md +124 -88
- package/assets/patterns/browser-verification-stand.md +169 -157
- package/assets/patterns/component-structure-new.md +51 -42
- package/assets/patterns/dependencies-upgrade.md +55 -39
- package/assets/patterns/doc-style-human.md +55 -37
- package/assets/patterns/doc-style-sweep.md +82 -79
- package/assets/patterns/doc-style-trace.md +87 -81
- package/assets/patterns/doc-style-write.md +130 -122
- package/assets/patterns/entity-aside.md +77 -63
- package/assets/patterns/entity-models-new.md +37 -37
- package/assets/patterns/entity-store.md +33 -33
- package/assets/patterns/git-workflow-commit.azure.md +94 -87
- package/assets/patterns/git-workflow-commit.github.md +160 -142
- package/assets/patterns/git-workflow-commit.gitlab.md +96 -90
- package/assets/patterns/git-workflow-docker.md +165 -147
- package/assets/patterns/git-workflow-freshness.md +45 -45
- package/assets/patterns/git-workflow-merge.md +102 -94
- package/assets/patterns/git-workflow-migration.md +54 -52
- package/assets/patterns/git-workflow-pr-ready.md +57 -56
- package/assets/patterns/git-workflow-pr.azure.md +127 -122
- package/assets/patterns/git-workflow-pr.github.md +186 -177
- package/assets/patterns/git-workflow-pr.gitlab.md +139 -132
- package/assets/patterns/git-workflow-restart.md +35 -31
- package/assets/patterns/git-workflow-secrets.md +80 -73
- package/assets/patterns/git-workflow-stack.md +136 -107
- package/assets/patterns/lib-layers-move.md +62 -53
- package/assets/patterns/lib-layers-new.md +59 -45
- package/assets/patterns/observability-record.md +72 -67
- package/assets/patterns/platform-access-di.md +31 -29
- package/assets/patterns/reuse-first-extend.md +66 -61
- package/assets/patterns/shared-code-new.md +39 -38
- package/assets/patterns/spec-driven-domain.md +161 -151
- package/assets/patterns/spec-driven-rule.md +179 -168
- package/assets/patterns/spec-driven-sweep.md +41 -39
- package/assets/patterns/status-report-table.github.md +48 -36
- package/assets/patterns/styling-bem-component.md +42 -42
- package/assets/patterns/styling-bem-layout.md +39 -34
- package/assets/patterns/styling-bem-sheet.md +59 -58
- package/assets/patterns/task-flow-archive.md +222 -215
- package/assets/patterns/task-flow-close.md +234 -203
- package/assets/patterns/task-flow-handoff.md +154 -145
- package/assets/patterns/task-flow-resume.md +138 -133
- package/assets/patterns/task-flow-start.md +228 -202
- package/assets/patterns/testing-e2e.md +102 -101
- package/assets/patterns/testing-unit.md +77 -70
- package/assets/patterns/ts-procedure.md +32 -29
- package/assets/patterns/turn-entry-map.md +50 -48
- package/assets/pitfalls/agent-kit.md +172 -142
- package/assets/pitfalls/doc-style.md +96 -91
- package/assets/pitfalls/git-workflow.azure.md +49 -46
- package/assets/pitfalls/git-workflow.github.md +270 -234
- package/assets/pitfalls/git-workflow.gitlab.md +49 -45
- package/assets/pitfalls/spec-driven.md +73 -71
- package/assets/pitfalls/styling-bem.md +46 -40
- package/assets/pitfalls/task-flow.md +262 -246
- package/assets/pitfalls/testing.md +99 -92
- package/assets/pitfalls/turn-conduct.md +96 -81
- package/assets/rules/angular-patterns.md +81 -80
- package/assets/rules/api-layer.md +77 -74
- package/assets/rules/autonomous-work.md +87 -74
- package/assets/rules/browser-verification.md +223 -214
- package/assets/rules/component-structure.md +72 -69
- package/assets/rules/dependencies.md +74 -67
- package/assets/rules/deploy-flow.azure.md +118 -108
- package/assets/rules/deploy-flow.github.md +145 -135
- package/assets/rules/deploy-flow.gitlab.md +120 -110
- package/assets/rules/doc-style.md +201 -173
- package/assets/rules/entity-conventions.needs-admin.md +81 -79
- package/assets/rules/entity-models.md +73 -70
- package/assets/rules/git-workflow.azure.md +224 -228
- package/assets/rules/git-workflow.github.md +268 -239
- package/assets/rules/git-workflow.gitlab.md +218 -217
- package/assets/rules/lib-layers.md +85 -86
- package/assets/rules/lists.md +101 -97
- package/assets/rules/navigation.md +78 -78
- package/assets/rules/observability.needs-app.md +165 -153
- package/assets/rules/platform-access.md +76 -75
- package/assets/rules/reuse-first.md +153 -143
- package/assets/rules/shared-code.md +82 -79
- package/assets/rules/spec-driven.md +279 -260
- package/assets/rules/status-report.md +62 -58
- package/assets/rules/styling-bem.md +81 -77
- package/assets/rules/task-flow.md +303 -270
- package/assets/rules/testing.md +224 -209
- package/assets/rules/turn-conduct.md +262 -258
- package/assets/rules/turn-entry.md +92 -87
- package/assets/rules/typescript-conventions.md +94 -88
- package/assets/samples/specs/_template/spec.md +47 -47
- package/assets/samples/tasks/_template/grill.md +20 -20
- package/assets/samples/tasks/_template/plan.md +32 -30
- package/assets/samples/tasks/_template/progress.md +16 -16
- package/assets/skills/agent-kit-extend.md +129 -113
- package/assets/skills/agent-kit.md +259 -233
- package/assets/skills/write-a-skill.md +76 -71
- package/assets/templates/findings.md +19 -19
- package/assets/templates/gate-map.sh +16 -14
- package/assets/templates/implementation.md +28 -27
- package/assets/templates/pattern.md +17 -17
- package/assets/templates/pitfalls.md +6 -6
- package/assets/templates/postmortem.md +24 -23
- package/assets/templates/project.sh +24 -24
- package/assets/templates/proposal.md +62 -60
- package/assets/templates/rule.md +38 -38
- package/assets/workflows/feature.js +46 -46
- package/assets/workflows/plan.js +54 -54
- package/bin/agent-kit.d.ts.map +1 -1
- package/bin/agent-kit.js +8 -1
- package/bin/agent-kit.js.map +1 -1
- package/lib/cargo-prose.d.ts +41 -0
- package/lib/cargo-prose.d.ts.map +1 -0
- package/lib/cargo-prose.js +88 -0
- package/lib/cargo-prose.js.map +1 -0
- package/lib/cargo.d.ts +12 -1
- package/lib/cargo.d.ts.map +1 -1
- package/lib/cargo.js +8 -2
- package/lib/cargo.js.map +1 -1
- package/lib/catalog.d.ts +2 -0
- package/lib/catalog.d.ts.map +1 -1
- package/lib/catalog.js +4 -3
- package/lib/catalog.js.map +1 -1
- package/lib/commands.d.ts.map +1 -1
- package/lib/commands.js +5 -2
- package/lib/commands.js.map +1 -1
- package/lib/companion.js +3 -2
- package/lib/companion.js.map +1 -1
- package/lib/enroll.d.ts +7 -1
- package/lib/enroll.d.ts.map +1 -1
- package/lib/enroll.js +12 -3
- package/lib/enroll.js.map +1 -1
- package/lib/fate.d.ts +29 -0
- package/lib/fate.d.ts.map +1 -0
- package/lib/fate.js +147 -0
- package/lib/fate.js.map +1 -0
- package/lib/override-marks.d.ts +7 -0
- package/lib/override-marks.d.ts.map +1 -1
- package/lib/override-marks.js +14 -0
- package/lib/override-marks.js.map +1 -1
- package/lib/plan.d.ts +11 -0
- package/lib/plan.d.ts.map +1 -1
- package/lib/plan.js +10 -1
- package/lib/plan.js.map +1 -1
- package/lib/ship.d.ts +29 -9
- package/lib/ship.d.ts.map +1 -1
- package/lib/ship.js +44 -2
- package/lib/ship.js.map +1 -1
- package/lib/shipment.d.ts.map +1 -1
- package/lib/shipment.fixture.d.ts +8 -1
- package/lib/shipment.fixture.d.ts.map +1 -1
- package/lib/shipment.fixture.js +9 -0
- package/lib/shipment.fixture.js.map +1 -1
- package/lib/shipment.js +38 -5
- package/lib/shipment.js.map +1 -1
- package/lib/sync.d.ts.map +1 -1
- package/lib/sync.js +45 -11
- package/lib/sync.js.map +1 -1
- package/package.json +1 -1
- package/rt-tools-agent-kit-0.27.0.tgz +0 -0
- package/rt-tools-agent-kit-0.24.0.tgz +0 -0
|
@@ -1,288 +1,314 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: agent-kit
|
|
3
|
-
description:
|
|
3
|
+
description: The portable rules layer of the agent — laws, rules, hooks and checks shipped by the package and adjusted by the tree through overrides. Load when a file with the rt-kit header is edited, the package is upgraded or the layout audit refuses. The shape of a new skill — write-a-skill.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
-
#
|
|
6
|
+
# The portable rules layer
|
|
7
7
|
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
8
|
+
Laws, rules, patterns, hooks, checks and roles are shipped by the package; the tree takes them
|
|
9
|
+
by layout and adjusts them with overrides. A laid-out file carries a header and is not edited —
|
|
10
|
+
either the package or the override is edited.
|
|
11
11
|
|
|
12
|
-
|
|
13
|
-
|
|
12
|
+
**Cold part:** `pitfalls.md` next to it — pitfalls, traps already stepped on. Loaded on demand,
|
|
13
|
+
not together with the skill.
|
|
14
14
|
|
|
15
|
-
##
|
|
15
|
+
## When to use
|
|
16
16
|
|
|
17
|
-
-
|
|
18
|
-
`rt-kit v
|
|
19
|
-
-
|
|
20
|
-
-
|
|
21
|
-
|
|
17
|
+
- The file you are about to edit carries the header
|
|
18
|
+
`rt-kit v<version> · <resource> · <checksum> · правится надстройкой, не здесь`.
|
|
19
|
+
- The package was updated, or `sync --check` refused in the push gate.
|
|
20
|
+
- Your own behaviour has to be added on top of the package one: a guard, the gate map, the
|
|
21
|
+
set of checks.
|
|
22
|
+
- The package is installed into a tree whose hooks and checks are already its own.
|
|
22
23
|
|
|
23
|
-
##
|
|
24
|
+
## Where what is set up
|
|
24
25
|
|
|
25
|
-
|
|
|
26
|
-
|
|
|
27
|
-
|
|
|
28
|
-
|
|
|
29
|
-
|
|
|
30
|
-
|
|
|
31
|
-
|
|
|
32
|
-
|
|
|
33
|
-
|
|
|
34
|
-
|
|
|
35
|
-
|
|
|
26
|
+
| What you change | Where the edit goes |
|
|
27
|
+
| ------------------------------------------------- | ------------------------------------------------------- |
|
|
28
|
+
| which rule the gate demands for which file | `.claude/rt-kit/gate-map.sh` — your own `skill_for` |
|
|
29
|
+
| ports, addresses, linters, branch form, inventory | `.claude/rt-kit/project.sh` — your own `rt_*` |
|
|
30
|
+
| paths and identifiers the checks live by | `.claude/rt-kit/checks.json` |
|
|
31
|
+
| which uniformity signs the tree takes | `checks.json`, keys `reuse.bundles` and `reuse.signals` |
|
|
32
|
+
| a section of a laid-out text | `.claude/rt-kit/overrides/<resource identifier>` |
|
|
33
|
+
| what to take and what to drop | `.claude/rt-kit.json`, keys `only` and `skip` |
|
|
34
|
+
| which roles are called by hand, not mandatorily | `.claude/rt-kit.json`, key `rolesOff` |
|
|
35
|
+
| what the tree has: storage, admin, packages | `.claude/rt-kit.json`, key `has` |
|
|
36
|
+
| the mechanism itself — guard, check, rule text | the resource in the package |
|
|
36
37
|
|
|
37
|
-
|
|
38
|
-
`_default
|
|
39
|
-
|
|
38
|
+
An override redeclares the function and may call the default by the same name with the
|
|
39
|
+
`_default` suffix. Text merges by `## ` sections: a matching heading replaces, a new one is
|
|
40
|
+
appended, an empty one lifts the package section.
|
|
40
41
|
|
|
41
|
-
|
|
42
|
-
|
|
42
|
+
A ready-made sample for every row of this table is the skill `agent-kit-extend`: how the edit
|
|
43
|
+
itself looks, what checks it and how it ends if put in the wrong place.
|
|
43
44
|
|
|
44
|
-
##
|
|
45
|
+
## Order
|
|
45
46
|
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
47
|
+
The layout puts everything or nothing: a refusal on even one file writes nothing — half a
|
|
48
|
+
layout is worse than a whole one. Either the override here or the resource itself is edited —
|
|
49
|
+
and that is the work of the tree where the package lives as sources; nothing is said about it
|
|
50
|
+
here.
|
|
49
51
|
|
|
50
|
-
|
|
51
|
-
|
|
52
|
+
**A layout is an edit of the tree, not a service call:** it rewrites hundreds of tracked files at
|
|
53
|
+
once, so the work is set up before `sync`, by the same rules as any other.
|
|
52
54
|
|
|
53
|
-
|
|
54
|
-
|
|
55
|
+
**The package version bump and the layout go in one change.** The layout audit stands in the
|
|
56
|
+
push gate: an edition bumped without a layout turns the main branch red and locks the whole tree.
|
|
55
57
|
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
58
|
+
**The layout puts the hook declaration together with the hook itself.** A hook is called by an
|
|
59
|
+
entry in the agent settings, and one laid out without it is indistinguishable from the outside
|
|
60
|
+
from a working one. The layout appends an entry for every event missing from the settings and
|
|
61
|
+
reports it. The edit only adds: entries are neither rewritten nor removed, what the tree removed
|
|
62
|
+
does not come back, and settings that cannot be parsed as JSON the package does not touch — it
|
|
63
|
+
prints a ready-made piece to enter by hand.
|
|
61
64
|
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
65
|
+
**This is held by the edit-location guard, not by memory.** It refuses an edit of a file with the
|
|
66
|
+
layout header at the minute of the edit and names the address: the source, if the tree holds
|
|
67
|
+
it, otherwise the override. The copy is edited not only by hand: the tree formatter rewrites a
|
|
68
|
+
laid-out file its own way, and the layout reads that exactly as a hand edit. Removing the copy
|
|
69
|
+
the guard lets through — a removed file the layout puts anew.
|
|
66
70
|
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
+
**An override is edited by section, not put in full.** Sections are added to it by different
|
|
72
|
+
branches and different sessions, and put in full it carries away all that this edit did not
|
|
73
|
+
touch. This is held by the second guard — it refuses a write over a non-empty override and names
|
|
74
|
+
the size of what would be wiped. Appending at the end and editing in place pass.
|
|
71
75
|
|
|
72
|
-
##
|
|
76
|
+
## Commands
|
|
73
77
|
|
|
74
78
|
```bash
|
|
75
|
-
npx agent-kit doctor #
|
|
76
|
-
npx agent-kit sync #
|
|
77
|
-
npx agent-kit sync --check #
|
|
78
|
-
npx agent-kit stats #
|
|
79
|
-
npx agent-kit enroll --code
|
|
80
|
-
npx agent-kit propose #
|
|
81
|
-
npx agent-kit
|
|
79
|
+
npx agent-kit doctor # what is laid out, what lags, what lies from a dropped resource
|
|
80
|
+
npx agent-kit sync # lay out
|
|
81
|
+
npx agent-kit sync --check # write nothing, refuse on a divergence
|
|
82
|
+
npx agent-kit stats # what was used, what never, what people stumbled on
|
|
83
|
+
npx agent-kit enroll --code <code> # enrol the tree in the intake and put its token
|
|
84
|
+
npx agent-kit propose # send the cargo to the intake: the digest, proposals and analyses
|
|
85
|
+
npx agent-kit fate # the fate of one's own records and the overrides that are due to be lifted
|
|
86
|
+
npx agent-kit adopt [files] # hand the package your own file lying on its path
|
|
82
87
|
```
|
|
83
88
|
|
|
84
|
-
|
|
85
|
-
|
|
89
|
+
Adoption sets the former content aside next to it, marked `.before-rt-kit`, and frees the path
|
|
90
|
+
for the layout; without names all foreign files are handed over at once.
|
|
86
91
|
|
|
87
|
-
|
|
88
|
-
|
|
92
|
+
Some commands of the layer are run by the agent, not by the program: `/feedback` puts a remark
|
|
93
|
+
about the rules as a block into the proposals file, `/skill-curator` reviews a closed task,
|
|
94
|
+
`/next-session` closes the session.
|
|
89
95
|
|
|
90
|
-
|
|
96
|
+
There are no commands for editing the package itself here: they are called where its resources
|
|
97
|
+
lie.
|
|
91
98
|
|
|
92
|
-
##
|
|
99
|
+
## Version bump
|
|
93
100
|
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
101
|
+
A matching heading replaces the package section in full, and everything the package added to such
|
|
102
|
+
a section in a new version vanishes silently: the layout matches, the headings match, and the
|
|
103
|
+
statements are gone. The heading audit catches a renamed section, not an extended one — the loss
|
|
104
|
+
has no other witnesses.
|
|
97
105
|
|
|
98
|
-
|
|
106
|
+
So the bump takes three steps, and the first goes before the installation.
|
|
99
107
|
|
|
100
|
-
1.
|
|
101
|
-
|
|
108
|
+
1. **A snapshot of the former edition of the resources.** The installation wipes it without a
|
|
109
|
+
trace, and there is nothing to compare with afterwards.
|
|
102
110
|
|
|
103
111
|
```bash
|
|
104
|
-
cp -r node_modules/@rt-tools/agent-kit/assets /tmp/agent-kit-assets
|
|
112
|
+
cp -r node_modules/@rt-tools/agent-kit/assets /tmp/agent-kit-assets-<former version>
|
|
105
113
|
```
|
|
106
114
|
|
|
107
|
-
2.
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
115
|
+
2. **Installation and layout.** The usual way. The layout puts the edition that is
|
|
116
|
+
**installed**, not the one the tree declared: the installed one is left over from a
|
|
117
|
+
neighbouring branch and lands in full, silently, with the same successful exit. A mismatch of
|
|
118
|
+
the exact number the layout refuses by itself; the fix is to install dependencies and repeat
|
|
119
|
+
the call.
|
|
120
|
+
3. **An audit of the replaced sections against the snapshot.** Which sections are replaced is
|
|
121
|
+
named by `doctor` — with the line "замещено надстройками разделов" and a list of
|
|
122
|
+
"resource · heading". Each is read in the snapshot and in the new edition: what the package
|
|
123
|
+
added is added to the override by hand.
|
|
114
124
|
|
|
115
|
-
|
|
125
|
+
Neither `doctor` nor `sync --check` audits this itself: they have no former edition.
|
|
116
126
|
|
|
117
|
-
|
|
118
|
-
|
|
127
|
+
For every named section the articles are compared, not the headings: the heading is exactly
|
|
128
|
+
what matched, that is what replaced the section. A ready-made pair of commands is in the cold
|
|
129
|
+
part next to it.
|
|
119
130
|
|
|
120
|
-
|
|
121
|
-
|
|
131
|
+
Then the decision is the usual one: the section the override was started for stays replaced,
|
|
132
|
+
and the section whose reason left with the fixed edition is lifted.
|
|
122
133
|
|
|
123
|
-
##
|
|
134
|
+
## What the package ships and what stays with the tree
|
|
124
135
|
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
136
|
+
The package is installed by foreign trees, and it ships them only what they carry out. A
|
|
137
|
+
resource that has no subject in a foreign tree, or nobody there to call it, is never a package
|
|
138
|
+
resource — it lives as the tree's own resource where the subject exists.
|
|
139
|
+
|
|
140
|
+
The sign is not an appraisal but two questions to the resource:
|
|
141
|
+
|
|
142
|
+
| Question | "No" means |
|
|
143
|
+
| ------------------------------------------------- | ------------------------------------------------ |
|
|
144
|
+
| Does the consumer have what the resource speaks of? | no subject: nothing to fill the companion with |
|
|
145
|
+
| Does the consumer have someone to call it? | no executor: the command does not run there |
|
|
146
|
+
|
|
147
|
+
"No" to even one — the resource stays with the tree that writes the package.
|
|
128
148
|
|
|
129
|
-
|
|
149
|
+
**The list of dropped resources does not close the boundary.** A line in `skip` says "I do not
|
|
150
|
+
need this" and lifts the layout at home; the resource stays in the package and keeps going to
|
|
151
|
+
everyone else. It is removed from the package itself, not from your own layout.
|
|
130
152
|
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
| Есть ли у потребителя кому его позвать? | исполнителя нет: команда у него не запускается |
|
|
153
|
+
**The tree's own rule is declared on a par with the package one:** the same shape, the same law
|
|
154
|
+
above, a companion next to it and its own branch in the gate map. The reader must not see that
|
|
155
|
+
it is younger.
|
|
135
156
|
|
|
136
|
-
|
|
157
|
+
What must be true at that is written as an agreement in the tree that writes the package: the
|
|
158
|
+
check that holds the boundary lives there too. A foreign tree has no business judging the
|
|
159
|
+
package resources, so the check does not go here.
|
|
137
160
|
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
161
|
+
## Feedback upwards
|
|
162
|
+
|
|
163
|
+
The rules layer is edited not from memory but by how it was used. This is held by three things.
|
|
164
|
+
|
|
165
|
+
**Observations** are written by the guards themselves — into `.claude/rt-kit/observations/`, a
|
|
166
|
+
file per day. A line holds the package resource name, the kind of event, the kind of edit, the
|
|
167
|
+
version and a session sign; no tree paths and no tree name are there. Switched off by the key
|
|
168
|
+
`"observe": false` in the config.
|
|
169
|
+
|
|
170
|
+
**The digest** is `agent-kit stats`. Its most valuable line is not "what was used" but **what is
|
|
171
|
+
laid out and never loaded**: a rule nobody opened gives itself away by nothing.
|
|
172
|
+
|
|
173
|
+
**The cost** is `agent-kit cost`. The digest says what was used; the cost — what it cost: the
|
|
174
|
+
weight of entering work, the weight of one rule and the weight of the whole layer. Counted is
|
|
175
|
+
not the file but what the session receives. The number is comparable only with one taken by the
|
|
176
|
+
same command.
|
|
177
|
+
|
|
178
|
+
**Proposals** come by two roads: the review of a closed task — by the `/skill-curator` command —
|
|
179
|
+
brings them in a batch, and a remark made in the middle of work is put by the agent itself with
|
|
180
|
+
the `/feedback` command. Both write into one file of the day and in one form; neither goes to
|
|
181
|
+
the network — the send carries them away.
|
|
182
|
+
|
|
183
|
+
**The wording of a record is judged by the send, not only by the guard on an edit.** The guard
|
|
184
|
+
stands on a `.md` of the tree, and a record leaves by a command — that is, past it. The send calls
|
|
185
|
+
the wording check laid out in the tree on the text of every record: one with findings does not
|
|
186
|
+
leave and is named by its file, its line and the first finding, while the rest of the batch goes.
|
|
187
|
+
A refused record stays lying on the disk with the mark «отбито» and leaves after the fix. A tree
|
|
188
|
+
that laid out no such check sends as before and says so by a line: silence about it would read as
|
|
189
|
+
a check that found nothing.
|
|
190
|
+
|
|
191
|
+
**The text of a record is written by the role `cargo-writer`, and it writes no files.** The
|
|
192
|
+
record is read by a person who knows neither this task nor this tree, while it is written by a
|
|
193
|
+
session thinking in the words of the rules layer. The role writes into the ready-made shape —
|
|
194
|
+
its own shape gets the block refused by the quote — and hands the text back: putting it on the
|
|
195
|
+
disk belongs to whoever answers for the send.
|
|
196
|
+
|
|
197
|
+
Every record carries four lines: **place** — where the edit goes in the resource, **reason** —
|
|
198
|
+
what went wrong without it, **closest** — the exact quote of the resource line this is closest
|
|
199
|
+
to, and **what it closes** — which overrides of the tree are lifted when the edit arrives as a
|
|
200
|
+
package edition.
|
|
201
|
+
|
|
202
|
+
The third line is the only one the machine checks: the quote is searched for in the resource,
|
|
203
|
+
and one not found refuses the block. There is nothing close at all — write exactly that: «нет».
|
|
204
|
+
A refused block stays lying with the mark «отбито» and the reason: it is visible that the review
|
|
205
|
+
took place and why it did not become an edit.
|
|
206
|
+
|
|
207
|
+
The fourth is written because the proposal goes outside while the override stays lying here:
|
|
208
|
+
without it, it replaces an already fixed section forever. There is nothing to lift — write
|
|
209
|
+
exactly that; the fourth line is never empty.
|
|
210
|
+
|
|
211
|
+
The same link is put on the override itself — as a markup comment in its section:
|
|
212
|
+
|
|
213
|
+
<!-- rt-proposed: rules/task-flow.md · «the article in full, as in the proposal» · 2026-09-03 -->
|
|
214
|
+
|
|
215
|
+
Nobody opens the proposal records on the day of the update: nothing points to them. The mark is
|
|
216
|
+
invisible in the assembled text, survives the merge by headings and is read by the machine: the
|
|
217
|
+
layout lists the sections whose article already exists in the new edition. A person lifts them —
|
|
218
|
+
something else may have been added to the section. A section without a mark counts as permanent.
|
|
219
|
+
|
|
220
|
+
Every proposal gets an address: «пакет», «компаньон» or «дерево». They are dumped into a file in
|
|
221
|
+
`.claude/rt-kit/proposals/` (the form is the template `proposal.md`), and `agent-kit propose`
|
|
222
|
+
carries to the intake those addressed to the package, together with the digest and the incident
|
|
223
|
+
analyses. A tree address in the digest or in the proposal text refuses the send in full.
|
|
224
|
+
|
|
225
|
+
The intake is a closed service: the digest speaks of the team's working habits, and in an open
|
|
226
|
+
work queue that is laid out for all to see. The intake address is declared by the key `intake`
|
|
227
|
+
in the tree config, the token by the key `token`, and it lies outside the tree.
|
|
228
|
+
|
|
229
|
+
Both values come from the intake owner and are not invented by the consumer: the address they
|
|
230
|
+
name, the token they issue as a one-off invitation code — the code enrols the tree in the intake
|
|
231
|
+
and puts the token into the file of the key `token`. Before the invitation the send refuses by
|
|
232
|
+
design, not by misconfiguration.
|
|
233
|
+
|
|
234
|
+
**The fate of its own records the tree asks by `agent-kit fate`.** The command reads the intake by
|
|
235
|
+
the token — the same one the cargo goes under — and prints every record with its state, what it was
|
|
236
|
+
fixed by and the version of the release. Under a record stands the override the mark of its section
|
|
237
|
+
ties to it: it is lifted now when the article already lies in the laid-out edition, and it waits for
|
|
238
|
+
an installation when the fix came out and has not reached this tree. A mark the intake gave no
|
|
239
|
+
record for is named apart. The command lifts nothing itself: the mark holds one article, and the
|
|
240
|
+
section may have been written into since.
|
|
241
|
+
|
|
242
|
+
**The tree sign is computed by the sender, not by a person.** It is derived from the repository
|
|
243
|
+
address, and the intake record is created by exactly it: a tree enrolled under its own word the
|
|
244
|
+
intake does not recognise. What would go and under which sign is printed by the dry run.
|
|
245
|
+
|
|
246
|
+
**The mark of a send is a trace for a person, not a store of state.** A clean tree after a send
|
|
247
|
+
means the whole cargo already lay in the intake, not that the send did not work.
|
|
248
|
+
|
|
249
|
+
They are reviewed where the editable resources lie and all consumers are visible at once — and
|
|
250
|
+
what arrives here is the intake's reply about how many records landed.
|
|
251
|
+
|
|
252
|
+
**The proposal file name is not named in tree texts.** It gives a reader of a foreign tree
|
|
253
|
+
nothing, and a link to a directory on the author's machine leads nowhere and turns the path check
|
|
254
|
+
red. Repository text says whom the proposal was sent to and what it is about; the package
|
|
255
|
+
resource may be named.
|
|
256
|
+
|
|
257
|
+
A proposal does not straighten the work. It lies as text, is read by eye and does not come into
|
|
258
|
+
the context by itself. It counts as closed only once it has entered a package resource: until
|
|
259
|
+
then it is not referred to as a current requirement and the hole is not counted closed.
|
|
260
|
+
|
|
261
|
+
**The owner's word about a proposal — "send it", "file it", "write a proposal" and any other form
|
|
262
|
+
of the same — is carried out by a send in the same turn.** A dry run does not count as a send: it
|
|
263
|
+
shows what would be sent and leaves no trace outside. The marks the send leaves in the tree land
|
|
264
|
+
as a second commit in the same branch. This is checked by the proposal guard at the end of the
|
|
265
|
+
turn.
|
|
266
|
+
|
|
267
|
+
## Installation where everything is already your own
|
|
268
|
+
|
|
269
|
+
1. `init`, then `skip` on everything the tree holds itself; an empty layout is a lawful start.
|
|
270
|
+
2. A snapshot of what the tree's checks say, before a single edit: it is the measure.
|
|
271
|
+
3. Resource by resource: bring the package edition up to the local one, move the subject matter
|
|
272
|
+
into an override, lift the drop, lay out, run the scenarios and compare with the snapshot.
|
|
273
|
+
4. The package does not write a layout over your own: a file without a header is foreign to
|
|
274
|
+
it. It is handed over with the `adopt` command — the former content lands next to it, marked
|
|
275
|
+
`.before-rt-kit`.
|
|
276
|
+
5. A resource whose local edition is richer than the package one in substance is not taken into
|
|
277
|
+
the layout. The sign is an article that the package edition lacks and cannot have: it follows
|
|
278
|
+
from the tree's subject. It goes into `skip`, and a proposal to remove it from the package
|
|
279
|
+
goes upwards.
|
|
280
|
+
6. Your own scenarios of a handed-over file are rewritten for the package behaviour or removed:
|
|
281
|
+
fixing the package edition in place is not allowed, its address is the package source or the
|
|
282
|
+
override.
|
|
283
|
+
|
|
284
|
+
## Tree traits
|
|
285
|
+
|
|
286
|
+
Some package rules are true only where there is a storage, an admin or an application. The tree
|
|
287
|
+
lists what it has by the key `has`; a resource names the trait it needs by a prefix in its name —
|
|
288
|
+
`observability.needs-app.md` — and to a tree that did not name such a trait it is not put at
|
|
289
|
+
all: neither itself nor the draft of its companion.
|
|
246
290
|
|
|
247
291
|
```json
|
|
248
292
|
{ "has": ["packages", "app"] }
|
|
249
293
|
```
|
|
250
294
|
|
|
251
|
-
-
|
|
252
|
-
|
|
253
|
-
-
|
|
295
|
+
- **Silence does not answer a requirement.** A tree with an empty `has` gets not one marked
|
|
296
|
+
resource: put at a guess, it comes back as an empty companion with nothing to fill it.
|
|
297
|
+
- **A requirement is not a kind.** A kind is chosen once; a tree has several traits at once.
|
|
254
298
|
|
|
255
|
-
##
|
|
299
|
+
## Disabled role
|
|
256
300
|
|
|
257
|
-
|
|
258
|
-
|
|
301
|
+
A role with a guard next to it is not called at the executor's discretion: the guard holds the
|
|
302
|
+
work until the role has had its say. A tree it gets in the way of names it by the key `rolesOff`
|
|
303
|
+
— by the role file name.
|
|
259
304
|
|
|
260
305
|
```json
|
|
261
306
|
{ "rolesOff": ["strict-teacher"] }
|
|
262
307
|
```
|
|
263
308
|
|
|
264
|
-
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
## Ловушки раскладки
|
|
271
|
-
|
|
272
|
-
- **Словарь — такой же разложенный ресурс, как правило.** Хук запуска кладёт его в контекст
|
|
273
|
-
целиком, до первой реплики, и оттого он выглядит обычным документом дерева; шапка у него есть,
|
|
274
|
-
но читается служебной строкой. Новое слово идёт в надстройку словаря, своим разделом.
|
|
275
|
-
|
|
276
|
-
- **Запись файла командой оболочки проверяется по всем путям, названным в её теле.** Гейт
|
|
277
|
-
вынимает пути из текста команды и читает тело документа целиком, если в команде есть имя
|
|
278
|
-
интерпретатора; строка импорта разложенного модуля тогда требует второе правило, а требуется
|
|
279
|
-
за раз одно — два отказа подряд, и каждый теряет написанное тело. Инструмент правки
|
|
280
|
-
проверяется одним своим путём; перенаправление оболочки — для того, что файлом дерева не станет.
|
|
281
|
-
- **Своё, стоящее рядом с разложенным, повторяет его механику молча.** Разбор списка известного,
|
|
282
|
-
корни исходников и снимок долга даёт модуль настройки проверок; второй такой же разбор в своей
|
|
283
|
-
проверке не видит ни сверка раскладки, ни проверка повторов. Перед тем как завести своё, смотрят,
|
|
284
|
-
что экспортирует модуль настройки проверок.
|
|
285
|
-
- **Правило, загруженное инструментом, бывает показано не целиком, и обрыв ничем не помечен.**
|
|
286
|
-
Длинный файл приходит в контекст обрезанным по строке, а обрыв приходится на хвост — туда, где
|
|
287
|
-
разделы надстройки дописаны в конец. Показанные строки сверяются с длиной файла одной командой;
|
|
288
|
-
расходятся — файл дочитывается чтением.
|
|
309
|
+
- **What is switched off is the mandatory call, not the role.** The role file stays laid out, and
|
|
310
|
+
it can be called by hand at any minute. The list is read by the guards themselves — through a
|
|
311
|
+
helper lying next to them.
|
|
312
|
+
- **It differs from dropping by the `skip` key in that it removes nothing.** A drop does not put
|
|
313
|
+
the role file at all: there is nobody left to call, and the guard next to it stays and keeps
|
|
314
|
+
refusing. Here it is the other way round — the role is in place, the guard is silent.
|