Concepts
Shadow mode
Connect Vindex and enforce nothing. In shadow mode every prompt is screened, logged and returned as usual, and nothing acts on it. Watch a week of real decisions land, then switch enforcement on when the numbers look right.
What changes
With shadow mode on:
- every decision says
shadow_mode: true; - no review item is opened;
- no webhook is sent, and
actions.webhooks_suppressedisshadow_mode.
Your app decides what to do with a shadow decision. The usual thing is to log it next to what you do today and enforce nothing.
The exception
So the rule for your app is one if: enforce every decision whose shadow_mode is false.
// shadow.mjs · Node 18+ · VINDEX_KEY=vx_test_... node shadow.mjs "a prompt"
const res = await fetch("https://api.getvindex.com/v1/check", {
method: "POST",
headers: { Authorization: `Bearer ${process.env.VINDEX_KEY}`, "Content-Type": "application/json" },
body: JSON.stringify({ input: { prompt: process.argv[2] ?? "a lighthouse at dusk, oil painting" } }),
});
const decision = await res.json();
if (decision.shadow_mode) {
console.log("log only:", decision.outcome); // compare with what you do today
} else {
console.log("enforce:", decision.outcome); // includes a minors block made in shadow mode
}Turning it on and off
Workspaces made in the dashboard start in shadow mode, recommended for your first week. Switch it in the dashboard under Settings, where the workspace's owners and admins see it. An API key can't change it (403 dashboard_only). The change reaches every check within about two minutes. GET /v1/tenant shows the current setting.
Shadow mode or dry run
Both screen without enforcing. A dry run is one request, and Vindex enforces nothing for it at all, a minors block included. Shadow mode covers the whole workspace, so your integration doesn't change when you go live.