"""Versioned grounded-state contracts for the ACE State Engine.

This package contains the implemented evidence, candidate, belief-projection,
transition, rollout, and explicitly reviewed promotion packets. These models
keep source evidence, simulation, and cognitive-memory meanings distinct.
"""

from core.engine.grounded_state.contracts import (
    BELIEF_STATE_ASSERTION_VERSION,
    CONSEQUENCE_ROLLOUT_REQUEST_VERSION,
    EVIDENCE_RECORD_VERSION,
    TRANSITION_HYPOTHESIS_VERSION,
    BeliefStateAssertionV1,
    BeliefStatus,
    CausalStrength,
    ConsequenceRolloutRequestV1,
    EvidenceKind,
    GroundedEvidenceRecordV1,
    ProbabilityEstimateV1,
    RolloutBranchInputV1,
    RolloutBranchKind,
    StatePatternV1,
    SupportingEvidenceOriginV1,
    TemporalScopeV1,
    TimePrecision,
    TransitionHypothesisV1,
    TransitionReviewState,
    canonical_hash,
    stable_id,
)
from core.engine.grounded_state.corpus import (
    REQUIRED_MAINTAINER_REVIEW_CASE_KEYS,
    REQUIRED_REFERENCE_CATEGORIES,
    TEMPORAL_REFERENCE_CASE_VERSION,
    TEMPORAL_REFERENCE_CORPUS_VERSION,
    TEMPORAL_REFERENCE_EXPECTATION_VERSION,
    BeliefExpectationV1,
    CorpusMaturity,
    EligibilityExpectationV1,
    EligibilityState,
    ExpectedSemanticsV1,
    ReferenceCategory,
    ReferenceEvidenceV1,
    RelationshipClassification,
    RelationshipEndpointKind,
    RelationshipEndpointV1,
    RelationshipExpectationV1,
    ReviewDecision,
    ReviewDispositionV1,
    ReviewedJudgmentV1,
    ReviewRequirement,
    ReviewStatus,
    RolloutEligibilityExpectationV1,
    StateRecordMeaning,
    TemporalReferenceCaseV1,
    TemporalReferenceCorpusV1,
)
from core.engine.grounded_state.evaluator import (
    TEMPORAL_REFERENCE_EVALUATION_VERSION,
    ContractValidationFailureV1,
    DuplicateEvidenceIdentityV1,
    EvidenceIdentityOccurrenceV1,
    TemporalReferenceEvaluationV1,
    evaluate_temporal_reference_corpus,
    evaluate_temporal_reference_file,
)
from core.engine.grounded_state.ingestion import (
    GroundedStateIngestionService,
    ingest_grounded_state_batch,
)
from core.engine.grounded_state.ingestion_contracts import (
    BATCH_RECEIPT_VERSION,
    CANONICAL_ENTITY_VERSION,
    EVENT_PARTICIPANT_VERSION,
    EVIDENCE_RELATION_VERSION,
    EXTRACTION_FAILURE_VERSION,
    GROUNDED_EVENT_VERSION,
    INGESTION_MANIFEST_VERSION,
    ITEM_RECEIPT_VERSION,
    RAW_ALIAS_VERSION,
    SOURCE_CLAIM_VERSION,
    SOURCE_RECORD_VERSION,
    SUPERSESSION_LINEAGE_VERSION,
    BatchIngestionReceiptV1,
    BoundedBatchManifestV1,
    CanonicalEntityV1,
    EventParticipantV1,
    EvidenceRelationKind,
    EvidenceRelationV1,
    ExtractionFailureV1,
    GroundedEventV1,
    GroundedIngestionItemV1,
    GroundedRecordCountsV1,
    GroundedRecordKind,
    IngestionDisposition,
    IngestionDispositionCountsV1,
    IngestionItemReceiptV1,
    RawAliasV1,
    RecordIngestionResultV1,
    SourceClaimV1,
    SourceRecordV1,
    SupersessionLineageV1,
)
from core.engine.grounded_state.persistence import (
    GroundedStatePersistenceError,
    GroundedStateProductScopeError,
    GroundedStateReplayConflict,
    GroundedStateStore,
)
from core.engine.grounded_state.promotion import (
    PromotionEligibilityError,
    PromotionService,
    build_promotion_proposal,
    retrieve_promoted_memories,
)
from core.engine.grounded_state.promotion_contracts import (
    PROMOTION_MEMORY_LINEAGE_VERSION,
    PROMOTION_PROPOSAL_VERSION,
    PROMOTION_RECEIPT_VERSION,
    PROMOTION_REVIEW_VERSION,
    PromotedMemoryProjectionV1,
    PromotionDisposition,
    PromotionEffectiveState,
    PromotionEvidenceVersionV1,
    PromotionMaterialV1,
    PromotionMemoryLineageV1,
    PromotionMemoryMeaning,
    PromotionOriginMeaning,
    PromotionProposalV1,
    PromotionReceiptV1,
    PromotionReviewV1,
    PromotionTargetKind,
    PromotionTransitionRevisionV1,
)
from core.engine.grounded_state.promotion_persistence import (
    PromotionPersistenceError,
    PromotionProductScopeError,
    PromotionReplayConflict,
    PromotionStore,
)
from core.engine.grounded_state.transition_contracts import (
    TRANSITION_BRANCH_INPUT_VERSION,
    TRANSITION_CALIBRATION_VERSION,
    TRANSITION_CHALLENGE_VERSION,
    TRANSITION_OUTCOME_VERSION,
    TRANSITION_PROPOSAL_VERSION,
    TRANSITION_REVIEW_VERSION,
    TRANSITION_REVISION_VERSION,
    ConditionOperator,
    ObservedTransitionOutcomeV1,
    RuleEvaluationV1,
    StateAssignmentV1,
    StateConditionV1,
    StateSnapshotV1,
    StateValueType,
    StateVariableV1,
    TransitionBranchInputV1,
    TransitionCalibrationReceiptV1,
    TransitionChallengeReceiptV1,
    TransitionDerivationRoute,
    TransitionHypothesisProposalV1,
    TransitionHypothesisRevisionV1,
    TransitionOutcomeDisposition,
    TransitionReviewV1,
    TransitionRuleKind,
    TransitionRuleV1,
    TransitionTriggerKind,
    TransitionTriggerV1,
)
from core.engine.grounded_state.transition_persistence import (
    TransitionProductScopeError,
    TransitionReplayConflict,
    TransitionStore,
)
from core.engine.grounded_state.transitions import (
    TransitionHypothesisService,
    TransitionResolutionError,
    build_transition_branch_input,
    calibrate_transition,
    challenge_transition,
    resolve_transition,
    review_transition,
)

