经 AI Skill Hub 精选评估,zeitlich开源AI工作流 获评「推荐使用」。这款Agent工作流在功能完整性、社区活跃度和易用性方面表现出色,AI 评分 7.5 分,适合有一定技术背景的用户使用。
zeitlich是基于Temporal的开源AI工作流,提供了一种有见地的AI代理实现,帮助开发者快速构建和部署AI应用。它以TypeScript编写,易于扩展和定制。
zeitlich开源AI工作流 是一套完整的 AI Agent 自动化工作流方案。通过可视化的节点编排,将复杂的多步骤任务拆解为清晰的自动化流程,实现全程无人值守的智能处理。支持与数百种外部服务和 API 无缝集成,适合构建数据处理管线、业务自动化和 AI 辅助决策系统。
zeitlich是基于Temporal的开源AI工作流,提供了一种有见地的AI代理实现,帮助开发者快速构建和部署AI应用。它以TypeScript编写,易于扩展和定制。
zeitlich开源AI工作流 是一套完整的 AI Agent 自动化工作流方案。通过可视化的节点编排,将复杂的多步骤任务拆解为清晰的自动化流程,实现全程无人值守的智能处理。支持与数百种外部服务和 API 无缝集成,适合构建数据处理管线、业务自动化和 AI 辅助决策系统。
# 方式一:npm 全局安装 npm install -g zeitlich # 方式二:npx 直接运行(无需安装) npx zeitlich --help # 方式三:项目依赖安装 npm install zeitlich # 方式四:从源码运行 git clone https://github.com/bead-ai/zeitlich cd zeitlich npm install npm start
# 命令行使用
zeitlich --help
# 基本用法
zeitlich [options] <input>
# Node.js 代码中使用
const zeitlich = require('zeitlich');
const result = await zeitlich.run(options);
console.log(result);
# zeitlich 配置说明 # 查看配置选项 zeitlich --config-example > config.yml # 常见配置项 # output_dir: ./output # log_level: info # workers: 4 # 环境变量(覆盖配置文件) export ZEITLICH_CONFIG="/path/to/config.yml"
npm install zeitlich ioredis \
@temporalio/workflow @temporalio/common
Peer dependencies:
@temporalio/workflow >=1.16.0 <2.0.0 (required)@temporalio/common >=1.16.0 <2.0.0 (required)@temporalio/worker >=1.16.0 <2.0.0 (optional — only when running a worker)@temporalio/envconfig >=1.16.0 <2.0.0 (optional — only when using envconfig)ioredis >= 5.0.0@langchain/core >= 1.0.0 (optional — only when using the LangChain adapter)@google/genai >= 1.0.0 (optional — only when using the Google GenAI adapter)@aws-sdk/client-bedrock-agentcore >= 3.900.0 (optional — only when using the Bedrock adapter)@aws-sdk/client-s3 >= 3.700.0 (optional — only when using the built-in S3 cold thread tier)Why peer deps? Zeitlich's public API surfaces@temporalio/*types (UpdateDefinition,ChildWorkflowOptions,Duration, etc.) directly. Peer deps guarantee a single resolved copy of each@temporalio/*package in the consumer's tree, eliminating brand-symbol skew between zeitlich's types and the consumer's own.
Required infrastructure:
temporal server start-dev)import { ChatAnthropic } from "@langchain/anthropic";
import { createLangChainAdapter } from "zeitlich/adapters/thread/langchain";
import { createRunAgentActivity } from "zeitlich";
const adapter = createLangChainAdapter({
redis,
model: new ChatAnthropic({ model: "claude-sonnet-4-20250514" }),
});
export function createActivities(client: WorkflowClient) {
return {
...adapter.createActivities("myAgentWorkflow"),
...createRunAgentActivity(client, adapter.invoker, "myAgentWorkflow"),
};
}
All adapters follow the same pattern — createActivities(scope) for worker registration and invoker for model calls.
Runnable examples (worker, client, workflows) are in a separate repo: zeitlich-examples.
Zeitlich's core is framework-agnostic — it defines generic interfaces (ModelInvoker, ThreadOps, MessageContent) that work with any LLM SDK. You choose a thread adapter (for conversation storage and model invocation) and a sandbox adapter (for filesystem operations), then wire them together.
The workflow wires together a thread adapter (for conversation storage / model calls) and a sandbox adapter (for filesystem tools). Both are pluggable — swap the proxy import to switch providers.
import { proxyActivities, workflowInfo } from "@temporalio/workflow";
import {
createAgentStateManager,
createSession,
defineWorkflow,
proxyRunAgent,
askUserQuestionTool,
bashTool,
defineTool,
} from "zeitlich/workflow";
import { searchTool } from "./tools";
import type { MyActivities } from "./activities";
import type { StoredMessage } from "@langchain/core/messages";
import { proxyLangChainThreadOps } from "zeitlich/adapters/thread/langchain/workflow";
import { proxyInMemorySandboxOps } from "zeitlich/adapters/sandbox/inmemory/workflow";
const runAgentActivity = proxyRunAgent<StoredMessage>();
const {
searchHandlerActivity,
bashHandlerActivity,
askUserQuestionHandlerActivity,
} = proxyActivities<MyActivities>({
startToCloseTimeout: "30m",
retry: {
maximumAttempts: 6,
initialInterval: "5s",
maximumInterval: "15m",
backoffCoefficient: 4,
},
});
export const myAgentWorkflow = defineWorkflow(
{ name: "myAgentWorkflow" },
async ({ prompt }: { prompt: string }, sessionInput) => {
const { runId } = workflowInfo();
const stateManager = createAgentStateManager({
initialState: {
systemPrompt: "You are a helpful assistant.",
},
agentName: "my-agent",
});
const session = await createSession({
agentName: "my-agent",
maxTurns: 20,
thread: { mode: "new", threadId: runId },
threadOps: proxyLangChainThreadOps(),
sandboxOps: proxyInMemorySandboxOps(),
runAgent: runAgentActivity,
buildContextMessage: () => [{ type: "text", text: prompt }],
tools: {
Search: defineTool({
...searchTool,
handler: searchHandlerActivity,
}),
AskUserQuestion: defineTool({
...askUserQuestionTool,
handler: askUserQuestionHandlerActivity,
hooks: {
onPostToolUse: () => {
stateManager.waitForInput();
},
},
}),
Bash: defineTool({
...bashTool,
handler: bashHandlerActivity,
}),
},
...sessionInput,
});
const result = await session.runSession({ stateManager });
return result;
}
);
Safe for use in Temporal workflow files:
| Export | Description |
|---|---|
createSession | Creates an agent session with tools, prompts, subagents, and hooks |
createAgentStateManager | Creates a state manager for workflow state with query/update handlers |
createToolRouter | Creates a tool router (used internally by session, or for advanced use) |
defineTool | Identity function for type-safe tool definition with handler and hooks |
defineSubagentWorkflow | Defines a subagent workflow with embedded name, description, and optional resultSchema |
defineSubagent | Creates a SubagentConfig from a SubagentDefinition with optional parent-specific overrides |
proxyRunAgent | Workflow-safe proxy for runAgent activities with LLM-optimised defaults (heartbeat, timeouts, retries) |
getShortId | Generate a compact, workflow-deterministic identifier (base-62, 12 chars) |
| Tool definitions | askUserQuestionTool, globTool, grepTool, readFileTool, writeFileTool, editTool, bashTool |
| Task tools | taskCreateTool, taskGetTool, taskListTool, taskUpdateTool for workflow task management |
| Skill utilities | parseSkillFile, createReadSkillTool, createReadSkillHandler |
defineWorkflow | Wraps a main workflow function, translating WorkflowInput into session-compatible fields |
| Lifecycle types | ThreadInit, SandboxInit, SandboxShutdown, SubagentSandboxShutdown, SubagentSandboxConfig |
| Types | Skill, SkillMetadata, SkillProvider, SubagentDefinition, SubagentConfig, ToolDefinition, ToolWithHandler, RouterContext, SessionConfig, WorkflowConfig, WorkflowInput, etc. |
zeitlich是一个有潜力的开源AI工作流,提供了一种有见地的AI代理实现,帮助开发者快速构建和部署AI应用。然而,它的社区和文档还需要进一步发展。
AI Skill Hub 为第三方内容聚合平台,本页面信息基于公开数据整理,不对工具功能和质量作任何法律背书。
建议在沙箱或测试环境中充分验证后,再部署至生产环境,并做好必要的安全评估。
✅ MIT 协议 — 最宽松的开源协议之一,可自由商用、修改、分发,仅需保留版权声明。
AI Skill Hub 点评:zeitlich开源AI工作流 的核心功能完整,质量良好。对于自动化工程师和运维人员来说,这是一个值得纳入个人工具库的选择。建议先在非生产环境试用,再逐步推广。
| 原始名称 | zeitlich |
| 原始描述 | 开源AI工作流:An opinionated AI agent implementation for Temporal。⭐11 · TypeScript |
| Topics | workflowagentsaitemporaltypescript |
| GitHub | https://github.com/bead-ai/zeitlich |
| License | MIT |
| 语言 | TypeScript |
收录时间:2026-05-22 · 更新时间:2026-05-23 · License:MIT · AI Skill Hub 不对第三方内容的准确性作法律背书。
选择 Agent 类型,复制安装指令后粘贴到对应客户端