360 Secure SkillHub
360 安全技能中心

Agent Lifecycle

这是一款Agent生命周期管理工具,核心功能包括生成智能体状态快照、对比快照差异、回滚至指定状态、追踪技能退役原因、查看完整变更历史。典型场景:升级前留存状态以便回滚、故障时排查变更点、记录技能更替原因。通过Python脚本执行命令操作,可追踪安装技能、配置状态等信息,数据以JSON格式本地存储,支持Darwin/Linux系统。

Trypto1019
Trypto1019
热度 81.29
最近更新 2026-04-29 12:01:24
分类:自动化依赖:代码执行应用场景:自动化脚本 / 任务管理 / 工作流 / DevOps

安装技能

复制下面的话术发给你的 Agent,它会通过 secure-skills 检索并安装该技能。

执行命令安装此 skill: npx secure-skills-cli add arc-agent-lifecycle
Metadata
name
agent-lifecycle
description
Manage the lifecycle of autonomous agents and their skills. Version configurations, plan upgrades, track retirement, and maintain change history across agent environments.
user-invocable
true
metadata
{"openclaw":{"emoji":"🔄","os":["darwin","linux"],"requires":{"bins":["python3"]}}}

Agent Lifecycle Manager

Track your agent's evolution from deployment to retirement. Version configurations, plan skill upgrades, and maintain a complete change history.

Why This Exists

Agents evolve constantly — new skills installed, old ones retired, configurations changed, models swapped. Without lifecycle tracking, you cannot answer: "What was my agent running last Tuesday?" or "What changed when things broke?"

Commands

Snapshot current agent state

python3 {baseDir}/scripts/lifecycle.py snapshot --name "pre-upgrade"

Compare two snapshots

python3 {baseDir}/scripts/lifecycle.py diff --from "pre-upgrade" --to "post-upgrade"

List all snapshots

python3 {baseDir}/scripts/lifecycle.py list

Rollback to a snapshot

python3 {baseDir}/scripts/lifecycle.py rollback --to "pre-upgrade" --dry-run

Track a skill retirement

python3 {baseDir}/scripts/lifecycle.py retire --skill old-skill --reason "Replaced by new-skill v2"

View change history

python3 {baseDir}/scripts/lifecycle.py history --limit 20

What It Tracks

  • Installed skills: Name, version, install date, last used
  • Configuration state: Environment vars, model assignments, feature flags
  • Change events: Installs, updates, removals, config changes
  • Retirement log: Why skills were removed, what replaced them
  • Snapshots: Point-in-time captures of full agent state

Data Storage

Lifecycle data is stored in ~/.openclaw/lifecycle/ as JSON files.