Forge
markdowndeeb25a2
1# Naming: layered «L» prefixes — semantic registry v1
2
3**Статус:** Accepted (normative for new prose, code, UI)
4**Дата:** 2026-05-31
5**SSOT для verify rungs:** [ADR 0148 §3](../adr/0148-agent-execution-environment-verification-ladder-and-native-tooling.md)
6**UX verify epoch:** [agent-verify-epoch-view-v1.md](agent-verify-epoch-view-v1.md)
7
8## Зачем
9
10В стеке CascadeIDE + CASA + KB одновременно живут **несколько независимых «L0…L4»**. Голые цифры **не переносятся между доменами**. В новых ADR, UI, DataBus и промптах — **semantic id** из таблиц ниже; legacy `L*` — только alias (миграция, grep старого кода).
11
12**Правило prose:** всегда квалифицировать домен — «verify rung `build.affected`», «safety `confirm`», «SA `comprehension`» — никогда голое «L2». **Код CIDE (2026-05-31):** legacy `L*` для verify/safety удалены — только semantic ids.
13
14---
15
16## 1. Verify rungs (AEE · ADR 0148)
17
18**Namespace:** `verify_rung` · enum / JSON string · UI labels RU в [agent-verify-epoch-view-v1.md](agent-verify-epoch-view-v1.md).
19
20| Semantic id (канон) | Legacy | Было `task_kind` id | RU (кратко) |
21|---------------------|--------|---------------------|-------------|
22| `diagnose.files` | L0 | `roslyn_file` | Диагностика файлов |
23| `compile.project` | L1 | `roslyn_project` | Компиляция проекта |
24| `build.affected` | L2 | `build_project` | Сборка затронутых |
25| `test.scoped` | L3 | `test_filtered` | Тесты (фильтр) |
26| `test.full` | L4 | `test_full` | Полный прогон |
27
28**Policy presets** (без L): `minimal` | `standard` | `strict` | `ci_parity` — cap по semantic id (см. ADR 0148 §3).
29
30**Implementation tasks** (не путать с rung): `roslyn.diagnose`, `msbuild.compile`, `dotnet.test` — backend runner; один rung может менять backend без смены id.
31
32---
33
34## 2. Agent safety (ADR 0038 · cockpit ADR 0021 §12)
35
36**Namespace:** `safety_level` · UI badge · autonomous JSON `safety_level`.
37
38| Semantic id | Legacy | Смысл |
39|-------------|--------|-------|
40| `safety.observe` | L1 | Read-only / advise; без высокорисковых IDE-команд и git push |
41| `safety.confirm` | L2 | Agent proposes; human confirms risky ops |
42| `safety.autonomous` | L3 | Full tool surface; external MCP allowed |
43
44HARM роли (0021 §12): распределение PF/PM по `safety_level`.
45
46| safety_level | Legacy | Human (PF/PM) | Agent (PF/PM) | Авиационный аналог |
47|--------------|--------|---------------|---------------|-------------------|
48| `safety.observe` | L1 Read-only | **PF** — полный контроль | **PM** — наблюдает, подсказывает | Manual flight, copilot monitoring |
49| `safety.confirm` | L2 Confirm edits | **PM** — мониторит, подтверждает | **PF** — предлагает, ждёт OK | Autopilot engaged, pilot confirms mode changes |
50| `safety.autonomous` | L3 Autonomous | **PM** — мониторит, **intervene** при проблеме | **PF** — действует самостоятельно | Full autopilot, pilot ready to intervene |
51
52PFD one-liners: observe → `Human: editing · Agent: advising`; confirm → `Agent: proposing · Human: confirming`; autonomous → `Agent: acting · Human: monitoring`.
53
54---
55
56## 3. Situation awareness — Endsley (ADR 0021 §11)
57
58**Namespace:** `sa_level` · PFD badge design · **не** safety и **не** verify.
59
60| Semantic id | Legacy | Авиация | IDE (пример) |
61|-------------|--------|---------|--------------|
62| `sa.perception` | SA L1 | Instrument readings | Build FAIL, test count, agent state |
63| `sa.comprehension` | SA L2 | Situation meaning | «2 errors in PaymentService.cs» |
64| `sa.projection` | SA L3 | Future state | «If merge → CI breaks» |
65
66**Дизайн-критерий:** PFD badge даёт минимум `sa.comprehension`, не голый `sa.perception`.
67
68---
69
70## 4. Reasoning visibility (ADR 0020)
71
72**Namespace:** `trace_layer` · chat / autonomous export.
73
74| Semantic id | Legacy | Смысл |
75|-------------|--------|-------|
76| `trace.answer` | L0 | Ответ пользователю + трассируемые действия среды (MCP, git, …) |
77| `trace.reasoning` | L1 | Streaming thinking / structured steps — **если API отдаёт** |
78| `trace.provider_raw` | L2 | Сырой request/response log (secrets redacted), TTL policy |
79
80---
81
82## 5. Intercom anchor notation (ADR 0128 · intercom UX ref)
83
84**Namespace:** `anchor.notation` · **не** Endsley SA.
85
86| Semantic id | Legacy | Пример |
87|-------------|--------|--------|
88| `anchor.notation.readable` | L1 (intercom doc) | `[Foo.cs M:GetUserAsync]` |
89| `anchor.notation.canonical` | L2 field record | `[F:Foo.cs; M:GetUserAsync; L:50-100]` |
90
91Human tiers **H0–H2**, positional **M0** — без переименования (не конфликтуют с verify/safety).
92
93---
94
95## 6. CASA / KB memory lattices (CASA-ADR-0002 · вне CIDE repo)
96
97**Namespace:** dotted semantic id · physical lattice ids **unchanged** (`L2_word_07`, `F0_schema`, …).
98**SSOT:** `casa-ontology-payload/design/naming-memory-layers-v0.md` · stacks `design/prisms/*/stack.v0.json`.
99
100| Semantic id | Legacy axes | Physical examples |
101|-------------|-------------|-------------------|
102| `memory.grapheme` | L0, **B0**, T0 | `L0_grapheme_*` |
103| `memory.syllable` | L1, **B1**, T1 | `L1_syllable` |
104| `memory.lexicon` | L2, **B2**, T2 | `L2_word_*`, `words-ru-*` |
105| `memory.phrase` | L3, **B3**, T3 | `L3_phrase` |
106| `memory.math.schema` | **F0** | `F0_schema` |
107| `memory.math.compose` | **F1** | `F1_compose` |
108| `memory.math.quantity` | **F2** | `F2_quantity` |
109| `episodic.io` | **H0** (buffer) | `H0_io` |
110| `episodic.surface` | **H1**, legacy `H0_episode` | `H1_surface` |
111| `episodic.rule` | **H2** | `H2_rule` |
112| `episodic.scene` | **H3** | `H3_scene` |
113| `sensory.audio.*` | **A*** | `A1_phon`, … |
114| `sensory.vis.*` | **V*** | `V1_object`, … |
115| `sensory.spatial.*` | **S*** | `S0_disparity`, … |
116| `control.*` | `lattice_*` | `lattice_dmn`, `lattice_predict`, … |
117
118**B0…B3** = bukvar curriculum steps → same semantic layers as `memory.*` (not separate lattices).
119**Prose:** qualify domain — never bare «F2» / «B0» / «H1» without semantic id.
120
121---
122
123## 7. External tool tiers (ADR 0148 · 0038)
124
125| Semantic id | Legacy | Смысл |
126|-------------|--------|-------|
127| `tool.native` | — | `IAeeTool` in-proc / supervised host |
128| `tool.external_mcp` | L3 external (0148 prose) | Polyglot MCP — при `safety.autonomous` |
129| `tool.shell_escape` | E-tier | Deny by default; audit |
130
131**`shell_escape_tier` (TOML):** `deny` | `tests_only` (legacy `l3_only`) | `allow_with_audit`.
132
133**IDE commands (MCP):** `safety.observe` | `safety.confirm` | `safety.autonomous` (legacy `set_safety_l1`…`l3`).
134
135---
136
137## 8. Миграция
138
139| Surface | Канон |
140|---------|-------|
141| C# constants | `VerifyRung.*`, `AgentSafetyLevel.*` |
142| TOML ladder | `diagnose_files_enabled`, `test_full_require_explicit`, … |
143| DataBus | `max_rung_reached: "build.affected"` |
144| Chat trace | `✓ diagnose.files 0.8s` |
145| Safety UI / autonomous | `safety.observe` … `safety.autonomous` |
146| IDE MCP safety set | `safety.observe` … `safety.autonomous` (same ids as `AgentSafetyLevel`) |
147| Shell escape tier | `deny` / `tests_only` / `allow_with_audit` |
148
149---
150
151## 9. Быстрая disambiguation
152
153| Ты видишь «L2» в… | Это скорее… |
154|-------------------|-------------|
155| `/agent verify`, AEE, build/test | **verify** `build.affected` |
156| Safety badge, autonomous mode | **safety** `confirm` |
157| PFD badge «2 errors in…» | **SA** `comprehension` |
158| Chat «thinking stream» | **trace** `reasoning` |
159| Intercom `[F:…; M:…]` | **anchor** `canonical` |
160| CASA `L2_word_07` | **memory** `lexicon` shard |
161| CASA `F0_schema` | **memory.math** `schema` |
162| CASA bukvar **B0** | **memory** `grapheme` (curriculum step) |
163| CASA `H1_surface` | **episodic** `surface` |
164
165---
166
167## История
168
169| Дата | Изменение |
170|------|-----------|
171| 2026-05-31 | v1: registry; verify semantic ids; Endsley/safety/trace/anchor/CASA layers |
172| 2026-05-31 | §6: CASA F/B/H/A/V/S + memory.math + episodic semantic ids (cross-ref casa naming v1) |
173
View only · write via MCP/CIDE