cayu.observability.logging
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.
LoggingEventSink
Section titled “LoggingEventSink”from cayu.observability import LoggingEventSinkEmit concise runtime event summaries through Python logging.
High-frequency streaming events (model.text.delta) log at TRACE_LEVEL
(5) so DEBUG stays readable; set the logger to TRACE_LEVEL to see them.
The sink does not configure global handlers, process logging levels, or
formatter state — the one exception being the non-clobbering, idempotent
registration of the "TRACE" level name at import (skipped if the name or the
level number is already taken). Applications stay responsible for logging
configuration.
Bases: EventSink.
emit (method)
Section titled “emit (method)”async LoggingEventSink.emit(event: Event) -> Noneemit_timing (method)
Section titled “emit_timing (method)”async LoggingEventSink.emit_timing(record: RuntimeTimingRecord) -> Noneinit (method)
Section titled “init (method)”LoggingEventSink.__init__(*, logger: logging.Logger | None=None, logger_name: str=DEFAULT_CAYU_LOGGER_NAME, error_summary_limit: int=DEFAULT_ERROR_SUMMARY_LIMIT, redactor: SecretRedactor | None=None, log_runtime_timing: bool=False) -> NoneRelease source · Runtime guarantees · Capability guides
TRACE_LEVEL
Section titled “TRACE_LEVEL”from cayu.observability import TRACE_LEVELTRACE_LEVEL = 5