Skip to content

chore: release v4.5.0#3998

Merged
ericallam merged 1 commit into
mainfrom
changeset-release/main
Jul 2, 2026
Merged

chore: release v4.5.0#3998
ericallam merged 1 commit into
mainfrom
changeset-release/main

Conversation

@github-actions

@github-actions github-actions Bot commented Jun 19, 2026

Copy link
Copy Markdown
Contributor

Trigger.dev v4.5.0

4.5.0 is the GA of the AI Agents platform. Everything built during the prerelease line (durable agents, Sessions, AI Prompts) is now stable on the latest tag, alongside a set of SDK and runtime improvements.

AI Agents (chat.agent)

Run Vercel AI SDK chat completions as durable Trigger.dev tasks instead of fragile API routes. A conversation runs as one long-lived task keyed on chatId, so it survives page refreshes, network blips, redeploys, and crashes, and every turn is a span in the dashboard.

import { chat } from "@trigger.dev/sdk/ai";
import { streamText, stepCountIs } from "ai";
import { anthropic } from "@ai-sdk/anthropic";

export const myChat = chat.agent({
  id: "my-chat",
  run: async ({ messages, signal }) => {
    return streamText({
      ...chat.toStreamTextOptions(), // system prompt, compaction, steering, telemetry
      model: anthropic("claude-sonnet-4-5"),
      messages,
      abortSignal: signal,
      stopWhen: stepCountIs(15),
    });
  },
});

Sessions

The durable primitive underneath chat.agent, usable on its own: a run-aware, bidirectional stream channel keyed on a stable externalId whose .in / .out streams survive run boundaries (suspend, crash, idle-timeout, redeploy). One Session spans many runs, which makes it a good fit for agent inboxes and approval flows.

import { sessions } from "@trigger.dev/sdk";

// Create the session and trigger its first run (idempotent on externalId)
await sessions.start({
  type: "inbox",
  externalId: userId,
  taskIdentifier: "inbox-agent",
});

const session = sessions.open(userId);
await session.in.send({ text: "hello" });

const stream = await session.out.read({ signal: AbortSignal.timeout(30_000) });
for await (const chunk of stream) console.log(chunk); // durable across run swaps

AI Prompts

Define prompt templates as code, versioned on every deploy, and override the text or model from the dashboard without redeploying (environment-scoped). Each generation links back to its prompt version for usage, cost, and latency.

import { prompts } from "@trigger.dev/sdk";
import { z } from "zod";

export const supportPrompt = prompts.define({
  id: "customer-support",
  model: "gpt-4o",
  variables: z.object({ customerName: z.string(), issue: z.string() }),
  content: `You are a support agent for Acme.
Customer: {{customerName}}
Issue: {{issue}}`,
});

// Honors any active dashboard override, else the current deployed version
const resolved = await supportPrompt.resolve({ customerName: "Alice", issue: "Can't log in" });
// resolved.text, resolved.model, resolved.version

useChat integration

useTriggerChatTransport is a Vercel AI SDK ChatTransport that runs useChat over Trigger.dev realtime with no API routes. Text, tool calls, reasoning, and data-* parts stream natively, and it works with AI SDK v5, v6, and now v7.

First-turn fast path (chat.headStart)

Runs the first turn in your warm server process while the agent boots in parallel, cutting cold-start time-to-first-chunk roughly in half (measured ~2.8s to ~1.2s). Available via the new @trigger.dev/sdk/chat-server subpath.

Human-in-the-loop, stop, and steering

The agent control surface: tool approvals (needsApproval + addToolApprovalResponse), client-driven stop-generation, mid-execution steering (pendingMessages), and between-turn context injection (chat.inject / chat.defer), all durable across the conversation.

Agent Skills

skills.define({ id, path }) bundles a SKILL.md folder into your deploy image. The agent gets a one-line summary up front and loads the full instructions plus scoped bash / readFile tools on demand (progressive disclosure), so a capability is something the model reaches for rather than a pre-declared typed tool.

trigger skills for coding assistants

trigger skills installs version-pinned Trigger.dev skills plus a bundled docs snapshot into Claude Code, Cursor, GitHub Copilot, and Codex, so your assistant's Trigger.dev knowledge stays current with your installed SDK version. trigger init now offers to set up the MCP server and skills too.

Model library

A new Models page in the dashboard: a catalog of models grouped by provider with context window, capabilities, and input / output pricing per 1M tokens, plus a "Your models" tab showing per-model usage, cost, and cache-hit sparklines from your actual traffic.

Dev branches

Run multiple local trigger dev sessions in parallel (separate git worktrees or coding agents) without runs colliding, each isolated with its own dashboard, via trigger dev --branch <name>.

TriggerClient

An instantiable client so one process can trigger and read across projects, environments, and preview branches, each with its own auth and baseURL, with no shared global state.

import { TriggerClient } from "@trigger.dev/sdk";

const prod = new TriggerClient({ accessToken: process.env.TRIGGER_PROD_KEY });
const preview = new TriggerClient({
  accessToken: process.env.TRIGGER_PREVIEW_KEY,
  previewBranch: "signup-flow",
});

await prod.tasks.trigger("send-email", { to: "user@example.com" });
await preview.runs.list({ status: ["COMPLETED"] });

SDK and runtime

  • AI SDK 7 support (v5 and v6 still supported), with OpenTelemetry telemetry auto-wired
  • Large trigger-payload offload: trigger payloads at or above 128KB upload to object storage automatically, using the same auth and baseURL as the trigger call
  • Region support on the runs API: filter runs by region and read each run's executing region (also on MCP list_runs)
  • Duplicate task-id detection: dev and deploy fail with a clear error instead of silently overwriting
  • envvars.upload gains an isSecret flag to import redacted secret variables
  • Retry hardening: TASK_MIDDLEWARE_ERROR now retries under the task's retry policy

@github-actions github-actions Bot changed the title chore: release (rc) chore: release v4.5.0-rc.8 Jun 19, 2026

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no bugs or issues to report.

Open in Devin Review

