@unson/brainbase-mcp 0.50.28 → 0.50.30

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 (39) hide show
  1. package/contracts/brainbase-public-contract.v1.json +1 -0
  2. package/dist/antigravity-judgment-hook.d.ts +191 -0
  3. package/dist/antigravity-judgment-hook.js +2042 -0
  4. package/dist/claude-code-judgment-hook.d.ts +23 -0
  5. package/dist/claude-code-judgment-hook.js +8 -5
  6. package/dist/cli.js +273 -6
  7. package/dist/graph-retrieval.d.ts +4 -0
  8. package/dist/graph-retrieval.js +4 -0
  9. package/dist/judgment-event-adapter.d.ts +37 -2
  10. package/dist/judgment-event-adapter.js +88 -3
  11. package/dist/judgment-event-outbox.d.ts +9 -1
  12. package/dist/judgment-event-outbox.js +45 -8
  13. package/dist/judgment-execution-outcome.d.ts +2 -1
  14. package/dist/judgment-execution-outcome.js +2 -1
  15. package/dist/judgment-frame.d.ts +26 -4
  16. package/dist/judgment-frame.js +190 -15
  17. package/dist/judgment-host.d.ts +30 -0
  18. package/dist/judgment-host.js +170 -22
  19. package/dist/judgment-model-outcome.d.ts +29 -1
  20. package/dist/judgment-model-outcome.js +69 -1
  21. package/dist/judgment-offline-binary-audit.d.ts +360 -0
  22. package/dist/judgment-offline-binary-audit.js +555 -0
  23. package/dist/judgment-project-binding.d.ts +1 -1
  24. package/dist/judgment-project-binding.js +2 -1
  25. package/dist/judgment-reasoning-audit.d.ts +115 -0
  26. package/dist/judgment-reasoning-audit.js +623 -0
  27. package/dist/judgment-reasoning-gate-prompt.d.ts +42 -0
  28. package/dist/judgment-reasoning-gate-prompt.js +83 -0
  29. package/dist/judgment-runtime-resolution.d.ts +2 -2
  30. package/dist/judgment-runtime-resolution.js +2 -2
  31. package/dist/judgment-runtime-resolution.public.d.ts +2 -2
  32. package/dist/judgment-session-world-model.d.ts +163 -0
  33. package/dist/judgment-session-world-model.js +408 -0
  34. package/dist/mcp-tool-schema-portability.d.ts +54 -0
  35. package/dist/mcp-tool-schema-portability.js +1013 -0
  36. package/dist/organization-graph.js +9 -1
  37. package/dist/remote-judgment-hook-http.d.ts +36 -3
  38. package/dist/remote-judgment-hook-http.js +94 -15
  39. package/package.json +14 -2