__all__ = [
    "BELIEF_STATE_ASSERTION_VERSION",
    "CONSEQUENCE_ROLLOUT_REQUEST_VERSION",
    "EVIDENCE_RECORD_VERSION",
    "TRANSITION_HYPOTHESIS_VERSION",
    "TRANSITION_BRANCH_INPUT_VERSION",
    "TRANSITION_CALIBRATION_VERSION",
    "TRANSITION_CHALLENGE_VERSION",
    "TRANSITION_OUTCOME_VERSION",
    "TRANSITION_PROPOSAL_VERSION",
    "TRANSITION_REVIEW_VERSION",
    "TRANSITION_REVISION_VERSION",
    "BATCH_RECEIPT_VERSION",
    "CANONICAL_ENTITY_VERSION",
    "EVENT_PARTICIPANT_VERSION",
    "EVIDENCE_RELATION_VERSION",
    "EXTRACTION_FAILURE_VERSION",
    "GROUNDED_EVENT_VERSION",
    "INGESTION_MANIFEST_VERSION",
    "ITEM_RECEIPT_VERSION",
    "RAW_ALIAS_VERSION",
    "SOURCE_CLAIM_VERSION",
    "SOURCE_RECORD_VERSION",
    "SUPERSESSION_LINEAGE_VERSION",
    "TEMPORAL_REFERENCE_CASE_VERSION",
    "TEMPORAL_REFERENCE_CORPUS_VERSION",
    "TEMPORAL_REFERENCE_EVALUATION_VERSION",
    "TEMPORAL_REFERENCE_EXPECTATION_VERSION",
    "REQUIRED_MAINTAINER_REVIEW_CASE_KEYS",
    "REQUIRED_REFERENCE_CATEGORIES",
    "BeliefExpectationV1",
    "BatchIngestionReceiptV1",
    "BoundedBatchManifestV1",
    "BeliefStateAssertionV1",
    "BeliefStatus",
    "CausalStrength",
    "CanonicalEntityV1",
    "ConditionOperator",
    "ConsequenceRolloutRequestV1",
    "ContractValidationFailureV1",
    "CorpusMaturity",
    "DuplicateEvidenceIdentityV1",
    "EvidenceRelationKind",
    "EvidenceRelationV1",
    "EligibilityExpectationV1",
    "EligibilityState",
    "EvidenceKind",
    "EvidenceIdentityOccurrenceV1",
    "ExpectedSemanticsV1",
    "EventParticipantV1",
    "ExtractionFailureV1",
    "GroundedEventV1",
    "GroundedEvidenceRecordV1",
    "GroundedIngestionItemV1",
    "GroundedRecordCountsV1",
    "GroundedRecordKind",
    "GroundedStateIngestionService",
    "GroundedStatePersistenceError",
    "GroundedStateProductScopeError",
    "GroundedStateReplayConflict",
    "GroundedStateStore",
    "PROMOTION_MEMORY_LINEAGE_VERSION",
    "PROMOTION_PROPOSAL_VERSION",
    "PROMOTION_RECEIPT_VERSION",
    "PROMOTION_REVIEW_VERSION",
    "PromotedMemoryProjectionV1",
    "PromotionDisposition",
    "PromotionEffectiveState",
    "PromotionEligibilityError",
    "PromotionEvidenceVersionV1",
    "PromotionMaterialV1",
    "PromotionMemoryLineageV1",
    "PromotionMemoryMeaning",
    "PromotionOriginMeaning",
    "PromotionPersistenceError",
    "PromotionProductScopeError",
    "PromotionProposalV1",
    "PromotionReceiptV1",
    "PromotionReplayConflict",
    "PromotionReviewV1",
    "PromotionService",
    "PromotionStore",
    "PromotionTargetKind",
    "PromotionTransitionRevisionV1",
    "IngestionDisposition",
    "IngestionDispositionCountsV1",
    "IngestionItemReceiptV1",
    "ProbabilityEstimateV1",
    "ObservedTransitionOutcomeV1",
    "RawAliasV1",
    "ReferenceCategory",
    "ReferenceEvidenceV1",
    "RelationshipClassification",
    "RelationshipEndpointKind",
    "RelationshipEndpointV1",
    "RelationshipExpectationV1",
    "ReviewDecision",
    "ReviewDispositionV1",
    "ReviewRequirement",
    "ReviewStatus",
    "RolloutBranchInputV1",
    "RolloutBranchKind",
    "RolloutEligibilityExpectationV1",
    "RecordIngestionResultV1",
    "ReviewedJudgmentV1",
    "StateRecordMeaning",
    "StatePatternV1",
    "StateAssignmentV1",
    "StateConditionV1",
    "StateSnapshotV1",
    "StateValueType",
    "StateVariableV1",
    "SourceClaimV1",
    "SourceRecordV1",
    "SupersessionLineageV1",
    "SupportingEvidenceOriginV1",
    "TemporalScopeV1",
    "TimePrecision",
    "TransitionHypothesisV1",
    "TransitionBranchInputV1",
    "TransitionCalibrationReceiptV1",
    "TransitionChallengeReceiptV1",
    "TransitionDerivationRoute",
    "TransitionHypothesisProposalV1",
    "TransitionHypothesisRevisionV1",
    "TransitionHypothesisService",
    "TransitionOutcomeDisposition",
    "TransitionProductScopeError",
    "TransitionReplayConflict",
    "TransitionResolutionError",
    "TransitionReviewV1",
    "TransitionReviewState",
    "TransitionRuleKind",
    "TransitionRuleV1",
    "TransitionStore",
    "TransitionTriggerKind",
    "TransitionTriggerV1",
    "RuleEvaluationV1",
    "TemporalReferenceCaseV1",
    "TemporalReferenceCorpusV1",
    "TemporalReferenceEvaluationV1",
    "canonical_hash",
    "evaluate_temporal_reference_corpus",
    "evaluate_temporal_reference_file",
    "ingest_grounded_state_batch",
    "build_promotion_proposal",
    "retrieve_promoted_memories",
    "stable_id",
    "build_transition_branch_input",
    "calibrate_transition",
    "challenge_transition",
    "resolve_transition",
    "review_transition",
]
