This document defines semantic responsibilities and API philosophy. Phase 1 introduces documented shells for this vocabulary; their presence does not implement the later-phase behavior described here or freeze pre-1.0 signatures.
- Use immutable value types for proposals, definitions, contexts, decisions, challenges, authorizations, and audit events.
- Require
Sendablefor values crossing concurrency boundaries. - Use closed enums for security-critical outcomes and reject unknown decoded cases.
- Use actors only to isolate genuinely shared mutable state; keep deterministic evaluation pure where possible.
- Make invalid, missing, expired, and unverifiable states explicit; do not encode them as permissive defaults.
- Avoid singleton registries, process-wide mutable policy, hidden clocks, and other global state.
- Compose narrow protocols and initializers; do not introduce a dependency injection framework.
- Use typed identifiers rather than interchangeable strings for security-relevant identities.
- Provide documentation and pseudo-code or compilable examples for every public API as it is introduced.
- Keep platform APIs out of the core module and behind adapter protocols.
An immutable, versioned declaration registered by an authorized host path. It identifies one exact tool/version and owns its complete immutable schema, lifecycle, maximum capabilities, and typed metadata. It contains no parser, executable closure, endpoint, or implicit authority. Later authorization binds the exact definition and snapshot.
An untrusted request to use a named/versioned tool with a closed host-parsed StructuredObject and declared provenance references. Creation is not schema validation. A proposal cannot carry authenticated identity, approval, or capabilities that the host has not supplied.
A host-originated, authenticated binding between a subject and an intended action scope. It records identity, freshness, scope/constraints, context reference, and an identifier suitable for decision binding. It is not authoritative when constructed from model output or unauthenticated text.
An immutable artifact representing narrowly scoped permission issued from one successful policy path. It binds the subject, tool/definition version, canonical arguments, capabilities, intent, policy/decision, confirmation when applicable, issuance/expiry, and single-use/idempotency identity. Possession alone is insufficient if verification or atomic consumption fails.
A safe-to-display, expiring request for host-mediated confirmation. It binds the canonical request, subject, decision, risk/capability summary, and challenge identity. Display content is derived from validated fields and cannot replace the underlying canonical binding. A response to one challenge is invalid for any changed request.
An immutable, privacy-minimized record of a security transition: input acceptance/rejection, decision, challenge, authorization issuance, verification, consumption, or denial. It includes ordering/correlation data and tamper-evidence links but excludes secrets and raw prompts by default.
The deterministic result of evaluating one versioned policy against one complete immutable input set. Its outcome is deny, require confirmation, or allow; it also carries stable reason codes, policy/version identity, granted/required capabilities, obligations, and input commitments. It is evidence for authorization issuance, not itself an execution token.
Structured origin and custody information for a proposal, argument, intent fact, or influence. It expresses source class, issuer, verification state, transformations, and references without converting claims into trust. Missing or unverifiable provenance is untrusted.
Evidence that content or a system may have shaped a proposal, such as retrieved text, tool output, memory, or another model. It enables policy to deny or escalate indirect prompt paths even when the influenced material is absent from final arguments.
A typed, versioned description of a privilege category or protected effect, optionally with normalized constraints. Requested/granted capability sets cannot exceed the registered definition, authenticated host authority, user intent, or policy. Unknown capabilities deny.
A closed, ordered only where explicitly specified classification of evidence or sources. It must not imply that trusted transport makes content trusted. Unknown values fail closed; no caller can create a higher class from model claims.
A host-attested snapshot of authenticated subject, tenant, session, delegated authority, assurance, environment, and security-relevant constraints. It contains references rather than secrets and has explicit freshness/version semantics. Model output cannot construct or mutate it authoritatively.
- CanonicalRequest: validated exact tool definition, complete schema, canonical arguments, reviewed argument-derived resources, and all applicable version bindings.
- EvaluationInput: complete immutable bundle of canonical request, host authority, intent, provenance/influence, security context, registry/policy bindings, and explicit host-supplied comparison time.
- DecisionReason: stable machine-readable reason code plus safe diagnostics; free text is never an authorization input.
- ConfirmationResponse: host-attested response bound to an exact challenge and authenticated subject.
- ConsumptionReceipt: future host evidence that one authorization was atomically consumed; Phase 6 deliberately defines no receipt or consumption operation.
- IdempotencyKey: identity of one logical operation, distinct from a model-supplied retry label.
ToolIDaccepts exact lowercase ASCII namespace syntax and never normalizes external input.ToolVersionis a canonical positive integer generation used only for exact binding.ToolDefinitionIDidentifies one immutable registered definition independently from tool/version identity.ToolRegistryDraftaccumulates definitions with value semantics and publishes only complete sets.ToolRegistrySnapshotexposes deterministic ordered definitions and exact lookup from immutable state.ToolDefinitionReferencebinds snapshot ID/version and the complete immutable definition value; it is an in-memory structural binding, not canonical serialization, a cryptographic commitment, or authorization.ToolLookupResultis constructible only by the snapshot and records resolution, not permission.ToolRegistryErrorexposes stable reasons and safe field/limit categories without raw rejected content.ToolLifecycleStateexplicitly distinguishes active, deprecated, and retired definitions.ToolSecurityMetadatais security-relevant classification;ToolDisplayMetadataandToolDescriptiveMetadataare non-authoritative.Capabilitydescribes a definition's maximum effect categories only. Phase 2 performs no authorization intersection.
The publication API deliberately accepts no ToolProposal, authentication claim, model output wrapper, clock, random source, persistence service, callback, endpoint, or executor. Calling publication is authority-sensitive host orchestration outside the core's ability to authenticate.
The public surface should make the safe path natural:
- The host parses untrusted bytes without coercion and preserves duplicate field occurrences in an unvalidated proposal.
- Validation against a registry snapshot produces a canonical request or a typed rejection.
- Evaluation requires all authenticated and provenance inputs explicitly.
- A policy decision can be audited but cannot be passed directly to an executor.
- Phase 6 authorization issuance accepts only eligible allow decisions and rejects confirmation or other obligations it cannot prove satisfied.
- Host structural validation requires exact expectations; future consumption and execution remain separate and outside this API.
The API must not expose convenience initializers that synthesize trusted provenance, authenticated intent, allow decisions, or non-expiring/reusable authorization.
SchemaID,SchemaVersion, andSchemaReferenceidentify one exact schema contract.CanonicalizationVersionis separate and has no inferred compatibility with schema versions.FieldNameandEnumCaseNameare restricted exact lowercase ASCII values. Construction never trims, folds case, normalizes, or repairs.FieldRequirementmakes required versus optional presence explicit. Optional absence supplies no default; null is never accepted.FieldKindis a finite inline closed vocabulary: ordinary string, reviewed resource identifier, Boolean, signedInt64, unsignedUInt64, closed enum, ordered array, and closed object.StructuredObjectuses[StructuredField], not a dictionary, to preserve duplicate occurrences for rejection.StructuredValuecontains typed host-parsed values and has no parser or coercion API.SchemaDefinitionvalidates maximum depth and schema-node bounds at construction.ObjectSchemaandEnumSchemareject duplicates and establish exact ordering.SchemaValidator.canonicalRequestaccepts only a non-publicly constructibleToolLookupResult, an exact matching schema, the exactToolProposal, and an understood canonicalization version. Proposal tool/version must match the lookup before argument validation.SchemaValidationErrorcontains a stable reason, optional safe schema-derived path, and optional public limit. It never echoes rejected input.CanonicalRequesthas no public initializer, retains the exact snapshot-bound definition and schema plus resources derived only fromresourceIDnodes, and exposes no canonical field collection. ItscanonicalBytes()method returns an independent copy of its opaque deterministic representation.
All Phase 3 types are immutable Sendable values. No actor is needed because schema construction, validation, and canonicalization have no shared mutable state.
- Raw claims (
HostAuthorityClaim,HostAttestationClaim,SecurityContextClaim,UserIntentClaim,ProvenanceClaim,InfluenceClaim, andInfluenceCollectionClaim) are public immutable data and never trusted merely because they were constructed. HostAuthority,ValidatedHostAttestation,SecurityContext,UserIntentEnvelope, validated provenance/influence values, andEvaluationInputexpose no public initializer. Narrow validators construct them after exact structural checks.HostAuthorityValidatorandHostAttestationValidatorare authority-sensitive host integration APIs requiring the independently retainedHostCapabilityBoundary. They implement no signature or caller authentication; applications must prevent model-controlled code from obtaining that boundary.ValidityWindowuses explicit boundedEpochSeconds, inclusive not-before, and exclusive expiry. Every validation API requires explicit evaluation time.IntentTargetis closed to an exact canonical request or an exact snapshot-bound definition. Intended capability scopes are nonempty; resource scopes may be exactly empty only for a genuinely resource-free request, bounded, sorted upper bounds—not grants.SecurityContextcontains closed unordered assurance and authentication-method classifications plus an optional separately attested delegation reference.ValidatedProvenanceSetmakes missing coverage unknown.hostVerifiedverifies a provenance record, not arbitrary content semantics, and is blocked by unsupported transformations.ValidatedInfluenceSetstores bounded acyclic relationships and separate collection results. Validated complete status is constructible only with an exact collector attestation.EvaluationInputValidatorperforms exact identity, request, scope, renewal, freshness, and lineage compatibility checks and returns no partial value.EvaluationInputhas no decision or execution API.
All Phase 4 collections have public deterministic limits and output ordering. No actor is required because every transformation is pure over explicit values. The complete example is in Examples/PHASE_4.md.
PolicyID,PolicyVersion,PolicySnapshotID,PolicySnapshotVersion,PolicyRuleID, andDecisionIDare exact bounded values.PolicyConditionis closed to unorderedall,any, and typed predicates;PolicyRulevalidates and normalizes the full bounded tree.PolicyScopeConstraintis an exact ceiling. Empty means none, not unrestricted.PolicyDefinitionsorts unique rules.PolicyDraftpublishes immutable exact snapshots bound to the host capability boundary;lookuprequires ID and version and rejects retired policy.PolicyEvaluator.evaluateis a pure namespace operation over explicit values. It evaluates all rules and constructs the only evaluatedPolicyDecision.PolicyDecisionhas no public initializer. Its.allowoutcome is evidence for possible Phase 6 processing, not an authorization or executable capability.
Every Phase 5 collection is bounded and deterministically ordered. No actor is needed because evaluation and publication are value transformations with no shared mutable state. See Examples/PHASE_5.md.
AuthorizationID, replay/consumption identities, versions, and generations are small validated immutable values.Authorizationand every authority-bearing subvalue expose onlyletproperties and no public initializer.AuthorizationIssuer.issueis the only construction path.- Issuance accepts complete concrete Phase 4/5 values rather than protocols, closures, service locators, or hidden global state.
AuthorizationScopeClaimandAuthorizationLifetimeExpectationare explicitly non-authoritative host expectations. Constructing either grants nothing.AuthorizationValidationContextis intentionally verbose: every security expectation is visible at the call site and exact equality is the contract.AuthorizationValidator.validaterequires explicitEpochSecondsand returns an immutableAuthorizationValidationResult; it does not consume or persist.AuthorizationErrorcontains only stable closed reasons, safe field categories, and public limits. It never returns raw arguments or rejected identifiers.
No actor is used because issuance and validation are pure deterministic value transformations. A future atomic consumption facility would own mutable isolation outside this Phase 6 API. See Examples/PHASE_6.md.
Security failures should be typed and stable enough for policy, tests, and audit correlation. Public diagnostics must separate safe operator detail from user-facing messages and secret/raw input. Error recovery must require an explicit new evaluation when any bound input changes.
Security-critical encodings, schemas, identifiers, policies, and artifacts require explicit versions. Forward compatibility does not mean accepting unknown fields or enums: a consumer that does not understand a version rejects it. Additive changes require a new understood schema/version or a field explicitly designated as non-security-relevant by the contract.
HostCapabilityBoundaryis a reference-identity capability retained by the host; authoritative values expose no method to recover it.HostAuthorityScopeis an immutable upper bound with nonempty capabilities and exact resources (including exact empty resource authority), never a default or grant.ToolDefinitionrequires complete schema content. Identifier-only construction is unavailable.FieldKind.resourceIDis the reviewed resource-binding vocabulary. There is no generic key path, closure, parser hook, or caller-defined extractor.- Issuance and validation require the independently retained host boundary. Convenience overloads that derive it from an artifact are prohibited.
- Collection-valued policy predicates reject empty operands at construction.
ProposalAssessmentClaim,ProposalAssessmentReference, and its validator provide privacy-safe boundary-local continuity.- Phase 3 and Phase 4 validators require the independently retained boundary and exact assessment at each handoff.
HostAttestationValidatorcomposes role-specific authorities sharing one exact domain and ceiling; policy publication requires a policy administrator.PolicyEvaluator.evaluateindependently requires the boundary, and decision binding retains complete exact snapshot and policy content.AuthorizationIssuer.issuerequires explicitissuedAt.AuthorizationValidationContextrequires an independently sourced expectedauthorizationID.- Validation returns a complete non-consuming
AuthorizationConsumptionBinding. .maximumEvaluationAgeSecondsreplaces the ambiguous pre-1.0 freshness case.
Strong private boundary references are compared by === and cannot be recovered
through public API. Custom Hashable implementations omit address-like boundary
identity while equality still checks it; hash collisions imply neither equality
nor authority.