trigger.dev README

The project's README from github.com/triggerdotdev/trigger.dev. As one markdown file: README.md.

Trigger.dev logo

Build and deploy fully‑managed AI agents and workflows

Website | Docs | Issues | Example projects | Feature requests | Public roadmap | Self-hosting

Open Source License npm SDK downloads

Twitter Follow Discord Ask DeepWiki GitHub stars

About Trigger.dev

Trigger.dev is the open-source platform for building AI workflows in TypeScript. Long-running tasks with retries, queues, observability, and elastic scaling.

The platform designed for building AI agents

Build AI agents using all the frameworks, services and LLMs you're used to, deploy them to Trigger.dev and get durable, long-running tasks with retries, queues, observability, and elastic scaling out of the box.

Key features

Write tasks in your codebase

Create tasks where they belong: in your codebase. Version control, localhost, test and review like you're already used to.

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

//1. You need to export each task
export const helloWorld = task({
  //2. Use a unique id for each task
  id: "hello-world",
  //3. The run function is the main function of the task
  run: async (payload: { message: string }) => {
    //4. You can write code that runs for a long time here, there are no timeouts
    console.log(payload.message);
  },
});

Deployment

Use our SDK to write tasks in your codebase. There's no infrastructure to manage, your tasks automatically scale and connect to our cloud. Or you can always self-host.

Environments

We support Development, Staging, Preview, and Production environments, allowing you to test your tasks before deploying them to production.

Full visibility of every job run

View every task in every run so you can tell exactly what happened. We provide a full trace view of every task run so you can see what happened at every step.

Trace view image

Getting started

The quickest way to get started is to create an account and project in our web app, and follow the instructions in the onboarding. Build and deploy your first task in minutes.

Self-hosting

If you prefer to self-host Trigger.dev, you can follow our self-hosting guides:

Support and community

We have a large active community in our official Discord server for support, including a dedicated channel for self-hosting.

Development

To setup and develop locally or contribute to the open source project, follow our development guide.

Meet the Amazing People Behind This Project:

trigger.dev (triggerdotdev/trigger.dev)

Searching Database…

这是什么?Trigger.dev 是一个开源平台,用于用 TypeScript 构建和部署持久可靠的 AI 智能体与工作流。它提供长时间运行的任务,并带有重试、队列、可观测性和弹性伸缩功能。
这是托管服务,还是我要加到项目里的代码库?两者兼有:你用 Trigger.dev 的 JavaScript/TypeScript SDK 在代码库中编写任务,然后将其部署到 Trigger.dev 的托管云端(无需管理基础设施),或部署到你自己的自托管实例。
我该怎么构建并部署第一个任务?在 Trigger.dev 网页应用中创建账户和项目,然后按照引导流程操作;几分钟内就能完成第一个任务的构建和部署。
我能不用云服务,自己部署吗?可以。Trigger.dev 提供 Docker Compose 自托管指南,以及官方 Helm chart,可用于部署到 Kubernetes 集群,适合不想使用托管云服务的用户。
除了 JavaScript/TypeScript,我能用其他语言写任务吗?任务使用 JS/TS SDK 编写,但构建扩展允许你接入构建过程,从而在任务内运行 Python 脚本、FFmpeg、浏览器和其他系统软件包。
它只能配合 Vercel 或 AWS Lambda 这类无服务器平台使用吗?不是。Trigger.dev 的一大卖点是任务完全没有超时限制,这与 AWS Lambda、Vercel 等无服务器平台不同,因此长时间运行的 AI 智能体作业可以一直运行到完成。
任务的“持久性”到底体现在哪里?它和普通的后台任务有什么不同?检查点机制让任务天然具备持久性;遇到未捕获的错误时,失败的任务会自动重试,因此工作即使遇到崩溃或临时故障也不会丢失。
自动化流程运行到一半时,我能让人工介入吗?可以。等待点(waitpoints)允许你暂停任务,让人工进行批准、拒绝或提供反馈,之后流程才会继续。
我能把 AI 的回复实时推送到应用前端吗?可以。Trigger.dev Realtime 允许你订阅运行中的任务,实时推送 LLM 的回复,并提供配套的 React hooks 包,方便前端集成。
我怎样控制并发,并安全地运行多个环境?你可以为每个任务设置并发规则和队列。平台还支持相互独立的 DEV、PREVIEW、STAGING 和 PROD 环境,让测试与生产运行互不干扰。
What are similar projects?evenfire, temporal, sim, brigade, dapr, agno, mission-control, kestra
Size
196 MB
Stars
16.6K
Age
3y
Commits · 90 Days