skill-lens-cli 0.1.0__tar.gz
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.
- skill_lens_cli-0.1.0/.github/workflows/ci.yml +70 -0
- skill_lens_cli-0.1.0/.gitignore +14 -0
- skill_lens_cli-0.1.0/AGENTS.md +132 -0
- skill_lens_cli-0.1.0/CHANGELOG.md +142 -0
- skill_lens_cli-0.1.0/LICENSE +21 -0
- skill_lens_cli-0.1.0/PHASE2_FINDINGS.md +545 -0
- skill_lens_cli-0.1.0/PHASE3_FINDINGS.md +325 -0
- skill_lens_cli-0.1.0/PHASE4_FINDINGS.md +204 -0
- skill_lens_cli-0.1.0/PHASE5_WALKTHROUGH.md +297 -0
- skill_lens_cli-0.1.0/PHASE6_PLAN.md +157 -0
- skill_lens_cli-0.1.0/PHASE6_WALKTHROUGH.md +303 -0
- skill_lens_cli-0.1.0/PKG-INFO +296 -0
- skill_lens_cli-0.1.0/README.md +260 -0
- skill_lens_cli-0.1.0/SKILL_LENS_SPECIFICATION.md +373 -0
- skill_lens_cli-0.1.0/pyproject.toml +87 -0
- skill_lens_cli-0.1.0/skill_lens/__init__.py +3 -0
- skill_lens_cli-0.1.0/skill_lens/cli.py +326 -0
- skill_lens_cli-0.1.0/skill_lens/core/__init__.py +1 -0
- skill_lens_cli-0.1.0/skill_lens/core/compare.py +172 -0
- skill_lens_cli-0.1.0/skill_lens/core/diff.py +503 -0
- skill_lens_cli-0.1.0/skill_lens/core/discovery.py +562 -0
- skill_lens_cli-0.1.0/skill_lens/core/doctor.py +464 -0
- skill_lens_cli-0.1.0/skill_lens/core/exitcodes.py +151 -0
- skill_lens_cli-0.1.0/skill_lens/core/hasher.py +117 -0
- skill_lens_cli-0.1.0/skill_lens/core/parser.py +311 -0
- skill_lens_cli-0.1.0/skill_lens/core/paths.py +130 -0
- skill_lens_cli-0.1.0/skill_lens/core/resolver.py +607 -0
- skill_lens_cli-0.1.0/skill_lens/core/scanner.py +230 -0
- skill_lens_cli-0.1.0/skill_lens/core/system.py +96 -0
- skill_lens_cli-0.1.0/skill_lens/models/__init__.py +73 -0
- skill_lens_cli-0.1.0/skill_lens/models/compare.py +104 -0
- skill_lens_cli-0.1.0/skill_lens/models/diff.py +231 -0
- skill_lens_cli-0.1.0/skill_lens/models/doctor.py +98 -0
- skill_lens_cli-0.1.0/skill_lens/models/enums.py +84 -0
- skill_lens_cli-0.1.0/skill_lens/models/installation.py +74 -0
- skill_lens_cli-0.1.0/skill_lens/models/parsing.py +105 -0
- skill_lens_cli-0.1.0/skill_lens/models/resolution.py +108 -0
- skill_lens_cli-0.1.0/skill_lens/py.typed +0 -0
- skill_lens_cli-0.1.0/skill_lens/registry/__init__.py +14 -0
- skill_lens_cli-0.1.0/skill_lens/registry/agents/antigravity.toml +50 -0
- skill_lens_cli-0.1.0/skill_lens/registry/agents/claude.toml +34 -0
- skill_lens_cli-0.1.0/skill_lens/registry/agents/codex.toml +64 -0
- skill_lens_cli-0.1.0/skill_lens/registry/agents/dsh.toml +93 -0
- skill_lens_cli-0.1.0/skill_lens/registry/agents/grok.toml +37 -0
- skill_lens_cli-0.1.0/skill_lens/registry/agents/omp.toml +84 -0
- skill_lens_cli-0.1.0/skill_lens/registry/agents/opencode.toml +48 -0
- skill_lens_cli-0.1.0/skill_lens/registry/agents/pi.toml +48 -0
- skill_lens_cli-0.1.0/skill_lens/registry/agents/qoder.toml +38 -0
- skill_lens_cli-0.1.0/skill_lens/registry/agents/windsurf.toml +38 -0
- skill_lens_cli-0.1.0/skill_lens/registry/loader.py +128 -0
- skill_lens_cli-0.1.0/skill_lens/render.py +464 -0
- skill_lens_cli-0.1.0/tests/__init__.py +1 -0
- skill_lens_cli-0.1.0/tests/conftest.py +111 -0
- skill_lens_cli-0.1.0/tests/fixtures/__init__.py +1 -0
- skill_lens_cli-0.1.0/tests/fixtures/builders.py +80 -0
- skill_lens_cli-0.1.0/tests/fixtures/discovery.py +84 -0
- skill_lens_cli-0.1.0/tests/fixtures/farm.py +54 -0
- skill_lens_cli-0.1.0/tests/fixtures/golden/antigravity_file_based.json +50 -0
- skill_lens_cli-0.1.0/tests/fixtures/golden/claude_nested_qualification.json +61 -0
- skill_lens_cli-0.1.0/tests/fixtures/golden/claude_personal_beats_project.json +61 -0
- skill_lens_cli-0.1.0/tests/fixtures/golden/diff_variant_hash_detection.json +70 -0
- skill_lens_cli-0.1.0/tests/fixtures/golden/disabled_override.json +39 -0
- skill_lens_cli-0.1.0/tests/fixtures/golden/malformed_frontmatter.json +75 -0
- skill_lens_cli-0.1.0/tests/fixtures/golden/opencode_ambiguous.json +61 -0
- skill_lens_cli-0.1.0/tests/fixtures/golden/phase4/compare_claude_vs_codex.json +67 -0
- skill_lens_cli-0.1.0/tests/fixtures/golden/phase4/doctor_farm.json +24 -0
- skill_lens_cli-0.1.0/tests/fixtures/golden/project_beats_global.json +321 -0
- skill_lens_cli-0.1.0/tests/fixtures/golden/symlink_cycle_guard.json +56 -0
- skill_lens_cli-0.1.0/tests/fixtures/golden/symlink_farm_multi_agent.json +41 -0
- skill_lens_cli-0.1.0/tests/fixtures/golden/system_container_traversal.json +39 -0
- skill_lens_cli-0.1.0/tests/fixtures/golden/tcc_permission_error.json +53 -0
- skill_lens_cli-0.1.0/tests/fixtures/golden/variant_hash_detection.json +61 -0
- skill_lens_cli-0.1.0/tests/fixtures/golden/worktree_dotgit_file.json +39 -0
- skill_lens_cli-0.1.0/tests/fixtures/scenarios.py +256 -0
- skill_lens_cli-0.1.0/tests/fixtures/snapshots/compare_claude_vs_codex_farm.txt +16 -0
- skill_lens_cli-0.1.0/tests/fixtures/snapshots/compare_diverged.txt +12 -0
- skill_lens_cli-0.1.0/tests/fixtures/snapshots/compare_empty.txt +6 -0
- skill_lens_cli-0.1.0/tests/fixtures/snapshots/diff_invalid_copy.txt +22 -0
- skill_lens_cli-0.1.0/tests/fixtures/snapshots/diff_markup_is_literal.txt +23 -0
- skill_lens_cli-0.1.0/tests/fixtures/snapshots/diff_no_baseline.txt +13 -0
- skill_lens_cli-0.1.0/tests/fixtures/snapshots/diff_no_differences.txt +6 -0
- skill_lens_cli-0.1.0/tests/fixtures/snapshots/diff_not_found.txt +1 -0
- skill_lens_cli-0.1.0/tests/fixtures/snapshots/diff_truncated.txt +31 -0
- skill_lens_cli-0.1.0/tests/fixtures/snapshots/diff_truncated_by_chars.txt +30 -0
- skill_lens_cli-0.1.0/tests/fixtures/snapshots/diff_unreadable_copy.txt +10 -0
- skill_lens_cli-0.1.0/tests/fixtures/snapshots/diff_variant_hash_detection.txt +23 -0
- skill_lens_cli-0.1.0/tests/fixtures/snapshots/doctor_findings.txt +12 -0
- skill_lens_cli-0.1.0/tests/fixtures/snapshots/doctor_healthy.txt +8 -0
- skill_lens_cli-0.1.0/tests/fixtures/snapshots/doctor_markup_is_literal.txt +10 -0
- skill_lens_cli-0.1.0/tests/fixtures/snapshots/scan_variant_hash_detection.txt +11 -0
- skill_lens_cli-0.1.0/tests/fixtures/snapshots/why_claude_personal_beats_project.txt +19 -0
- skill_lens_cli-0.1.0/tests/test_cli.py +446 -0
- skill_lens_cli-0.1.0/tests/test_compare.py +254 -0
- skill_lens_cli-0.1.0/tests/test_discovery.py +148 -0
- skill_lens_cli-0.1.0/tests/test_doctor.py +293 -0
- skill_lens_cli-0.1.0/tests/test_fixtures.py +252 -0
- skill_lens_cli-0.1.0/tests/test_hasher.py +164 -0
- skill_lens_cli-0.1.0/tests/test_models.py +100 -0
- skill_lens_cli-0.1.0/tests/test_parser.py +227 -0
- skill_lens_cli-0.1.0/tests/test_paths.py +118 -0
- skill_lens_cli-0.1.0/tests/test_phase0_gate.py +136 -0
- skill_lens_cli-0.1.0/tests/test_phase1_gate.py +194 -0
- skill_lens_cli-0.1.0/tests/test_phase2_gate.py +546 -0
- skill_lens_cli-0.1.0/tests/test_phase3_gate.py +565 -0
- skill_lens_cli-0.1.0/tests/test_phase4_gate.py +195 -0
- skill_lens_cli-0.1.0/tests/test_phase5_gate.py +267 -0
- skill_lens_cli-0.1.0/tests/test_phase6_gate.py +358 -0
- skill_lens_cli-0.1.0/tests/test_registry.py +234 -0
- skill_lens_cli-0.1.0/tests/test_render_snapshots.py +376 -0
- skill_lens_cli-0.1.0/uv.lock +710 -0
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
name: CI
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: [main]
|
|
6
|
+
pull_request:
|
|
7
|
+
|
|
8
|
+
permissions:
|
|
9
|
+
contents: read
|
|
10
|
+
|
|
11
|
+
jobs:
|
|
12
|
+
test:
|
|
13
|
+
name: ${{ matrix.os }} / py${{ matrix.python-version }}
|
|
14
|
+
runs-on: ${{ matrix.os }}
|
|
15
|
+
strategy:
|
|
16
|
+
fail-fast: false
|
|
17
|
+
matrix:
|
|
18
|
+
os: [ubuntu-latest, macos-latest]
|
|
19
|
+
python-version: ["3.11", "3.12", "3.13", "3.14"]
|
|
20
|
+
steps:
|
|
21
|
+
- uses: actions/checkout@v5
|
|
22
|
+
|
|
23
|
+
- name: Install uv
|
|
24
|
+
uses: astral-sh/setup-uv@v10.2.0
|
|
25
|
+
with:
|
|
26
|
+
python-version: ${{ matrix.python-version }}
|
|
27
|
+
enable-cache: true
|
|
28
|
+
|
|
29
|
+
- name: Install the project (locked)
|
|
30
|
+
run: uv sync --locked --extra dev
|
|
31
|
+
|
|
32
|
+
- name: Lint
|
|
33
|
+
run: uv run ruff check .
|
|
34
|
+
|
|
35
|
+
- name: Format check
|
|
36
|
+
run: uv run ruff format --check .
|
|
37
|
+
|
|
38
|
+
- name: Type check
|
|
39
|
+
run: uv run mypy
|
|
40
|
+
|
|
41
|
+
- name: Tests
|
|
42
|
+
run: uv run pytest --cov=skill_lens --cov-report=term-missing
|
|
43
|
+
|
|
44
|
+
packaging:
|
|
45
|
+
name: packaging (build + install)
|
|
46
|
+
runs-on: ubuntu-latest
|
|
47
|
+
steps:
|
|
48
|
+
- uses: actions/checkout@v5
|
|
49
|
+
|
|
50
|
+
- name: Install uv
|
|
51
|
+
uses: astral-sh/setup-uv@v10.2.0
|
|
52
|
+
with:
|
|
53
|
+
python-version: "3.13"
|
|
54
|
+
|
|
55
|
+
- name: Build wheel and sdist
|
|
56
|
+
run: uv build --out-dir dist
|
|
57
|
+
|
|
58
|
+
- name: The wheel must carry the agent registry
|
|
59
|
+
run: |
|
|
60
|
+
wheel=$(ls dist/*.whl)
|
|
61
|
+
count=$(unzip -l "$wheel" | grep -c 'registry/agents/.*\.toml')
|
|
62
|
+
echo "registry TOMLs in wheel: $count"
|
|
63
|
+
test "$count" -eq 10
|
|
64
|
+
|
|
65
|
+
- name: Verify console script installs and runs
|
|
66
|
+
run: |
|
|
67
|
+
uv venv /tmp/smoke --python 3.13
|
|
68
|
+
uv pip install --python /tmp/smoke dist/*.whl
|
|
69
|
+
/tmp/smoke/bin/skill-lens --version
|
|
70
|
+
/tmp/smoke/bin/skill-lens --help
|
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
# AGENTS.md — Guardrails for AI Coding Assistants
|
|
2
|
+
|
|
3
|
+
Welcome, AI agent. You are pair-programming on **Skill Lens**, a local diagnostics and resolution CLI tool for AI agent capabilities (`SKILL.md`).
|
|
4
|
+
|
|
5
|
+
The developer driving you has zero coding experience and is vibe-coding this project. Your job is to be disciplined, reliable, and strictly follow the specification in `SKILL_LENS_SPECIFICATION.md`.
|
|
6
|
+
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
## 0. Communication Rules (READ FIRST)
|
|
10
|
+
|
|
11
|
+
- **The developer has zero coding experience. Explain everything in plain, simple English.**
|
|
12
|
+
- **No unexplained jargon.** If a technical term is unavoidable, define it in one short sentence the first time you use it.
|
|
13
|
+
- **Lead with the outcome, not the mechanics.** Say what changed and why it matters to the user before listing files or code details.
|
|
14
|
+
- **Use everyday analogies** for technical concepts (e.g. "a symlink is like a shortcut icon").
|
|
15
|
+
- **When reporting a task:** what I did, why it helps, whether it works, and what (if anything) you need from the developer — in that order, in short bullets.
|
|
16
|
+
- **When something breaks:** explain it in one plain sentence, then the fix, then confirm it is resolved. Never dump a raw stack trace without a plain-English translation.
|
|
17
|
+
- **Ask before assuming.** If a decision affects behaviour or the user's machine, ask in plain language rather than guessing.
|
|
18
|
+
- **No walls of text.** Prefer short paragraphs and tight bullet lists over long technical essays.
|
|
19
|
+
|
|
20
|
+
---
|
|
21
|
+
|
|
22
|
+
## 1. Absolute Golden Rules
|
|
23
|
+
|
|
24
|
+
1. **Strictly Read-Only Target Execution:**
|
|
25
|
+
- Skill Lens never writes, modifies, moves, or deletes user skills on their machine. It is 100% read-only.
|
|
26
|
+
2. **Never Touch Real `$HOME` in Tests:**
|
|
27
|
+
- All tests must use `tmp_path` fixtures and monkeypatched `HOME` via `skill_lens/core/paths.py`.
|
|
28
|
+
- Never run tests against live `~/.claude`, `~/.agents`, or `~/.codex`.
|
|
29
|
+
3. **No Lazy Module-Level Path Expansion:**
|
|
30
|
+
- Do NOT write `DEFAULT_DIR = Path("~/.claude").expanduser()` at the module top level. It will evaluate at import time and bypass test monkeypatching. Always resolve paths inside functions via `paths.py`.
|
|
31
|
+
4. **Machine-Readable JSON First:**
|
|
32
|
+
- All core features must output valid dataclasses and JSON models. Rich formatting is strictly a presentation layer on top of the data.
|
|
33
|
+
5. **No System Bloat or Creep:**
|
|
34
|
+
- NO full-screen TUI (Textual). Line-oriented CLI only.
|
|
35
|
+
- NO SQLite or databases in v1.
|
|
36
|
+
- NO AI API calls or telemetry.
|
|
37
|
+
- NO Windows support in v1. macOS and Linux only.
|
|
38
|
+
6. **Provenance Over Hallucination:**
|
|
39
|
+
- Never invent or guess an agent's collision or precedence behavior. Every rule in `registry/agents/*.toml` must declare its evidence kind (`documented`, `empirical`, `inferred`). If undocumented, emit `ambiguous` or `unverified`.
|
|
40
|
+
|
|
41
|
+
---
|
|
42
|
+
|
|
43
|
+
## 2. Test & Verification Protocol
|
|
44
|
+
|
|
45
|
+
- **Linter & Formatter:** `ruff check .` and `ruff format .`
|
|
46
|
+
- **Type Checker:** `mypy` (strict, scoped to `skill_lens/` via `[tool.mypy]`)
|
|
47
|
+
- **Test Runner:** `pytest`
|
|
48
|
+
- **Coverage Gate:** `pytest --cov=skill_lens` (threshold in `[tool.coverage.report]`)
|
|
49
|
+
- Before finishing any task, run:
|
|
50
|
+
```bash
|
|
51
|
+
pytest --cov=skill_lens
|
|
52
|
+
mypy
|
|
53
|
+
ruff check .
|
|
54
|
+
ruff format --check .
|
|
55
|
+
```
|
|
56
|
+
- **Snapshot tests:** the terminal output of `scan`, `why` and `diff` is pinned as
|
|
57
|
+
plain text under `tests/fixtures/snapshots/`. A snapshot failure means the
|
|
58
|
+
rendering changed: read the difference first, then regenerate with
|
|
59
|
+
`pytest tests/test_render_snapshots.py --update-snapshots`. Never regenerate
|
|
60
|
+
without reviewing what changed.
|
|
61
|
+
- Commit only when all tests pass cleanly.
|
|
62
|
+
|
|
63
|
+
---
|
|
64
|
+
|
|
65
|
+
## 3. Architecture Overview
|
|
66
|
+
|
|
67
|
+
```text
|
|
68
|
+
skill_lens/
|
|
69
|
+
├── __init__.py
|
|
70
|
+
├── cli.py # Typer commands (scan, why, agents, diff, doctor, compare)
|
|
71
|
+
├── render.py # All Rich layout (scan, why, diff, agents, doctor, compare)
|
|
72
|
+
├── models/ # Frozen dataclasses (SkillInstallation, DiffReport, ...)
|
|
73
|
+
├── core/
|
|
74
|
+
│ ├── paths.py # Lazy environment & path resolution
|
|
75
|
+
│ ├── parser.py # Frontmatter extraction & symlink canonicalization
|
|
76
|
+
│ ├── hasher.py # Streaming SHA-256 fingerprint (newline-normalised)
|
|
77
|
+
│ ├── discovery.py # Agent-agnostic entrypoint discovery + variant labels
|
|
78
|
+
│ ├── resolver.py # 3-axis resolution engine
|
|
79
|
+
│ ├── scanner.py # Inventory view over one discovery pass
|
|
80
|
+
│ ├── diff.py # Unified diff computation (pure; no Rich)
|
|
81
|
+
│ ├── doctor.py # Phase 4: diagnostics & hygiene checks
|
|
82
|
+
│ ├── compare.py # Phase 4: pairwise capability comparison (pure; no Rich)
|
|
83
|
+
│ ├── system.py # Phase 4: TCC-resilient live discovery adapter
|
|
84
|
+
│ └── exitcodes.py # Phase 6: exit-code contract + --fail-on policy (pure; no Typer/Rich)
|
|
85
|
+
└── registry/
|
|
86
|
+
├── loader.py # TOML agent-definition loader
|
|
87
|
+
└── agents/ # Agent definition TOML files (codex.toml, claude.toml, ...)
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
---
|
|
91
|
+
|
|
92
|
+
## 4. Project record (read before changing a finished phase)
|
|
93
|
+
|
|
94
|
+
Each reviewed phase keeps its findings as a permanent record, including the code
|
|
95
|
+
that was wrong and why. Read the relevant one before touching that area — the
|
|
96
|
+
rules in them were paid for:
|
|
97
|
+
|
|
98
|
+
- [`PHASE2_FINDINGS.md`](./PHASE2_FINDINGS.md) — 20 findings (F-01 … F-20) in the
|
|
99
|
+
registry, discovery and resolver. Load-bearing for anything touching precedence,
|
|
100
|
+
variant labels or canonical paths.
|
|
101
|
+
- [`PHASE3_FINDINGS.md`](./PHASE3_FINDINGS.md) — 4 findings (D-01 … D-04) in the
|
|
102
|
+
`diff` truncation and presentation layer, plus the test gaps that let them
|
|
103
|
+
through.
|
|
104
|
+
- [`PHASE4_FINDINGS.md`](./PHASE4_FINDINGS.md) — 8 findings (C-01 ... C-08) in the
|
|
105
|
+
`doctor` / `compare` engines and the golden-file harness, plus the review
|
|
106
|
+
suggestions deliberately not adopted and why.
|
|
107
|
+
- [`PHASE6_PLAN.md`](./PHASE6_PLAN.md) — the Phase 6 plan: the exit-code
|
|
108
|
+
contract, `--fail-on`, and the evidence-integrity work. Phase 6 is *new scope*
|
|
109
|
+
added after 0.1.0, not part of the original roadmap.
|
|
110
|
+
- [`PHASE6_WALKTHROUGH.md`](./PHASE6_WALKTHROUGH.md) — what Phase 6 shipped: the
|
|
111
|
+
two registry defects found by reading vendor docs, the mutation results, and
|
|
112
|
+
the mistakes made. Read it before changing `core/exitcodes.py`, adding a
|
|
113
|
+
`--fail-on`, or editing an agent's `evidence` / `source` fields.
|
|
114
|
+
- [`PHASE5_WALKTHROUGH.md`](./PHASE5_WALKTHROUGH.md) — the packaging and release
|
|
115
|
+
walkthrough: what ships in the wheel, the CI gate, and the deliberate decision
|
|
116
|
+
to defer publishing. Section 10 covers the Phase 5 gate test. Read it before
|
|
117
|
+
changing `pyproject.toml`, the contents of the wheel, or the release steps.
|
|
118
|
+
|
|
119
|
+
They were produced by independent read-only review delegated to other models
|
|
120
|
+
(Phase 4 by two axes: one reviewer per repo standards, one per specification),
|
|
121
|
+
then reproduced and fixed by the orchestrator. Two habits came out of them and
|
|
122
|
+
should be kept: **reproduce a reported defect before believing it** (a false
|
|
123
|
+
alarm costs as much as a miss), and **never regenerate a snapshot or golden
|
|
124
|
+
without reading the diff** — pinned output proves the output did not change,
|
|
125
|
+
not that it was right.
|
|
126
|
+
|
|
127
|
+
A third habit came from the first CI run: **a test that cannot fail is worse than
|
|
128
|
+
no test.** `tests/test_phase5_gate.py` and `tests/test_phase6_gate.py` were
|
|
129
|
+
mutation-tested — each guard was deliberately broken to confirm it fails. Do the
|
|
130
|
+
same for any new gate. Two of the ten Phase 6 mutations *survived* and exposed a
|
|
131
|
+
real hole (a scan test that only ever scanned a clean sandbox) and a piece of
|
|
132
|
+
dead code, so the habit earns its keep.
|
|
@@ -0,0 +1,142 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
All notable changes to Skill Lens are recorded here.
|
|
4
|
+
|
|
5
|
+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
|
|
6
|
+
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
|
+
|
|
8
|
+
Every entry below was verified against the repository gate: `pytest`, `ruff check .`
|
|
9
|
+
and `ruff format --check .` all clean, plus a green CI run on macOS and Linux.
|
|
10
|
+
|
|
11
|
+
---
|
|
12
|
+
|
|
13
|
+
## [0.1.0] — 2026-10-01
|
|
14
|
+
|
|
15
|
+
First release. A local, strictly read-only diagnostics and resolution engine for AI
|
|
16
|
+
agent skills (`SKILL.md`), shipped as the `skill-lens` command.
|
|
17
|
+
|
|
18
|
+
> **This release was never published to PyPI.** It is the version the repository
|
|
19
|
+
> was built towards; there is no `0.1.0` tag and no upload has happened. Phase 6
|
|
20
|
+
> (below) is therefore part of what `0.1.0` will contain rather than a change
|
|
21
|
+
> after it. Publishing remains deliberately manual — see
|
|
22
|
+
> [`PHASE5_WALKTHROUGH.md`](./PHASE5_WALKTHROUGH.md).
|
|
23
|
+
|
|
24
|
+
### Added
|
|
25
|
+
|
|
26
|
+
- **Exit-code contract.** `skill-lens doctor` and `skill-lens scan` can now gate
|
|
27
|
+
a pipeline. `0` means the command ran with nothing over the threshold, `1`
|
|
28
|
+
means findings reached it, `2` means the command could not run (bad usage,
|
|
29
|
+
unknown agent), and `3` is reserved for an unexpected internal fault.
|
|
30
|
+
- **`--fail-on {never,error,warning,info}`** on `doctor` and `scan`. The default
|
|
31
|
+
is `never`, so every `0.1.0` exit status is unchanged. The report is always
|
|
32
|
+
printed before a non-zero exit, so a gate never hides its own evidence.
|
|
33
|
+
- **Registry evidence invariant.** No agent may claim `documented` or
|
|
34
|
+
`empirical` evidence without a citable `source` URL, and no root may claim
|
|
35
|
+
`documented` evidence without one. Previously this was a convention with
|
|
36
|
+
nothing enforcing it.
|
|
37
|
+
- **A self-audit check in `doctor`** that reports agents whose precedence had to
|
|
38
|
+
be inferred, so the tool states its own limits instead of only the user's.
|
|
39
|
+
Informational severity; silent with the registry as shipped.
|
|
40
|
+
|
|
41
|
+
### Fixed
|
|
42
|
+
|
|
43
|
+
- **`dsh` was missing both user-level skill roots.** Its registry entry knew only
|
|
44
|
+
the two project roots and a plugin root, so Skill Lens could not see
|
|
45
|
+
`~/.dsh/skills` or `~/.agents/skills` — where a real dsh user's skills actually
|
|
46
|
+
live. Both are now declared, in the order the vendor documentation specifies.
|
|
47
|
+
- **`omp`'s managed-skills folder was ranked above the folders that should win.**
|
|
48
|
+
The vendor documents the `omp-managed` provider at priority 5 of 9, always
|
|
49
|
+
deferring to an authored skill; the registry ranked it at 70, claiming the
|
|
50
|
+
opposite.
|
|
51
|
+
- **dsh's documented rank direction is inverted relative to Skill Lens.** The
|
|
52
|
+
upstream numbers are now translated rather than copied, with the translation
|
|
53
|
+
recorded in the registry file and asserted by a test.
|
|
54
|
+
|
|
55
|
+
### Changed
|
|
56
|
+
|
|
57
|
+
- `dsh` and `omp` are no longer entirely `inferred`. Both now cite primary
|
|
58
|
+
vendor documentation, taking the registry to 10 of 10 agents with a source.
|
|
59
|
+
- `omp` deliberately keeps `coexist_policy = "ambiguous"` even though its
|
|
60
|
+
collision behaviour is now documented. Neither `shadow` nor `merge` can
|
|
61
|
+
express namespaced coexistence, and both would emit a false statement;
|
|
62
|
+
under-claiming is the correct direction of error. See the walkthrough.
|
|
63
|
+
- Dropped the legacy `License :: OSI Approved :: MIT License` classifier. The
|
|
64
|
+
SPDX `license = "MIT"` expression is authoritative under PEP 639, and shipping
|
|
65
|
+
both left the metadata self-contradictory. `twine check` still passes.
|
|
66
|
+
|
|
67
|
+
### Verification hardening (post-Phase 6)
|
|
68
|
+
|
|
69
|
+
The release gate now checks two properties it previously only asserted in prose.
|
|
70
|
+
|
|
71
|
+
- **Strict type checking.** `mypy --strict` runs over `skill_lens/` in CI, with
|
|
72
|
+
`types-PyYAML` supplying the one missing stub. The `py.typed` marker and the
|
|
73
|
+
`Typing :: Typed` classifier already shipped; a strict checker is what makes
|
|
74
|
+
that promise verifiable rather than decorative. It surfaced exactly two
|
|
75
|
+
findings, both fixed: an unparameterised `dict` in the registry loader, and a
|
|
76
|
+
presentation-layer import that reached through `core.resolver` for a model it
|
|
77
|
+
should have taken from `models.resolution`.
|
|
78
|
+
- **A coverage gate.** `pytest --cov=skill_lens` now fails below 90% branch
|
|
79
|
+
coverage; the suite currently measures **93%**. The threshold lives in
|
|
80
|
+
`[tool.coverage.report]` and the type-check scope in `[tool.mypy]`, so CI
|
|
81
|
+
enforces exactly what a local run does.
|
|
82
|
+
- **Drift guards for both.** Five assertions in `tests/test_phase5_gate.py` pin
|
|
83
|
+
the dev-dependency list, the mypy scope, the coverage threshold, and that CI
|
|
84
|
+
actually invokes both. Each was mutation-tested: breaking the declaration
|
|
85
|
+
produces exactly one failure.
|
|
86
|
+
|
|
87
|
+
### Known limitations
|
|
88
|
+
|
|
89
|
+
- Namespaced coexistence — a losing variant that survives under
|
|
90
|
+
`<namespace>/<name>` — is not modelled. `omp` under-claims as a result.
|
|
91
|
+
- `--fail-on info` fails on essentially any machine, because `doctor` reports
|
|
92
|
+
normal setups as informational notes. Use `error` or `warning` for a gate.
|
|
93
|
+
|
|
94
|
+
### Also in this release (Phases 0–5)
|
|
95
|
+
|
|
96
|
+
The engine itself:
|
|
97
|
+
- **`scan`** — inventory of every skill visible to an agent, grouped by canonical
|
|
98
|
+
library versus entrypoint, with status labels (`ACTIVE`, `COEXISTS`, `SHADOWED`,
|
|
99
|
+
`DISABLED`, `INVALID`, `AMBIGUOUS`, `UNREADABLE`, `UNSEARCHED`).
|
|
100
|
+
- **`why <skill> --agent <agent>`** — explains, axis by axis, why a given agent
|
|
101
|
+
resolves a given skill to the copy it picked. Every reason carries a stable
|
|
102
|
+
`rule_id` and an evidence level.
|
|
103
|
+
- **`diff`** — unified diff between every copy of one skill, with truncation that
|
|
104
|
+
is honest about what it dropped.
|
|
105
|
+
- **`agents`** — the agent registry table: collision policy, evidence kind, and
|
|
106
|
+
how many roots each agent declares.
|
|
107
|
+
- **`doctor`** — hygiene checks: broken symlinks, unreadable (TCC-blocked)
|
|
108
|
+
directories, malformed frontmatter, and the Codex context-budget check.
|
|
109
|
+
- **`compare --agent A --agent B`** — pairwise capability comparison between two
|
|
110
|
+
agents, including the skills only one of them can see.
|
|
111
|
+
- **Three-axis resolver** — agent, location rank, and variant identity resolved
|
|
112
|
+
independently, then reconciled.
|
|
113
|
+
- **Agent registry** — 10 agent definitions as TOML with per-rule provenance
|
|
114
|
+
(`documented`, `empirical`, `inferred`). Rules without evidence are reported as
|
|
115
|
+
`ambiguous` or `unverified` rather than guessed.
|
|
116
|
+
- **`--json` on every command** — stable, sorted-key, machine-readable output. The
|
|
117
|
+
presentation layer is strictly downstream of the data.
|
|
118
|
+
- **Golden fixtures** — 16 hand-written scenarios pinning behaviour (the spec's 12
|
|
119
|
+
core scenarios plus the Phase 3 and Phase 4 additions), plus 17 plain-text
|
|
120
|
+
render snapshots.
|
|
121
|
+
- **Packaging** — `skill-lens` console script, `py.typed` marker, tracked
|
|
122
|
+
`uv.lock`, and a CI job that asserts the wheel carries all 10 registry files.
|
|
123
|
+
|
|
124
|
+
### Fixed (engine, Phases 0–5)
|
|
125
|
+
|
|
126
|
+
- A symlink cycle no longer crashes `scan` or `doctor` on Python 3.11–3.12,
|
|
127
|
+
where `Path.resolve()` raises `RuntimeError` rather than `OSError`.
|
|
128
|
+
- A permission-blocked directory is now reported as `unreadable` on Python
|
|
129
|
+
3.11–3.13 instead of crashing discovery — those versions re-raise
|
|
130
|
+
`PermissionError` from `is_file()`/`is_dir()` where 3.14 returns `False`.
|
|
131
|
+
- CLI test assertions strip ANSI escapes, so they no longer depend on whether
|
|
132
|
+
the host terminal happens to be colourised.
|
|
133
|
+
|
|
134
|
+
### Known limitations (engine, Phases 0–5)
|
|
135
|
+
|
|
136
|
+
- macOS and Linux only. Windows is out of scope for v1.
|
|
137
|
+
- Live discovery is advisory. Where an agent's real precedence behaviour is not
|
|
138
|
+
documented, Skill Lens says `inferred` or `unverified` instead of guessing.
|
|
139
|
+
*(Closed for the two agents that were uncited in Phase 6; all 10 agents now
|
|
140
|
+
cite a primary source.)*
|
|
141
|
+
|
|
142
|
+
[0.1.0]: https://github.com/Hazem-Samak/skill-lens/releases/tag/v0.1.0
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Hazem Samak
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|