@andresmassello/uscha 1.40.1

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.
Files changed (98) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +104 -0
  3. package/bin/README.md +6 -0
  4. package/bin/uscha.js +28 -0
  5. package/package.json +38 -0
  6. package/uscha-kit/.claude/skills/uscha-adr-refine/SKILL.md +161 -0
  7. package/uscha-kit/.claude/skills/uscha-characterize/SKILL.md +124 -0
  8. package/uscha-kit/.claude/skills/uscha-devloop/SKILL.md +490 -0
  9. package/uscha-kit/.claude/skills/uscha-devloop/qa_ledger.py +5602 -0
  10. package/uscha-kit/.claude/skills/uscha-discovery/SKILL.md +161 -0
  11. package/uscha-kit/.claude/skills/uscha-mirador/SKILL.md +145 -0
  12. package/uscha-kit/.claude/skills/uscha-mirador/mirador-render.py +112 -0
  13. package/uscha-kit/.claude/skills/uscha-mirador/mirador-watch.ps1 +22 -0
  14. package/uscha-kit/.claude/skills/uscha-mirador/mirador-watch.sh +26 -0
  15. package/uscha-kit/.claude/skills/uscha-mirador/mirador.template.html +586 -0
  16. package/uscha-kit/.claude/skills/uscha-mirador/telemetry-extract.py +130 -0
  17. package/uscha-kit/.claude/skills/uscha-reverse-discovery/SKILL.md +116 -0
  18. package/uscha-kit/.claude/skills/uscha-rubric/SKILL.md +79 -0
  19. package/uscha-kit/.claude/skills/uscha-sysdoc/SKILL.md +88 -0
  20. package/uscha-kit/.claude-plugin/plugin.json +24 -0
  21. package/uscha-kit/.codex-plugin/plugin.json +37 -0
  22. package/uscha-kit/CHANGELOG-1.10.0.md +84 -0
  23. package/uscha-kit/CHANGELOG-1.11.0.md +67 -0
  24. package/uscha-kit/CHANGELOG-1.12.0.md +46 -0
  25. package/uscha-kit/CHANGELOG-1.13.0.md +33 -0
  26. package/uscha-kit/CHANGELOG-1.14.0.md +42 -0
  27. package/uscha-kit/CHANGELOG-1.15.0.md +58 -0
  28. package/uscha-kit/CHANGELOG-1.16.0.md +55 -0
  29. package/uscha-kit/CHANGELOG-1.17.0.md +44 -0
  30. package/uscha-kit/CHANGELOG-1.18.0.md +42 -0
  31. package/uscha-kit/CHANGELOG-1.19.0.md +41 -0
  32. package/uscha-kit/CHANGELOG-1.2.2.md +16 -0
  33. package/uscha-kit/CHANGELOG-1.2.3.md +20 -0
  34. package/uscha-kit/CHANGELOG-1.2.4.md +10 -0
  35. package/uscha-kit/CHANGELOG-1.2.5.md +23 -0
  36. package/uscha-kit/CHANGELOG-1.2.6.md +11 -0
  37. package/uscha-kit/CHANGELOG-1.2.7.md +15 -0
  38. package/uscha-kit/CHANGELOG-1.2.8.md +24 -0
  39. package/uscha-kit/CHANGELOG-1.2.9.md +4 -0
  40. package/uscha-kit/CHANGELOG-1.20.0.md +29 -0
  41. package/uscha-kit/CHANGELOG-1.21.0.md +33 -0
  42. package/uscha-kit/CHANGELOG-1.22.0.md +60 -0
  43. package/uscha-kit/CHANGELOG-1.23.0.md +75 -0
  44. package/uscha-kit/CHANGELOG-1.24.0.md +50 -0
  45. package/uscha-kit/CHANGELOG-1.25.0.md +55 -0
  46. package/uscha-kit/CHANGELOG-1.26.0.md +70 -0
  47. package/uscha-kit/CHANGELOG-1.27.0.md +45 -0
  48. package/uscha-kit/CHANGELOG-1.28.0.md +35 -0
  49. package/uscha-kit/CHANGELOG-1.29.0.md +20 -0
  50. package/uscha-kit/CHANGELOG-1.3.0.md +74 -0
  51. package/uscha-kit/CHANGELOG-1.30.0.md +46 -0
  52. package/uscha-kit/CHANGELOG-1.31.0.md +59 -0
  53. package/uscha-kit/CHANGELOG-1.32.0.md +50 -0
  54. package/uscha-kit/CHANGELOG-1.33.0.md +46 -0
  55. package/uscha-kit/CHANGELOG-1.34.0.md +55 -0
  56. package/uscha-kit/CHANGELOG-1.35.0.md +30 -0
  57. package/uscha-kit/CHANGELOG-1.36.0.md +33 -0
  58. package/uscha-kit/CHANGELOG-1.37.0.md +41 -0
  59. package/uscha-kit/CHANGELOG-1.38.0.md +11 -0
  60. package/uscha-kit/CHANGELOG-1.39.0.md +14 -0
  61. package/uscha-kit/CHANGELOG-1.4.0.md +68 -0
  62. package/uscha-kit/CHANGELOG-1.40.0.md +16 -0
  63. package/uscha-kit/CHANGELOG-1.40.1.md +11 -0
  64. package/uscha-kit/CHANGELOG-1.5.0.md +64 -0
  65. package/uscha-kit/CHANGELOG-1.6.0.md +57 -0
  66. package/uscha-kit/CHANGELOG-1.7.0.md +74 -0
  67. package/uscha-kit/CHANGELOG-1.8.0.md +46 -0
  68. package/uscha-kit/CHANGELOG-1.9.0.md +112 -0
  69. package/uscha-kit/LICENSE +21 -0
  70. package/uscha-kit/README.md +497 -0
  71. package/uscha-kit/VERSION +1 -0
  72. package/uscha-kit/WORKBENCH.md +178 -0
  73. package/uscha-kit/hooks/block-approved-writes.ps1 +46 -0
  74. package/uscha-kit/hooks/hooks.json +15 -0
  75. package/uscha-kit/install-uscha.py +344 -0
  76. package/uscha-kit/skills/uscha-adr-refine/SKILL.md +161 -0
  77. package/uscha-kit/skills/uscha-characterize/SKILL.md +124 -0
  78. package/uscha-kit/skills/uscha-devloop/SKILL.md +490 -0
  79. package/uscha-kit/skills/uscha-devloop/qa_ledger.py +5602 -0
  80. package/uscha-kit/skills/uscha-discovery/SKILL.md +161 -0
  81. package/uscha-kit/skills/uscha-mirador/SKILL.md +145 -0
  82. package/uscha-kit/skills/uscha-mirador/mirador-render.py +112 -0
  83. package/uscha-kit/skills/uscha-mirador/mirador-watch.ps1 +22 -0
  84. package/uscha-kit/skills/uscha-mirador/mirador-watch.sh +26 -0
  85. package/uscha-kit/skills/uscha-mirador/mirador.template.html +586 -0
  86. package/uscha-kit/skills/uscha-mirador/telemetry-extract.py +130 -0
  87. package/uscha-kit/skills/uscha-reverse-discovery/SKILL.md +116 -0
  88. package/uscha-kit/skills/uscha-rubric/SKILL.md +79 -0
  89. package/uscha-kit/skills/uscha-sysdoc/SKILL.md +88 -0
  90. package/uscha-kit/templates/.gitattributes +6 -0
  91. package/uscha-kit/templates/CLAUDE.md +56 -0
  92. package/uscha-kit/templates/CONSTITUTION.md +149 -0
  93. package/uscha-kit/templates/RUBRIC.md +38 -0
  94. package/uscha-kit/templates/docs/adr/README.md +19 -0
  95. package/uscha-kit/templates/rubric-grader-prompt.md +63 -0
  96. package/uscha-kit/tests/smoke-engine.sh +1739 -0
  97. package/uscha-kit/uscha.config.json +181 -0
  98. package/uscha-kit/workbench-doctor.sh +45 -0
