护栏与审查

actiongate-jev

@omkarghugarkar0072TypeScriptApache-2.0更新于 2026-09-19可当场跑

基于 OpenRouter,使用确定性策略和 TypeSafe Jev 实现 AI agent 工具调用的运行时授权和安全控制。

英文原文

Runtime authorization and guardrails for AI-agent tool calls with deterministic policy and TypeSafe Jev via OpenRouter.

omkarghugarkar007/actiongate-jev

它在哪儿调用了 Jev

JEV_MODEL: z.string().default("typesafe/jev-1.13"),

apps/api/src/config.ts:11

链接指向我们抓取当天的那个 commit,行号是准的。

它问 Jev 的问题

下面是从这个项目源码里原样取出来的 question 组合。

取自 packages/decision-provider/test/openrouter.live.test.ts:12

  1. wants_refund是/否

    Does the user explicitly request a refund?

  2. intent选项

    What is the requested outcome?

    • refundRefund a charge
    • explainExplain a charge

用你自己的内容跑一遍

代码
import { experimental_evaluate as evaluate } from 'ai';

const { answers } = await evaluate({
  model: 'typesafe-ai/jev',
  state,
  questions: {
    wants_refund: { type: 'boolean', instructions: 'Does the user explicitly request a refund?' },
    intent: { type: 'choice', instructions: 'What is the requested outcome?',
      criteria: { refund: 'Refund a charge', explain: 'Explain a charge' } },
  },
});

同类的其他项目