Hooks & Guardrails

How FlyDocs hooks enforce standards automatically — context injection, auto-formatting, and script approval.

Hooks are deterministic scripts that fire automatically in response to events. They're not suggestions the AI might follow. They run every time, whether the AI pays attention or not.


Built-in hooks

FlyDocs ships with three hooks:

Built-in Hooks

CONTEXT
Context injection
Fires before every prompt. Injects project context, active issue state, and session information before the AI sees your message. The AI starts every interaction informed, so you never re-explain.
FORMAT
Auto-formatting
Fires after every file edit. Formats code after every change using your project's formatter. Consistent output without relying on the AI to remember formatting rules.
APPROVE
Script approval
Fires before skill script execution. Automatically approves known FlyDocs skill scripts so they run without confirmation dialogs. No interruptions during workflow.

Why hooks matter

Every AI tool lets you write instructions. A 400-line instructions file is a suggestion; the AI might follow it, might not. Hooks are the enforcement layer: they handle the deterministic stuff (formatting, context, approvals) so the AI can focus on the creative work: solving problems and delivering value.


Stay in the loop

We're building new hook types and expanding the enforcement layer. Join the Discord for upcoming features, support, and early access to what's next.


Next