@@ -0,0 +1,38 @@
1
+ # RUBRIC — <name of the change or project>
2
+
3
+ > The rubric is the ACCEPTANCE of the NON-testable: a versioned qualitative criterion,
4
+ > with weights, anchors and threshold. A grader (any agent, any LLM, or a
5
+ > human) scores it criterion by criterion WITH `file:line` evidence and emits the JSON
6
+ > of the contract (see `templates/rubric-grader-prompt.md`); `qa_ledger.py rubric-ingest`
7
+ > absorbs it. By default it ADVISES; it gates only if you declare it
8
+ > (`defaults.rubric.gate: true` in the config, or `--gate`).
9
+ >
10
+ > Parseable format: `- [ ] RB-01 (peso 3) — criterion`. The weight is optional
11
+ > (default 1). The anchors are for the grader; the engine does not parse them.
12
+
13
+ threshold: 0.80
14
+
15
+ ## Criteria
16
+
17
+ - [ ] RB-01 (peso 3) — Sane error handling: every external call has a timeout,
18
+ the failure is translated into an actionable message and exceptions are not swallowed.
19
+ - anchor-pass: `client.get(url, timeout=5)` + retry with backoff + log with context.
20
+ - anchor-fail: `except Exception: pass`, or a `catch` that only re-raises without context.
21
+ - [ ] RB-02 (peso 2) — Repo conventions respected: naming, package structure
22
+ and style consistent with the neighboring code (not with the author's preference).
23
+ - anchor-pass: the new file is indistinguishable in style from its siblings.
24
+ - anchor-fail: a module with camelCase in a snake_case repo.
25
+ - [ ] RB-03 (peso 2) — API/surface ergonomics: names that say what they do,
26
+ parameters without surprises, the common case is the easy one.
27
+ - [ ] RB-04 (peso 1) — The change's documentation explains the WHY, it does not paraphrase
28
+ the code.
29
+
30
+ ## Negative criteria
31
+
32
+ > Things that must NOT appear. If the grader finds them (verdict `fail` WITH
33
+ > evidence), they subtract their weight from the score.
34
+
35
+ - [ ] RB-NEG-01 (peso 2) — Comments that narrate the correctness of the change itself
36
+ ("now correctly handles...") instead of documenting the code.
37
+ - [ ] RB-NEG-02 (peso 1) — Speculative abstractions: interfaces/layers with a single
38
+ use and no request in the SPEC.
@@ -0,0 +1,19 @@
1
+ # Architecture Decision Records
2
+
3
+ Durable technical decisions of this repo. One per file:
4
+ `ADR-NNN-<slug>.md`. They are written by `/discovery` or `/adr-refine`, or proposed during the
5
+ build when a real decision appears (see the ADR rules in `CLAUDE.md`).
6
+
7
+ Format: Status (proposed/accepted/experiment/deprecated/superseded) · Context · Alternatives ·
8
+ Decision · Consequences · Implementation Plan (affected paths, patterns, tests) ·
9
+ Verification (checkboxes).
10
+
11
+ `Status: Experiment` is for a bounded, reversible hypothesis that needs real feedback.
12
+ It must include: Hypothesis, Feedback Signal, Review By or Review Trigger, Promote
13
+ Criteria, and Rollback / Supersede Criteria. Missing/expired metadata is advisory in
14
+ Mirador/dashboard; it is not a readiness score.
15
+
16
+ ## Index
17
+
18
+ <!-- add one line per ADR -->
19
+ - _(no ADRs yet)_
@@ -0,0 +1,63 @@
1
+ # Rubric grader — neutral prompt (works on any agent/LLM, or by hand)
2
+
3
+ > This is the PORTABLE piece of the rubric layer: instructions for ANY runner —
4
+ > Claude Code, Codex, Gemini CLI, Cursor, a `curl` to any API, or a human.
5
+ > The only coupling with the method is the output JSON CONTRACT, which
6
+ > `qa_ledger.py rubric-ingest` validates and ingests. Who emits the JSON is irrelevant.
7
+
8
+ ## Instructions for the grader
9
+
10
+ You are an evaluator with an ISOLATED context. You read ONLY two things:
11
+
12
+ 1. `RUBRIC.md` — the criteria (weighted RB-nn, with anchors), the negative
13
+ criteria (RB-NEG-nn) and the threshold.
14
+ 2. The change's diff (or the changed files).
15
+
16
+ You do NOT read the reasoning of whoever made the change, nor its description, nor its PR body —
17
+ your value is precisely in having no attachment to how the result was produced.
18
+
19
+ For each rubric criterion:
20
+
21
+ - Emit a `pass` or `fail` verdict.
22
+ - **Evidence is mandatory for every verdict that affects the score**
23
+ (a `pass` on a positive criterion; a `fail` on a negative one): a concrete
24
+ `file:line` citation + a snippet. Without evidence, the verdict does NOT score — the
25
+ engine discards it and lists it as unsupported.
26
+ - Use the anchors as calibration: if the code looks more like the anchor-fail than
27
+ the anchor-pass, it is `fail`. When in doubt, `fail` — the optimistic bias is the
28
+ failure mode this contract exists to counter.
29
+ - In `note`, one line of justification (what you saw, not what you assume).
30
+
31
+ ## The output contract (the only thing that matters)
32
+
33
+ Write a single JSON:
34
+
35
+ ```json
36
+ {
37
+ "criteria": [
38
+ {"id": "RB-01", "verdict": "pass",
39
+ "evidence": "src/client.py:42 — client.get(url, timeout=5) with retry",
40
+ "note": "all external calls have a timeout and backoff"},
41
+ {"id": "RB-02", "verdict": "fail",
42
+ "evidence": "src/NewModule.py:1 — camelCase in a snake_case repo",
43
+ "note": "does not follow the neighboring modules' convention"},
44
+ {"id": "RB-NEG-01", "verdict": "pass", "evidence": "", "note": "does not appear"}
45
+ ]
46
+ }
47
+ ```
48
+
49
+ - `id`: must exist in `RUBRIC.md` (unknown IDs = ingest error).
50
+ - `verdict`: `pass` | `fail`. On the NEGATIVE ones, `pass` = the forbidden practice does NOT
51
+ appear; `fail` = it appears (and subtracts its weight from the score, with evidence).
52
+ - Criteria you do not evaluate count as `fail` (not evaluated is not passed).
53
+
54
+ ## How it is ingested (the operator or the loop runs it, not you)
55
+
56
+ ```bash
57
+ python3 <path>/qa_ledger.py rubric-ingest --repo <REPO> --report grader.json \
58
+ [--rubric RUBRIC.md] [--gate]
59
+ ```
60
+
61
+ Advisory by default; `--gate` (or `defaults.rubric.gate: true` in the config — the
62
+ human's declaration) turns a score below the threshold into a gated record:
63
+ it blocks convergence and caps readiness ≤65 through the ledger's existing machinery.