agentic-scorecard 0.3.0 → 0.4.0

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 (31) hide show
  1. package/AGENT_PROMPT.md +68 -52
  2. package/README.md +50 -37
  3. package/benchmark/v0.4/adapter-contract.md +129 -0
  4. package/benchmark/v0.4/adapters/known-agent-harnesses.yaml +266 -0
  5. package/benchmark/v0.4/adapters/known-ci-providers.yaml +57 -0
  6. package/benchmark/v0.4/adapters/known-command-wrappers.yaml +37 -0
  7. package/benchmark/v0.4/adapters/known-environment-tooling.yaml +17 -0
  8. package/benchmark/v0.4/adapters/known-github-conventions.yaml +27 -0
  9. package/benchmark/v0.4/adapters/known-python-tooling.yaml +15 -0
  10. package/benchmark/v0.4/adapters/known-security-tools.yaml +45 -0
  11. package/benchmark/v0.4/adapters/known-verification-tools.yaml +65 -0
  12. package/benchmark/v0.4/agent-evidence-schema.json +74 -0
  13. package/benchmark/v0.4/attestation-schema.json +35 -0
  14. package/benchmark/v0.4/benchmark.yaml +127 -0
  15. package/benchmark/v0.4/calibration-matrix.md +60 -0
  16. package/benchmark/v0.4/controls/context.yaml +75 -0
  17. package/benchmark/v0.4/controls/environment.yaml +93 -0
  18. package/benchmark/v0.4/controls/governance.yaml +132 -0
  19. package/benchmark/v0.4/controls/learning.yaml +78 -0
  20. package/benchmark/v0.4/controls/observability.yaml +91 -0
  21. package/benchmark/v0.4/controls/resilience.yaml +170 -0
  22. package/benchmark/v0.4/controls/security.yaml +143 -0
  23. package/benchmark/v0.4/controls/specification.yaml +65 -0
  24. package/benchmark/v0.4/controls/testing.yaml +82 -0
  25. package/benchmark/v0.4/controls/tooling.yaml +69 -0
  26. package/benchmark/v0.4/report-schema.json +89 -0
  27. package/benchmark/v0.4/scoring-policy.md +175 -0
  28. package/dist/cli.js +2315 -162
  29. package/package.json +3 -2
  30. package/templates/agent-evidence.yaml +2 -2
  31. package/templates/attestations.yaml +3 -1
@@ -0,0 +1,175 @@
1
+ # v0.4 scoring policy
2
+
3
+ This document is normative for benchmark version 0.4.0.
4
+
5
+ ## Unit and assessment scope
6
+
7
+ The unit is one repository plus explicitly supplied repository-semantic, external, and
8
+ organizational evidence bound to that repository. The default `tracked` mode considers only
9
+ Git-tracked paths, using their current working-tree contents. Reports record the commit, remote, and
10
+ dirty state. `workspace` mode is available for provisional assessment and is not directly
11
+ comparable with tracked-mode reports.
12
+
13
+ Generated reports, attestations, evidence requests, and imported evidence bundles never qualify as
14
+ repository evidence. An assessment must be idempotent: adding its own generated artifacts cannot
15
+ change its score.
16
+
17
+ ## Dimension scores
18
+
19
+ Each dimension earns level `n` only when every applicable control at that level and every lower
20
+ level is met. More than one control may exist at a level when separate observable outcomes are
21
+ required. Controls met above the first gap are reported but do not increase the dimension score.
22
+
23
+ The normative score is the sum of ten dimension scores, with a maximum of 40. Its percentage is
24
+ display-only and does not determine readiness.
25
+
26
+ ### Repository-detected progress
27
+
28
+ v0.4 also reports an explanatory repository score and ceiling. For each dimension, the ceiling is
29
+ the highest consecutive level for which every control has a deterministic, non-manual repository
30
+ collector. The achieved value is the highest consecutive level established only with
31
+ `repository-detected` evidence. The two values are summed across dimensions.
32
+
33
+ Agent-collected and human-attested evidence never increases repository-detected progress. The
34
+ repository percentage is `achieved / ceiling`; it does not replace the normative score, remove
35
+ UNKNOWN controls, or affect readiness-profile decisions.
36
+
37
+ ## Readiness decisions
38
+
39
+ Each autonomy profile defines a floor for every dimension. A profile passes only if every floor is
40
+ met. Strength in one dimension cannot compensate for a security, testing, governance, or recovery
41
+ gap elsewhere. No profile grants deployment or production authority.
42
+
43
+ When a passed target profile depends on agent-collected or human-attested controls, the report's
44
+ target-profile headline discloses the number of required controls from each provenance class.
45
+
46
+ ## Evidence scopes and provenance
47
+
48
+ - `repository-detected`: a deterministic collector found qualifying evidence in the selected path
49
+ scope. It proves the reported artifact match, not consistent human behavior or external
50
+ enforcement.
51
+ - `agent-collected`: an authorized agent supplied a structured, source-backed repository-semantic
52
+ or external claim. It may satisfy only explicitly eligible controls and is never independently
53
+ verified.
54
+ - `attested`: an accountable person supplied a dated, expiring claim and durable reference.
55
+ - `unknown`: evidence is unavailable, expired, mismatched, unauthorized, or inconclusive.
56
+
57
+ Repository controls use non-empty files, control-specific term thresholds, semantic component
58
+ groups, structurally identifiable non-placeholder ownership mappings, enabled integration-triggered
59
+ CI invocations with adapter-declared full action identities plus explicit refs or executable plus
60
+ required argument-group signatures and prohibited non-blocking modes, executable step/job structure,
61
+ auto-loaded provider entry points, supported complete conditions and inheritance, no unparsed path
62
+ or exclusion gates, and blocking foreground exit-status
63
+ propagation, bounded line windows, and per-pattern candidate limits. Partial evidence remains
64
+ visible but does not pass a control. An ownership artifact, explicit accountable-human approval
65
+ authority, and explicit accountable-human merge authority are independently required for
66
+ `ADRB-GOV-002`; a generic owner/reviewer mention or declared agent authority cannot establish either
67
+ human authority. Directly negated authority statements do not count as positive evidence whether
68
+ negation appears before or after the matched phrase, including a colon-delimited policy label, and
69
+ explicit mappings require a recognized repository-wide target or path/component target rather than
70
+ arbitrary or punctuation-only syntax.
71
+ Typed ownership-table scope columns may use substantive component names, while conventional
72
+ plain-text former-owner sections remain inactive. Restrictive phrases such as `must not exceed`
73
+ establish an upper bound and are not treated as absence of the control.
74
+ `ADRB-RES-002` requires resource budgets and retry bounds as independent co-located components;
75
+ neither substitutes for the other.
76
+ Mechanical Level 3 context, environment, specification, testing, and learning controls require
77
+ structurally recognized CI commands; comments, documentation, and command-name keywords do not
78
+ establish execution. `ADRB-ENV-003` requires a locked installation plus independent test and
79
+ static-analysis command classes in the same CI execution group; commands split across jobs or
80
+ workflow files do not prove that one clean environment performs canonical verification. GitHub
81
+ event conditions are part of that identity, so commands restricted to mutually exclusive
82
+ `pull_request` and `merge_group` executions do not combine.
83
+ `ADRB-TST-003`
84
+ requires independent test and static-analysis command classes aggregated across the assessed CI
85
+ entry points. Root package-manager tasks must
86
+ resolve to tracked script definitions whose command bodies establish the applicable command class,
87
+ including when supported wrappers or global package-manager options precede the invocation.
88
+ Context-changing package/workspace options require resolution of the selected manifest or fail
89
+ closed; nested package-exec tools may qualify only at a supported executable position.
90
+ Custom guidance validators additionally require adapter-declared validation structures in the
91
+ executed tracked source after language comments are excluded; file presence or comment text alone
92
+ does not establish behavior. Specification-traceability and knowledge-curation checks use the same
93
+ source-bound standard. A recognized specification validator binds an approved work-item reference
94
+ to both implementation and verification artifacts; checking only for a heading is insufficient.
95
+ Constant-false branches and validation functions without a top-level reachable call path fail closed.
96
+ Required structural groups cannot combine across unreachable function bodies. JavaScript/TypeScript
97
+ class methods, object shorthand methods, and object arrow methods fail closed when the conservative
98
+ collector cannot prove their invocation.
99
+ Tool-specific discovery or listing modes do not count as execution. In a supported fail-fast shell,
100
+ each multiline command may contribute because any failure gates the step; without fail-fast
101
+ semantics, only the final effective foreground command may establish execution.
102
+ Catalog pattern order is significant when a candidate limit is present: authoritative entry points
103
+ precede large run, skill, or documentation corpora. External platform, organization, and outcome
104
+ controls cannot be inferred from repository keywords.
105
+
106
+ Human attestations and agent evidence may satisfy only controls explicitly eligible for those
107
+ classes. A v0.4 control may permit an `agent-collected` repository claim when a legitimate tracked
108
+ artifact uses an unrecognized convention. This is a semantic alternative, not a deterministic
109
+ pass: it remains separately labelled and does not increase repository-detected progress. Human
110
+ attestations cannot override repository-artifact controls. `ADRB-SEC-003` permits a dated, expiring
111
+ human attestation only for its platform alternative, such as host-native secret scanning or push
112
+ protection; it cannot attest the repository CI alternative. Malformed or unknown v0.4 attestation
113
+ control IDs are rejected rather than silently ignored. Every v0.4 attestation file is bound to the
114
+ assessed repository's normalized, sanitized origin URL, or its canonical root when no origin exists,
115
+ and rejects unknown file or claim fields. An optional remote `.git` suffix does not change target
116
+ identity. Human attestations are repository-bound and expiring but not
117
+ commit-bound: they establish accountable platform, organization, or outcome facts whose review
118
+ period may span repository commits. `agentic-scorecard init` derives the target; a file for another
119
+ repository fails closed. A non-`unknown` attestation with a generated `TODO` owner or evidence value
120
+ fails closed, as does any attestation whose review date is later than the assessment time.
121
+
122
+ Controls require every evidence check by default. A v0.4 control may explicitly declare
123
+ `evidence_mode: any` only when the checks are alternative ways to establish the same outcome. A
124
+ repository-only run remains `unknown` when the repository alternative is absent and an external
125
+ alternative has not been collected; it does not infer either a platform pass or a platform failure.
126
+ Supplemental evidence resolves only alternatives with the same scope. A negative claim makes the
127
+ control `not_met` only when every alternative is established negatively; any uncollected alternative
128
+ keeps the control `unknown`.
129
+ The report shows every alternative and its provenance. Control confidence comes from the
130
+ alternative that establishes the decisive pass or complete negative result; supplemental input on a
131
+ different alternative does not relabel the result or its evidence-summary/profile dependency.
132
+ An unresolved control always serializes control confidence as `none`; the supplemental input remains
133
+ visible in its separately labelled claim fields.
134
+ Established-control tables display the scope of the evidence that resolved the control rather than
135
+ an unresolved alternative scope.
136
+
137
+ Level 4 requires time-series or outcome evidence and an improvement decision influenced by it. The
138
+ existence of a dashboard is insufficient.
139
+
140
+ ## Agent evidence bundles
141
+
142
+ An agent evidence bundle is version-bound and target-bound. Claims record scope, status, collector,
143
+ collection and expiry times, a privacy-safe derivation summary, and durable references. The core
144
+ scanner makes no network calls; the agent obtains explicit authorization and uses read-only tools to
145
+ create the bundle. An error is distinct from a negative result and cannot pass a control.
146
+
147
+ Agent evidence can satisfy only controls with `allow_agent_evidence: true` and an allowed scope.
148
+ Deterministic passes take precedence. Repository-scoped claims additionally require tracked files
149
+ to match HEAD and references of the form `repo:<tracked-path>[#Lx-Ly]`; every referenced path must
150
+ exist in the tracked assessment scope at the exact bound commit. Untracked generated artifacts do
151
+ not affect tracked-scope evidence. An agent may use such a claim only to
152
+ establish the control outcome from a nonstandard artifact the deterministic catalog did not
153
+ recognize.
154
+
155
+ `ADRB-SEC-007` deliberately accepts source-backed agent claims at repository, platform, or
156
+ organization scope because enforced untrusted-input safeguards may be implemented as tracked
157
+ adversarial harness tests, platform sandbox or tool policy, or organization-wide controls. The
158
+ claim's scope must identify where enforcement actually resides. Repository-scoped claims remain
159
+ commit-bound and line-referenced; no scope may pass from prose alone, and deterministic repository
160
+ keyword scanning is not an evidence path for this non-compensating security floor.
161
+
162
+ ## Changes and comparability
163
+
164
+ v0.1, v0.2, and v0.3 remain immutable. Scores from v0.1, v0.2, v0.3, and v0.4 are not directly
165
+ comparable because evidence and control semantics changed. Reports are comparable only when
166
+ benchmark version, target profile, repository scope, evidence policy, and assessment mode match.
167
+
168
+ ## Claims
169
+
170
+ Allowed: “We self-assessed repository X against ADRB v0.4.0 on DATE; N controls were
171
+ repository-detected, M agent-collected, and P human-attested. Repository-detected progress was A of
172
+ an offline ceiling C.”
173
+
174
+ Not allowed: “Certified,” “compliant,” “safe,” “secure,” or “independently verified” based only on
175
+ this self-assessment.