@askdkc/kiokuko 0.1.32 → 0.2.1
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.ja.md +59 -4
- package/README.ko.md +54 -4
- package/README.md +66 -4
- package/README.zh-CN.md +54 -4
- package/dist/agent-file/render.d.ts +1 -1
- package/dist/agent-file/render.d.ts.map +1 -1
- package/dist/agent-file/render.js +13 -6
- package/dist/agent-file/render.js.map +1 -1
- package/dist/akinator/agent-task.d.ts +2 -0
- package/dist/akinator/agent-task.d.ts.map +1 -1
- package/dist/akinator/agent-task.js +49 -13
- package/dist/akinator/agent-task.js.map +1 -1
- package/dist/akinator/capabilities.d.ts.map +1 -1
- package/dist/akinator/capabilities.js +21 -14
- package/dist/akinator/capabilities.js.map +1 -1
- package/dist/akinator/skill-discovery-attempt.d.ts +7 -1
- package/dist/akinator/skill-discovery-attempt.d.ts.map +1 -1
- package/dist/akinator/skill-discovery-attempt.js +104 -25
- package/dist/akinator/skill-discovery-attempt.js.map +1 -1
- package/dist/cli.d.ts.map +1 -1
- package/dist/cli.js +5 -1
- package/dist/cli.js.map +1 -1
- package/dist/commands/agent.d.ts.map +1 -1
- package/dist/commands/agent.js +18 -9
- package/dist/commands/agent.js.map +1 -1
- package/dist/commands/enno.d.ts +7 -0
- package/dist/commands/enno.d.ts.map +1 -0
- package/dist/commands/enno.js +76 -0
- package/dist/commands/enno.js.map +1 -0
- package/dist/commands/setup.d.ts +5 -1
- package/dist/commands/setup.d.ts.map +1 -1
- package/dist/commands/setup.js +83 -18
- package/dist/commands/setup.js.map +1 -1
- package/dist/config/paths.d.ts +6 -0
- package/dist/config/paths.d.ts.map +1 -1
- package/dist/config/paths.js +40 -0
- package/dist/config/paths.js.map +1 -1
- package/dist/enno-oduno/adapters.d.ts +18 -0
- package/dist/enno-oduno/adapters.d.ts.map +1 -0
- package/dist/enno-oduno/adapters.js +216 -0
- package/dist/enno-oduno/adapters.js.map +1 -0
- package/dist/enno-oduno/advisory-store.d.ts +25 -0
- package/dist/enno-oduno/advisory-store.d.ts.map +1 -0
- package/dist/enno-oduno/advisory-store.js +93 -0
- package/dist/enno-oduno/advisory-store.js.map +1 -0
- package/dist/enno-oduno/advisory.d.ts +16 -0
- package/dist/enno-oduno/advisory.d.ts.map +1 -0
- package/dist/enno-oduno/advisory.js +128 -0
- package/dist/enno-oduno/advisory.js.map +1 -0
- package/dist/enno-oduno/confirmation.d.ts +4 -0
- package/dist/enno-oduno/confirmation.d.ts.map +1 -0
- package/dist/enno-oduno/confirmation.js +124 -0
- package/dist/enno-oduno/confirmation.js.map +1 -0
- package/dist/enno-oduno/directives.d.ts +12 -0
- package/dist/enno-oduno/directives.d.ts.map +1 -0
- package/dist/enno-oduno/directives.js +241 -0
- package/dist/enno-oduno/directives.js.map +1 -0
- package/dist/enno-oduno/enno-oduno.d.mts +2 -0
- package/dist/enno-oduno/enno-oduno.d.mts.map +1 -0
- package/dist/enno-oduno/enno-oduno.mjs +3 -0
- package/dist/enno-oduno/enno-oduno.mjs.map +1 -0
- package/dist/enno-oduno/experts.d.ts +6 -0
- package/dist/enno-oduno/experts.d.ts.map +1 -0
- package/dist/enno-oduno/experts.js +18 -0
- package/dist/enno-oduno/experts.js.map +1 -0
- package/dist/enno-oduno/goki.d.mts +2 -0
- package/dist/enno-oduno/goki.d.mts.map +1 -0
- package/dist/enno-oduno/goki.mjs +3 -0
- package/dist/enno-oduno/goki.mjs.map +1 -0
- package/dist/enno-oduno/handoff.d.ts +4 -0
- package/dist/enno-oduno/handoff.d.ts.map +1 -0
- package/dist/enno-oduno/handoff.js +18 -0
- package/dist/enno-oduno/handoff.js.map +1 -0
- package/dist/enno-oduno/harness.d.ts +20 -0
- package/dist/enno-oduno/harness.d.ts.map +1 -0
- package/dist/enno-oduno/harness.js +65 -0
- package/dist/enno-oduno/harness.js.map +1 -0
- package/dist/enno-oduno/instructions.d.ts +5 -0
- package/dist/enno-oduno/instructions.d.ts.map +1 -0
- package/dist/enno-oduno/instructions.js +10 -0
- package/dist/enno-oduno/instructions.js.map +1 -0
- package/dist/enno-oduno/role-runner.d.ts +9 -0
- package/dist/enno-oduno/role-runner.d.ts.map +1 -0
- package/dist/enno-oduno/role-runner.js +171 -0
- package/dist/enno-oduno/role-runner.js.map +1 -0
- package/dist/enno-oduno/schemas.d.ts +668 -0
- package/dist/enno-oduno/schemas.d.ts.map +1 -0
- package/dist/enno-oduno/schemas.js +381 -0
- package/dist/enno-oduno/schemas.js.map +1 -0
- package/dist/enno-oduno/service.d.ts +49 -0
- package/dist/enno-oduno/service.d.ts.map +1 -0
- package/dist/enno-oduno/service.js +1005 -0
- package/dist/enno-oduno/service.js.map +1 -0
- package/dist/enno-oduno/skills.d.ts +22 -0
- package/dist/enno-oduno/skills.d.ts.map +1 -0
- package/dist/enno-oduno/skills.js +127 -0
- package/dist/enno-oduno/skills.js.map +1 -0
- package/dist/enno-oduno/store.d.ts +67 -0
- package/dist/enno-oduno/store.d.ts.map +1 -0
- package/dist/enno-oduno/store.js +380 -0
- package/dist/enno-oduno/store.js.map +1 -0
- package/dist/enno-oduno/types.d.ts +357 -0
- package/dist/enno-oduno/types.d.ts.map +1 -0
- package/dist/enno-oduno/types.js +64 -0
- package/dist/enno-oduno/types.js.map +1 -0
- package/dist/enno-oduno/verifier.d.ts +9 -0
- package/dist/enno-oduno/verifier.d.ts.map +1 -0
- package/dist/enno-oduno/verifier.js +101 -0
- package/dist/enno-oduno/verifier.js.map +1 -0
- package/dist/enno-oduno/zenki.d.mts +2 -0
- package/dist/enno-oduno/zenki.d.mts.map +1 -0
- package/dist/enno-oduno/zenki.mjs +3 -0
- package/dist/enno-oduno/zenki.mjs.map +1 -0
- package/dist/ledger/types.d.ts +1 -1
- package/dist/ledger/types.d.ts.map +1 -1
- package/dist/ledger/types.js +5 -0
- package/dist/ledger/types.js.map +1 -1
- package/dist/mcp/server.d.ts +1 -0
- package/dist/mcp/server.d.ts.map +1 -1
- package/dist/mcp/server.js +76 -26
- package/dist/mcp/server.js.map +1 -1
- package/dist/setup/claude-config.d.ts +2 -0
- package/dist/setup/claude-config.d.ts.map +1 -1
- package/dist/setup/claude-config.js +12 -0
- package/dist/setup/claude-config.js.map +1 -1
- package/dist/setup/enno-client-config.d.ts +9 -0
- package/dist/setup/enno-client-config.d.ts.map +1 -0
- package/dist/setup/enno-client-config.js +172 -0
- package/dist/setup/enno-client-config.js.map +1 -0
- package/dist/setup/opencode-config.d.ts +2 -0
- package/dist/setup/opencode-config.d.ts.map +1 -1
- package/dist/setup/opencode-config.js +12 -0
- package/dist/setup/opencode-config.js.map +1 -1
- package/dist/setup/render.d.ts +2 -0
- package/dist/setup/render.d.ts.map +1 -1
- package/dist/setup/render.js +23 -12
- package/dist/setup/render.js.map +1 -1
- package/dist/setup/standard-skills.d.ts +23 -4
- package/dist/setup/standard-skills.d.ts.map +1 -1
- package/dist/setup/standard-skills.js +51 -1
- package/dist/setup/standard-skills.js.map +1 -1
- package/dist/skills/discovery-service.d.ts.map +1 -1
- package/dist/skills/discovery-service.js +7 -3
- package/dist/skills/discovery-service.js.map +1 -1
- package/dist/skills/types.d.ts +1 -0
- package/dist/skills/types.d.ts.map +1 -1
- package/migrations/013_enno_oduno.sql +176 -0
- package/migrations/014_oduno_reflection_phases.sql +40 -0
- package/migrations/015_skill_discovery_attempt_digests.sql +90 -0
- package/migrations/016_enno_advisory_rounds.sql +67 -0
- package/package.json +7 -1
- package/skills/kiokuko-enno-oduno/SKILL.md +143 -0
- package/skills/kiokuko-enno-oduno/enno-oduno.png +0 -0
- package/skills/kiokuko-single-purpose-functions/SKILL.md +44 -258
- package/skills/kiokuko-single-purpose-functions/references/boundaries-and-ownership.md +50 -0
- package/skills/kiokuko-single-purpose-functions/references/domain-and-types.md +48 -0
- package/skills/kiokuko-single-purpose-functions/references/effects-and-data.md +43 -0
- package/skills/kiokuko-single-purpose-functions/references/protocols-and-idempotency.md +42 -0
- package/skills/kiokuko-single-purpose-functions/references/verification.md +41 -0
- package/skills/kiokuko-soul/SKILL.md +72 -0
- package/skills/kiokuko-ui-design-soul/SKILL.md +39 -1178
- package/skills/kiokuko-ui-design-soul/references/accessibility-and-navigation.md +31 -0
- package/skills/kiokuko-ui-design-soul/references/async-recovery.md +49 -0
- package/skills/kiokuko-ui-design-soul/references/forms-and-controls.md +35 -0
- package/skills/kiokuko-ui-design-soul/references/interaction-feedback.md +34 -0
- package/skills/kiokuko-ui-design-soul/references/responsive-and-platform.md +38 -0
- package/skills/kiokuko-ui-design-soul/references/safety-and-review.md +39 -0
- package/templates/AGENTS.md +11 -6
|
@@ -1,288 +1,74 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: kiokuko-single-purpose-functions
|
|
3
|
-
description: Use whenever writing, modifying, reviewing, debugging, or refactoring code
|
|
3
|
+
description: Use whenever writing, modifying, reviewing, debugging, or refactoring code. Apply a compact universal function contract, then route each function or WorkUnit to one to three versioned expert fragments for its actual risks.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
<!-- KIOKUKO MANAGED STANDARD SKILL: kiokuko-single-purpose-functions -->
|
|
7
7
|
|
|
8
|
-
# Single-purpose function
|
|
8
|
+
# Single-purpose function router
|
|
9
9
|
|
|
10
|
-
##
|
|
10
|
+
## Outcome
|
|
11
11
|
|
|
12
|
-
|
|
12
|
+
Create code whose functions each own one cohesive externally observable responsibility, with explicit boundaries, effects, failures, and focused verification across languages, frameworks, and repositories.
|
|
13
13
|
|
|
14
|
-
|
|
14
|
+
This file is the mandatory compact index for code work. It is not a request to read every reference. Read this index completely, select the smallest sufficient expert set, and then read only those expert files.
|
|
15
15
|
|
|
16
|
-
|
|
16
|
+
## Universal core
|
|
17
17
|
|
|
18
|
-
|
|
18
|
+
Apply these invariants to every created or changed function:
|
|
19
19
|
|
|
20
|
-
|
|
20
|
+
1. State one contract: input, success, expected failures, effects, and observable result.
|
|
21
|
+
2. Give it one responsibility and one reason to change. Do not create meaningless micro-functions.
|
|
22
|
+
3. Validate hostile input at the boundary; keep the private core constrained by types or validated values.
|
|
23
|
+
4. Do not mutate caller-owned input unless mutation is the explicit API contract.
|
|
24
|
+
5. Make domain decisions deterministic. Keep persistence, network, filesystem, process, clock, randomness, UI, and logging effects explicit.
|
|
25
|
+
6. Return or throw failures intentionally. Do not silently swallow, partially succeed, or leak lower-layer accidents as the public contract.
|
|
26
|
+
7. Add the smallest runnable test that proves success, the important failure, and the regression being changed.
|
|
27
|
+
8. Preserve unrelated code and existing public behavior unless the task explicitly changes it.
|
|
21
28
|
|
|
22
|
-
|
|
23
|
-
- one primary reason to change;
|
|
24
|
-
- one defined success result;
|
|
25
|
-
- one explicit set of expected failures;
|
|
26
|
-
- one declared effect profile.
|
|
29
|
+
Small is not the objective. Cohesion is. Keep operations together when splitting them would hide sequencing, duplicate policy, or weaken a transaction.
|
|
27
30
|
|
|
28
|
-
|
|
31
|
+
## MoE selection contract
|
|
29
32
|
|
|
30
|
-
|
|
33
|
+
For each new or materially changed function, or for the smallest WorkUnit that owns a cohesive use case:
|
|
31
34
|
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
- coordinate one atomic use case.
|
|
35
|
+
1. classify the dominant risk;
|
|
36
|
+
2. select one expert ID from the table below;
|
|
37
|
+
3. add at most two more only when the same contract genuinely crosses those risks;
|
|
38
|
+
4. record a concrete reason for every selection;
|
|
39
|
+
5. read the selected files before implementation or review.
|
|
38
40
|
|
|
39
|
-
|
|
41
|
+
Do not make a new Skill per function. The function contract is the execution envelope; `expertRefs` are its mixture-of-experts dispatch. If two functions need materially different expert sets or reasons to change, split the WorkUnit or record separate function contracts inside it.
|
|
40
42
|
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
Before changing code, inspect the relevant source, tests, documentation, types, error conventions, and adjacent helpers.
|
|
44
|
-
|
|
45
|
-
Preserve the repository’s established contracts unless the task explicitly changes them:
|
|
46
|
-
|
|
47
|
-
- public APIs and serialized formats;
|
|
48
|
-
- error types, codes, and messages;
|
|
49
|
-
- transaction and concurrency rules;
|
|
50
|
-
- ownership and mutation conventions;
|
|
51
|
-
- framework and dependency boundaries;
|
|
52
|
-
- security and privacy requirements;
|
|
53
|
-
- test and build commands.
|
|
54
|
-
|
|
55
|
-
Reuse a project helper when it already implements the required behavior. Do not introduce a parallel result type, validation library, database wrapper, dependency container, or architecture merely because it is familiar from another project.
|
|
56
|
-
|
|
57
|
-
## Function layers
|
|
58
|
-
|
|
59
|
-
Classify every new or materially changed function before implementing it.
|
|
60
|
-
|
|
61
|
-
### Boundary parser or validator
|
|
62
|
-
|
|
63
|
-
A boundary function receives data that is not yet trusted, including network requests, command-line input, environment variables, configuration files, database rows, files, messages, provider responses, and deserialized state.
|
|
64
|
-
|
|
65
|
-
It should:
|
|
66
|
-
|
|
67
|
-
1. bound work before expensive processing;
|
|
68
|
-
2. reject malformed shape, type, range, encoding, size, depth, count, or unknown fields when required;
|
|
69
|
-
3. avoid invoking caller-controlled getters, proxies, hooks, or serialization behavior;
|
|
70
|
-
4. create an owned normalized value;
|
|
71
|
-
5. return that value or produce one narrow, safe expected failure.
|
|
72
|
-
|
|
73
|
-
After validation, delegate to typed or otherwise constrained internal code. Do not make every internal helper revalidate the same value.
|
|
74
|
-
|
|
75
|
-
### Pure domain function
|
|
76
|
-
|
|
77
|
-
A pure domain function performs one decision, state transition, normalization, ranking, projection, or calculation over validated values.
|
|
78
|
-
|
|
79
|
-
It must not hide reads of time, randomness, environment, locale-sensitive state, mutable globals, filesystem, database, or network. Pass variable dependencies explicitly. The same explicit inputs should produce the same output.
|
|
80
|
-
|
|
81
|
-
### Persistence function
|
|
82
|
-
|
|
83
|
-
A persistence function performs one storage capability.
|
|
84
|
-
|
|
85
|
-
It should:
|
|
86
|
-
|
|
87
|
-
- use the project’s established database or storage abstraction;
|
|
88
|
-
- parameterize queries where applicable;
|
|
89
|
-
- avoid transport and presentation concerns;
|
|
90
|
-
- avoid network and unrelated filesystem work;
|
|
91
|
-
- remain transaction-agnostic unless it explicitly owns the transaction;
|
|
92
|
-
- validate stored data before treating it as domain state;
|
|
93
|
-
- preserve revision, idempotency, ordering, and identity invariants.
|
|
94
|
-
|
|
95
|
-
### Effect adapter
|
|
96
|
-
|
|
97
|
-
An adapter wraps one external capability, such as reading a file, calling a provider, obtaining time, generating an identifier, writing a response, or opening a database.
|
|
98
|
-
|
|
99
|
-
Expose the smallest capability required. Prefer a narrow function or interface over a broad service container.
|
|
100
|
-
|
|
101
|
-
### Use-case orchestrator
|
|
102
|
-
|
|
103
|
-
An orchestrator coordinates one application operation. It may combine validation, pure decisions, persistence, and adapters, but it should not absorb their detailed policies.
|
|
104
|
-
|
|
105
|
-
## Required contract
|
|
106
|
-
|
|
107
|
-
Before implementing a new function or materially changing an existing one, determine:
|
|
43
|
+
In Enno-Oduno plans, `expertRefs` is required for code-changing WorkUnits and is revision-bound. Outside Enno-Oduno, keep the same mapping in the working plan or review notes:
|
|
108
44
|
|
|
109
45
|
```text
|
|
110
|
-
|
|
111
|
-
Layer: boundary | domain | persistence | adapter | orchestrator
|
|
112
|
-
Responsibility:
|
|
113
|
-
Inputs and trust level:
|
|
114
|
-
Input ownership:
|
|
115
|
-
Success output:
|
|
116
|
-
Expected failures:
|
|
117
|
-
Other propagated failures:
|
|
118
|
-
External effects:
|
|
119
|
-
Transaction or resource ownership:
|
|
120
|
-
Idempotency or replay behavior:
|
|
121
|
-
Security and privacy constraints:
|
|
122
|
-
Preconditions:
|
|
123
|
-
Postconditions:
|
|
46
|
+
target -> responsibility -> expert IDs -> focused verifier
|
|
124
47
|
```
|
|
125
48
|
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
## Non-negotiable rules
|
|
129
|
-
|
|
130
|
-
### 1. Do not mutate caller-owned input
|
|
131
|
-
|
|
132
|
-
Treat parameters as immutable unless the contract explicitly transfers ownership.
|
|
133
|
-
|
|
134
|
-
- Do not modify caller-provided objects, arrays, maps, sets, buffers, collections, or records.
|
|
135
|
-
- Return a new value for transformations.
|
|
136
|
-
- Local mutation of newly allocated, unobservable data is allowed when it improves clarity or measured performance.
|
|
137
|
-
- Do not use shared mutable state for domain behavior.
|
|
138
|
-
|
|
139
|
-
Add an input-snapshot test when accidental mutation is plausible.
|
|
140
|
-
|
|
141
|
-
### 2. Validate values at the real trust boundary
|
|
142
|
-
|
|
143
|
-
Static types, annotations, interfaces, and schemas known only to the compiler do not validate runtime data.
|
|
144
|
-
|
|
145
|
-
Use the repository’s established validation approach. Validate external JSON, database rows, configuration, files, provider responses, and messages before converting them into domain values. Reject or explicitly handle unknown fields when the contract is closed.
|
|
146
|
-
|
|
147
|
-
Use an unconstrained type such as `unknown`, a raw byte buffer, or a generic map only at a real boundary. Internal helpers should receive constrained values.
|
|
148
|
-
|
|
149
|
-
### 3. Bound work before trust
|
|
150
|
-
|
|
151
|
-
Every externally influenced collection, string, nested object, retry loop, result set, or payload needs a justified bound.
|
|
152
|
-
|
|
153
|
-
Check limits before full traversal, expansion, hashing, serialization, proportional allocation, persistence, retrying, or returning data. Truncate only when the contract explicitly defines a preview or diagnostic field; otherwise reject oversized authoritative input.
|
|
154
|
-
|
|
155
|
-
### 4. Produce an owned snapshot
|
|
156
|
-
|
|
157
|
-
Do not retain references to hostile or caller-controlled data after validation. Copy accepted values into owned structures before canonicalization, hashing, persistence, or asynchronous use.
|
|
158
|
-
|
|
159
|
-
Where the runtime permits hostile object behavior, account for accessors, proxies, cycles, malformed text, unsupported prototypes, and non-finite numbers.
|
|
160
|
-
|
|
161
|
-
### 5. Use narrow types and exact states
|
|
162
|
-
|
|
163
|
-
- Prefer the strongest practical static analysis and type-checking mode supported by the project.
|
|
164
|
-
- Avoid escape hatches such as `any`, unchecked casts, suppressed diagnostics, or untyped dictionaries when a narrower representation is possible.
|
|
165
|
-
- Use enums, literal unions, sealed variants, value objects, or equivalent exact state models.
|
|
166
|
-
- Distinguish missing, null, unknown, empty, unavailable, and invalid when the protocol distinguishes them.
|
|
167
|
-
- Omit absent optional values rather than inventing ambiguous placeholders.
|
|
168
|
-
- Keep assertions adjacent to the runtime check that proves them.
|
|
169
|
-
|
|
170
|
-
### 6. Make expected failures explicit and safe
|
|
171
|
-
|
|
172
|
-
Use the project’s established error taxonomy or result convention. Choose the narrowest existing failure category.
|
|
173
|
-
|
|
174
|
-
Do not use `false`, `null`, an empty string, or a swallowed exception to represent several unrelated failures. Do not catch an error merely to hide it or continue from uncertain state.
|
|
175
|
-
|
|
176
|
-
At public boundaries:
|
|
177
|
-
|
|
178
|
-
- map internal failures to stable public behavior;
|
|
179
|
-
- keep details bounded and allowlisted;
|
|
180
|
-
- never echo credentials, tokens, private data, raw request bodies, or unsafe provider responses;
|
|
181
|
-
- preserve both operation and cleanup failures when both occur.
|
|
182
|
-
|
|
183
|
-
### 7. Keep domain decisions deterministic
|
|
184
|
-
|
|
185
|
-
Inject time, randomness, environment, current directory, locale, filesystem, database, network, and provider access. Use stable ordering and serialization when output participates in hashes, identities, manifests, caches, snapshots, or replay.
|
|
186
|
-
|
|
187
|
-
### 8. Preserve transaction and resource discipline
|
|
188
|
-
|
|
189
|
-
- Let one use case own the transaction or resource lifecycle.
|
|
190
|
-
- Keep low-level storage functions composable inside that owner.
|
|
191
|
-
- Do not perform network calls, user prompts, or unrelated slow work while holding a write transaction or scarce lock.
|
|
192
|
-
- Do not add nested transaction ownership where an outer transaction already exists.
|
|
193
|
-
- Treat ambiguous commit or cleanup state explicitly; do not compensate as though rollback were proven.
|
|
194
|
-
|
|
195
|
-
### 9. Preserve idempotency and compare-and-swap semantics
|
|
196
|
-
|
|
197
|
-
Bind every meaning-bearing input to request identities, expected revisions, generation tokens, content hashes, or cache keys.
|
|
198
|
-
|
|
199
|
-
- Exact replay may reuse the recorded acknowledgement.
|
|
200
|
-
- Reusing an identity with changed input is a conflict.
|
|
201
|
-
- Compare the exact observed version before mutation.
|
|
202
|
-
- Never silently overwrite newer or independently owned state.
|
|
203
|
-
- Never present partial or ambiguous cleanup as full success.
|
|
204
|
-
|
|
205
|
-
### 10. Preserve external contracts
|
|
206
|
-
|
|
207
|
-
A refactor is not behavior-preserving if it accidentally changes a machine contract.
|
|
208
|
-
|
|
209
|
-
Preserve applicable command output, exit status, API schema, HTTP status, protocol envelope, database migration history, file format, line ending, file mode, ownership marker, event order, and backward-compatibility behavior.
|
|
210
|
-
|
|
211
|
-
### 11. Keep security checks in the success path
|
|
212
|
-
|
|
213
|
-
Security validation is not optional logging. Apply required authorization, normalization, sanitization, size checks, secret detection, and path or URL restrictions before persistence or delivery.
|
|
214
|
-
|
|
215
|
-
A detected secret or invalid value must not reappear in errors, logs, hashes exposed to callers, temporary diagnostics, or responses.
|
|
216
|
-
|
|
217
|
-
### 12. Test the contract independently
|
|
218
|
-
|
|
219
|
-
Use the repository’s existing test framework and style. Cover the applicable cases:
|
|
220
|
-
|
|
221
|
-
- normal success;
|
|
222
|
-
- empty, minimum, maximum, and exact boundary values;
|
|
223
|
-
- wrong primitive type or malformed structure;
|
|
224
|
-
- unknown fields for closed inputs;
|
|
225
|
-
- each expected failure category;
|
|
226
|
-
- no mutation of caller-owned input;
|
|
227
|
-
- no secret or raw invalid-value echo;
|
|
228
|
-
- deterministic ordering, hashing, or replay identity;
|
|
229
|
-
- exact replay and changed-input conflict;
|
|
230
|
-
- bounded retry and non-retryable failure;
|
|
231
|
-
- operation-plus-cleanup failure;
|
|
232
|
-
- integration with the real boundary when adapter behavior changes.
|
|
233
|
-
|
|
234
|
-
Assert observable behavior, not private call order, unless ordering itself is a documented invariant.
|
|
235
|
-
|
|
236
|
-
## Required workflow
|
|
237
|
-
|
|
238
|
-
1. Read the governing repository contracts and adjacent implementation.
|
|
239
|
-
2. Define the smallest coherent behavior change.
|
|
240
|
-
3. Classify each changed function’s layer.
|
|
241
|
-
4. Determine its input, output, failure, effect, ownership, and replay contract.
|
|
242
|
-
5. Validate once at the hostile boundary and create owned data.
|
|
243
|
-
6. Implement deterministic policy in the pure core.
|
|
244
|
-
7. Add only the narrow external capability required.
|
|
245
|
-
8. Compose the use case without mixing detailed policies into orchestration.
|
|
246
|
-
9. Add a regression test for the counterexample that would disprove the contract.
|
|
247
|
-
10. Run the narrowest affected tests, then the repository’s documented static, type, test, build, and package checks as applicable.
|
|
248
|
-
11. Report what changed, what was verified, what was skipped, and any residual risk.
|
|
249
|
-
|
|
250
|
-
Do not invent commands that are absent from the repository.
|
|
251
|
-
|
|
252
|
-
## Decomposition tests
|
|
49
|
+
Do not load unselected fragments “just in case.” If repository evidence exposes a new risk, update the selection explicitly before consuming that fragment.
|
|
253
50
|
|
|
254
|
-
|
|
51
|
+
## Expert index
|
|
255
52
|
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
8. Error mapping or validation policy is duplicated across layers.
|
|
264
|
-
9. Security, replay, or cleanup state is implicit instead of represented.
|
|
53
|
+
| Expert ID | Select when the contract owns | Read |
|
|
54
|
+
| --- | --- | --- |
|
|
55
|
+
| `code.boundary.v1` | parsing, validation, authorization, ownership, untrusted input | [boundaries-and-ownership.md](references/boundaries-and-ownership.md) |
|
|
56
|
+
| `code.domain.v1` | domain rules, state transitions, narrow types, deterministic decisions | [domain-and-types.md](references/domain-and-types.md) |
|
|
57
|
+
| `code.effects.v1` | database, filesystem, network, process, transaction, resource lifetime | [effects-and-data.md](references/effects-and-data.md) |
|
|
58
|
+
| `code.protocol.v1` | retry, idempotency, concurrency, revisions, external/public protocols | [protocols-and-idempotency.md](references/protocols-and-idempotency.md) |
|
|
59
|
+
| `code.verification.v1` | regression repair, test design, review, compatibility or failure evidence | [verification.md](references/verification.md) |
|
|
265
60
|
|
|
266
|
-
|
|
61
|
+
Typical selections:
|
|
267
62
|
|
|
268
|
-
|
|
63
|
+
- pure calculation: `code.domain.v1`;
|
|
64
|
+
- request parser: `code.boundary.v1` + `code.verification.v1`;
|
|
65
|
+
- transactional write: `code.effects.v1` + `code.protocol.v1`;
|
|
66
|
+
- public API repair: `code.boundary.v1` + `code.protocol.v1` + `code.verification.v1`.
|
|
269
67
|
|
|
270
|
-
|
|
68
|
+
## Escalation references
|
|
271
69
|
|
|
272
|
-
-
|
|
273
|
-
- cast external data directly into a domain type;
|
|
274
|
-
- weaken types merely to satisfy one inconvenient call site;
|
|
275
|
-
- mutate input because copying is inconvenient;
|
|
276
|
-
- swallow corruption, conflict, partial failure, or uncertain state;
|
|
277
|
-
- echo invalid or secret-like values in public failures;
|
|
278
|
-
- retry by matching error-message text when structured classification exists;
|
|
279
|
-
- run external work inside a write transaction without a documented reason;
|
|
280
|
-
- bypass revision, idempotency, identity, authorization, or ownership checks;
|
|
281
|
-
- overwrite independently owned state;
|
|
282
|
-
- create dozens of trivial wrappers to satisfy a function-count or line-count target;
|
|
283
|
-
- change public contracts as incidental cleanup;
|
|
284
|
-
- declare completion without naming the verification actually run.
|
|
70
|
+
Read [kiokuko-patterns.md](references/kiokuko-patterns.md) only when a selected fragment needs a fuller TypeScript example. Read [review-checklist.md](references/review-checklist.md) for comprehensive code review or final verification, not for every function edit.
|
|
285
71
|
|
|
286
|
-
## Completion
|
|
72
|
+
## Completion report
|
|
287
73
|
|
|
288
|
-
|
|
74
|
+
Report the function or WorkUnit contracts changed, selected expert IDs, focused verifier results, and anything not verified. A build alone does not prove boundary, failure, or interaction behavior.
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
<!-- KIOKUKO MANAGED STANDARD SKILL: kiokuko-single-purpose-functions -->
|
|
2
|
+
|
|
3
|
+
# `code.boundary.v1` — boundaries and ownership
|
|
4
|
+
|
|
5
|
+
Select this expert when a function receives data or authority from a caller, user, file, database, environment, network, parser, plugin, or another process.
|
|
6
|
+
|
|
7
|
+
## Contract
|
|
8
|
+
|
|
9
|
+
The public boundary accepts broad input only long enough to validate and normalize it into a narrow internal value. Reject malformed, ambiguous, oversized, unauthorized, or out-of-scope input before domain work or effects begin.
|
|
10
|
+
|
|
11
|
+
Define explicitly:
|
|
12
|
+
|
|
13
|
+
- what input representations are accepted;
|
|
14
|
+
- whether normalization changes identity or only representation;
|
|
15
|
+
- which limits prevent resource abuse;
|
|
16
|
+
- which caller or principal is authorized;
|
|
17
|
+
- which errors are public and stable;
|
|
18
|
+
- who owns mutable collections, buffers, streams, or objects after the call.
|
|
19
|
+
|
|
20
|
+
Validation must match the actual threat boundary. A TypeScript type annotation does not validate JSON. A UI constraint does not validate an HTTP request. A prior parser does not authorize the current operation.
|
|
21
|
+
|
|
22
|
+
## Ownership rules
|
|
23
|
+
|
|
24
|
+
- Treat caller-owned inputs as immutable by default. Copy before sorting, filtering in place, deleting keys, or retaining a mutable reference.
|
|
25
|
+
- Do not return internal mutable state directly when callers could corrupt invariants.
|
|
26
|
+
- Make transfer of ownership explicit for streams, handles, transactions, and buffers.
|
|
27
|
+
- Avoid aliases where one layer can mutate data another layer assumes is stable.
|
|
28
|
+
- Preserve original user data through validation failures unless destructive normalization is the explicit contract.
|
|
29
|
+
|
|
30
|
+
## Boundary shape
|
|
31
|
+
|
|
32
|
+
Prefer a thin public function that performs hostile-boundary work and then calls a constrained private core:
|
|
33
|
+
|
|
34
|
+
```ts
|
|
35
|
+
function parseCreateRequest(input: unknown): CreateRequest {
|
|
36
|
+
const parsed = createRequestSchema.safeParse(input);
|
|
37
|
+
if (!parsed.success) throw new PublicError('invalid_request');
|
|
38
|
+
return parsed.data;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
function decideCreate(request: CreateRequest): CreateDecision {
|
|
42
|
+
// No unknown input remains here.
|
|
43
|
+
}
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
Do not scatter the same validation across several deeper functions. Centralize public error mapping so transport, database, or parser details do not accidentally become the API.
|
|
47
|
+
|
|
48
|
+
## Focused verification
|
|
49
|
+
|
|
50
|
+
Test at least one valid input, each materially different rejection class, caller-input immutability, and the absence of effects after rejection. For authorization boundaries, include a counterexample that has valid shape but insufficient authority.
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
<!-- KIOKUKO MANAGED STANDARD SKILL: kiokuko-single-purpose-functions -->
|
|
2
|
+
|
|
3
|
+
# `code.domain.v1` — domain rules and narrow types
|
|
4
|
+
|
|
5
|
+
Select this expert when the function decides business rules, computes values, classifies states, or moves an entity through a state machine.
|
|
6
|
+
|
|
7
|
+
## Contract
|
|
8
|
+
|
|
9
|
+
Domain logic should be deterministic for the same validated input. Keep clocks, randomness, persistence, network calls, environment reads, and logging outside the decision or inject their values explicitly.
|
|
10
|
+
|
|
11
|
+
Model legal states and transitions directly. Prefer narrow unions, enums, tagged results, value objects, and exhaustive branches over booleans or loosely related nullable fields whose combinations can become invalid.
|
|
12
|
+
|
|
13
|
+
Define:
|
|
14
|
+
|
|
15
|
+
- the valid input state;
|
|
16
|
+
- the exact transition or result;
|
|
17
|
+
- invariants preserved before and after;
|
|
18
|
+
- expected domain rejections;
|
|
19
|
+
- whether the operation is total or intentionally partial.
|
|
20
|
+
|
|
21
|
+
## Cohesion rules
|
|
22
|
+
|
|
23
|
+
- A function may contain several steps when they implement one rule and change for the same reason.
|
|
24
|
+
- Split unrelated policy decisions even if they currently share a caller.
|
|
25
|
+
- Do not extract trivial wrappers that merely rename an expression without creating a useful contract.
|
|
26
|
+
- Do not mix “decide what should happen” with “persist or publish it” when the decision can be represented as data.
|
|
27
|
+
|
|
28
|
+
Example:
|
|
29
|
+
|
|
30
|
+
```ts
|
|
31
|
+
type Transition =
|
|
32
|
+
| { kind: 'advance'; next: State }
|
|
33
|
+
| { kind: 'reject'; code: 'stale_revision' | 'terminal' };
|
|
34
|
+
|
|
35
|
+
function decideAdvance(current: State, expectedRevision: number): Transition {
|
|
36
|
+
if (current.revision !== expectedRevision) return { kind: 'reject', code: 'stale_revision' };
|
|
37
|
+
if (current.status === 'completed') return { kind: 'reject', code: 'terminal' };
|
|
38
|
+
return { kind: 'advance', next: { ...current, revision: current.revision + 1 } };
|
|
39
|
+
}
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
## Failure behavior
|
|
43
|
+
|
|
44
|
+
Expected domain failure is part of the result contract, not an accident to catch broadly. Use one explicit representation consistently. Reserve unexpected exceptions for integrity failures or defects that the current function cannot safely classify.
|
|
45
|
+
|
|
46
|
+
## Focused verification
|
|
47
|
+
|
|
48
|
+
Test representative valid states, every legal transition family, forbidden transitions, boundary values, and determinism. When a state space is finite, test exhaustiveness or generate a transition table rather than relying only on happy-path examples.
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
<!-- KIOKUKO MANAGED STANDARD SKILL: kiokuko-single-purpose-functions -->
|
|
2
|
+
|
|
3
|
+
# `code.effects.v1` — effects, data, and resource lifetime
|
|
4
|
+
|
|
5
|
+
Select this expert when a contract touches a database, filesystem, network, subprocess, cache, message bus, clock, random source, UI runtime, or long-lived resource.
|
|
6
|
+
|
|
7
|
+
## Contract
|
|
8
|
+
|
|
9
|
+
Make the effect profile visible at the function boundary. A function that appears pure but reads global state, mutates a cache, logs sensitive data, or launches background work has a misleading contract.
|
|
10
|
+
|
|
11
|
+
Separate four concerns when practical:
|
|
12
|
+
|
|
13
|
+
1. validate and authorize the request;
|
|
14
|
+
2. decide the domain change;
|
|
15
|
+
3. apply effects under an explicit atomicity policy;
|
|
16
|
+
4. translate infrastructure outcomes into the public result.
|
|
17
|
+
|
|
18
|
+
Do not split a transaction merely to make functions shorter. Operations that must commit or roll back together belong under one transaction owner. Conversely, do not hide unrelated writes inside a function whose name promises only a read or calculation.
|
|
19
|
+
|
|
20
|
+
## Data integrity
|
|
21
|
+
|
|
22
|
+
- State which writes are atomic and which partial outcomes are possible.
|
|
23
|
+
- Use compare-and-set, revision checks, unique constraints, or locks where concurrent writers can violate invariants.
|
|
24
|
+
- Check affected-row counts when they prove the intended state transition occurred.
|
|
25
|
+
- Never claim persistence before durable completion.
|
|
26
|
+
- Keep schema or serialization compatibility explicit at stored-data boundaries.
|
|
27
|
+
- Do not swallow a failed cleanup, rollback, or close when it changes correctness.
|
|
28
|
+
|
|
29
|
+
## External effects
|
|
30
|
+
|
|
31
|
+
- Bound time, output, memory, and retries.
|
|
32
|
+
- Define cancellation semantics: cancelling the UI is not the same as cancelling the work.
|
|
33
|
+
- Close files, streams, transactions, child processes, and subscriptions on success and failure.
|
|
34
|
+
- Avoid fire-and-forget work unless ownership, failure reporting, and process lifetime are deliberately defined.
|
|
35
|
+
- Sanitize logs and previews; do not leak secrets or private payloads through diagnostic output.
|
|
36
|
+
|
|
37
|
+
## Testing seam
|
|
38
|
+
|
|
39
|
+
Inject the narrow effect capability needed by the contract rather than an entire ambient service container. A focused fake should let tests observe calls, order, arguments, cleanup, and failure mapping without reproducing the infrastructure implementation.
|
|
40
|
+
|
|
41
|
+
## Focused verification
|
|
42
|
+
|
|
43
|
+
Test successful effect order, failure before mutation, failure during mutation, rollback or cleanup, timeout/cancellation, and concurrent or stale writes when applicable. Integration-test the real adapter separately from deterministic domain tests.
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
<!-- KIOKUKO MANAGED STANDARD SKILL: kiokuko-single-purpose-functions -->
|
|
2
|
+
|
|
3
|
+
# `code.protocol.v1` — protocols, concurrency, and idempotency
|
|
4
|
+
|
|
5
|
+
Select this expert when callers retry, messages can be duplicated, state is revisioned, several actors race, or a public/API/storage protocol must remain compatible.
|
|
6
|
+
|
|
7
|
+
## Contract
|
|
8
|
+
|
|
9
|
+
Identity, ordering, and state transition rules are public behavior. Do not infer them from error text, timestamps, repository-wide “latest” records, or other ambiguous signals.
|
|
10
|
+
|
|
11
|
+
Define:
|
|
12
|
+
|
|
13
|
+
- the stable operation or request identity;
|
|
14
|
+
- which input fields are bound to that identity;
|
|
15
|
+
- the exact legal source states;
|
|
16
|
+
- the expected revision or version;
|
|
17
|
+
- retry and replay behavior;
|
|
18
|
+
- what a duplicate with identical input returns;
|
|
19
|
+
- what a duplicate identity with changed input returns;
|
|
20
|
+
- which actor owns each transition.
|
|
21
|
+
|
|
22
|
+
## Idempotency
|
|
23
|
+
|
|
24
|
+
A safe idempotent operation distinguishes exact replay from conflicting reuse. Persist or derive a digest from the complete bound input. Return the stored result for an exact replay; reject changed input under the same key.
|
|
25
|
+
|
|
26
|
+
Do not generate a new identity for a transport retry. Do generate a new identity for a new logical operation, even when the visible task text happens to match.
|
|
27
|
+
|
|
28
|
+
## Concurrency
|
|
29
|
+
|
|
30
|
+
- Check revision and allowed source state in the same atomic mutation.
|
|
31
|
+
- Make ambiguous candidates fail closed or remain unbound; never guess.
|
|
32
|
+
- Treat zero or multiple affected rows as evidence that the expected transition did not occur.
|
|
33
|
+
- Prevent stale completion, retry, or callback results from overwriting newer state.
|
|
34
|
+
- Keep terminal states terminal unless the protocol explicitly defines a new revision or recovery transition.
|
|
35
|
+
|
|
36
|
+
## Compatibility
|
|
37
|
+
|
|
38
|
+
For versioned APIs or stored structures, accept an older representation only when the compatibility policy is explicit and tested. Do not create silent fallback paths that bypass a new safety invariant. Prefer a clean break when old data cannot satisfy the current contract safely.
|
|
39
|
+
|
|
40
|
+
## Focused verification
|
|
41
|
+
|
|
42
|
+
Test first execution, exact replay, conflicting reuse, stale revision, wrong source state, concurrent claim, terminal-state behavior, and response compatibility. A text-match test is insufficient when the protocol exposes structured codes or exact identities.
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
<!-- KIOKUKO MANAGED STANDARD SKILL: kiokuko-single-purpose-functions -->
|
|
2
|
+
|
|
3
|
+
# `code.verification.v1` — focused evidence and review
|
|
4
|
+
|
|
5
|
+
Select this expert for regression repair, behavior review, compatibility changes, or any function whose correctness claim depends on evidence beyond ordinary local reasoning.
|
|
6
|
+
|
|
7
|
+
## Evidence contract
|
|
8
|
+
|
|
9
|
+
Verification must exercise the same boundary and pipeline as the reported or intended behavior. A build does not replace a typecheck. A unit test of a helper does not replace the HTTP, CLI, hook, database, browser, or packaging path that failed.
|
|
10
|
+
|
|
11
|
+
Before editing, state a falsifiable invariant and at least one counterexample. After editing, run the smallest focused verifier that proves the change, then the broader verifier proportional to regression risk.
|
|
12
|
+
|
|
13
|
+
## Test shape
|
|
14
|
+
|
|
15
|
+
For each changed contract cover:
|
|
16
|
+
|
|
17
|
+
- representative success;
|
|
18
|
+
- important expected failure;
|
|
19
|
+
- the reported regression or a concrete counterexample;
|
|
20
|
+
- absence of forbidden effects after rejection;
|
|
21
|
+
- ownership or immutability when mutable input is possible;
|
|
22
|
+
- concurrency, retry, cancellation, or cleanup when the selected experts require them.
|
|
23
|
+
|
|
24
|
+
Prefer observable behavior over private implementation details. Use deterministic inputs and narrow fakes. Keep test names specific enough to identify the contract and failure class.
|
|
25
|
+
|
|
26
|
+
## Review method
|
|
27
|
+
|
|
28
|
+
Trace caller to boundary to domain decision to effects to public result. Check generated instructions, stored representations, migrations, packaging manifests, and runtime adapters when they are part of delivery; source code alone may not be the shipped behavior.
|
|
29
|
+
|
|
30
|
+
Classify uncertainty honestly:
|
|
31
|
+
|
|
32
|
+
- verified by a matching runnable test;
|
|
33
|
+
- inspected from source only;
|
|
34
|
+
- blocked by environment or unavailable dependency;
|
|
35
|
+
- not checked.
|
|
36
|
+
|
|
37
|
+
Do not convert a sandbox, listener, DNS, registry, or permission restriction into a product defect without a matching permitted rerun. Do not repeatedly run an unchanged blocked verifier.
|
|
38
|
+
|
|
39
|
+
## Completion
|
|
40
|
+
|
|
41
|
+
Report exact verifier commands or test names, their result, changed contract scope, and remaining gaps. If only a subset ran, do not claim the full suite passed.
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: kiokuko-soul
|
|
3
|
+
description: Use before every non-trivial Kiokuko-governed task as the mandatory first-read SOUL router. Route applicable Enno-Oduno control, code work, and interactive UI work to the bundled specialist Skills without replacing their contracts.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
<!-- KIOKUKO MANAGED STANDARD SKILL: kiokuko-soul -->
|
|
7
|
+
|
|
8
|
+
# Kiokuko SOUL router
|
|
9
|
+
|
|
10
|
+
## Outcome
|
|
11
|
+
|
|
12
|
+
Start every non-trivial Kiokuko-governed task from one stable routing decision, then read the applicable compact specialist indexes and only the expert fragments required by the current role and work.
|
|
13
|
+
|
|
14
|
+
This Skill routes work. It does not duplicate specialist instructions, invent an Enno-Oduno run, select another model, or authorize effects beyond the user request and current client permissions.
|
|
15
|
+
|
|
16
|
+
## Required entry
|
|
17
|
+
|
|
18
|
+
Read this Skill before any other bundled Kiokuko Skill.
|
|
19
|
+
|
|
20
|
+
For every `task_prepare` call, set `soulRead: true` only after reading this
|
|
21
|
+
complete local `SKILL.md` for the current logical request. `task_prepare` also
|
|
22
|
+
requires the exact local `kiokuko-soul` capability for every task. Omission,
|
|
23
|
+
false attestation, missing availability, unknown availability, aliases,
|
|
24
|
+
namespaced copies, and fetched references fail closed. The attestation is an
|
|
25
|
+
explicit client claim; it is not remote proof of model cognition.
|
|
26
|
+
|
|
27
|
+
Then inspect the current user request, repository evidence, `task_prepare` or `task_answer` result when present, and any revision-bound Enno-Oduno directive. Treat a returned `nextAction`, role, required-Skill list, and stop condition as authoritative for that run.
|
|
28
|
+
|
|
29
|
+
Read the complete `SKILL.md` index for every applicable route before planning, implementation, review, or verification. Each specialist index defines versioned expert fragments. Read only fragments selected by the approved WorkUnit or concrete task risk; do not load every reference by default. Do not substitute this router's summary for a specialist core contract.
|
|
30
|
+
|
|
31
|
+
## Routes
|
|
32
|
+
|
|
33
|
+
### Enno-Oduno control
|
|
34
|
+
|
|
35
|
+
Read and apply `kiokuko-enno-oduno` only when its activation boundary is satisfied:
|
|
36
|
+
|
|
37
|
+
- `task_prepare` or `task_answer` returned `ennoOduno.applicable=true` for the current `enno-oduno` role;
|
|
38
|
+
- a continuation directive resumes that role for an existing run; or
|
|
39
|
+
- the user explicitly asks to inspect or operate an Enno-Oduno run.
|
|
40
|
+
|
|
41
|
+
Do not invent a run, role, revision, WorkUnit, or state transition merely because Kiokuko is present.
|
|
42
|
+
|
|
43
|
+
### Code work
|
|
44
|
+
|
|
45
|
+
Read and apply the `kiokuko-single-purpose-functions` index before writing, modifying, debugging, refactoring, or reviewing code, and before decomposing a code-changing WorkPlan. Select one to three `code.*` expert fragments for each cohesive function or WorkUnit.
|
|
46
|
+
|
|
47
|
+
### Interactive UI work
|
|
48
|
+
|
|
49
|
+
Read and apply the `kiokuko-ui-design-soul` index before designing, implementing, modifying, debugging, or reviewing an interactive interface. Select one to three `ui.*` expert fragments for the actual interaction risks. If UI work changes code, apply both the code and UI indexes.
|
|
50
|
+
|
|
51
|
+
### Combined work
|
|
52
|
+
|
|
53
|
+
Routes compose. Read every applicable specialist index; never choose only one when the task spans multiple contracts. Fragment selection remains narrow inside those routes.
|
|
54
|
+
|
|
55
|
+
Use this order:
|
|
56
|
+
|
|
57
|
+
1. `kiokuko-soul`;
|
|
58
|
+
2. `kiokuko-enno-oduno` when the current role requires Enno-Oduno control;
|
|
59
|
+
3. `kiokuko-single-purpose-functions` for code planning or code work;
|
|
60
|
+
4. `kiokuko-ui-design-soul` for interactive UI work.
|
|
61
|
+
|
|
62
|
+
The current revision-bound directive may narrow which routes the active role performs. Do not let a later route cross a role boundary or expand an approved WorkUnit.
|
|
63
|
+
|
|
64
|
+
## Availability and trust
|
|
65
|
+
|
|
66
|
+
When a current directive or capability recommendation marks a routed Skill as required, stop on `required_capability_unavailable`, a blocked Enno-Oduno state, or equivalent unavailable-required-Skill result.
|
|
67
|
+
|
|
68
|
+
Do not satisfy a required bundled Skill with a similarly named, namespaced, fetched, or reference-only Skill. Never install or execute external Skill content automatically.
|
|
69
|
+
|
|
70
|
+
Skill availability alone is not evidence that its contract was applied. The
|
|
71
|
+
mandatory `soulRead: true` attestation makes that claim explicit but does not
|
|
72
|
+
turn it into cryptographic or remote proof.
|