Playground/Agents & workflows/LangChain
API ACTIVITY

Usage & budget

PLAYGROUND SAFETY LIMITS

Steady requests. Visible limits.

0 active · 0/20 queued

Browser: one start every 1.2 seconds (at most 50/minute), up to 2 active calls and 20 waiting. Shared by examples in this tab. Waiting requests cancel when their run is stopped; a full queue rejects new work without an API call.

Server: 60 requests per rolling 60 seconds and 2 concurrent calls per key, per server instance. Other tabs using the same key share that instance’s allowance. This in-memory safeguard resets on restart and is not a distributed or account-wide quota.

Source: playground policy in lib/requestRateLimit.ts. TypeSafe may impose separate limits. Provider HTTP 429 pauses calls until its reported reset; without a reset time, retry requires your action. HTTP 402 is a budget/billing failure, not a pacing limit. No automatic retries or background replay.

Your TypeSafe API key

Import your key to override the shared server default.

Saved on this browser until removed or site data is cleared. Masked on screen; sent only with Jev requests through this app. The saved value is never displayed.

Connecting
RUNNABLE TYPESCRIPT INTEGRATION

Jev × LangChain

Wrap Jev as a real LangChain tool. Return a policy-checked routing decision to your host application.

WORKSPACE GUIDE

LangChain

Try a typed routing tool with live classification or a mocked response.

Tool inputPolicy gateStructured result

What you provide

A user request and current graph node, passed to the real structured LangChain tool adapter.

What happens

The adapter validates input, restricts routing to allowed candidates, invokes live Jev or a mock, and applies deterministic policy.

What you get

A structured routing result for a calling application, including approval or policy stops. The adapter never executes the selected downstream tool.

Walk through a run

  1. 01

    Choose the request

    Use a preset or edit the request and current graph node.

  2. 02

    Invoke the tool

    Try a mock invocation without credits, or use live Jev classification.

  3. 03

    Read the contract

    Inspect the returned route, policy decision, and structured output for your application.

Try this

Invoke the mock with a read request, then a production change. Compare the returned route and approval requirement.

Execution limits

The LangChain tool is real. It returns a decision and never executes downstream actions.

Explore the example. Check the evidence.
LangChain .invoke()→Jev closed-set choice→Policy gate→Typed result

Invoke the routing tool

@langchain/core

Both buttons invoke a real LangChain structured tool on the server. Live mode uses Jev; mock mode substitutes seeded predictions. Neither executes a downstream action.

What this integration guarantees
  • Zod validates the request and the two supported routing points.
  • Blocked requests stop before Jev; forbidden nodes never enter the candidate set.
  • Both scores must reach 85%. Low confidence asks for clarification.
  • Configuration changes return an approval requirement, not permission to execute.

Tool response

Tool inputPolicy gateStructured result

A tool result your application can use

Inspect the selected node, policy override and confidence as structured data. The host retains control of execution.

Use it in your TypeScript app

Local integration example · not a published LangChain plugin package

import { createJevRoutingTool } from "./lib/langchain/jev-tool";
import { serverJevTransport } from "./lib/serverJev";

const jevRouter = createJevRoutingTool({
  transport: serverJevTransport,
});

const decision = await jevRouter.invoke({
  request: "Check the current rate limit settings",
  current_node: "ops_agent",
});

// Route only after your host enforces policy and approval.
// decision.executed is always false.
console.log(decision);

Try locally: pnpm example:langchain runs the actual tool through a RunnableLambda chain with mock predictions.

Use live Jev: set TYPESAFE_API_KEY in your server environment or .env.local, then run pnpm example:langchain --live.

The factory is in lib/langchain/jev-tool.ts. Pass it as a tool to your LangChain host or call .invoke() directly. No OpenAI or LangSmith key is required for this example.