feat(ms-ai-architect): Spor D steg A — eng+infra K10-fix → korpus-invariant ≥90 oppfylt
Skjerper ms-ai-infrastructure-description for å bryte build↔operate-overlappet mot ms-ai-engineering (operatør-godkjent leaning, S38): "multi-region"→"cross-region" og "edge AI architecture"→"edge AI deployment". Fjerner de delte distinktive tokenene `multi` (vekt 0.5) og `architecture` (0.333) → eng↔infra combined 7.4167→6.5833 (< 7.0 terskel). Korpus-maks faller til 6.8333 (eng↔gov, pass). Begge edits sammen gir lavere worst-case enn edit #1 alene (6.9167), derfor robust margin. Resultat: K10-gulvet løftes for begge → eng 89→96, infra 89→96. ALLE 5 skills nå ≥90 (advisor 91, eng/gov/infra/sec 96). Korpus-invarianten (operatør-krav S38) oppfylt. Judge-cache (🔑-regel): description-edit invaliderer infra K1. Re-judget mot det operatør-kuraterte 20-settet — UENDRET 1.0/0.0/1.0 (edit fjerner kun tokens → kan ikke gi falske positive; in-domain #2/#6 trigger fortsatt på BCDR/hybrid-vokabular). K4/K7/K8/K9 uendret (body/refs urørt). Provenance oppdatert S11→S39. Test: K10-real-five-testen pinnet pre-fix-baseline (eng+infra FAIL) — oppdatert til å pinne korpus-invarianten (alle 5 pass, eng↔infra < 7.0). kb-eval 142/142, kb-update 316/316, validate 239/0, kb-integrity 192/0. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
c1a09062d4
commit
a6ff17fd45
3 changed files with 20 additions and 11 deletions
|
|
@ -79,9 +79,16 @@ test('perSkillSiblingOverlap — empty pairs yields empty verdict map', () => {
|
|||
// Real-data path — eng + infra FAIL at 7.0; the other three PASS
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
test('K10 on the real five — eng+infra FAIL (Azure-deployment boundary), rest PASS', () => {
|
||||
test('K10 on the real five — ALL pass (eng↔infra boundary sharpened S39, corpus invariant)', () => {
|
||||
// Build descriptions straight from the curated belongs_to graph + lexical
|
||||
// surfaces via the same core the detector uses, so this asserts on live tokens.
|
||||
//
|
||||
// S39 (steg A): the eng↔infra pair used to fail K10 at combined=7.4167 (the
|
||||
// Azure-deployment build↔operate boundary). The infra description was sharpened
|
||||
// — "multi-region"→"cross-region", "edge AI architecture"→"edge AI deployment" —
|
||||
// removing the shared distinctive tokens `multi` (0.5) and `architecture` (0.333),
|
||||
// dropping the pair under threshold. This test now pins the corpus invariant:
|
||||
// every skill passes K10 (a precondition for the ≥90 % score on all five).
|
||||
const skills = ['ms-ai-advisor', 'ms-ai-engineering', 'ms-ai-governance', 'ms-ai-infrastructure', 'ms-ai-security'];
|
||||
const descriptionsBySkill = {};
|
||||
for (const s of skills) {
|
||||
|
|
@ -90,13 +97,15 @@ test('K10 on the real five — eng+infra FAIL (Azure-deployment boundary), rest
|
|||
}
|
||||
const overlap = computeOverlapFromInputs(descriptionsBySkill, promptSet);
|
||||
const k10 = perSkillSiblingOverlap(overlap.pairs, { threshold: 7.0 });
|
||||
assert.equal(k10['ms-ai-engineering'].pass, false);
|
||||
assert.equal(k10['ms-ai-infrastructure'].pass, false);
|
||||
assert.equal(k10['ms-ai-engineering'].worstSibling, 'ms-ai-infrastructure');
|
||||
assert.equal(k10['ms-ai-infrastructure'].worstSibling, 'ms-ai-engineering');
|
||||
assert.equal(k10['ms-ai-advisor'].pass, true);
|
||||
assert.equal(k10['ms-ai-governance'].pass, true);
|
||||
assert.equal(k10['ms-ai-security'].pass, true);
|
||||
for (const s of skills) {
|
||||
assert.equal(k10[s].pass, true, `${s} must pass K10 (maxCombined ${k10[s].maxCombined} < 7.0)`);
|
||||
assert.ok(k10[s].maxCombined < 7.0, `${s} maxCombined ${k10[s].maxCombined} must be < 7.0`);
|
||||
}
|
||||
// The formerly-failing pair is now safely under threshold (was 7.4167).
|
||||
const engInfra = overlap.pairs.find(
|
||||
(p) => p.key === 'ms-ai-engineering|ms-ai-infrastructure',
|
||||
);
|
||||
assert.ok(engInfra.combined < 7.0, `eng↔infra combined ${engInfra.combined} must be < 7.0`);
|
||||
});
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue