Skip to content

feat(skill): disclose source/version provenance in the generated skill - #7

Merged
blendsdk merged 11 commits into
masterfrom
feat/skill-provenance
Sep 24, 2026
Merged

blendsdk merged 11 commits into
masterfrom
feat/skill-provenance

Conversation

@blendsdk

Copy link
Copy Markdown
Owner

Summary

Makes the generated fluentui Agent Skill self-describing: it now discloses the FluentUI source/version provenance of the snapshot and instructs the agent to say "not covered by this skill version" for APIs the snapshot does not contain, instead of guessing.

Closes microsoft/fluentui#36792 (Request 1: skill provenance disclosure).

What changed

Area Change
Scraper sources.fluentui records the umbrella @fluentui/react-components name + version at scrape time (SourceInfo.packageName/packageVersion, VersionPaths.umbrellaPackageDir)
Generator Renders a ## Source & versions section into references/index.md from the schema + package.json; new SkillRenderContext; GENERATOR_VERSION → 1.1.0
Skill guidance .agents/skills/fluentui/SKILL.md hard rule 8 (cite covered version, list used references, refuse uncovered APIs) and corrected React peer range >=16.14.0 <20.0.0
Corpus Same-commit v9 refresh; @fluentui/react-components 9.74.1; committed tree regenerated
Release scripts/release.mjs regenerates and stages the skill after a version bump

The section is timestamp-free, so the drift gate stays a byte comparison. Example output:

| Item | Value |
| --- | --- |
| Fluent UI version | v9 |
| Fluent UI source | `master` @ `fdf755c` |
| Umbrella package | `@fluentui/react-components` 9.74.1 |
| Component packages | 51 packages, 9.2.17–9.25.0 |
| Skill version | 1.3.1 |
| Generator | 1.1.0 |
| Schema hash | `daa4e080d4f0` |

Verification

npm run verify — PASS: 762 Vitest tests + 18 release tests, plus typecheck, version parity, and the drift/validate/freshness/secrets skill gates.

Review

Independent per-phase quality review under strict CodeOps defaults; one 🟠 major (package count mislabelled; now deduped by package) and six 🟡 minors found and resolved. Re-review of the fix diff passed with one cosmetic follow-up, also fixed. Full audit trail in plans/skill-provenance/08-quality-review.md.

Notes

  • Plan and execution artifacts live in plans/skill-provenance/; RD-03 and RD-01 are amended.
  • Runtime decisions recorded in the ambiguity register (AR-12..AR-14): regeneration timing, enhancer run mode, and drift-check testability.
  • No stable-tag corpus re-scrape (deferred) and no runtime provenance injection (by design).

- add plans/skill-provenance/ plan set with requirements, component specs,
  testing strategy, execution plan, and the ambiguity register
- record a preflight pass with notes: 3 major and 5 minor findings resolved
- track the standalone feature as SP-01 in the roadmap

Verification: npm run verify (build, tests, skill gates) passed.
- add optional packageName/packageVersion to SourceInfo
- add umbrellaPackageDir to VersionPaths and set it for v9
- export readPackageJson and add readUmbrellaPackage
- record the umbrella package on sources.fluentui during a scrape
- add spec and impl tests plus the umbrella fixture package.json

Verification: npm run verify (737 tests, skill gates) passed.

Ref: plans/skill-provenance/99-execution-plan.md
Task: 1.1.1-1.1.8
- add SkillRenderContext and render the section into references/index.md
- add formatPackageVersionRange with numeric, count-aware ordering
- read the skill version from package.json via a packageJsonPath option
- bump GENERATOR_VERSION to 1.1.0 and regenerate the committed tree
- add spec and impl tests; update buildSkillFiles call sites

The committed tree is regenerated here (rather than only in the later
corpus-refresh step) because the drift gate compares it byte for byte and
must stay green.

Verification: npm run verify (751 tests, skill gates) passed.

Ref: plans/skill-provenance/99-execution-plan.md
Task: 2.1.1-2.2.6
- add hard rule 8: cite the covered version, list used references, and
  say "not covered by this skill version" for absent APIs
- correct compatibility to the real React peer range >=16.14.0 <20.0.0
- add specification tests for the rule and the compatibility value

Verification: npm run verify (756 tests, skill gates) passed.

Ref: plans/skill-provenance/99-execution-plan.md
Task: 3.1.1-3.2.3
…te the skill

- re-scrape the same commit; sources.fluentui now records
  @fluentui/react-components 9.74.1
- carry components and guides forward with no LLM calls (0 enhanced)
- regenerate the committed skill; index.md shows the umbrella row
- record runtime note: enhancer ran with --components-only

Verification: npm run verify (756 tests, skill gates) passed.

Ref: plans/skill-provenance/99-execution-plan.md
Task: 4.1.1-4.1.4
- add regenerateSkill and call it after the version bump (skipped on
  --dry-run and --no-git-commit)
- export releaseStagePaths and stage .agents/skills/fluentui
- add an integration spec for the bump to regenerate to drift path
- forward an optional packageJsonPath through checkDrift
- amend RD-03 for the provenance section and RD-01 for the umbrella fields

Verification: npm run verify (757 vitest + 18 release tests, skill gates) passed.

Ref: plans/skill-provenance/99-execution-plan.md
Task: 5.1.1-5.2.4
- set the SP-01 roadmap row to Done and update the header counts
- drop plan-case ids from the provenance spec test comments

Verification: npm run verify (757 vitest + 18 release tests, skill gates) passed.
- dedupe formatPackageVersionRange by packageName (198 entries, 51 packages)
  and regenerate the committed tree
- always regenerate the skill in the release flow, including --no-git-commit
- resolve and forward packageJsonPath from the drift CLI against its cwd
- document the regeneration step in release docs and the workflow header
- add readSkillVersion failure-path tests and tighten the rule-8 spec assertion
- record the phase quality review and findings in 08-quality-review.md

Verification: npm run verify (762 vitest + 18 release tests, skill gates) passed.
- include the regeneration step in the release.mjs --dry-run message
- record the re-review verdict in the quality report

Verification: npm run verify (762 vitest + 18 release tests, skill gates) passed.
- merge the v1.3.2 release so the tree matches the base version
- regenerate so references/index.md records skill version 1.3.2

Verification: npm run verify (762 vitest + 18 release tests, skill gates) passed.
@blendsdk
blendsdk merged commit 43ba4ac into master Sep 24, 2026
1 check passed
@blendsdk
blendsdk deleted the feat/skill-provenance branch September 24, 2026 21:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants