Hook topology
Named hooks are pipelines built from .use(step) chains. Every step is wrapped in an instrumentation envelope that streams start / end / error taps into the runtime telemetry bus. Use this diagram to understand why a hook tap shows up in Studio's live stream — and how to add your own observer without touching the hook itself.
Key points:
- Taps are passive — they never alter hook output. Adding a tap is safe at runtime.
- The same telemetry stream powers Studio's Live page and any external OTel bridge attached via
attachOtelExporter. runtime.adoptHook(hook)is what wires a hook into the global telemetry stream; you only call it manually for hooks created outside the app graph.