Evidence Gate
@knolo/evidence-gate@0.1.0 evaluates structured answer claims against a verified V5 Knowledge Image. It returns a deterministic decision for every claim, preserves conflicts, and emits a certificate root that can be checked offline.
The gate verifies provenance and policy. It does not use a model to decide whether prose is true. The host extracts claims and declares the evidence relations it wants checked. The package depends on @knolo/core ^6.0.0. It does not implement composition, and it does not change V5 container bytes, roots, or receipt contracts.
import { evaluateEvidenceGateV1, verifyEvidenceGateV1 } from '@knolo/evidence-gate';
const result = evaluateEvidenceGateV1({
image,
principal: 'support-agent',
policy: {
knowledge: { version: 1, default: 'allow' },
onConflict: 'contested',
requireEvidenceFor: ['fact', 'instruction', 'calculation'],
},
claims: [
{
id: 'refund-window',
text: 'Refunds are available within 30 days.',
modality: 'fact',
evidence: [{ objectId, sourceDigest, start: 0, end: 34, relation: 'supports' }],
},
],
});
verifyEvidenceGateV1(result, { /* the same request */ });evidence-gate check --image knowledge.v5 --request request.json --out result.json
evidence-gate explain --image knowledge.v5 --request request.json --result result.jsonThe request JSON contains principal, policy, and claims. The image is passed separately so the CLI can verify its bytes.
Evidence Gate is claim-level support, conflict, and abstention. KAR is a minimum evidence set under a plan. They are different packages. A gate certificate is not a KAR SATISFIED result.