How to tag ClearRun calls with modelId and sessionId

Add modelId and sessionId to /api/evaluate calls. modelId records which model wrote the answer. sessionId is your own id for grouping calls, such as a conversation or a test run.

Last updated

Steps

  1. Add the fields

    await clearrun.evaluate({
      prompt,
      responseText: answer,
      modelId: process.env.OPENAI_MODEL,
      sessionId: 'run-2026-11-09',
    });
  2. Keep your own copy

    Store the same tags with the verdictId in your system, so you can compare scores by model or run.

Workspaces

To keep receipts in separate chains, use workspaceId. See How to choose which workspace a receipt goes to (workspaceId).