Documentation
¶
Overview ¶
Package policy contains graph-native control policies that translate typed observations and state into explicit activation decisions. A policy never owns model routing implicitly: developers instantiate and connect one policy node for each model activation path they want.
Index ¶
- Constants
- Variables
- func AdmittedTemporalEvidenceType() element.Type
- func AuthorityCandidateType() element.Type
- func Descriptors() []element.Descriptor
- func FactoryRegistrations() ([]graphruntime.FactoryRegistration, error)
- func GenerateOnObservationDescriptor() element.Descriptor
- func GenerationCancelType() element.Type
- func GenerationOutcomeType() element.Type
- func GenerationStateType() element.Type
- func IntentDispositionProducerDescriptor() element.Descriptor
- func IntentDispositionProducerOutcomeType() element.Type
- func IntentDispositionProducerResolutionType() element.Type
- func IntentDispositionProducerStateType() element.Type
- func IntentDispositionRetryDescriptor() element.Descriptor
- func IntentDispositionRetryExhaustedType() element.Type
- func IntentDispositionRetryOutcomeType() element.Type
- func IntentDispositionRetryStateType() element.Type
- func IntentDispositionType() element.Type
- func IntentSettlementAcknowledgementType() element.Type
- func IntentSettlementCancelType() element.Type
- func IntentSettlementCleanupType() element.Type
- func IntentSettlementDecisionType() element.Type
- func IntentSettlementDescriptor() element.Descriptor
- func IntentSettlementOutcomeType() element.Type
- func IntentSettlementProbeType() element.Type
- func IntentSettlementResetType() element.Type
- func IntentSettlementStateType() element.Type
- func ObservationInvocationDescriptor() element.Descriptor
- func RegisterDescriptors(catalog *resolve.Catalog) error
- func RegisterFactories(registry *graphruntime.Registry) error
- func ResponseCreateType() element.Type
- func SemanticAdmissionDescriptor() element.Descriptor
- func SemanticAdmissionOutcomeType() element.Type
- func SemanticAdmissionStateType() element.Type
- func SemanticDeciderResolutionType() element.Type
- func SemanticDecisionType() element.Type
- func SemanticGrantType() element.Type
- func SessionInvocationDescriptor() element.Descriptor
- func SessionInvocationOutcomeType() element.Type
- func SessionInvocationStateType() element.Type
- func SessionInvocationUpdateType() element.Type
- func TemporalEvidenceAdmissionDescriptor() element.Descriptor
- func TemporalEvidenceOutcomeType() element.Type
- func ValidateTemporalEvidenceAdmissionConfig(config TemporalEvidenceAdmissionConfig) error
- func VerifyAdmittedTemporalEvidence(snapshot trajectory.Snapshot, admission AdmittedTemporalEvidence, ...) error
- func VerifyIntentSettlementCancellation(snapshot trajectory.Snapshot, cancellation IntentSettlementCancellation) error
- func VerifyIntentSettlementCleanup(snapshot trajectory.Snapshot, envelope element.Envelope, ...) error
- func VerifyIntentSettlementDecision(snapshot trajectory.Snapshot, decision IntentSettlementDecision, ...) error
- func VerifyIntentSettlementProbe(snapshot trajectory.Snapshot, probe IntentSettlementProbe, ...) error
- func VerifyIntentSettlementReset(snapshot trajectory.Snapshot, reset IntentSettlementAddress) error
- type AdmittedTemporalEvidence
- type GenerateOnObservationConfig
- type GenerationCancel
- type GenerationOutcome
- type GenerationOutcomeKind
- type GenerationState
- type IntentDetectorIdentity
- type IntentDisposition
- type IntentDispositionKind
- type IntentDispositionProducerConfig
- type IntentDispositionProducerOutcome
- type IntentDispositionProducerOutcomeKind
- type IntentDispositionProducerResolution
- type IntentDispositionProducerState
- type IntentDispositionRetryConfig
- type IntentDispositionRetryExhaustion
- type IntentDispositionRetryOutcome
- type IntentDispositionRetryOutcomeKind
- type IntentDispositionRetryState
- type IntentSettlementAcknowledgement
- type IntentSettlementAddress
- type IntentSettlementCancellation
- type IntentSettlementCleanup
- type IntentSettlementConfig
- type IntentSettlementDecision
- type IntentSettlementDecisionKind
- type IntentSettlementOutcome
- type IntentSettlementOutcomeKind
- type IntentSettlementProbe
- type IntentSettlementResultIdentity
- type IntentSettlementState
- type ObservationInvocationConfig
- type ResponseCreate
- type ResponseCreatePurpose
- type SemanticAdmissionConfig
- type SemanticAdmissionOutcome
- type SemanticAdmissionOutcomeKind
- type SemanticAdmissionState
- type SemanticDecider
- type SemanticDeciderDescriptor
- type SemanticDeciderFactory
- type SemanticDeciderRegistry
- func (registry *SemanticDeciderRegistry) Describe(reference string) (SemanticDeciderDescriptor, error)
- func (registry *SemanticDeciderRegistry) Open(reference string) (SemanticDecider, SemanticDeciderDescriptor, error)
- func (registry *SemanticDeciderRegistry) Register(reference string, descriptor SemanticDeciderDescriptor, ...) error
- type SemanticDeciderResolution
- type SemanticDecision
- type SemanticGrant
- type SessionInvocationConfig
- type SessionInvocationOutcome
- type SessionInvocationOutcomeKind
- type SessionInvocationState
- type SessionInvocationUpdate
- type StandingReport
- type TemporalEvidenceAdmissionConfig
- type TemporalEvidenceAdmissionMode
- type TemporalEvidenceAdmissionOutcome
- type TemporalEvidenceAdmissionOutcomeKind
- type TemporalEvidenceItemIdentity
- type TemporalEvidenceRequirement
- type TemporalEvidenceSourceSet
Constants ¶
const ( // IntentDispositionRetrySchedulerService lets deterministic simulations // drive the same graph-visible retry deadlines as production. A mount that // does not provide it receives a lifecycle-owned system scheduler. IntentDispositionRetrySchedulerService = "policy.intent-disposition-retry.scheduler" )
const ( // SemanticDeciderRegistryService is the mount-scoped provider registry used // by SemanticAdmission. A graph selects one symbolic reference; endpoint, // credential, client, and model construction remain provider-plugin state. SemanticDeciderRegistryService = "policy.semantic.deciders" )
Variables ¶
var ErrAdmittedTemporalEvidenceSuperseded = errors.New(
"admitted temporal evidence was superseded by later user evidence",
)
ErrAdmittedTemporalEvidenceSuperseded means the admission was valid for its immutable prefix, but a later user-authority observation now supersedes its durable intent in the current snapshot. Callers may safely discard retained work carrying this error without treating the canonical store as corrupt.
Functions ¶
func AuthorityCandidateType ¶
func Descriptors ¶
func Descriptors() []element.Descriptor
func FactoryRegistrations ¶
func FactoryRegistrations() ([]graphruntime.FactoryRegistration, error)
func GenerateOnObservationDescriptor ¶
func GenerateOnObservationDescriptor() element.Descriptor
GenerateOnObservationDescriptor turns one successful observation commit into one model activation. The commit outcome carries the store-attested identity of the exact trajectory prefix containing the observation, so the policy never joins against or retains a second trajectory State payload.
func GenerationCancelType ¶
func GenerationOutcomeType ¶
func GenerationStateType ¶
func IntentDispositionProducerDescriptor ¶
func IntentDispositionProducerDescriptor() element.Descriptor
IntentDispositionProducerDescriptor is the reference semantic/vision classifier for IntentSettlement probes. It is deliberately a separate node from both continuation and settlement: an application-authoritative node may replace it by producing the same IntentDisposition type, while this node owns an independently selected narrow Decider client and lifecycle.
func IntentDispositionRetryDescriptor ¶
func IntentDispositionRetryDescriptor() element.Descriptor
IntentDispositionRetryDescriptor is an explicit graph-owned retry policy for an indeterminate settlement classification. It forwards the first immutable probe immediately and can replay only that exact envelope after a bounded, inspectable delay. It never classifies evidence and never changes the probe. A developer can omit or replace this node without changing either the settlement gate or the disposition producer.
func IntentDispositionType ¶
func IntentSettlementDescriptor ¶
func IntentSettlementDescriptor() element.Descriptor
IntentSettlementDescriptor gates post-effect observation evidence until an independently connected, deployment-selected detector classifies the exact resulting state. It does not infer task completion from a successful tool call, visual quiet, or the absence of another model proposal.
func ObservationInvocationDescriptor ¶
func ObservationInvocationDescriptor() element.Descriptor
ObservationInvocationDescriptor owns settings and response creation for committed participant content. Unlike SessionInvocation, it accepts ordinary observation commits and confers no semantic decision or speech-over authority. GenerateOnCommit selects automatic activation in the values plane; the default records the committed context and waits for an explicit response.create.
func RegisterDescriptors ¶
func RegisterFactories ¶
func RegisterFactories(registry *graphruntime.Registry) error
func ResponseCreateType ¶
func SemanticAdmissionDescriptor ¶
func SemanticAdmissionDescriptor() element.Descriptor
SemanticAdmissionDescriptor is a policy gate between canonical observation commit and model activation. It emits the original typed commit/create only on the voice or silent branch selected by an enumerated semantic act. The decision and outcome are separately inspectable; suppression is never represented as a missing or successful generation.
func SemanticDecisionType ¶
func SemanticGrantType ¶
func SessionInvocationDescriptor ¶
func SessionInvocationDescriptor() element.Descriptor
SessionInvocationDescriptor is the graph-owned session configuration and activation boundary. Transport adapters translate authenticated session updates into Update events; the element snapshots those settings and is the only component allowed to place them in cognition.Generate.
Observation commits carry an exact canonical prefix and therefore produce authority-bearing activations. Explicit response creation is also visible and carries no observation authority, but its transport-supplied context binding prevents the model from sampling a stale trajectory snapshot.
func TemporalEvidenceAdmissionDescriptor ¶
func TemporalEvidenceAdmissionDescriptor() element.Descriptor
TemporalEvidenceAdmissionDescriptor is a reusable causal-evidence gate. It consumes only store-attested observation commit outcomes and revalidates the named prefix against the mounted canonical store before admitting anything.
func ValidateTemporalEvidenceAdmissionConfig ¶
func ValidateTemporalEvidenceAdmissionConfig(config TemporalEvidenceAdmissionConfig) error
ValidateTemporalEvidenceAdmissionConfig validates the values-plane contract a consumer expects from a connected temporal-admission policy. Consumers must pin this expectation independently; an admission payload cannot prove which explicit observer/source set the graph author configured upstream.
func VerifyAdmittedTemporalEvidence ¶
func VerifyAdmittedTemporalEvidence( snapshot trajectory.Snapshot, admission AdmittedTemporalEvidence, expected TemporalEvidenceAdmissionConfig, ) error
VerifyAdmittedTemporalEvidence verifies that admission is a faithful, content-free description of evidence in snapshot. Consumers should call it at their trust boundary instead of trusting identities copied through a typed graph port: it re-proves the canonical prefix and trigger, durable intent, causal freshness, distinct qualifying pairs, and the complete source set selected by expected. Requiring the independently pinned expectation is what prevents a forged payload from downgrading the mode or replacing an explicitly configured observer/source cohort.
func VerifyIntentSettlementCancellation ¶
func VerifyIntentSettlementCancellation( snapshot trajectory.Snapshot, cancellation IntentSettlementCancellation, ) error
VerifyIntentSettlementCancellation proves that an exact cancellation names canonical final user authority. It intentionally permits an older intent: cancellation can race a newer intent, but the complete identity prevents it from revoking that newer epoch.
func VerifyIntentSettlementCleanup ¶
func VerifyIntentSettlementCleanup( snapshot trajectory.Snapshot, envelope element.Envelope, cleanup IntentSettlementCleanup, expected IntentSettlementConfig, ) error
VerifyIntentSettlementCleanup proves that a cleanup control carries one exact canceled intent, the exact admitted result consequence that triggered cleanup, and payload-bound causal identities for the evidence and cancellation inputs. It does not attest that those source envelopes were delivered on a particular graph edge; graph wiring supplies that authority, while a consumer must independently match the control to its local canceled state. The typed control authorizes bounded bookkeeping retirement only; it does not authorize cognition or terminal disposition.
func VerifyIntentSettlementDecision ¶
func VerifyIntentSettlementDecision( snapshot trajectory.Snapshot, decision IntentSettlementDecision, expected IntentSettlementConfig, ) error
VerifyIntentSettlementDecision independently proves a gate-to-activation terminal control. It verifies the immutable historical prefix even when a newer user intent has since been appended; the consumer must additionally require the decision's invocation/call/intent to match its own active state.
func VerifyIntentSettlementProbe ¶
func VerifyIntentSettlementProbe( snapshot trajectory.Snapshot, probe IntentSettlementProbe, expected IntentSettlementConfig, ) error
VerifyIntentSettlementProbe independently proves that a probe is the exact, canonical classification request selected by contract. A disposition producer should call this against the current store snapshot before resolving media or invoking a model; graph typing alone does not make a payload trusted.
func VerifyIntentSettlementReset ¶
func VerifyIntentSettlementReset( snapshot trajectory.Snapshot, reset IntentSettlementAddress, ) error
VerifyIntentSettlementReset proves that a reset names one canonical durable user-intent epoch. Authorization to emit it remains a graph-edge decision; this verifier makes the terminal witness independently checkable.
Types ¶
type AdmittedTemporalEvidence ¶
type AdmittedTemporalEvidence struct {
Mode TemporalEvidenceAdmissionMode `json:"mode"`
SourceSet TemporalEvidenceSourceSet `json:"source_set,omitempty"`
TriggerCommit stateelements.ObservationCommitOutcome `json:"trigger_commit"`
TriggerObservation TemporalEvidenceItemIdentity `json:"trigger_observation"`
DurableIntent *TemporalEvidenceItemIdentity `json:"durable_intent,omitempty"`
QualifyingObservations []TemporalEvidenceItemIdentity `json:"qualifying_observations,omitempty"`
Prefix trajectory.PrefixIdentity `json:"prefix"`
}
AdmittedTemporalEvidence binds a validated trigger commit to the exact prefix inspected by the policy. After-intent admissions additionally name the selected durable user intent and one distinct qualifying observation for every frozen requirement. The payload contains identities, never observed text or media bytes.
type GenerateOnObservationConfig ¶
type GenerateOnObservationConfig struct {
Role string `json:"role"`
Invocation continuation.Invocation `json:"invocation"`
// MaxPending is deprecated and ignored by descriptor revision 3. It remains
// accepted, with its historical validation bound, so existing values files
// do not fail merely because activation no longer has a pending context join.
MaxPending int `json:"max_pending,omitempty"`
TerminalMemory int `json:"terminal_memory,omitempty"`
CancelMemory int `json:"cancel_memory,omitempty"`
}
GenerateOnObservationConfig is a values-plane activation template. Role distinguishes independently connected fast, deliberative, or specialist nodes. SourceRevision and ExpectedContextVersion are derived from live commit evidence and therefore cannot be authored here.
type GenerationCancel ¶
type GenerationCancel struct {
GenerationID string `json:"generation_id,omitempty"`
// StreamID cancels every revision of this exact stream in the addressed
// session while its bounded cancellation record is retained. A new request
// uses a new stream identity; one matching revision does not consume this
// cancellation. GenerationID instead addresses only one model activation.
StreamID string `json:"stream_id,omitempty"`
Reason string `json:"reason,omitempty"`
// DurableIntent optionally narrows cancellation to one exact canonical
// user-authority epoch. Generic generation policies may ignore it, but a
// policy that retains durable intent across several observations must
// independently verify this identity before clearing state. The pointer
// preserves the historical stream/generation-addressed wire shape for
// policies that do not opt into durable-intent coordination.
DurableIntent *TemporalEvidenceItemIdentity `json:"durable_intent,omitempty"`
}
type GenerationOutcome ¶
type GenerationOutcome struct {
Kind GenerationOutcomeKind `json:"kind"`
GenerationID string `json:"generation_id,omitempty"`
Role string `json:"role"`
StreamID string `json:"stream_id,omitempty"`
SourceRevision uint64 `json:"source_revision,omitempty"`
ContextVersion uint64 `json:"context_version,omitempty"`
TriggerItemID string `json:"trigger_item_id,omitempty"`
Code string `json:"code,omitempty"`
Message string `json:"message,omitempty"`
FinishedNS uint64 `json:"finished_ns,omitempty"`
}
func (GenerationOutcome) InspectionCause ¶
func (GenerationOutcome) InspectionCause() element.InspectionCauseKind
type GenerationOutcomeKind ¶
type GenerationOutcomeKind string
const ( GenerationEmitted GenerationOutcomeKind = "emitted" GenerationCanceled GenerationOutcomeKind = "canceled" GenerationRefused GenerationOutcomeKind = "refused" GenerationIgnored GenerationOutcomeKind = "ignored" )
type GenerationState ¶
type GenerationState struct {
Role string `json:"role"`
ContextVersion uint64 `json:"context_version"`
Emitted uint64 `json:"emitted"`
Canceled uint64 `json:"canceled"`
Refused uint64 `json:"refused"`
Ignored uint64 `json:"ignored"`
TerminalMemory int `json:"terminal_memory"`
CancellationMemory int `json:"cancellation_memory"`
}
func (GenerationState) InspectionCause ¶
func (GenerationState) InspectionCause() element.InspectionCauseKind
type IntentDetectorIdentity ¶
type IntentDetectorIdentity struct {
Reference string `json:"reference"`
Revision string `json:"revision"`
ConfigurationDigest string `json:"configuration_digest"`
}
IntentDetectorIdentity pins the exact replaceable producer authorized to classify settlement probes. Reference identifies the graph/application registration, while Revision and ConfigurationDigest bind its behavior. Credentials and provider-specific settings remain outside the payload.
type IntentDisposition ¶
type IntentDisposition struct {
Probe IntentSettlementProbe `json:"probe"`
Detector IntentDetectorIdentity `json:"detector"`
Kind IntentDispositionKind `json:"kind"`
DecisionStartedNS uint64 `json:"decision_started_ns"`
DecisionFinishedNS uint64 `json:"decision_finished_ns"`
}
IntentDisposition is the only input that can make an intent terminal. The exact echoed Probe prevents a typed but stale or cross-result classification from settling different work. Decision times are retained for replay and must be positive, ordered, and no earlier than the probe.
type IntentDispositionKind ¶
type IntentDispositionKind string
const ( IntentDispositionContinue IntentDispositionKind = "continue" IntentDispositionSucceeded IntentDispositionKind = "succeeded" IntentDispositionFailed IntentDispositionKind = "failed" IntentDispositionIndeterminate IntentDispositionKind = "indeterminate" )
type IntentDispositionProducerConfig ¶
type IntentDispositionProducerConfig struct {
ExpectedSettlement IntentSettlementConfig `json:"expected_settlement"`
DirectVisualInput bool `json:"direct_visual_input,omitempty"`
MaxEvidenceBytes int `json:"max_evidence_bytes,omitempty"`
MaxMediaBytes int `json:"max_media_bytes,omitempty"`
MaxMediaItems int `json:"max_media_items,omitempty"`
MaxPending int `json:"max_pending,omitempty"`
TerminalMemory int `json:"terminal_memory,omitempty"`
CancelMemory int `json:"cancel_memory,omitempty"`
}
IntentDispositionProducerConfig independently pins the settlement contract it accepts and the exact detector registration authorized to answer it. DirectVisualInput makes resolving every media item on the exact trigger observation mandatory; disabling it is an explicit text-semantic policy.
type IntentDispositionProducerOutcome ¶
type IntentDispositionProducerOutcome struct {
Kind IntentDispositionProducerOutcomeKind `json:"kind"`
ProbeID string `json:"probe_id,omitempty"`
DurableIntentItemID string `json:"durable_intent_item_id,omitempty"`
Disposition IntentDispositionKind `json:"disposition,omitempty"`
DispositionItemID string `json:"disposition_item_id,omitempty"`
Code string `json:"code,omitempty"`
Message string `json:"message,omitempty"`
DecisionStartedNS uint64 `json:"decision_started_ns,omitempty"`
DecisionFinishedNS uint64 `json:"decision_finished_ns,omitempty"`
}
IntentDispositionProducerOutcome exposes both inspection evidence and the exact cancellation acknowledgement consumed by an external coordinator. A canceled outcome that directly names the cancel envelope is published only after a matching in-flight decision has returned; it is therefore positive quiescence evidence. Ordinary classification control still flows solely through the strongly typed disposition output, and failures never masquerade as a succeeded or failed user intent.
func (IntentDispositionProducerOutcome) InspectionCause ¶
func (IntentDispositionProducerOutcome) InspectionCause() element.InspectionCauseKind
type IntentDispositionProducerOutcomeKind ¶
type IntentDispositionProducerOutcomeKind string
const ( IntentDispositionProducerProduced IntentDispositionProducerOutcomeKind = "produced" IntentDispositionProducerRefused IntentDispositionProducerOutcomeKind = "refused" IntentDispositionProducerFailed IntentDispositionProducerOutcomeKind = "failed" IntentDispositionProducerCanceled IntentDispositionProducerOutcomeKind = "canceled" IntentDispositionProducerIgnored IntentDispositionProducerOutcomeKind = "ignored" )
type IntentDispositionProducerResolution ¶
type IntentDispositionProducerResolution struct {
Detector IntentDetectorIdentity `json:"detector"`
Descriptor SemanticDeciderDescriptor `json:"descriptor"`
DescriptorDigest string `json:"descriptor_digest"`
RegistryRevision uint64 `json:"registry_revision"`
DirectVisualInput bool `json:"direct_visual_input"`
}
IntentDispositionProducerResolution exposes the complete immutable decider deployment selected by the symbolic detector reference. The compact Detector value is exactly what probes and dispositions carry.
func (IntentDispositionProducerResolution) InspectionCause ¶
func (IntentDispositionProducerResolution) InspectionCause() element.InspectionCauseKind
type IntentDispositionProducerState ¶
type IntentDispositionProducerState struct {
Revision uint64 `json:"revision"`
Pending int `json:"pending"`
Active bool `json:"active"`
Produced uint64 `json:"produced"`
Continued uint64 `json:"continued"`
Succeeded uint64 `json:"succeeded"`
FailedIntent uint64 `json:"failed_intent"`
Indeterminate uint64 `json:"indeterminate"`
ProviderFailures uint64 `json:"provider_failures"`
Canceled uint64 `json:"canceled"`
Refused uint64 `json:"refused"`
Ignored uint64 `json:"ignored"`
TerminalEntries int `json:"terminal_entries"`
CancellationEntries int `json:"cancellation_entries"`
MaxPending int `json:"max_pending"`
TerminalMemory int `json:"terminal_memory"`
CancellationMemory int `json:"cancellation_memory"`
}
func (IntentDispositionProducerState) InspectionCause ¶
func (IntentDispositionProducerState) InspectionCause() element.InspectionCauseKind
type IntentDispositionRetryConfig ¶
type IntentDispositionRetryConfig struct {
InitialDelayMS int `json:"initial_delay_ms,omitempty"`
BackoffFactor int `json:"backoff_factor,omitempty"`
MaxDelayMS int `json:"max_delay_ms,omitempty"`
MaxRetries int `json:"max_retries,omitempty"`
MaxElapsedMS int `json:"max_elapsed_ms,omitempty"`
MaxPending int `json:"max_pending,omitempty"`
TerminalMemory int `json:"terminal_memory,omitempty"`
CancelMemory int `json:"cancel_memory,omitempty"`
}
IntentDispositionRetryConfig is deterministic by construction: delays use an integer factor and no hidden jitter. MaxRetries counts retries after the initial attempt. MaxElapsedMS bounds the retry window beginning when the policy accepts the original probe; the producer's initial call remains independently bounded by its selected semantic-decider descriptor.
type IntentDispositionRetryExhaustion ¶
type IntentDispositionRetryExhaustion struct {
Probe IntentSettlementProbe `json:"probe"`
Retries int `json:"retries"`
FirstObservedNS uint64 `json:"first_observed_ns"`
FinishedNS uint64 `json:"finished_ns"`
LastDispositionItemID string `json:"last_disposition_item_id,omitempty"`
Code string `json:"code"`
}
IntentDispositionRetryExhaustion is a typed control-plane result a developer may route to a fallback, escalation, user prompt, or explicit Drop. It does not silently reinterpret uncertainty as success or failure.
func (IntentDispositionRetryExhaustion) InspectionCause ¶
func (IntentDispositionRetryExhaustion) InspectionCause() element.InspectionCauseKind
type IntentDispositionRetryOutcome ¶
type IntentDispositionRetryOutcome struct {
Kind IntentDispositionRetryOutcomeKind `json:"kind"`
SessionID string `json:"session_id,omitempty"`
ProbeID string `json:"probe_id,omitempty"`
DurableIntentItemID string `json:"durable_intent_item_id,omitempty"`
Disposition IntentDispositionKind `json:"disposition,omitempty"`
DispositionItemID string `json:"disposition_item_id,omitempty"`
Retry int `json:"retry,omitempty"`
DelayMS int `json:"delay_ms,omitempty"`
DeadlineNS uint64 `json:"deadline_ns,omitempty"`
FinishedNS uint64 `json:"finished_ns"`
Code string `json:"code,omitempty"`
Message string `json:"message,omitempty"`
}
IntentDispositionRetryOutcome makes trigger timing, attempts, cancellation, and exhaustion visible without using an inspection event as control.
func (IntentDispositionRetryOutcome) InspectionCause ¶
func (IntentDispositionRetryOutcome) InspectionCause() element.InspectionCauseKind
type IntentDispositionRetryOutcomeKind ¶
type IntentDispositionRetryOutcomeKind string
const ( IntentDispositionRetryObserved IntentDispositionRetryOutcomeKind = "observed" IntentDispositionRetryScheduled IntentDispositionRetryOutcomeKind = "scheduled" IntentDispositionRetryEmitted IntentDispositionRetryOutcomeKind = "retried" IntentDispositionRetrySettled IntentDispositionRetryOutcomeKind = "settled" IntentDispositionRetryExhausted IntentDispositionRetryOutcomeKind = "exhausted" IntentDispositionRetryCanceled IntentDispositionRetryOutcomeKind = "canceled" IntentDispositionRetryReset IntentDispositionRetryOutcomeKind = "reset" IntentDispositionRetryIgnored IntentDispositionRetryOutcomeKind = "ignored" IntentDispositionRetryRefused IntentDispositionRetryOutcomeKind = "refused" )
type IntentDispositionRetryState ¶
type IntentDispositionRetryState struct {
Revision uint64 `json:"revision"`
Pending int `json:"pending"`
Armed int `json:"armed"`
Observed uint64 `json:"observed"`
Indeterminate uint64 `json:"indeterminate"`
Scheduled uint64 `json:"scheduled"`
Retried uint64 `json:"retried"`
Settled uint64 `json:"settled"`
Exhausted uint64 `json:"exhausted"`
Canceled uint64 `json:"canceled"`
Reset uint64 `json:"reset"`
Ignored uint64 `json:"ignored"`
Refused uint64 `json:"refused"`
EarliestDeadlineNS uint64 `json:"earliest_deadline_ns,omitempty"`
MaxPending int `json:"max_pending"`
MaxRetries int `json:"max_retries"`
TerminalEntries int `json:"terminal_entries"`
CancellationEntries int `json:"cancellation_entries"`
}
func (IntentDispositionRetryState) InspectionCause ¶
func (IntentDispositionRetryState) InspectionCause() element.InspectionCauseKind
type IntentSettlementAcknowledgement ¶
type IntentSettlementAcknowledgement struct {
Decision IntentSettlementDecision `json:"decision"`
GenerationID string `json:"generation_id"`
AcknowledgedNS uint64 `json:"acknowledged_ns"`
}
IntentSettlementAcknowledgement is emitted by the downstream activation only after it independently verifies Decision and atomically clears the matching active effect. Echoing the complete decision prevents an ack for a different result, intent, or terminal kind from releasing the gate.
type IntentSettlementAddress ¶
type IntentSettlementAddress struct {
SessionID string `json:"session_id"`
DurableIntent TemporalEvidenceItemIdentity `json:"durable_intent"`
Reason string `json:"reason"`
}
IntentSettlementAddress is an exact administrative/user-policy reset. Both the payload and envelope name the session, and the full durable-intent identity prevents a delayed reset from reopening a newer epoch.
type IntentSettlementCancellation ¶
type IntentSettlementCancellation struct {
SessionID string `json:"session_id"`
DurableIntent TemporalEvidenceItemIdentity `json:"durable_intent"`
Reason string `json:"reason,omitempty"`
}
IntentSettlementCancellation revokes one exact durable-intent epoch. It is intentionally distinct from GenerationCancel: model generation and media stream addresses cannot safely identify an intent, and reusing them would allow a session interrupt to race a newer canonical intent. A graph that starts with a protocol-level session cancel must explicitly translate it at a stateful policy boundary that knows this complete canonical identity.
type IntentSettlementCleanup ¶
type IntentSettlementCleanup struct {
Evidence AdmittedTemporalEvidence `json:"evidence"`
Cancellation IntentSettlementCancellation `json:"cancellation"`
EvidenceItemID string `json:"evidence_item_id"`
CancellationItemID string `json:"cancellation_item_id"`
}
IntentSettlementCleanup carries a revoked intent's exact result-linked consequence on a control lane that can never be mistaken for ordinary activation evidence. The cancellation payload and its envelope identity let a downstream element verify why the evidence is cleanup-only even when this control overtakes a separately routed generation cancellation.
type IntentSettlementConfig ¶
type IntentSettlementConfig struct {
ExpectedAdmission TemporalEvidenceAdmissionConfig `json:"expected_admission"`
CandidateSources []TemporalEvidenceRequirement `json:"candidate_sources"`
Detector IntentDetectorIdentity `json:"detector"`
MaxTrackedIntents int `json:"max_tracked_intents,omitempty"`
CancelMemory int `json:"cancel_memory,omitempty"`
}
IntentSettlementConfig independently pins both the upstream temporal admission contract and the observation sources on which task-settlement classification is meaningful. CandidateSources is generic: a computer-use graph may select a screen observer while another graph may select a device or application-state observer.
type IntentSettlementDecision ¶
type IntentSettlementDecision struct {
TerminalID string `json:"terminal_id"`
Kind IntentSettlementDecisionKind `json:"kind"`
SessionID string `json:"session_id"`
Evidence AdmittedTemporalEvidence `json:"evidence"`
Probe IntentSettlementProbe `json:"probe"`
Disposition *IntentDisposition `json:"disposition,omitempty"`
Cancellation *IntentSettlementCancellation `json:"cancellation,omitempty"`
Reset *IntentSettlementAddress `json:"reset,omitempty"`
SupersedingIntent *TemporalEvidenceItemIdentity `json:"superseding_intent,omitempty"`
InvocationID string `json:"invocation_id"`
StateRevisionBefore uint64 `json:"state_revision_before"`
StateRevisionAfter uint64 `json:"state_revision_after"`
FinishedNS uint64 `json:"finished_ns"`
}
IntentSettlementDecision is the gate's authoritative terminal output. It carries the exact held admission and accepted disposition so a downstream activation policy can independently re-attest the canonical prefix and clear the one matching effect. Inspection outcomes are not used as control.
type IntentSettlementDecisionKind ¶
type IntentSettlementDecisionKind string
const ( IntentSettlementDecisionSucceeded IntentSettlementDecisionKind = "succeeded" IntentSettlementDecisionFailed IntentSettlementDecisionKind = "failed" IntentSettlementDecisionSuperseded IntentSettlementDecisionKind = "superseded" IntentSettlementDecisionReset IntentSettlementDecisionKind = "reset" IntentSettlementDecisionCanceled IntentSettlementDecisionKind = "canceled" )
type IntentSettlementOutcome ¶
type IntentSettlementOutcome struct {
Kind IntentSettlementOutcomeKind `json:"kind"`
Operation string `json:"operation"`
SessionID string `json:"session_id,omitempty"`
DurableIntentItemID string `json:"durable_intent_item_id,omitempty"`
TriggerObservationItemID string `json:"trigger_observation_item_id,omitempty"`
ResultItemID string `json:"result_item_id,omitempty"`
ProbeID string `json:"probe_id,omitempty"`
Disposition IntentDispositionKind `json:"disposition,omitempty"`
Code string `json:"code,omitempty"`
Message string `json:"message,omitempty"`
StateRevisionBefore uint64 `json:"state_revision_before"`
StateRevisionAfter uint64 `json:"state_revision_after"`
FinishedNS uint64 `json:"finished_ns"`
}
IntentSettlementOutcome contains only identities and closed decisions. The before/after revisions make every state transition reconstructible without rerunning a possibly nondeterministic detector.
func (IntentSettlementOutcome) InspectionCause ¶
func (IntentSettlementOutcome) InspectionCause() element.InspectionCauseKind
type IntentSettlementOutcomeKind ¶
type IntentSettlementOutcomeKind string
const ( IntentSettlementAdmitted IntentSettlementOutcomeKind = "admitted" IntentSettlementHeld IntentSettlementOutcomeKind = "held" IntentSettlementSuppressed IntentSettlementOutcomeKind = "suppressed" IntentSettlementRefused IntentSettlementOutcomeKind = "refused" IntentSettlementReset IntentSettlementOutcomeKind = "reset" IntentSettlementCanceled IntentSettlementOutcomeKind = "canceled" IntentSettlementCleanupForwarded IntentSettlementOutcomeKind = "cleanup" IntentSettlementIgnored IntentSettlementOutcomeKind = "ignored" )
type IntentSettlementProbe ¶
type IntentSettlementProbe struct {
ProbeID string `json:"probe_id"`
Issuer string `json:"issuer"`
Sequence uint64 `json:"sequence"`
SessionID string `json:"session_id"`
Evidence AdmittedTemporalEvidence `json:"evidence"`
DurableIntent TemporalEvidenceItemIdentity `json:"durable_intent"`
TriggerObservation TemporalEvidenceItemIdentity `json:"trigger_observation"`
Result IntentSettlementResultIdentity `json:"result"`
Prefix trajectory.PrefixIdentity `json:"prefix"`
Detector IntentDetectorIdentity `json:"detector"`
IssuedNS uint64 `json:"issued_ns"`
}
IntentSettlementProbe is content-free, deterministic classification work. Evidence carries the complete typed admission (still only identities) so a producer can independently reopen and verify it before resolving the exact canonical observation through its separately declared data/service path. A disposition must return this probe byte-for-byte.
type IntentSettlementResultIdentity ¶
type IntentSettlementResultIdentity struct {
TrajectoryItemID string `json:"trajectory_item_id"`
StoreVersion uint64 `json:"store_version"`
InvocationID string `json:"invocation_id"`
CallID string `json:"call_id"`
Tool string `json:"tool"`
}
IntentSettlementResultIdentity names the exact successful canonical tool result that precedes a candidate observation. Prefix binds its complete payload, so this identity need not copy result bytes into the control plane.
type IntentSettlementState ¶
type IntentSettlementState struct {
Revision uint64 `json:"revision"`
TrackedIntents int `json:"tracked_intents"`
PendingIntents int `json:"pending_intents"`
TerminalIntents int `json:"terminal_intents"`
AcknowledgedTerminals int `json:"acknowledged_terminals"`
Admitted uint64 `json:"admitted"`
Cleanups uint64 `json:"cleanups"`
Held uint64 `json:"held"`
Suppressed uint64 `json:"suppressed"`
Refused uint64 `json:"refused"`
Indeterminate uint64 `json:"indeterminate"`
Resets uint64 `json:"resets"`
CancellationRequests uint64 `json:"cancellation_requests"`
CancellationsCompleted uint64 `json:"cancellations_completed"`
MaxTrackedIntents int `json:"max_tracked_intents"`
CancellationEntries int `json:"cancellation_entries"`
CancellationMemory int `json:"cancellation_memory"`
Saturated bool `json:"saturated"`
}
IntentSettlementState is a bounded, content-free operational projection. Internal exact identities remain in bounded records and are exposed on probes/outcomes rather than copied into a lossy latest-state lane.
func (IntentSettlementState) InspectionCause ¶
func (IntentSettlementState) InspectionCause() element.InspectionCauseKind
type ObservationInvocationConfig ¶
type ObservationInvocationConfig struct {
SessionInvocationConfig
GenerateOnCommit bool `json:"generate_on_commit,omitempty"`
}
type ResponseCreate ¶
type ResponseCreate struct {
ResponseID string `json:"response_id"`
// ExpectedContextVersion and ExpectedContextItemID are one inseparable
// state binding supplied by the authenticated transport adapter. Explicit
// creation has no observation authority, but it may not sample an older
// context merely because graph input lanes were scheduled independently.
ExpectedContextVersion *uint64 `json:"expected_context_version"`
ExpectedContextItemID string `json:"expected_context_item_id"`
// CommittedContext lets append-only consumers reconstruct the exact
// authenticated prefix from a later State when independent lossless lanes
// deliver a newer snapshot first. It must agree with both legacy fields.
CommittedContext *stateelements.CommittedContext `json:"committed_context,omitempty"`
// TrustedPurpose is attached only inside the fixed graph after an admitted
// graph-owned trigger. Transport-originated response.create requests must
// leave it empty; SemanticAdmission is the trust boundary that enforces
// that rule before adding a purpose to its downstream copy.
TrustedPurpose ResponseCreatePurpose `json:"trusted_purpose,omitempty"`
}
func (ResponseCreate) InspectionCause ¶
func (ResponseCreate) InspectionCause() element.InspectionCauseKind
type ResponseCreatePurpose ¶
type ResponseCreatePurpose string
ResponseCreatePurpose is a closed, graph-owned reason for generation that cannot be inferred reliably from ordinary conversation text alone.
const (
ResponseCreatePurposePostCommitSilence ResponseCreatePurpose = "post-commit-silence"
)
type SemanticAdmissionConfig ¶
type SemanticAdmissionConfig struct {
Decider string `json:"decider"`
DirectVisualInput bool `json:"direct_visual_input,omitempty"`
StandingExtraction bool `json:"standing_extraction,omitempty"`
RecentLines int `json:"recent_lines,omitempty"`
MaxPending int `json:"max_pending,omitempty"`
TerminalMemory int `json:"terminal_memory,omitempty"`
CancelMemory int `json:"cancel_memory,omitempty"`
StandingMemory int `json:"standing_memory,omitempty"`
// Rules is the instruction the policy model reads with the situation. It
// is one text for every event kind - a provisional transcript, a settled
// one, a frame, a quiet clock - because the question is the same at each:
// speak now or not, and while speaking, stop or not. Empty selects
// interaction.ChoiceInstruction. The option set is never configured; it
// is derived from whether the agent is speaking.
Rules string `json:"rules,omitempty"`
}
type SemanticAdmissionOutcome ¶
type SemanticAdmissionOutcome struct {
Kind SemanticAdmissionOutcomeKind `json:"kind"`
Operation string `json:"operation"`
Choice *coreinteraction.Choice `json:"choice,omitempty"`
Event coreinteraction.TranscriptEventKind `json:"event,omitempty"`
StreamID string `json:"stream_id,omitempty"`
SourceRevision uint64 `json:"source_revision,omitempty"`
ContextVersion uint64 `json:"context_version,omitempty"`
DecisionItemID string `json:"decision_item_id,omitempty"`
Code string `json:"code,omitempty"`
Message string `json:"message,omitempty"`
FinishedNS uint64 `json:"finished_ns,omitempty"`
}
func (SemanticAdmissionOutcome) InspectionCause ¶
func (SemanticAdmissionOutcome) InspectionCause() element.InspectionCauseKind
type SemanticAdmissionOutcomeKind ¶
type SemanticAdmissionOutcomeKind string
const ( SemanticAdmissionAdmitted SemanticAdmissionOutcomeKind = "admitted" SemanticAdmissionSuppressed SemanticAdmissionOutcomeKind = "suppressed" SemanticAdmissionCanceled SemanticAdmissionOutcomeKind = "canceled" SemanticAdmissionRefused SemanticAdmissionOutcomeKind = "refused" SemanticAdmissionFailed SemanticAdmissionOutcomeKind = "failed" SemanticAdmissionIgnored SemanticAdmissionOutcomeKind = "ignored" )
type SemanticAdmissionState ¶
type SemanticAdmissionState struct {
InvocationRevision uint64 `json:"invocation_revision"`
InvocationDigest string `json:"invocation_digest,omitempty"`
ContextVersion uint64 `json:"context_version"`
Pending int `json:"pending"`
Active bool `json:"active"`
AdmittedVoice uint64 `json:"admitted_voice"`
Stopped uint64 `json:"stopped"`
Suppressed uint64 `json:"suppressed"`
Canceled uint64 `json:"canceled"`
Refused uint64 `json:"refused"`
Failed uint64 `json:"failed"`
Ignored uint64 `json:"ignored"`
TerminalMemory int `json:"terminal_memory"`
CancellationMemory int `json:"cancellation_memory"`
StandingPolicies int `json:"standing_policies"`
StandingMemory int `json:"standing_memory"`
// Holding says the next decision waits for an admitted generation to
// answer; HoldTimeouts counts holds lifted because it never did.
Holding bool `json:"holding,omitempty"`
HoldTimeouts uint64 `json:"hold_timeouts,omitempty"`
}
func (SemanticAdmissionState) InspectionCause ¶
func (SemanticAdmissionState) InspectionCause() element.InspectionCauseKind
type SemanticDecider ¶
type SemanticDecider interface {
coreinteraction.Decider
Descriptor() SemanticDeciderDescriptor
}
SemanticDecider extends the deliberately narrow enumerated Decider contract with exact live deployment identity. Decide can return only a supplied option. A descriptor may separately declare the optional interaction.Generator control-plane capability used for standing-policy extraction; neither capability can emit tools or acquire speech authority.
type SemanticDeciderDescriptor ¶
type SemanticDeciderDescriptor struct {
Provider string `json:"provider"`
Model string `json:"model"`
Protocol string `json:"protocol"`
Revision string `json:"revision"`
ConfigurationDigest string `json:"configuration_digest"`
Vision bool `json:"vision,omitempty"`
// StandingExtraction declares that the same provider plug-in also
// implements interaction.Generator. SemanticAdmission may use that
// separately bounded control-plane capability to extract structured
// standing policies; extracted text never receives cognition, tool, or
// speech authority.
StandingExtraction bool `json:"standing_extraction,omitempty"`
DecisionTimeoutMS int64 `json:"decision_timeout_ms"`
}
SemanticDeciderDescriptor is the provider-neutral, serializable identity of one enumerated interaction-act deployment. ConfigurationDigest binds all provider-specific non-secret behavior knobs without exposing their shape to the graph element. A credential is deliberately absent.
func (SemanticDeciderDescriptor) Validate ¶
func (descriptor SemanticDeciderDescriptor) Validate() error
type SemanticDeciderFactory ¶
type SemanticDeciderFactory func() (SemanticDecider, error)
type SemanticDeciderRegistry ¶
type SemanticDeciderRegistry struct {
// contains filtered or unexported fields
}
SemanticDeciderRegistry is immutable-by-registration deployment state. Factories are not invoked during graph discovery, profile freeze, or preflight; SemanticAdmission opens only its exact selected factory at Run.
func NewSemanticDeciderRegistry ¶
func NewSemanticDeciderRegistry() *SemanticDeciderRegistry
func (*SemanticDeciderRegistry) Describe ¶
func (registry *SemanticDeciderRegistry) Describe( reference string, ) (SemanticDeciderDescriptor, error)
Describe returns the immutable deployment descriptor registered under reference without opening a live policy client. Graph-native interaction elements use this during Mount to validate their selected policy while preserving the repository rule that provider factories are opened only after Run begins.
func (*SemanticDeciderRegistry) Open ¶
func (registry *SemanticDeciderRegistry) Open( reference string, ) (SemanticDecider, SemanticDeciderDescriptor, error)
Open creates one independently owned semantic decider and verifies that its live descriptor is exactly the descriptor registered during deployment assembly. Callers must close the returned decider when it implements io.Closer. Opening a fresh instance is important: two graph policy nodes may select the same symbolic deployment, but must not accidentally share mutable per-decision caches or lifecycle state.
func (*SemanticDeciderRegistry) Register ¶
func (registry *SemanticDeciderRegistry) Register( reference string, descriptor SemanticDeciderDescriptor, factory SemanticDeciderFactory, ) error
type SemanticDeciderResolution ¶
type SemanticDeciderResolution struct {
Reference string `json:"reference"`
Descriptor SemanticDeciderDescriptor `json:"descriptor"`
DescriptorDigest string `json:"descriptor_digest"`
RegistryRevision uint64 `json:"registry_revision"`
}
type SemanticDecision ¶
type SemanticDecision struct {
Operation string `json:"operation"`
Choice coreinteraction.Choice `json:"choice"`
SpokeOver bool `json:"spoke_over,omitempty"`
// Event names the transcript event the choice was taken on - "partial",
// "final", or empty for a frame, a clock, or an explicit request. A trace
// that cannot tell a decision on a live hypothesis from one on the settled
// words cannot say whether the policy acted early or late.
Event coreinteraction.TranscriptEventKind `json:"event,omitempty"`
Policy string `json:"policy"`
EvidenceItemID string `json:"evidence_item_id"`
StreamID string `json:"stream_id,omitempty"`
SourceRevision uint64 `json:"source_revision,omitempty"`
ContextVersion uint64 `json:"context_version"`
InvocationDigest string `json:"invocation_digest"`
Provider string `json:"provider"`
Model string `json:"model"`
Confidence float64 `json:"confidence,omitempty"`
Measured bool `json:"measured,omitempty"`
// DecisionStage names what produced the choice: "policy" when the model
// chose it, "state" when the option set left nothing to decide, "clock"
// when an unowned quiet tick was answered without asking.
DecisionStage string `json:"decision_stage,omitempty"`
StandingBefore int `json:"standing_before,omitempty"`
StandingAfter int `json:"standing_after,omitempty"`
StandingPinned int `json:"standing_pinned,omitempty"`
StandingRevoked int `json:"standing_revoked,omitempty"`
StartedNS uint64 `json:"started_ns"`
FinishedNS uint64 `json:"finished_ns"`
// Evidence is exactly what the policy model was shown, when one was
// asked. It is conversation content and therefore a debug payload, but
// without it a wrong choice cannot be told from a wrong question.
Evidence string `json:"evidence,omitempty"`
// Standing reports what the standing-instruction pass concluded on this
// event, when it ran.
Standing *StandingReport `json:"standing,omitempty"`
// Questions are the step questions the policy was asked, in order, with
// their answers: the choice is composed from them.
Questions []coreinteraction.AskedQuestion `json:"questions,omitempty"`
}
func (SemanticDecision) InspectionCause ¶
func (SemanticDecision) InspectionCause() element.InspectionCauseKind
type SemanticGrant ¶
type SemanticGrant struct {
Commit stateelements.ObservationCommitOutcome `json:"commit"`
Choice coreinteraction.Choice `json:"choice"`
DecisionItemID string `json:"decision_item_id"`
// SpokeOver says the choice invoked the voice while the other party was
// still speaking. The overlap controller protects such a run from being
// cancelled as an accidental barge-in: it was the decision.
SpokeOver bool `json:"spoke_over,omitempty"`
}
SemanticGrant couples the exact canonical observation receipt to the act that authorized its branch. SessionInvocation consumes this typed value so neither an envelope convention nor a mutated state receipt can silently erase whether generation deliberately began over an active speaker.
func (SemanticGrant) InspectionCause ¶
func (SemanticGrant) InspectionCause() element.InspectionCauseKind
type SessionInvocationConfig ¶
type SessionInvocationOutcome ¶
type SessionInvocationOutcome struct {
Kind SessionInvocationOutcomeKind `json:"kind"`
Operation string `json:"operation"`
GenerationID string `json:"generation_id,omitempty"`
Role string `json:"role"`
InvocationRevision uint64 `json:"invocation_revision,omitempty"`
InvocationDigest string `json:"invocation_digest,omitempty"`
StreamID string `json:"stream_id,omitempty"`
SourceRevision uint64 `json:"source_revision,omitempty"`
ObservationRevision uint64 `json:"observation_revision,omitempty"`
Choice *coreinteraction.Choice `json:"choice,omitempty"`
SpokeOver bool `json:"spoke_over,omitempty"`
ContextVersion uint64 `json:"context_version,omitempty"`
TriggerItemID string `json:"trigger_item_id,omitempty"`
Code string `json:"code,omitempty"`
Message string `json:"message,omitempty"`
FinishedNS uint64 `json:"finished_ns,omitempty"`
}
func (SessionInvocationOutcome) InspectionCause ¶
func (SessionInvocationOutcome) InspectionCause() element.InspectionCauseKind
type SessionInvocationOutcomeKind ¶
type SessionInvocationOutcomeKind string
const ( SessionInvocationUpdated SessionInvocationOutcomeKind = "updated" SessionInvocationEmitted SessionInvocationOutcomeKind = "emitted" SessionInvocationCanceled SessionInvocationOutcomeKind = "canceled" SessionInvocationRefused SessionInvocationOutcomeKind = "refused" SessionInvocationIgnored SessionInvocationOutcomeKind = "ignored" )
type SessionInvocationState ¶
type SessionInvocationState struct {
Role string `json:"role"`
InvocationRevision uint64 `json:"invocation_revision"`
InvocationDigest string `json:"invocation_digest,omitempty"`
ContextVersion uint64 `json:"context_version"`
Updated uint64 `json:"updated"`
Emitted uint64 `json:"emitted"`
Canceled uint64 `json:"canceled"`
Refused uint64 `json:"refused"`
Ignored uint64 `json:"ignored"`
TerminalMemory int `json:"terminal_memory"`
CancellationMemory int `json:"cancellation_memory"`
}
func (SessionInvocationState) InspectionCause ¶
func (SessionInvocationState) InspectionCause() element.InspectionCauseKind
type SessionInvocationUpdate ¶
type SessionInvocationUpdate struct {
Revision uint64 `json:"revision"`
Invocation continuation.Invocation `json:"invocation"`
// Contract is what the session told the agent to be and do, on its own:
// the invocation's instruction is that plus the voice model's operating
// rules, and the interaction policy must not read the voice's rules as
// the person's wishes. Empty means the invocation instruction is all
// there is.
Contract string `json:"contract,omitempty"`
}
func (SessionInvocationUpdate) InspectionCause ¶
func (SessionInvocationUpdate) InspectionCause() element.InspectionCauseKind
type StandingReport ¶ added in v0.2.0
type StandingReport struct {
Utterance string `json:"utterance"`
Pinned []string `json:"pinned,omitempty"`
Revoked []string `json:"revoked,omitempty"`
Dropped []string `json:"dropped,omitempty"`
InForce []string `json:"in_force,omitempty"`
Calls []coreinteraction.ModelCall `json:"calls,omitempty"`
Failure string `json:"failure,omitempty"`
}
StandingReport is what one run of the standing-instruction pass did: the words it read, every question it asked and the answer it got, and the pinboard it left behind.
type TemporalEvidenceAdmissionConfig ¶
type TemporalEvidenceAdmissionConfig struct {
Mode TemporalEvidenceAdmissionMode `json:"mode"`
SourceSet TemporalEvidenceSourceSet `json:"source_set,omitempty"`
Required []TemporalEvidenceRequirement `json:"required,omitempty"`
}
TemporalEvidenceAdmissionConfig makes the admission timing and source set a values-plane choice. Immediate validates and forwards the exact committed trigger. AfterIntent requires fresh causal evidence for either graph-authored pairs or the pairs discovered before the durable intent.
type TemporalEvidenceAdmissionMode ¶
type TemporalEvidenceAdmissionMode string
const ( TemporalEvidenceAdmissionImmediate TemporalEvidenceAdmissionMode = "immediate" TemporalEvidenceAdmissionAfterIntent TemporalEvidenceAdmissionMode = "after_intent" )
type TemporalEvidenceAdmissionOutcome ¶
type TemporalEvidenceAdmissionOutcome struct {
Kind TemporalEvidenceAdmissionOutcomeKind `json:"kind"`
Mode TemporalEvidenceAdmissionMode `json:"mode"`
TriggerItemID string `json:"trigger_item_id,omitempty"`
TrajectoryItemID string `json:"trajectory_item_id,omitempty"`
DurableIntentItemID string `json:"durable_intent_item_id,omitempty"`
RequiredObservations int `json:"required_observations,omitempty"`
QualifiedObservations int `json:"qualified_observations,omitempty"`
Code string `json:"code,omitempty"`
Message string `json:"message,omitempty"`
FinishedNS uint64 `json:"finished_ns,omitempty"`
}
func (TemporalEvidenceAdmissionOutcome) InspectionCause ¶
func (TemporalEvidenceAdmissionOutcome) InspectionCause() element.InspectionCauseKind
type TemporalEvidenceAdmissionOutcomeKind ¶
type TemporalEvidenceAdmissionOutcomeKind string
const ( TemporalEvidenceAdmissionAdmitted TemporalEvidenceAdmissionOutcomeKind = "admitted" TemporalEvidenceAdmissionRefused TemporalEvidenceAdmissionOutcomeKind = "refused" TemporalEvidenceAdmissionIgnored TemporalEvidenceAdmissionOutcomeKind = "ignored" )
type TemporalEvidenceItemIdentity ¶
type TemporalEvidenceItemIdentity struct {
TrajectoryItemID string `json:"trajectory_item_id"`
TriggerItemID string `json:"trigger_item_id"`
StoreVersion uint64 `json:"store_version"`
SourceRevision uint64 `json:"source_revision"`
OccurredNS uint64 `json:"occurred_ns"`
Authority trajectory.Authority `json:"authority"`
Observer string `json:"observer,omitempty"`
Source string `json:"source,omitempty"`
}
TemporalEvidenceItemIdentity is a content-free identity for one exact item in Prefix. StoreVersion is its one-based position in that immutable prefix.
type TemporalEvidenceSourceSet ¶
type TemporalEvidenceSourceSet string
TemporalEvidenceSourceSet selects how after-intent requirements are fixed. Explicit uses the graph-authored Required pairs. ObservedBeforeIntent freezes the distinct observer/source pairs already present before the newest final user intent in the trigger's exact canonical prefix. In neither mode can a pre-intent observation satisfy the resulting freshness requirement.
const ( TemporalEvidenceSourceSetExplicit TemporalEvidenceSourceSet = "explicit" TemporalEvidenceSourceSetObservedBeforeIntent TemporalEvidenceSourceSet = "observed_before_intent" )
Source Files
¶
- contract.go
- intent_disposition_producer.go
- intent_disposition_producer_runtime.go
- intent_disposition_retry.go
- intent_disposition_retry_runtime.go
- intent_settlement.go
- intent_settlement_runtime.go
- intent_settlement_verify.go
- observation_invocation.go
- runtime.go
- semantic_admission.go
- semantic_admission_runtime.go
- session_invocation.go
- session_invocation_runtime.go
- temporal_evidence.go
- temporal_evidence_runtime.go
- temporal_evidence_verify.go