Skip to content

4 · Work with typed signals

You will understand why a detector decision needs structured evidence and how that structure improves debugging, policy composition, and audit.

A boolean can answer “blocked or allowed,” but it cannot explain which detector produced the decision, what score or label it emitted, or which threshold and metadata were active. Typed signals make those fields explicit and validate their shape at the boundary.

detector → typed signal → policy decision → case artifact → audit

The type is not decoration. It is the shared contract between independently evolving detectors, policies, serialization, and metrics.

When adding a signal field, trace every consumer: construction, policy logic, artifact serialization, report/export, and backward compatibility. A field that exists only in one layer is not an end-to-end feature.

Download the Chapter 4 notebook

Continue with the task-focused Tutorials or use the Reference for exact contracts.