Repository navigation
Commit aa5523a
kb init: judge coverage by the most specific owner; never absorb a module with an ancestor prefix
The afd-plugin pilot (dry run) made the coverage metric meaningless. The
skeleton wrote an aggregate owner "components" listing its components'
prefixes; the modules stage absorbed the package root by appending
afd_plugin/ to it, a catch-all that matches every file; deepen gave the
hottest module to that owner (it reached as many files as the component
owner and came first in routing order) and wrote 12 rules to
components/rules.md; and pr_weighted_coverage counted a file rule-bearing
when ANY matching owner had rules, so coverage jumped 10% -> 100% and
deepen stopped with 8 hot modules untouched.
- init_coverage.most_specific: the owners with the longest matching
prefix, then the deepest page (a component's own page beats an
aggregate entry page listing the same area); rule-bearing now uses
only those. shadowing() lists directory prefixes that are strict
ancestors of another owner's prefix.
- init_modules: absorption picks the owner that owns most of the
module's files most specifically, and cover_prefixes adds only
prefixes for the module's own unrouted files: the module directory
when no other module or OTHER owner's prefix lies under it, else the
highest such directory per file, else the file. A module needing more
than 20 prefixes gets a map card instead; card owners use the same
cover.
- init_deepen: a module's owner is its most specific owner; "already
bears rules" and the uncovered-hot list use the same rule.
- skeleton: a checklist note names every owner prefix that shadows
other owners' prefixes, so the owner can narrow it.
Replayed offline on the pilot's pin: the root absorbs 4 files instead of
afd_plugin/, the hottest module goes to execution-platforms, and rules
on the aggregate page now count for 4.5%, not 100%.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>1 parent 81b8a48 commit aa5523a
6 files changed
Lines changed: 321 additions & 34 deletions
File tree
- doc/architecture/SPEC
- src/infermatrix_copilot/kb_service
- test
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
329 | 329 | | |
330 | 330 | | |
331 | 331 | | |
332 | | - | |
333 | | - | |
| 332 | + | |
| 333 | + | |
334 | 334 | | |
335 | 335 | | |
| 336 | + | |
| 337 | + | |
| 338 | + | |
| 339 | + | |
| 340 | + | |
336 | 341 | | |
337 | 342 | | |
338 | 343 | | |
| |||
377 | 382 | | |
378 | 383 | | |
379 | 384 | | |
380 | | - | |
| 385 | + | |
| 386 | + | |
381 | 387 | | |
382 | 388 | | |
383 | 389 | | |
| |||
400 | 406 | | |
401 | 407 | | |
402 | 408 | | |
403 | | - | |
404 | | - | |
| 409 | + | |
| 410 | + | |
| 411 | + | |
| 412 | + | |
| 413 | + | |
| 414 | + | |
405 | 415 | | |
406 | 416 | | |
407 | 417 | | |
| |||
420 | 430 | | |
421 | 431 | | |
422 | 432 | | |
423 | | - | |
| 433 | + | |
| 434 | + | |
424 | 435 | | |
425 | 436 | | |
426 | 437 | | |
427 | 438 | | |
428 | 439 | | |
429 | 440 | | |
430 | | - | |
| 441 | + | |
431 | 442 | | |
432 | 443 | | |
433 | 444 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
11 | | - | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
12 | 19 | | |
13 | 20 | | |
14 | 21 | | |
| |||
80 | 87 | | |
81 | 88 | | |
82 | 89 | | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
83 | 133 | | |
84 | 134 | | |
85 | 135 | | |
| |||
121 | 171 | | |
122 | 172 | | |
123 | 173 | | |
124 | | - | |
125 | | - | |
126 | | - | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
127 | 180 | | |
128 | 181 | | |
129 | 182 | | |
| |||
135 | 188 | | |
136 | 189 | | |
137 | 190 | | |
138 | | - | |
| 191 | + | |
139 | 192 | | |
140 | 193 | | |
141 | 194 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
7 | | - | |
8 | | - | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
9 | 11 | | |
10 | 12 | | |
11 | 13 | | |
| |||
32 | 34 | | |
33 | 35 | | |
34 | 36 | | |
35 | | - | |
| 37 | + | |
36 | 38 | | |
37 | 39 | | |
38 | 40 | | |
| |||
174 | 176 | | |
175 | 177 | | |
176 | 178 | | |
177 | | - | |
178 | | - | |
| 179 | + | |
| 180 | + | |
179 | 181 | | |
180 | 182 | | |
181 | 183 | | |
182 | 184 | | |
183 | | - | |
| 185 | + | |
184 | 186 | | |
185 | 187 | | |
186 | 188 | | |
187 | 189 | | |
188 | 190 | | |
189 | | - | |
190 | | - | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
191 | 198 | | |
192 | 199 | | |
193 | 200 | | |
| |||
0 commit comments