18namespace neograph::program {
20enum class RecordedEvidenceCoverage : std::uint8_t { Full, Partial, Redacted };
22NEOGRAPH_PROGRAM_API std::string_view to_string(RecordedEvidenceCoverage coverage)
noexcept;
23NEOGRAPH_PROGRAM_API RecordedEvidenceCoverage
24recorded_evidence_coverage_from_string(std::string_view value);
26struct RecordedCapabilityFailure {
28 std::string classification;
30 json witness = json::object();
32 bool operator==(
const RecordedCapabilityFailure&)
const =
default;
37 std::uint64_t sequence = 0;
38 CapabilityBindingReceipt binding;
39 std::string operation_id;
41 std::optional<std::string> effect_id;
46struct RecordedCapabilityEvidenceData {
48 RecordedEvidenceCoverage coverage = RecordedEvidenceCoverage::Partial;
49 bool redacted =
false;
50 std::optional<ProgramPendingInput> input_outcome;
51 std::optional<ProgramPendingEffect> effect_outcome;
52 std::optional<RecordedCapabilityFailure> failure;
58 static constexpr std::uint32_t STORAGE_SCHEMA_VERSION = 1;
63 const std::string& id()
const noexcept;
65 RecordedEvidenceCoverage coverage()
const noexcept;
66 bool redacted()
const noexcept;
67 std::optional<ProgramPendingInput> input_outcome()
const;
68 std::optional<ProgramPendingEffect> effect_outcome()
const;
69 std::optional<RecordedCapabilityFailure> failure()
const;
70 std::string serialize_canonical()
const;
75 std::shared_ptr<const Impl> impl_;
87 std::vector<RecordedCapabilityCallReference> expected_calls,
88 std::vector<RecordedCapabilityEvidence> evidence);
95 const std::string& fingerprint()
const noexcept;
96 const std::vector<CapabilityBindingReceipt>& exact_bindings()
const noexcept;
97 const std::vector<RecordedCapabilityCallReference>& expected_calls()
const noexcept;
98 const std::vector<RecordedCapabilityEvidence>& evidence()
const noexcept;
105 std::unique_ptr<Impl> impl_;
118 std::string_view owner_scope,
119 std::string_view any_run_id);
130 const ProgramTransitionPublication& target_initial_publication()
const noexcept;
135 std::shared_ptr<const Impl> impl_;
145 const std::vector<ProgramRunGeneration>& generations()
const noexcept;
146 const std::vector<ProgramHistoricalReplacementStep>& replacements()
const noexcept;
151 std::shared_ptr<const Impl> impl_;
Admission and process-local materialization of immutable Programs.
A ProgramTransitionStore for a caller that cannot suspend: the synchronous Program API,...
Read-only, fail-closed evidence for one immutable A -> ... -> N lineage.
One fully revalidated transition in a historical replacement chain.
Immutable, content-addressed command-journal value.
Immutable identity of one admitted topology generation in a run lineage.
Immutable content-addressed head of one stable run lineage.
Deep-owned, content-addressed run snapshot used for reconnect and CAS publication.
Move-only captured evidence proposal.
void validate_target(const ProgramVersion &target) const
Re-check against the pinned target version immediately before start.
Canonical immutable result or failure for one exact recorded capability call.
Protocol-neutral durable pending input and effect values.
Exact host-resource receipt returned by the Catalog capability binder.
Exact expected coordinate loaded from the source run's durable call/effect ledger.
Constructed only by the Catalog's trusted captured-capability registration.
Atomic owner-scoped Program transition publication.