@@ -0,0 +1,360 @@
1
+ import type { JudgmentDAGOutcomeObservation } from './judgment-dag-replay-evaluation.js';
2
+ import type { SessionMiniWorldModelV2 } from './judgment-session-world-model.js';
3
+ /**
4
+ * RFC-001 v2.0 PR-C: Offline 7-Item Binary Audit Rubric (+ Ungrounded Fabrication),
5
+ * LLM-as-a-Judge structured schemas & prompt builders with explicit score polarity,
6
+ * PoLL 2-of-3 cross-family jury aggregator, and Replay Eval observation bridges.
7
+ *
8
+ * Design boundary:
9
+ * - Strictly offline Eval / audit only. Never wired into live conversation hooks
10
+ * (`judgment-host.ts`, `claude-code-judgment-hook.ts`, `remote-judgment-hook-http.ts`).
11
+ * - Side-effect free: pure constants, schemas, validators, and aggregators; no I/O or LLM calls.
12
+ */
13
+ export declare const OFFLINE_BINARY_AUDIT_RUBRIC_VERSION: "offline-binary-audit-rubric.v1";
14
+ export declare const OFFLINE_BINARY_AUDIT_EVALUATION_SCHEMA_VERSION: "judgment-offline-binary-audit.v1";
15
+ export declare const OFFLINE_BINARY_AUDIT_JUDGE_SCHEMA_ID: "brainbase-offline-binary-audit-judge.v1";
16
+ export declare const OFFLINE_GRADED_DISTORTION_JUDGE_SCHEMA_ID: "brainbase-offline-graded-distortion-judge.v1";
17
+ export declare const OFFLINE_BINARY_AUDIT_DEFECT_CODES: readonly ["cross_block_self_contradiction", "falsified_if_inversion", "unreflected_lag_or_constraint", "stock_flow_unit_confusion", "local_patch_ignoring_structural_refutations", "counterexample_scope_mismatch", "ungrounded_fabrication"];
18
+ export type OfflineBinaryAuditDefectCode = (typeof OFFLINE_BINARY_AUDIT_DEFECT_CODES)[number];
19
+ export type OfflineBinaryAuditItemNumber = 1 | 2 | 3 | 4 | 5 | 6 | 7;
20
+ export interface OfflineBinaryAuditItemDefinition {
21
+ readonly item_number: OfflineBinaryAuditItemNumber;
22
+ readonly code: OfflineBinaryAuditDefectCode;
23
+ readonly title: string;
24
+ readonly summary: string;
25
+ }
26
+ export declare const OFFLINE_BINARY_AUDIT_ITEMS: readonly OfflineBinaryAuditItemDefinition[];
27
+ /**
28
+ * PR-C Offline 7-Item Binary Audit Rubric (updated after Exp-07).
29
+ * Item 7 closes the Ungrounded Fabrication blind spot exposed when restricting
30
+ * an auditor strictly to 6 distortion rules with an Answer Wavering guard.
31
+ *
32
+ * Verbatim RFC-001 v2.0 contract (`schemas-and-prompts-v3.ts`).
33
+ */
34
+ export declare const OFFLINE_BINARY_AUDIT_RUBRIC_V1: string;
35
+ /**
36
+ * Unambiguous score polarity text embedded in BOTH LLM-as-a-Judge prompts and JSON Schemas
37
+ * to prevent polarity-flip scoring bugs.
38
+ */
39
+ export declare const OFFLINE_GRADED_SCORE_POLARITY_GUIDE: "\u30B9\u30B3\u30A2\u6975\u6027\uFF08\u53B3\u5B88\u30FB\u53CD\u8EE2\u7981\u6B62\uFF09: 1 = pass / \u6B6A\u307F\u306A\u3057, 0.5 = warn, 0 = fail / \u6B6A\u307F\u3042\u308A\uFF08higher_is_better: \u9AD8\u3044\u307B\u3069\u5065\u5168\uFF09\u3002";
40
+ export declare const OFFLINE_BINARY_VERDICT_POLARITY_GUIDE: "\u5224\u5B9A\u6975\u6027\uFF08\u53B3\u5B88\u30FB\u53CD\u8EE2\u7981\u6B62\uFF09: PASS = no defect (\u9805\u76EE1\u301C7\u306E\u660E\u78BA\u306A\u6B20\u9665\u306A\u3057 / \u6B6A\u307F\u306A\u3057 / score 1), FAIL = 1+ explicit defect among items 1\u20137 (\u9805\u76EE1\u301C7\u306E\u3046\u30611\u3064\u4EE5\u4E0A\u306E\u660E\u78BA\u306A\u6B20\u9665\u3042\u308A / \u6B6A\u307F\u3042\u308A / score 0)\u3002";
41
+ export type BinaryAuditVerdict = 'PASS' | 'FAIL';
42
+ export interface ProviderAuditVote {
43
+ readonly provider: 'gemini' | 'claude' | 'codex' | string;
44
+ readonly verdict: BinaryAuditVerdict;
45
+ readonly defect_summary: string;
46
+ readonly violated_items?: readonly OfflineBinaryAuditItemNumber[];
47
+ }
48
+ export interface PollJuryResult {
49
+ readonly verdict: BinaryAuditVerdict;
50
+ readonly fail_votes: number;
51
+ readonly total_votes: number;
52
+ readonly threshold: number;
53
+ readonly dissenting_providers: readonly string[];
54
+ }
55
+ export interface OfflineBinaryAuditJudgeOutput {
56
+ readonly verdict: BinaryAuditVerdict;
57
+ readonly violated_items: readonly OfflineBinaryAuditItemNumber[];
58
+ readonly defect_summary: string;
59
+ readonly evidence_quotes: readonly string[];
60
+ }
61
+ export interface OfflineBinaryAuditJudgePromptInput {
62
+ readonly userPrompt: string;
63
+ readonly draftResponse: string;
64
+ readonly confirmedContext?: string;
65
+ readonly sessionWorldModel?: SessionMiniWorldModelV2 | null;
66
+ readonly rubric?: string;
67
+ }
68
+ export interface GradedRubricPromptEntry {
69
+ readonly pattern: string;
70
+ readonly title: string;
71
+ readonly definition: string;
72
+ readonly pass_criteria: string;
73
+ readonly warn_criteria: string;
74
+ readonly fail_criteria: string;
75
+ readonly positive_anchor: string;
76
+ readonly negative_anchor: string;
77
+ }
78
+ export interface OfflineGradedDistortionJudgePromptInput {
79
+ readonly userPrompt: string;
80
+ readonly draftResponse: string;
81
+ readonly confirmedContext?: string;
82
+ readonly rubricEntries: Readonly<Record<string, GradedRubricPromptEntry>>;
83
+ }
84
+ export interface OfflineGradedPatternJudgeScore {
85
+ readonly status: 'pass' | 'warn' | 'fail' | 'not_applicable';
86
+ readonly score: 0 | 0.5 | 1;
87
+ readonly rationale: string;
88
+ }
89
+ export interface OfflineGradedDistortionJudgeOutput {
90
+ readonly overall_status: 'pass' | 'warn' | 'fail';
91
+ readonly overall_score: number;
92
+ readonly patterns: Readonly<Record<string, OfflineGradedPatternJudgeScore>>;
93
+ }
94
+ export interface OfflineBinaryAuditEvaluationInput {
95
+ readonly votes: readonly ProviderAuditVote[];
96
+ readonly failThreshold?: number;
97
+ readonly expectedVerdict?: BinaryAuditVerdict;
98
+ }
99
+ export interface OfflineBinaryAuditEvaluationResult {
100
+ readonly schema_version: typeof OFFLINE_BINARY_AUDIT_EVALUATION_SCHEMA_VERSION;
101
+ readonly rubric_version: typeof OFFLINE_BINARY_AUDIT_RUBRIC_VERSION;
102
+ readonly jury: PollJuryResult;
103
+ /** Explicit numeric polarity: 1 = pass / 歪みなし (PASS), 0 = fail / 歪みあり (FAIL). */
104
+ readonly pass_score: 0 | 1;
105
+ readonly fail_vote_ratio: number;
106
+ readonly unanimous: boolean;
107
+ readonly aggregated_violated_items: readonly OfflineBinaryAuditItemNumber[];
108
+ readonly defect_summaries: readonly {
109
+ readonly provider: string;
110
+ readonly defect_summary: string;
111
+ }[];
112
+ readonly expected_match?: boolean;
113
+ }
114
+ export interface JudgmentDAGBinaryAuditObservationOptions {
115
+ /**
116
+ * Optional node ID in the target Judgment DAG to also emit node-scoped
117
+ * observations so `evaluateJudgmentDAGVersions` can compute `node_calibration`.
118
+ */
119
+ readonly nodeId?: string;
120
+ /**
121
+ * Optional metric namespace prefix (defaults to `'offline_audit'`).
122
+ */
123
+ readonly metricPrefix?: string;
124
+ }
125
+ /**
126
+ * Structured JSON Schema for LLM-as-a-Judge 7-item binary audit verdicts.
127
+ * Embeds explicit verdict polarity (`PASS = no defect / FAIL = 1+ explicit defect among items 1–7`)
128
+ * directly in schema `description` fields to prevent polarity-flip bugs.
129
+ */
130
+ export declare const OFFLINE_BINARY_AUDIT_JUDGE_SCHEMA_V1: {
131
+ readonly $schema: "https://json-schema.org/draft/2020-12/schema";
132
+ readonly $id: "brainbase-offline-binary-audit-judge.v1";
133
+ readonly title: "Brainbase Offline 7-Item Binary Audit Verdict";
134
+ readonly description: "Structured verdict for Brainbase Offline Binary Audit Rubric v1 (7 items including Item 7: Ungrounded Fabrication). Polarity: PASS = no defect / FAIL = 1+ explicit defect among items 1–7 (numeric mapping: 1 = pass / 歪みなし, 0 = fail / 歪みあり).";
135
+ readonly type: "object";
136
+ readonly additionalProperties: false;
137
+ readonly required: readonly ["verdict", "violated_items", "defect_summary", "evidence_quotes"];
138
+ readonly properties: {
139
+ readonly verdict: {
140
+ readonly type: "string";
141
+ readonly enum: readonly ["PASS", "FAIL"];
142
+ readonly description: "Binary audit verdict polarity: PASS = no defect (項目1〜7の明確な欠陥なし / 歪みなし), FAIL = 1+ explicit defect among items 1–7 (項目1〜7のいずれかに明確な欠陥あり / 歪みあり).";
143
+ };
144
+ readonly violated_items: {
145
+ readonly type: "array";
146
+ readonly items: {
147
+ readonly type: "integer";
148
+ readonly minimum: 1;
149
+ readonly maximum: 7;
150
+ };
151
+ readonly uniqueItems: true;
152
+ readonly description: "Rubric item numbers violated (1–7, where 7 = Ungrounded Fabrication). Must be empty [] when verdict=\"PASS\", and non-empty when verdict=\"FAIL\".";
153
+ };
154
+ readonly defect_summary: {
155
+ readonly type: "string";
156
+ readonly description: "Concise 1–2 point defect summary citing violated item number(s) when verdict=\"FAIL\" (empty string when verdict=\"PASS\").";
157
+ };
158
+ readonly evidence_quotes: {
159
+ readonly type: "array";
160
+ readonly items: {
161
+ readonly type: "string";
162
+ };
163
+ readonly description: "Short verbatim excerpts or arithmetic contradictions from the draft/context grounding each defect when verdict=\"FAIL\" (empty [] when verdict=\"PASS\").";
164
+ };
165
+ };
166
+ };
167
+ /**
168
+ * Structured JSON Schema for graded LLM-as-a-Judge distortion scoring across the 5 canonical patterns.
169
+ * Explicitly states `1 = pass / 歪みなし, 0.5 = warn, 0 = fail / 歪みあり` in schema `description` fields.
170
+ */
171
+ export declare const OFFLINE_GRADED_DISTORTION_JUDGE_SCHEMA_V1: {
172
+ readonly $schema: "https://json-schema.org/draft/2020-12/schema";
173
+ readonly $id: "brainbase-offline-graded-distortion-judge.v1";
174
+ readonly title: "Brainbase Offline Graded Reasoning Distortion Audit";
175
+ readonly description: "Graded LLM-as-a-Judge scoring output for Brainbase reasoning distortion patterns. Score polarity (higher is better; never invert): 1 = pass / 歪みなし, 0.5 = warn, 0 = fail / 歪みあり.";
176
+ readonly type: "object";
177
+ readonly additionalProperties: false;
178
+ readonly required: readonly ["overall_status", "overall_score", "patterns"];
179
+ readonly properties: {
180
+ readonly overall_status: {
181
+ readonly type: "string";
182
+ readonly enum: readonly ["pass", "warn", "fail"];
183
+ readonly description: "Overall graded status derived from patterns and aligned with score polarity (1 = pass / 歪みなし, 0.5 = warn, 0 = fail / 歪みあり): pass requires overall_score = 1 with no warn/fail patterns; warn requires 0.5 <= overall_score < 1 with >=1 warn and no fail patterns; fail requires 0 <= overall_score < 1 with >=1 fail pattern.";
184
+ };
185
+ readonly overall_score: {
186
+ readonly type: "number";
187
+ readonly minimum: 0;
188
+ readonly maximum: 1;
189
+ readonly description: "Aggregate score across applicable patterns (strictly higher_is_better; never invert): 1 = pass / 歪みなし, 0.5 = warn, 0 = fail / 歪みあり (pass => 1, warn => [0.5, 1), fail => [0, 1)).";
190
+ };
191
+ readonly patterns: {
192
+ readonly type: "object";
193
+ readonly additionalProperties: false;
194
+ readonly required: readonly ["counterexample_scope_mismatch", "base_rate_neglect", "layer_conflation", "conclusion_lock_cherry_picking", "local_patch_without_model_update"];
195
+ readonly description: "Per-pattern graded assessments using polarity: 1 = pass / 歪みなし, 0.5 = warn, 0 = fail / 歪みあり.";
196
+ readonly properties: {
197
+ readonly counterexample_scope_mismatch: {
198
+ readonly type: "object";
199
+ readonly additionalProperties: false;
200
+ readonly required: readonly ["status", "score", "rationale"];
201
+ readonly description: `Graded assessment for distortion pattern "${string}". Score polarity (higher is better): 1 = pass / \u6B6A\u307F\u306A\u3057, 0.5 = warn, 0 = fail / \u6B6A\u307F\u3042\u308A.`;
202
+ readonly properties: {
203
+ readonly status: {
204
+ readonly type: "string";
205
+ readonly enum: readonly ["pass", "warn", "fail", "not_applicable"];
206
+ readonly description: "Pattern status aligned with score polarity: pass or not_applicable => score 1 (歪みなし), warn => score 0.5, fail => score 0 (歪みあり).";
207
+ };
208
+ readonly score: {
209
+ readonly type: "number";
210
+ readonly enum: readonly [0, 0.5, 1];
211
+ readonly description: "Score polarity (strictly higher_is_better; never invert): 1 = pass / 歪みなし, 0.5 = warn, 0 = fail / 歪みあり.";
212
+ };
213
+ readonly rationale: {
214
+ readonly type: "string";
215
+ readonly description: "Brief evidence-grounded justification for the assigned status and score.";
216
+ };
217
+ };
218
+ };
219
+ readonly base_rate_neglect: {
220
+ readonly type: "object";
221
+ readonly additionalProperties: false;
222
+ readonly required: readonly ["status", "score", "rationale"];
223
+ readonly description: `Graded assessment for distortion pattern "${string}". Score polarity (higher is better): 1 = pass / \u6B6A\u307F\u306A\u3057, 0.5 = warn, 0 = fail / \u6B6A\u307F\u3042\u308A.`;
224
+ readonly properties: {
225
+ readonly status: {
226
+ readonly type: "string";
227
+ readonly enum: readonly ["pass", "warn", "fail", "not_applicable"];
228
+ readonly description: "Pattern status aligned with score polarity: pass or not_applicable => score 1 (歪みなし), warn => score 0.5, fail => score 0 (歪みあり).";
229
+ };
230
+ readonly score: {
231
+ readonly type: "number";
232
+ readonly enum: readonly [0, 0.5, 1];
233
+ readonly description: "Score polarity (strictly higher_is_better; never invert): 1 = pass / 歪みなし, 0.5 = warn, 0 = fail / 歪みあり.";
234
+ };
235
+ readonly rationale: {
236
+ readonly type: "string";
237
+ readonly description: "Brief evidence-grounded justification for the assigned status and score.";
238
+ };
239
+ };
240
+ };
241
+ readonly layer_conflation: {
242
+ readonly type: "object";
243
+ readonly additionalProperties: false;
244
+ readonly required: readonly ["status", "score", "rationale"];
245
+ readonly description: `Graded assessment for distortion pattern "${string}". Score polarity (higher is better): 1 = pass / \u6B6A\u307F\u306A\u3057, 0.5 = warn, 0 = fail / \u6B6A\u307F\u3042\u308A.`;
246
+ readonly properties: {
247
+ readonly status: {
248
+ readonly type: "string";
249
+ readonly enum: readonly ["pass", "warn", "fail", "not_applicable"];
250
+ readonly description: "Pattern status aligned with score polarity: pass or not_applicable => score 1 (歪みなし), warn => score 0.5, fail => score 0 (歪みあり).";
251
+ };
252
+ readonly score: {
253
+ readonly type: "number";
254
+ readonly enum: readonly [0, 0.5, 1];
255
+ readonly description: "Score polarity (strictly higher_is_better; never invert): 1 = pass / 歪みなし, 0.5 = warn, 0 = fail / 歪みあり.";
256
+ };
257
+ readonly rationale: {
258
+ readonly type: "string";
259
+ readonly description: "Brief evidence-grounded justification for the assigned status and score.";
260
+ };
261
+ };
262
+ };
263
+ readonly conclusion_lock_cherry_picking: {
264
+ readonly type: "object";
265
+ readonly additionalProperties: false;
266
+ readonly required: readonly ["status", "score", "rationale"];
267
+ readonly description: `Graded assessment for distortion pattern "${string}". Score polarity (higher is better): 1 = pass / \u6B6A\u307F\u306A\u3057, 0.5 = warn, 0 = fail / \u6B6A\u307F\u3042\u308A.`;
268
+ readonly properties: {
269
+ readonly status: {
270
+ readonly type: "string";
271
+ readonly enum: readonly ["pass", "warn", "fail", "not_applicable"];
272
+ readonly description: "Pattern status aligned with score polarity: pass or not_applicable => score 1 (歪みなし), warn => score 0.5, fail => score 0 (歪みあり).";
273
+ };
274
+ readonly score: {
275
+ readonly type: "number";
276
+ readonly enum: readonly [0, 0.5, 1];
277
+ readonly description: "Score polarity (strictly higher_is_better; never invert): 1 = pass / 歪みなし, 0.5 = warn, 0 = fail / 歪みあり.";
278
+ };
279
+ readonly rationale: {
280
+ readonly type: "string";
281
+ readonly description: "Brief evidence-grounded justification for the assigned status and score.";
282
+ };
283
+ };
284
+ };
285
+ readonly local_patch_without_model_update: {
286
+ readonly type: "object";
287
+ readonly additionalProperties: false;
288
+ readonly required: readonly ["status", "score", "rationale"];
289
+ readonly description: `Graded assessment for distortion pattern "${string}". Score polarity (higher is better): 1 = pass / \u6B6A\u307F\u306A\u3057, 0.5 = warn, 0 = fail / \u6B6A\u307F\u3042\u308A.`;
290
+ readonly properties: {
291
+ readonly status: {
292
+ readonly type: "string";
293
+ readonly enum: readonly ["pass", "warn", "fail", "not_applicable"];
294
+ readonly description: "Pattern status aligned with score polarity: pass or not_applicable => score 1 (歪みなし), warn => score 0.5, fail => score 0 (歪みあり).";
295
+ };
296
+ readonly score: {
297
+ readonly type: "number";
298
+ readonly enum: readonly [0, 0.5, 1];
299
+ readonly description: "Score polarity (strictly higher_is_better; never invert): 1 = pass / 歪みなし, 0.5 = warn, 0 = fail / 歪みあり.";
300
+ };
301
+ readonly rationale: {
302
+ readonly type: "string";
303
+ readonly description: "Brief evidence-grounded justification for the assigned status and score.";
304
+ };
305
+ };
306
+ };
307
+ };
308
+ };
309
+ };
310
+ };
311
+ /**
312
+ * Build an offline LLM-as-a-Judge prompt for the 7-item binary audit gate.
313
+ * Uses independent external auditor framing and states binary verdict polarity
314
+ * (`PASS = no defect / FAIL = 1+ explicit defect among items 1–7`) explicitly in prompt text.
315
+ */
316
+ export declare function buildOfflineBinaryAuditJudgePrompt(input: OfflineBinaryAuditJudgePromptInput): string;
317
+ /**
318
+ * Build an offline LLM-as-a-Judge prompt for graded distortion rubric scoring.
319
+ * Explicitly states `1 = pass / 歪みなし, 0.5 = warn, 0 = fail / 歪みあり` in prompt text.
320
+ */
321
+ export declare function buildOfflineGradedDistortionJudgePrompt(input: OfflineGradedDistortionJudgePromptInput): string;
322
+ /**
323
+ * Validate and normalize a raw structured JSON output from an offline binary audit judge
324
+ * into a `ProviderAuditVote` while enforcing polarity and violated-item consistency.
325
+ */
326
+ export declare function parseBinaryAuditJudgeOutput(raw: unknown, provider: string): {
327
+ readonly output: OfflineBinaryAuditJudgeOutput;
328
+ readonly vote: ProviderAuditVote;
329
+ };
330
+ /**
331
+ * Validate a graded LLM-as-a-Judge response and reject polarity inversions
332
+ * (e.g. `status === 'pass'` scored as `0`, or `status === 'fail'` scored as `1`).
333
+ */
334
+ export declare function parseGradedDistortionJudgeOutput(raw: unknown): OfflineGradedDistortionJudgeOutput;
335
+ /**
336
+ * Cross-family PoLL majority aggregator (default 2-of-3).
337
+ * Neutralizes single-provider strictness bias (proven on Codex FPR 33.3% -> Jury FPR 0.0% in Exp-07).
338
+ *
339
+ * Matches `aggregatePollJuryVerdict()` in RFC-001 v2.0 (`schemas-and-prompts-v3.ts`).
340
+ */
341
+ export declare function aggregatePollJuryVerdict(votes: readonly ProviderAuditVote[], failThreshold?: number): PollJuryResult;
342
+ /**
343
+ * Evaluate a set of cross-family provider votes under `OFFLINE_BINARY_AUDIT_RUBRIC_V1`
344
+ * and return an immutable evaluation summary with explicit numeric score polarity
345
+ * (`pass_score: 1 = PASS / 歪みなし, 0 = FAIL / 歪みあり`).
346
+ */
347
+ export declare function evaluateOfflineBinaryAudit(input: OfflineBinaryAuditEvaluationInput): OfflineBinaryAuditEvaluationResult;
348
+ /**
349
+ * Convert a `PollJuryResult` or `OfflineBinaryAuditEvaluationResult` into
350
+ * `JudgmentDAGOutcomeObservation[]` consumable directly by
351
+ * `createJudgmentDAGOutcomeAttachment` and `evaluateJudgmentDAGVersions`
352
+ * in `src/judgment-dag-replay-evaluation.ts`.
353
+ *
354
+ * Emits higher-is-better polarity metrics:
355
+ * - `<prefix>.binary_pass` (`boolean`: `true` when `verdict === 'PASS'`)
356
+ * - `<prefix>.binary_score` (`number`: `1` = PASS / 歪みなし, `0` = FAIL / 歪みあり)
357
+ * - `<prefix>.poll_pass_vote_ratio` (`number`: fraction of PASS votes in `[0, 1]`)
358
+ * - `<prefix>.poll_agreement_ratio` (`number`: fraction of votes matching jury verdict in `[0, 1]`)
359
+ */
360
+ export declare function toJudgmentDAGBinaryAuditObservations(result: PollJuryResult | OfflineBinaryAuditEvaluationResult, options?: JudgmentDAGBinaryAuditObservationOptions): readonly JudgmentDAGOutcomeObservation[];