Skip to content

cayu.evals.memory_attribution

Public Cayu API. Definitions are grouped by their public source module, and definitions from private implementation modules appear on their package’s page; adding a symbol does not move existing links. The import shown at each entry is a supported public namespace. Read the Python API overview and install the required extra.

eval_memory_attribution_bounds_for_trial_count

Section titled “eval_memory_attribution_bounds_for_trial_count”
from cayu.evals import eval_memory_attribution_bounds_for_trial_count

Partition both fresh closure reads before any trial is dispatched.

eval_memory_attribution_bounds_for_trial_count(trial_count: int) -> MemoryAttributionBounds

Release source · Runtime guarantees · Capability guides

from cayu.evals import eval_memory_attribution_fingerprint

Reuse the runtime/intervention projection’s canonical identity.

eval_memory_attribution_fingerprint(attribution: MemoryAttribution) -> str

Release source · Runtime guarantees · Capability guides

from cayu.evals import EVAL_MEMORY_ATTRIBUTION_MAX_BYTES
EVAL_MEMORY_ATTRIBUTION_MAX_BYTES = 1 << 20

Release source · Runtime guarantees · Capability guides

eval_memory_attribution_max_bytes_for_trial_count

Section titled “eval_memory_attribution_max_bytes_for_trial_count”
from cayu.evals import eval_memory_attribution_max_bytes_for_trial_count

Partition the final published memory section before any trial dispatches.

eval_memory_attribution_max_bytes_for_trial_count(trial_count: int) -> int

Release source · Runtime guarantees · Capability guides

EVAL_MEMORY_ATTRIBUTION_PROJECTION_BUDGET_BYTES

Section titled “EVAL_MEMORY_ATTRIBUTION_PROJECTION_BUDGET_BYTES”
from cayu.evals import EVAL_MEMORY_ATTRIBUTION_PROJECTION_BUDGET_BYTES
EVAL_MEMORY_ATTRIBUTION_PROJECTION_BUDGET_BYTES = 8 << 20

Release source · Runtime guarantees · Capability guides

EVAL_MEMORY_ATTRIBUTION_RESULT_BUDGET_BYTES

Section titled “EVAL_MEMORY_ATTRIBUTION_RESULT_BUDGET_BYTES”
from cayu.evals import EVAL_MEMORY_ATTRIBUTION_RESULT_BUDGET_BYTES
EVAL_MEMORY_ATTRIBUTION_RESULT_BUDGET_BYTES = 9 << 20

Release source · Runtime guarantees · Capability guides

from cayu.evals import EVAL_MEMORY_ATTRIBUTION_SCHEMA_VERSION
EVAL_MEMORY_ATTRIBUTION_SCHEMA_VERSION = 1

Release source · Runtime guarantees · Capability guides

EVAL_MEMORY_ATTRIBUTION_SOURCE_BUDGET_BYTES

Section titled “EVAL_MEMORY_ATTRIBUTION_SOURCE_BUDGET_BYTES”
from cayu.evals import EVAL_MEMORY_ATTRIBUTION_SOURCE_BUDGET_BYTES
EVAL_MEMORY_ATTRIBUTION_SOURCE_BUDGET_BYTES = 32 << 20

Release source · Runtime guarantees · Capability guides

eval_memory_attribution_source_limit_for_trial_count

Section titled “eval_memory_attribution_source_limit_for_trial_count”
from cayu.evals import eval_memory_attribution_source_limit_for_trial_count

Partition retained source wrappers across one published run before dispatch.

eval_memory_attribution_source_limit_for_trial_count(trial_count: int) -> int

Release source · Runtime guarantees · Capability guides

from cayu.evals import eval_memory_source_alias
eval_memory_source_alias(*, session_id: str, key_id: str, key: bytes) -> EvalMemorySourceAliasV1

Release source · Runtime guarantees · Capability guides

from cayu.evals import EvalMemoryAttributionCapturePolicyV1

One fixed eval-owned projection contract.

Bases: BaseModel.

Defaults below are source expressions; Field(...) includes schema/validation settings and default_factory creates a fresh value. Inherited declarations are included. Constructor behavior follows the model or dataclass shown in the bases/decorators.

Name Type Default
schema_version Literal[1] EVAL_MEMORY_ATTRIBUTION_POLICY_SCHEMA_VERSION
revision StrictStr required
runtime_projection Literal['cayu.memory_attribution.v1'] 'cayu.memory_attribution.v1'
max_sources Literal[100] EVAL_MEMORY_ATTRIBUTION_MAX_SOURCES
max_receipts Literal[100] MEMORY_ATTRIBUTION_DEFAULT_MAX_RECEIPTS
max_exposures Literal[100] MEMORY_ATTRIBUTION_DEFAULT_MAX_EXPOSURES
max_items Literal[1000] MEMORY_ATTRIBUTION_DEFAULT_MAX_ITEMS
max_source_bytes Literal[4194304] EVAL_MEMORY_ATTRIBUTION_MAX_SOURCE_BYTES_PER_TRIAL
max_projection_bytes Literal[524288] EVAL_MEMORY_ATTRIBUTION_MAX_PROJECTION_BYTES_PER_TRIAL
max_document_bytes Literal[1048576] EVAL_MEMORY_ATTRIBUTION_MAX_BYTES
EvalMemoryAttributionCapturePolicyV1.validate_schema_version_type(value: object) -> object
EvalMemoryAttributionCapturePolicyV1.validate_integer_policy_limits(value: object, info) -> object
EvalMemoryAttributionCapturePolicyV1.validate_revision(value: str) -> str
EvalMemoryAttributionCapturePolicyV1.validate_content() -> Self
EvalMemoryAttributionCapturePolicyV1.standard() -> EvalMemoryAttributionCapturePolicyV1

Release source · Runtime guarantees · Capability guides

from cayu.evals import EvalMemoryAttributionEvidenceV1

Complete portable memory evidence for one eval trial’s session tree.

Bases: BaseModel.

Defaults below are source expressions; Field(...) includes schema/validation settings and default_factory creates a fresh value. Inherited declarations are included. Constructor behavior follows the model or dataclass shown in the bases/decorators.

Name Type Default
schema_version Literal[1] EVAL_MEMORY_ATTRIBUTION_SCHEMA_VERSION
revision StrictStr required
policy EvalMemoryAttributionCapturePolicyV1 required
effective_bounds MemoryAttributionBounds required
effective_source_limit StrictInt Field(ge=0, le=EVAL_MEMORY_ATTRIBUTION_MAX_SOURCES)
effective_max_bytes StrictInt Field(ge=1, le=EVAL_MEMORY_ATTRIBUTION_MAX_BYTES)
completeness EvalMemoryEvidenceCompleteness required
limitations tuple[EvalMemoryEvidenceLimitation, ...] ()
total_source_count StrictInt Field(ge=0, le=MAX_DURABLE_JSON_INTEGER)
retained_source_count StrictInt Field(ge=0, le=EVAL_MEMORY_ATTRIBUTION_MAX_SOURCES)
omitted_source_count_at_least StrictInt Field(ge=0, le=MAX_DURABLE_JSON_INTEGER)
sources tuple[EvalMemoryAttributionSourceV1, ...] Field(default=(), max_length=EVAL_MEMORY_ATTRIBUTION_MAX_SOURCES)
proves_empty StrictBool required
has_indeterminate_exposure StrictBool required
EvalMemoryAttributionEvidenceV1.validate_schema_version_type(value: object) -> object
EvalMemoryAttributionEvidenceV1.validate_revision(value: str) -> str
EvalMemoryAttributionEvidenceV1.validate_ordered_limitations(value: object) -> object
EvalMemoryAttributionEvidenceV1.validate_ordered_sources(value: object) -> object
EvalMemoryAttributionEvidenceV1.validate_evidence() -> Self
EvalMemoryAttributionEvidenceV1.create(*, effective_bounds: MemoryAttributionBounds, effective_source_limit: int=EVAL_MEMORY_ATTRIBUTION_MAX_SOURCES, effective_max_bytes: int=EVAL_MEMORY_ATTRIBUTION_MAX_BYTES, completeness: EvalMemoryEvidenceCompleteness, limitations: tuple[EvalMemoryEvidenceLimitation, ...], total_source_count: int, sources: tuple[EvalMemoryAttributionSourceV1, ...], omitted_source_count_at_least: int=0) -> EvalMemoryAttributionEvidenceV1
EvalMemoryAttributionEvidenceV1.unavailable(reason: EvalMemoryEvidenceLimitation=EvalMemoryEvidenceLimitation.MISSING, *, effective_bounds: MemoryAttributionBounds | None=None, effective_source_limit: int=EVAL_MEMORY_ATTRIBUTION_MAX_SOURCES, effective_max_bytes: int=EVAL_MEMORY_ATTRIBUTION_MAX_BYTES) -> EvalMemoryAttributionEvidenceV1

Release source · Runtime guarantees · Capability guides

from cayu.evals import EvalMemoryAttributionSourceV1

Bases: BaseModel.

Defaults below are source expressions; Field(...) includes schema/validation settings and default_factory creates a fresh value. Inherited declarations are included. Constructor behavior follows the model or dataclass shown in the bases/decorators.