@github-actions github-actions Bot changed the title chore: release v4.5.0-rc.8 chore: release (rc) Jun 21, 2026
@github-actions github-actions Bot force-pushed the changeset-release/main branch from ae55093 to 136f0f1 Compare June 21, 2026 08:30
@github-actions github-actions Bot changed the title chore: release (rc) chore: release v4.5.0-rc.8 Jun 21, 2026
@github-actions github-actions Bot changed the title chore: release v4.5.0-rc.8 chore: release (rc) Jun 21, 2026
@github-actions github-actions Bot force-pushed the changeset-release/main branch from 136f0f1 to c156016 Compare June 21, 2026 12:48
@github-actions github-actions Bot changed the title chore: release (rc) chore: release v4.5.0-rc.8 Jun 21, 2026
@github-actions github-actions Bot changed the title chore: release v4.5.0-rc.8 chore: release (rc) Jun 22, 2026
@github-actions github-actions Bot force-pushed the changeset-release/main branch from c156016 to 0c8a043 Compare June 22, 2026 07:52
@github-actions github-actions Bot changed the title chore: release (rc) chore: release v4.5.0-rc.8 Jun 22, 2026
@github-actions github-actions Bot changed the title chore: release v4.5.0-rc.8 chore: release (rc) Jun 22, 2026
@github-actions github-actions Bot force-pushed the changeset-release/main branch from 0c8a043 to 616d755 Compare June 22, 2026 09:04
@github-actions github-actions Bot changed the title chore: release (rc) chore: release v4.5.0-rc.8 Jun 22, 2026
@github-actions github-actions Bot changed the title chore: release v4.5.0-rc.8 chore: release (rc) Jun 22, 2026
@github-actions github-actions Bot force-pushed the changeset-release/main branch from 616d755 to b9a6bba Compare June 22, 2026 12:49
@github-actions github-actions Bot changed the title chore: release (rc) chore: release v4.5.0-rc.8 Jun 22, 2026
@github-actions github-actions Bot changed the title chore: release v4.5.0-rc.8 chore: release (rc) Jun 22, 2026
@github-actions github-actions Bot force-pushed the changeset-release/main branch from b9a6bba to cca62fb Compare June 22, 2026 14:32
@github-actions github-actions Bot changed the title chore: release (rc) chore: release v4.5.0-rc.8 Jun 22, 2026
@github-actions github-actions Bot changed the title chore: release v4.5.0-rc.8 chore: release (rc) Jun 22, 2026
@github-actions github-actions Bot force-pushed the changeset-release/main branch from cca62fb to f4824a4 Compare June 22, 2026 16:33
@github-actions github-actions Bot changed the title chore: release (rc) chore: release v4.5.0-rc.8 Jun 22, 2026
@github-actions github-actions Bot changed the title chore: release v4.5.0-rc.8 chore: release (rc) Jun 24, 2026
@github-actions github-actions Bot force-pushed the changeset-release/main branch from f4824a4 to 7574c5d Compare June 24, 2026 16:57
@github-actions github-actions Bot changed the title chore: release (rc) chore: release v4.5.0-rc.8 Jun 24, 2026
@github-actions github-actions Bot changed the title chore: release v4.5.0-rc.8 chore: release (rc) Jun 24, 2026
@github-actions github-actions Bot force-pushed the changeset-release/main branch from 7574c5d to 8d70f1f Compare June 24, 2026 18:06
@github-actions github-actions Bot changed the title chore: release (rc) chore: release v4.5.0-rc.8 Jun 24, 2026
@github-actions github-actions Bot changed the title chore: release v4.5.0-rc.8 chore: release (rc) Jun 24, 2026
@github-actions github-actions Bot force-pushed the changeset-release/main branch from 2a245cd to db92175 Compare June 26, 2026 14:12
@github-actions github-actions Bot changed the title chore: release (rc) chore: release v4.5.0-rc.8 Jun 26, 2026
@github-actions github-actions Bot changed the title chore: release v4.5.0-rc.8 chore: release (rc) Jun 26, 2026
@github-actions github-actions Bot force-pushed the changeset-release/main branch from db92175 to 5e8a257 Compare June 26, 2026 15:14
@github-actions github-actions Bot changed the title chore: release (rc) chore: release v4.5.0-rc.8 Jun 26, 2026
@github-actions github-actions Bot changed the title chore: release v4.5.0-rc.8 chore: release (rc) Jun 27, 2026
@github-actions github-actions Bot force-pushed the changeset-release/main branch from 5e8a257 to 6eebcd3 Compare June 27, 2026 14:52
@github-actions github-actions Bot changed the title chore: release (rc) chore: release v4.5.0-rc.8 Jun 27, 2026
@github-actions github-actions Bot changed the title chore: release v4.5.0-rc.8 chore: release (rc) Jun 28, 2026
@github-actions github-actions Bot force-pushed the changeset-release/main branch from 6eebcd3 to c68dd49 Compare June 28, 2026 16:28
@github-actions github-actions Bot changed the title chore: release (rc) chore: release v4.5.0-rc.8 Jun 28, 2026
@github-actions github-actions Bot changed the title chore: release v4.5.0-rc.8 chore: release (rc) Jun 29, 2026
@github-actions github-actions Bot force-pushed the changeset-release/main branch from c68dd49 to 261e3e9 Compare June 29, 2026 09:55
@github-actions github-actions Bot changed the title chore: release (rc) chore: release v4.5.0-rc.8 Jun 29, 2026
@github-actions github-actions Bot changed the title chore: release v4.5.0-rc.8 chore: release (rc) Jun 29, 2026
@github-actions github-actions Bot force-pushed the changeset-release/main branch from 261e3e9 to a500557 Compare June 29, 2026 18:11
@github-actions github-actions Bot changed the title chore: release (rc) chore: release v4.5.0-rc.8 Jun 29, 2026
@github-actions github-actions Bot changed the title chore: release v4.5.0-rc.8 chore: release (rc) Jun 30, 2026
@github-actions github-actions Bot changed the title chore: release (rc) chore: release v4.5.0-rc.8 Jun 30, 2026
@github-actions github-actions Bot force-pushed the changeset-release/main branch from a500557 to 1262b1b Compare June 30, 2026 08:16
@github-actions github-actions Bot changed the title chore: release v4.5.0-rc.8 chore: release (rc) Jun 30, 2026
@github-actions github-actions Bot force-pushed the changeset-release/main branch from 1262b1b to d45c73e Compare June 30, 2026 11:36
@github-actions github-actions Bot changed the title chore: release (rc) chore: release v4.5.0-rc.8 Jun 30, 2026
@github-actions github-actions Bot changed the title chore: release v4.5.0-rc.8 chore: release (rc) Jun 30, 2026
@github-actions github-actions Bot force-pushed the changeset-release/main branch from d45c73e to 3fbe081 Compare June 30, 2026 12:36
@github-actions github-actions Bot changed the title chore: release (rc) chore: release v4.5.0-rc.8 Jun 30, 2026
@github-actions github-actions Bot changed the title chore: release v4.5.0-rc.8 chore: release (rc) Jun 30, 2026
@github-actions github-actions Bot force-pushed the changeset-release/main branch from 3fbe081 to 1450668 Compare June 30, 2026 14:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant