metadata#

Classes

EvaluationCacheSlot

Metadata-only cache slot for teacher hidden states or prefix activations.

EvaluationMetadataCache

Create manifest-backed cache directories for future tensor-backed reuse.

class EvaluationCacheSlot#

Bases: object

Metadata-only cache slot for teacher hidden states or prefix activations.

__init__(*, kind, cache_id, path, manifest)#
Parameters:
  • kind (str)

  • cache_id (str)

  • path (Path)

  • manifest (dict[str, Any])

Return type:

None

cache_id: str#
kind: str#
manifest: dict[str, Any]#
property manifest_path: Path#
path: Path#
to_dict()#
Return type:

dict[str, Any]

class EvaluationMetadataCache#

Bases: object

Create manifest-backed cache directories for future tensor-backed reuse.

These slots intentionally store metadata only. They give Stage 6/7 callers a stable identity and directory contract before the real tensor cache exists.

__init__(root)#
Parameters:

root (str | Path)

evict_expired_prefixes()#
Return type:

list[str]

prepare_prefix(inputs, settings=None, *, metadata=None, ttl_seconds=None)#
Parameters:
  • inputs (Any)

  • settings (Any | None)

  • metadata (dict[str, Any] | None)

  • ttl_seconds (int | None)

Return type:

EvaluationCacheSlot

prepare_teacher_hidden(inputs, settings=None, *, metadata=None)#
Parameters:
  • inputs (Any)

  • settings (Any | None)

  • metadata (dict[str, Any] | None)

Return type:

EvaluationCacheSlot