Name Type Default
source EvalMemorySourceReferenceV1 required
terminal_status Literal['completed', 'failed', 'interrupted'] required
expected_receipt_count StrictInt | None Field(default=None, ge=0, le=MAX_DURABLE_JSON_INTEGER)
expected_exposure_count StrictInt | None Field(default=None, ge=0, le=MAX_DURABLE_JSON_INTEGER)
attribution MemoryAttribution | None None
attribution_fingerprint StrictStr | None None
limitations tuple[EvalMemoryEvidenceLimitation, ...] ()
EvalMemoryAttributionSourceV1.validate_ordered_limitations(value: object) -> object
EvalMemoryAttributionSourceV1.copy_attribution(value: object) -> object
EvalMemoryAttributionSourceV1.validate_fingerprint(value: str | None) -> str | None
EvalMemoryAttributionSourceV1.validate_source() -> Self

Release source · Runtime guarantees · Capability guides

from cayu.evals import EvalMemoryEvidenceCompleteness

Bases: StrEnum.

Defaults below are source expressions; Field(...) includes schema/validation settings and default_factory creates a fresh value. Inherited declarations are included. Constructor behavior follows the model or dataclass shown in the bases/decorators.

Name Type Default
COMPLETE class attribute 'complete'
TRUNCATED class attribute 'truncated'
UNAVAILABLE class attribute 'unavailable'

Release source · Runtime guarantees · Capability guides

from cayu.evals import EvalMemoryEvidenceLimitation

Bases: StrEnum.

Defaults below are source expressions; Field(...) includes schema/validation settings and default_factory creates a fresh value. Inherited declarations are included. Constructor behavior follows the model or dataclass shown in the bases/decorators.

Name Type Default
SOURCE_LIMIT class attribute 'source_limit'
SOURCE_BYTES_LIMIT class attribute 'source_bytes_limit'
PROJECTION_BYTES_LIMIT class attribute 'projection_bytes_limit'
RUNTIME_ATTRIBUTION_TRUNCATED class attribute 'runtime_attribution_truncated'
STORE_UNSUPPORTED class attribute 'store_unsupported'
EVIDENCE_READ_FAILED class attribute 'evidence_read_failed'
ALIAS_KEY_UNAVAILABLE class attribute 'alias_key_unavailable'
MISSING class attribute 'missing'
DELETED class attribute 'deleted'
LEGACY class attribute 'legacy'
CONTRADICTORY_LINEAGE class attribute 'contradictory_lineage'
SOURCE_TREE_INCOMPLETE class attribute 'source_tree_incomplete'
CLOSURE_CHANGED class attribute 'closure_changed'
DEADLINE_EXPIRED class attribute 'deadline_expired'

Release source · Runtime guarantees · Capability guides

from cayu.evals import EvalMemorySourceAliasV1

Bases: BaseModel.

Defaults below are source expressions; Field(...) includes schema/validation settings and default_factory creates a fresh value. Inherited declarations are included. Constructor behavior follows the model or dataclass shown in the bases/decorators.

Name Type Default
algorithm Literal['hmac-sha256'] 'hmac-sha256'
key_id StrictStr Field(max_length=64)
digest StrictStr Field(min_length=64, max_length=64)
EvalMemorySourceAliasV1.validate_key_id(value: str) -> str
EvalMemorySourceAliasV1.validate_digest(value: str) -> str

Release source · Runtime guarantees · Capability guides

from cayu.evals import EvalMemorySourceReferenceV1

Bases: BaseModel.

Defaults below are source expressions; Field(...) includes schema/validation settings and default_factory creates a fresh value. Inherited declarations are included. Constructor behavior follows the model or dataclass shown in the bases/decorators.

Name Type Default
role Literal['root', 'descendant'] required
tree_path tuple[StrictInt, ...] Field(max_length=32)
session_alias EvalMemorySourceAliasV1 | None None
EvalMemorySourceReferenceV1.validate_ordered_path(value: object) -> object
EvalMemorySourceReferenceV1.validate_role() -> Self

Release source · Runtime guarantees · Capability guides

from cayu.evals import standard_eval_memory_attribution_bounds
standard_eval_memory_attribution_bounds(*, max_source_bytes: int=EVAL_MEMORY_ATTRIBUTION_MAX_SOURCE_BYTES_PER_TRIAL, max_projection_bytes: int=EVAL_MEMORY_ATTRIBUTION_MAX_PROJECTION_BYTES_PER_TRIAL) -> MemoryAttributionBounds

Release source · Runtime guarantees · Capability guides