Async post-guards
If every applicable output policy for a tenant is in shadow or async mode (i.e. nothing can block or rewrite the response), DeepintShield runs the post-LLM evaluation off the critical path — the user gets the response immediately, and findings still land in the audit store via the persistence queue.
Default behavior
Section titled “Default behavior”On. Auto-detected per tenant; no opt-in needed.
# Plugin config:{ "async_post_guards_when_no_sync": true }
# Or env var:DEEPINTSHIELD_GUARD_ASYNC_POST_GUARDS=trueWhen this kicks in
Section titled “When this kicks in”The optimization fires when both conditions hold for the request:
- The tenant’s hydrated bundle has zero output-scope policies in
syncmode (every policy isshadoworasync). - The request itself doesn’t carry any sync-mode policies via VK overrides or governance attachments.
If either check fails, the regular sync post-evaluation runs (response is held until the verdict is in).
What stays the same
Section titled “What stays the same”- Audit trail — every finding still lands in the evidence store. The trace, decision, and findings records are written from the background worker, not from the request path.
- Shadow/async finding semantics — already non-enforcing under the execution-modes contract; this optimization just doesn’t waste the user’s latency on them.
- Sync findings — never affected. If any sync policy exists, evaluation runs inline as before.
How to verify it’s active
Section titled “How to verify it’s active”Response headers reveal the mode that ran:
x-deepintshield-guardrail-status: passx-deepintshield-guardrail-mode: asyncOr mode: shadow for shadow-only, or mode: sync for sync-only.