cayu.knowledge.curator
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.
CandidatePolicyDisposition
Section titled “CandidatePolicyDisposition”from cayu import CandidatePolicyDispositionApplication-policy disposition before independent evaluation.
Bases: StrEnum.
Fields and attributes
Section titled “Fields and attributes”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 |
|---|---|---|
ACCEPTED |
class attribute |
'accepted' |
REJECTED |
class attribute |
'rejected' |
Release source · Runtime guarantees · Capability guides
group_learning_signals
Section titled “group_learning_signals”from cayu import group_learning_signalsGroup copied signals deterministically by scope and bounded batch size.
group_learning_signals(signals: Iterable[LearningSignal], *, max_signals_per_batch: int=50) -> list[LearningBatch]Release source · Runtime guarantees · Capability guides
KnowledgeCandidateGenerator
Section titled “KnowledgeCandidateGenerator”from cayu import KnowledgeCandidateGeneratorProvider-neutral candidate generation over one copied bounded batch.
Bases: Protocol.
generate_candidates (method)
Section titled “generate_candidates (method)”async KnowledgeCandidateGenerator.generate_candidates(batch: LearningBatch) -> list[LearningCandidate]Release source · Runtime guarantees · Capability guides
KnowledgeCandidatePolicy
Section titled “KnowledgeCandidatePolicy”from cayu import KnowledgeCandidatePolicyOptional application-owned content rejection or transformation hook.
Bases: Protocol.
apply_candidate_policy (method)
Section titled “apply_candidate_policy (method)”async KnowledgeCandidatePolicy.apply_candidate_policy(candidate: LearningCandidate, signals: tuple[LearningSignal, ...]) -> KnowledgeCandidatePolicyDecisionRelease source · Runtime guarantees · Capability guides
KnowledgeCandidatePolicyDecision
Section titled “KnowledgeCandidatePolicyDecision”from cayu import KnowledgeCandidatePolicyDecisionApplication-owned rejection or bounded transformation result.
Bases: _CuratorModel.
Fields and attributes
Section titled “Fields and attributes”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] |
LEARNING_SCHEMA_VERSION |
disposition |
CandidatePolicyDisposition |
required |
code |
StrictStr |
required |
notes |
StrictStr | None |
None |
candidate |
LearningCandidate | None |
None |
validate_code (method)
Section titled “validate_code (method)”KnowledgeCandidatePolicyDecision.validate_code(value: str) -> strvalidate_notes (method)
Section titled “validate_notes (method)”KnowledgeCandidatePolicyDecision.validate_notes(value: str | None) -> str | Nonecopy_candidate (method)
Section titled “copy_candidate (method)”KnowledgeCandidatePolicyDecision.copy_candidate(value: object) -> objectvalidate_disposition (method)
Section titled “validate_disposition (method)”KnowledgeCandidatePolicyDecision.validate_disposition() -> KnowledgeCandidatePolicyDecisionRelease source · Runtime guarantees · Capability guides
KnowledgeCurator
Section titled “KnowledgeCurator”from cayu import KnowledgeCuratorExplicit governed knowledge curation over Cayu’s revision store.
init (method)
Section titled “init (method)”KnowledgeCurator.__init__(store: _CuratorStore, *, candidate_generator: KnowledgeCandidateGenerator, evaluator: LearningEvaluator, config: KnowledgeCuratorConfig, access_scope: KnowledgeAccessScope | None=None, candidate_policy: KnowledgeCandidatePolicy | None=None, activation_policy: KnowledgeActivationPolicy | None=None, clock: Callable[[], datetime] | None=None) -> Noneconfig (property)
Section titled “config (property)”KnowledgeCurator.config() -> KnowledgeCuratorConfigaccess_scope (property)
Section titled “access_scope (property)”KnowledgeCurator.access_scope() -> KnowledgeAccessScopeReturn the exact copied access boundary enforced by this curator.
aclose (method)
Section titled “aclose (method)”async KnowledgeCurator.aclose(*, timeout_s: float=10.0) -> boolSeal and drain publications retained beyond their curation callers.
aenter (method)
Section titled “aenter (method)”async KnowledgeCurator.__aenter__() -> KnowledgeCuratoraexit (method)
Section titled “aexit (method)”async KnowledgeCurator.__aexit__(*_exc_info: object) -> Nonecurate (method)
Section titled “curate (method)”async KnowledgeCurator.curate(batch: LearningBatch) -> LearningBatchResultGenerate, independently evaluate, govern, and persist knowledge.
Release source · Runtime guarantees · Capability guides
KnowledgeCuratorConfig
Section titled “KnowledgeCuratorConfig”from cayu import KnowledgeCuratorConfigApplication-owned policy and resource bounds for reviewed curation.
Bases: _CuratorModel.
Fields and attributes
Section titled “Fields and attributes”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] |
LEARNING_SCHEMA_VERSION |
candidate_generator_identity |
StrictStr |
required |
evaluator_identity |
StrictStr |
required |
policy_identity |
StrictStr | None |
None |
pipeline_version |
StrictStr |
'cayu.knowledge-curator.v1' |
namespace |
StrictStr |
DEFAULT_KNOWLEDGE_NAMESPACE |
labels |
dict[str, str] |
Field(default_factory=dict) |
visibility |
KnowledgeVisibility |
KnowledgeVisibility.GLOBAL |
allowed_kinds |
tuple[StrictStr, ...] |
BUILTIN_KNOWLEDGE_KINDS |
created_by |
StrictStr |
'knowledge_curator' |
governance |
KnowledgeGovernanceConfig |
Field(default_factory=KnowledgeGovernanceConfig) |
max_signals |
StrictInt |
50 |
max_signal_bytes |
StrictInt |
16 * 1024 |
max_batch_bytes |
StrictInt |
256 * 1024 |
max_candidates |
StrictInt |
20 |
max_candidate_bytes |
StrictInt |
64 * 1024 |
max_candidate_text_bytes |
StrictInt |
32 * 1024 |
max_candidate_title_bytes |
StrictInt |
4 * 1024 |
max_candidate_batch_bytes |
StrictInt |
512 * 1024 |
max_source_references_per_signal |
StrictInt |
20 |
max_source_references_per_candidate |
StrictInt |
100 |
max_source_reference_bytes |
StrictInt |
16 * 1024 |
max_metadata_bytes |
StrictInt |
16 * 1024 |
max_evaluator_notes_bytes |
StrictInt |
16 * 1024 |
max_evaluator_concurrency |
StrictInt |
4 |
max_in_flight_publications |
StrictInt |
100 |
candidate_generator_timeout_seconds |
StrictFloat |
120.0 |
evaluator_timeout_seconds |
StrictFloat |
120.0 |
candidate_policy_timeout_seconds |
StrictFloat |
30.0 |
chunk_target_bytes |
StrictInt |
DEFAULT_KNOWLEDGE_CHUNK_TARGET_BYTES |
chunk_overlap_bytes |
StrictInt |
DEFAULT_KNOWLEDGE_CHUNK_OVERLAP_BYTES |
max_chunks |
StrictInt |
100 |
validate_identity (method)
Section titled “validate_identity (method)”KnowledgeCuratorConfig.validate_identity(value: str, info) -> strvalidate_policy_identity (method)
Section titled “validate_policy_identity (method)”KnowledgeCuratorConfig.validate_policy_identity(value: str | None) -> str | Nonecopy_labels (method)
Section titled “copy_labels (method)”KnowledgeCuratorConfig.copy_labels(value: Any) -> dict[str, str]copy_governance (method)
Section titled “copy_governance (method)”KnowledgeCuratorConfig.copy_governance(value: object) -> objectcopy_allowed_kinds (method)
Section titled “copy_allowed_kinds (method)”KnowledgeCuratorConfig.copy_allowed_kinds(value: object) -> tuple[str, ...]validate_positive_int (method)
Section titled “validate_positive_int (method)”KnowledgeCuratorConfig.validate_positive_int(value: int, info) -> intvalidate_text_capacity (method)
Section titled “validate_text_capacity (method)”KnowledgeCuratorConfig.validate_text_capacity(value: int, info) -> intvalidate_nonnegative_overlap (method)
Section titled “validate_nonnegative_overlap (method)”KnowledgeCuratorConfig.validate_nonnegative_overlap(value: int) -> intvalidate_timeout (method)
Section titled “validate_timeout (method)”KnowledgeCuratorConfig.validate_timeout(value: float, info) -> floatvalidate_bounds (method)
Section titled “validate_bounds (method)”KnowledgeCuratorConfig.validate_bounds() -> KnowledgeCuratorConfigfingerprint (property)
Section titled “fingerprint (property)”KnowledgeCuratorConfig.fingerprint() -> strRelease source · Runtime guarantees · Capability guides
LearningBatch
Section titled “LearningBatch”from cayu import LearningBatchOne already-grouped, explicitly submitted curation batch.
Bases: _CuratorModel.
Fields and attributes
Section titled “Fields and attributes”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] |
LEARNING_SCHEMA_VERSION |
id |
StrictStr |
required |
signals |
tuple[LearningSignal, ...] |
required |
validate_id (method)
Section titled “validate_id (method)”LearningBatch.validate_id(value: str) -> strcopy_signals (method)
Section titled “copy_signals (method)”LearningBatch.copy_signals(value: object) -> objectvalidate_signal_identity (method)
Section titled “validate_signal_identity (method)”LearningBatch.validate_signal_identity() -> LearningBatchscope (property)
Section titled “scope (property)”LearningBatch.scope() -> strfingerprint (property)
Section titled “fingerprint (property)”LearningBatch.fingerprint() -> strRelease source · Runtime guarantees · Capability guides
LearningBatchOutcome
Section titled “LearningBatchOutcome”from cayu import LearningBatchOutcomeOutcome of the batch-wide candidate-generation boundary.
Bases: StrEnum.
Fields and attributes
Section titled “Fields and attributes”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 |
|---|---|---|
COMPLETED |
class attribute |
'completed' |
GENERATOR_FAILED |
class attribute |
'generator_failed' |
GENERATOR_TIMED_OUT |
class attribute |
'generator_timed_out' |
GENERATOR_INVALID |
class attribute |
'generator_invalid' |
Release source · Runtime guarantees · Capability guides
LearningBatchResult
Section titled “LearningBatchResult”from cayu import LearningBatchResultBounded public result for one explicit curation invocation.
Bases: _CuratorModel.
Fields and attributes
Section titled “Fields and attributes”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] |
LEARNING_SCHEMA_VERSION |
batch_id |
StrictStr |
required |
batch_fingerprint |
StrictStr |
required |
configuration_fingerprint |
StrictStr |
required |
scope |
StrictStr |
required |
outcome |
LearningBatchOutcome |
required |
code |
StrictStr |
required |
signal_count |
StrictInt |
required |
candidate_count |
StrictInt |
required |
signals |
tuple[LearningSignalResult, ...] |
required |
candidates |
tuple[LearningCandidateResult, ...] |
() |
processed_at |
datetime |
required |
validate_identity (method)
Section titled “validate_identity (method)”LearningBatchResult.validate_identity(value: str, info) -> strvalidate_fingerprint (method)
Section titled “validate_fingerprint (method)”LearningBatchResult.validate_fingerprint(value: str, info) -> strcopy_candidates (method)
Section titled “copy_candidates (method)”LearningBatchResult.copy_candidates(value: object) -> objectcopy_signals (method)
Section titled “copy_signals (method)”LearningBatchResult.copy_signals(value: object) -> objectvalidate_processed_at (method)
Section titled “validate_processed_at (method)”LearningBatchResult.validate_processed_at(value: datetime) -> datetimevalidate_count (method)
Section titled “validate_count (method)”LearningBatchResult.validate_count(value: int, info) -> intvalidate_result_contract (method)
Section titled “validate_result_contract (method)”LearningBatchResult.validate_result_contract() -> LearningBatchResultRelease source · Runtime guarantees · Capability guides
LearningCandidate
Section titled “LearningCandidate”from cayu import LearningCandidateOne generator-proposed reusable knowledge item.
Bases: _CuratorModel.
Fields and attributes
Section titled “Fields and attributes”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] |
LEARNING_SCHEMA_VERSION |
proposal_key |
StrictStr |
required |
text |
StrictStr |
required |
signal_ids |
tuple[StrictStr, ...] |
required |
title |
StrictStr | None |
None |
kind |
StrictStr |
'fact' |
aspects |
tuple[StrictStr, ...] |
() |
impact_targets |
tuple[StrictStr, ...] |
() |
confidence_hint |
StrictFloat | None |
None |
source_references |
tuple[LearningSourceReference, ...] |
() |
metadata |
dict[str, Any] |
Field(default_factory=dict) |
validate_identity (method)
Section titled “validate_identity (method)”LearningCandidate.validate_identity(value: str, info) -> strvalidate_text (method)
Section titled “validate_text (method)”LearningCandidate.validate_text(value: str) -> strvalidate_title (method)
Section titled “validate_title (method)”LearningCandidate.validate_title(value: str | None) -> str | Nonecopy_signal_ids (method)
Section titled “copy_signal_ids (method)”LearningCandidate.copy_signal_ids(value: object) -> tuple[str, ...]copy_taxonomy (method)
Section titled “copy_taxonomy (method)”LearningCandidate.copy_taxonomy(value: object, info) -> tuple[str, ...]copy_source_references (method)
Section titled “copy_source_references (method)”LearningCandidate.copy_source_references(value: object) -> objectvalidate_confidence_hint (method)
Section titled “validate_confidence_hint (method)”LearningCandidate.validate_confidence_hint(value: float | None) -> float | Nonecopy_metadata (method)
Section titled “copy_metadata (method)”LearningCandidate.copy_metadata(value: Any) -> dict[str, Any]validate_sources (method)
Section titled “validate_sources (method)”LearningCandidate.validate_sources() -> LearningCandidatefingerprint (property)
Section titled “fingerprint (property)”LearningCandidate.fingerprint() -> strRelease source · Runtime guarantees · Capability guides
LearningCandidateOutcome
Section titled “LearningCandidateOutcome”from cayu import LearningCandidateOutcomeDurable or fail-closed outcome for one generated candidate.
Bases: StrEnum.
Fields and attributes
Section titled “Fields and attributes”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 |
|---|---|---|
PENDING_PERSISTED |
class attribute |
'pending_persisted' |
ACTIVE_PERSISTED |
class attribute |
'active_persisted' |
EXISTING_PENDING |
class attribute |
'existing_pending' |
EXISTING_ACTIVE |
class attribute |
'existing_active' |
EXISTING_ARCHIVED |
class attribute |
'existing_archived' |
EXISTING_DELETED |
class attribute |
'existing_deleted' |
EVALUATOR_REJECTED |
class attribute |
'evaluator_rejected' |
POLICY_REJECTED |
class attribute |
'policy_rejected' |
ACTIVATION_REJECTED |
class attribute |
'activation_rejected' |
INVALID |
class attribute |
'invalid' |
FAILED |
class attribute |
'failed' |
CONFLICT |
class attribute |
'conflict' |
Release source · Runtime guarantees · Capability guides
LearningCandidateResult
Section titled “LearningCandidateResult”from cayu import LearningCandidateResultBounded public result for one generated candidate.
Bases: _CuratorModel.
Fields and attributes
Section titled “Fields and attributes”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] |
LEARNING_SCHEMA_VERSION |
proposal_key |
StrictStr |
required |
candidate_fingerprint |
StrictStr |
required |
outcome |
LearningCandidateOutcome |
required |
code |
StrictStr |
required |
decision |
LearningDecision | None |
None |
entry_id |
StrictStr | None |
None |
entry_revision |
StrictInt | None |
None |
entry_status |
KnowledgeStatus | None |
None |
warning_code |
StrictStr | None |
None |
validate_required_identity (method)
Section titled “validate_required_identity (method)”LearningCandidateResult.validate_required_identity(value: str, info) -> strvalidate_fingerprint (method)
Section titled “validate_fingerprint (method)”LearningCandidateResult.validate_fingerprint(value: str) -> strcopy_decision (method)
Section titled “copy_decision (method)”LearningCandidateResult.copy_decision(value: object) -> objectvalidate_optional_identity (method)
Section titled “validate_optional_identity (method)”LearningCandidateResult.validate_optional_identity(value: str | None, info) -> str | Nonevalidate_revision (method)
Section titled “validate_revision (method)”LearningCandidateResult.validate_revision(value: int | None) -> int | Nonevalidate_outcome_contract (method)
Section titled “validate_outcome_contract (method)”LearningCandidateResult.validate_outcome_contract() -> LearningCandidateResultRelease source · Runtime guarantees · Capability guides
LearningDecision
Section titled “LearningDecision”from cayu import LearningDecisionOne independent evaluator decision for one exact candidate.
Bases: _CuratorModel.
Fields and attributes
Section titled “Fields and attributes”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] |
LEARNING_SCHEMA_VERSION |
verdict |
LearningVerdict |
required |
code |
StrictStr |
required |
notes |
StrictStr | None |
None |
confidence |
StrictFloat | None |
None |
metadata |
dict[str, Any] |
Field(default_factory=dict) |
validate_code (method)
Section titled “validate_code (method)”LearningDecision.validate_code(value: str) -> strvalidate_notes (method)
Section titled “validate_notes (method)”LearningDecision.validate_notes(value: str | None) -> str | Nonevalidate_confidence (method)
Section titled “validate_confidence (method)”LearningDecision.validate_confidence(value: float | None) -> float | Nonecopy_metadata (method)
Section titled “copy_metadata (method)”LearningDecision.copy_metadata(value: Any) -> dict[str, Any]Release source · Runtime guarantees · Capability guides
LearningEvaluator
Section titled “LearningEvaluator”from cayu import LearningEvaluatorIndependent evaluation of one candidate against its copied signals.
Bases: Protocol.
evaluate_candidate (method)
Section titled “evaluate_candidate (method)”async LearningEvaluator.evaluate_candidate(candidate: LearningCandidate, signals: tuple[LearningSignal, ...]) -> LearningDecisionRelease source · Runtime guarantees · Capability guides
LearningSignal
Section titled “LearningSignal”from cayu import LearningSignalOne deterministic application observation; it is not knowledge.
Bases: _CuratorModel.
Fields and attributes
Section titled “Fields and attributes”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] |
LEARNING_SCHEMA_VERSION |
id |
StrictStr |
required |
deduplication_key |
StrictStr |
required |
kind |
StrictStr |
required |
scope |
StrictStr |
required |
summary |
StrictStr |
required |
source_references |
tuple[LearningSourceReference, ...] |
required |
occurred_at |
datetime |
required |
metadata |
dict[str, Any] |
Field(default_factory=dict) |
validate_identity (method)
Section titled “validate_identity (method)”LearningSignal.validate_identity(value: str, info) -> strvalidate_summary (method)
Section titled “validate_summary (method)”LearningSignal.validate_summary(value: str) -> strcopy_source_references (method)
Section titled “copy_source_references (method)”LearningSignal.copy_source_references(value: object) -> objectcopy_metadata (method)
Section titled “copy_metadata (method)”LearningSignal.copy_metadata(value: Any) -> dict[str, Any]validate_occurred_at (method)
Section titled “validate_occurred_at (method)”LearningSignal.validate_occurred_at(value: datetime) -> datetimevalidate_sources (method)
Section titled “validate_sources (method)”LearningSignal.validate_sources() -> LearningSignalfingerprint (property)
Section titled “fingerprint (property)”LearningSignal.fingerprint() -> strRelease source · Runtime guarantees · Capability guides
LearningSignalOutcome
Section titled “LearningSignalOutcome”from cayu import LearningSignalOutcomeParticipation outcome for one submitted signal.
Bases: StrEnum.
Fields and attributes
Section titled “Fields and attributes”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 |
|---|---|---|
CANDIDATE_GENERATED |
class attribute |
'candidate_generated' |
NO_CANDIDATE_GENERATED |
class attribute |
'no_candidate_generated' |
BATCH_FAILED |
class attribute |
'batch_failed' |
Release source · Runtime guarantees · Capability guides
LearningSignalResult
Section titled “LearningSignalResult”from cayu import LearningSignalResultHow one submitted signal participated in an explicit curation call.
Bases: _CuratorModel.
Fields and attributes
Section titled “Fields and attributes”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] |
LEARNING_SCHEMA_VERSION |
signal_id |
StrictStr |
required |
signal_fingerprint |
StrictStr |
required |
outcome |
LearningSignalOutcome |
required |
code |
StrictStr |
required |
candidate_proposal_keys |
tuple[StrictStr, ...] |
() |
validate_identity (method)
Section titled “validate_identity (method)”LearningSignalResult.validate_identity(value: str, info) -> strvalidate_fingerprint (method)
Section titled “validate_fingerprint (method)”LearningSignalResult.validate_fingerprint(value: str) -> strcopy_candidate_proposal_keys (method)
Section titled “copy_candidate_proposal_keys (method)”LearningSignalResult.copy_candidate_proposal_keys(value: object) -> tuple[str, ...]validate_outcome (method)
Section titled “validate_outcome (method)”LearningSignalResult.validate_outcome() -> LearningSignalResultRelease source · Runtime guarantees · Capability guides
LearningSourceReference
Section titled “LearningSourceReference”from cayu import LearningSourceReferenceOne bounded exact source reference carried into KnowledgeEvidence.
Bases: _CuratorModel.
Fields and attributes
Section titled “Fields and attributes”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] |
LEARNING_SCHEMA_VERSION |
source_type |
StrictStr |
required |
source_id |
StrictStr | None |
None |
source_uri |
StrictStr | None |
None |
source_revision |
StrictStr | None |
None |
source_hash |
StrictStr | None |
None |
locator |
dict[str, Any] |
Field(default_factory=dict) |
role |
KnowledgeEvidenceRole |
KnowledgeEvidenceRole.ORIGIN |
metadata |
dict[str, Any] |
Field(default_factory=dict) |
validate_source_type (method)
Section titled “validate_source_type (method)”LearningSourceReference.validate_source_type(value: str) -> strvalidate_optional_identity (method)
Section titled “validate_optional_identity (method)”LearningSourceReference.validate_optional_identity(value: str | None, info) -> str | Nonevalidate_source_uri (method)
Section titled “validate_source_uri (method)”LearningSourceReference.validate_source_uri(value: str | None) -> str | Nonecopy_json_fields (method)
Section titled “copy_json_fields (method)”LearningSourceReference.copy_json_fields(value: Any, info) -> dict[str, Any]validate_exact_source (method)
Section titled “validate_exact_source (method)”LearningSourceReference.validate_exact_source() -> LearningSourceReferenceidentity_material (method)
Section titled “identity_material (method)”LearningSourceReference.identity_material() -> dict[str, Any]fingerprint (property)
Section titled “fingerprint (property)”LearningSourceReference.fingerprint() -> strRelease source · Runtime guarantees · Capability guides
LearningVerdict
Section titled “LearningVerdict”from cayu import LearningVerdictIndependent evaluator verdict for one exact candidate.
Bases: StrEnum.
Fields and attributes
Section titled “Fields and attributes”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 |
|---|---|---|
ACCEPTED |
class attribute |
'accepted' |
REJECTED |
class attribute |
'rejected' |
Release source · Runtime guarantees · Capability guides
validate_learning_batch
Section titled “validate_learning_batch”from cayu import validate_learning_batchCopy and validate a batch against one curator’s pre-provider bounds.
Durable job producers use the same boundary as KnowledgeCurator before
enqueueing work, so an oversized request cannot consume queue storage and
fail only after a worker has claimed it.
validate_learning_batch(batch: LearningBatch, *, config: KnowledgeCuratorConfig) -> LearningBatch