# How to build a self-improvement loop for your Skills
**作者**: Zach Lloyd
**日期**: 2026-06-16T15:39:09.000Z
**来源**: [https://x.com/zachlloydtweets/status/2066908445425496348](https://x.com/zachlloydtweets/status/2066908445425496348)
---

There’s been a lot of chatter about using “loops” lately to drive agents, and I think this has been accompanied by a bit of “what actually is a loop”?
I can’t speak for everyone else using the term, but I wanted to show a practical approach using Skills and cloud agents for a particularly powerful kind of loop: a self-improvement loop.
This is the idea that an agent can improve the quality of its own Skills over time from external feedback. My example is a loop that involves a human feedback step, but if you have a clear goal that doesn’t require a human, you can use the same method with an automated grader.
To make matters concrete, say this Skill does issue triage, separating incoming issues into a few buckets: ready-to-implement, duplicate, needs-info. This would also work for a code review Skill, a bug fixing Skill, an incident response Skill, and so on.
Here’s what a first draft of the Skill might look like:

Full triage-issue Skill
What you need to do is set up the following loops:
1. An inner agent loop: this is where you actually apply the Skill. For issue triage, you could be running it manually, or, more likely, you have an integration with your task tracker that runs the Skill whenever a new issue is filed. Interactions with the Skill are recorded somewhere: in a file, an agent trace, or an interaction in an external system like Slack or Github.
2. An outer agent loop: this is an agent that runs on a schedule and observes the inner loop use of the Skill. For the issue triager, this will likely be a cloud agent that pulls records of every time the Triage agent ran. Its job is to look at all the runs of the inner agent and adjust its Skill based on the performance of those runs. Since Skills are just files, this means it should make a diff to improve Skill based on user feedback from past runs.
I’ll show you how to do this in practice using Warp and Oz, our cloud agent platform, but there are lots of ways you can accomplish it. We will use Github Issues as the issue tracker.
Here is a sample repo with the Skills and GitHub workflows to follow along.
## Step 1: set up the inner agent loop
The inner agent loop uses a Github action that runs on every new issue created.

Full GitHub Action
The Github action invokes a cloud agent through Oz, Warp’s cloud agent platform. This cloud agent syncs the repo, pulls in the issue contents from github, and tries to classify it. The code on how to set this up is in the repo linked below.
Now when a new issue comes in, a cloud agent runs the inner loop triaging skill, and applies a label indicating that a new feature request is ready to implement.

## Step 2: set up the outer loop for self-improvement
Let’s say though that a human reviewer doesn’t agree with the agent assignment. As a person looking at the agent’s assigned labels, I switch the issue from “ready to implement” to “needs info” and add a comment on the thread as to why it was mis-categorized, e.g. because there is ambiguity on whether we should add a setting for the new feature.

Here’s where the outer loop becomes interesting. The outer loop agent runs once a day and looks at all issues that have been triaged, and when it runs, it will find that I manually adjusted the label and gave a reason why.

Full improve-triage-issue Skill
Since the outer loop agent Skill is run through a coding agent, it will take the feedback I provided and make a diff to update the triage Skill.

Once that diff merges, it feeds back into Skill that drives the inner loop agent, and the next time the agent runs the Skill should work better.

Would love to know if this is useful for folks. We use self improvement loops to manage the Warp open-source repository, and we extracted the framework behind it for others to adopt. Early version here.
## 相关链接
- [Zach Lloyd](https://x.com/zachlloydtweets)
- [@zachlloydtweets](https://x.com/zachlloydtweets)
- [54K](https://x.com/zachlloydtweets/status/2066908445425496348/analytics)
- [Full triage-issue Skill](https://github.com/warpdotdev-demos/issue-triage-loop/blob/main/.agents/skills/triage-issue/SKILL.md)
- [Here is a sample repo](https://github.com/warpdotdev-demos/issue-triage-loop)
- [Full GitHub Action](https://github.com/warpdotdev-demos/issue-triage-loop/blob/main/.github/workflows/triage-new-issues.yml)
- [Full improve-triage-issue Skill](https://github.com/warpdotdev-demos/issue-triage-loop/blob/main/.agents/skills/improve-triage-skill/SKILL.md)
- [Early version here](https://github.com/warpdotdev/oz-for-oss)
- [Upgrade to Premium](https://x.com/i/premium_sign_up)
- [11:39 PM · Jun 16, 2026](https://x.com/zachlloydtweets/status/2066908445425496348)
- [54.6K Views](https://x.com/zachlloydtweets/status/2066908445425496348/analytics)
- [View quotes](https://x.com/zachlloydtweets/status/2066908445425496348/quotes)
---
*导出时间: 2026/6/17 15:10:38*
---
## 中文翻译
# 如何为你的技能构建自我改进循环
**作者**: Zach Lloyd
**日期**: 2026-06-16T15:39:09.000Z
**来源**: [https://x.com/zachlloydtweets/status/2066908445425496348](https://x.com/zachlloydtweets/status/2066908445425496348)
---

最近,关于使用“循环”来驱动智能体的讨论很多,而且这种讨论往往伴随着“循环到底是什么”的疑问。
我不能代表所有使用这个术语的人,但我想展示一种使用技能和云智能体的实用方法,针对一种特别强大的循环:自我改进循环。
其核心思想是,智能体可以随着时间推移,根据外部反馈来提高其自身技能的质量。我的例子包含一个人工反馈步骤,但如果你有一个不需要人类介入的明确目标,你可以使用同样的方法,搭配一个自动评分器。
具体来说,假设有一个技能负责问题分流,将传入的问题分为几类:准备实施、重复、需要更多信息。这也适用于代码审查技能、Bug修复技能、事件响应技能等等。
以下是该技能的初稿可能的样子:

完整的问题分流技能
你需要建立以下循环:
1. 内部智能体循环:这是你实际应用技能的地方。对于问题分流,你可以手动运行,或者更可能的情况是,你与任务跟踪器集成,每当提交新问题时就运行该技能。与技能的交互会被记录在某处:文件中、智能体跟踪中,或者外部系统(如 Slack 或 Github)的交互记录中。
2. 外部智能体循环:这是一个按计划运行的智能体,用于观察内部循环对技能的使用。对于问题分流器,这可能是一个云智能体,它会在每次分流智能体运行时拉取记录。它的任务是查看内部智能体的所有运行情况,并根据这些运行的表现来调整其技能。由于技能只是文件,这意味着它应该根据过去运行中的用户反馈生成差异,以改进技能。
我将向你展示如何使用 Warp 和 Oz(我们的云智能体平台)在实际操作中做到这一点,但有很多方法可以实现这一点。我们将使用 Github Issues 作为问题跟踪器。
这是一个包含技能和 GitHub 工作流的示例仓库,供你参考。
## 步骤 1:建立内部智能体循环
内部智能体循环使用一个 GitHub Action,在每个创建的新问题上运行。

完整的 GitHub Action
该 GitHub Action 通过 Oz(Warp 的云智能体平台)调用一个云智能体。这个云智能体同步仓库,从 github 拉取问题内容,并尝试对其进行分类。关于如何设置此代码,请查看下面链接中的仓库。
现在,当一个新问题进来时,云智能体会运行内部循环的分流技能,并应用一个标签,表明新的功能请求已准备好实施。

## 步骤 2:建立用于自我改进的外部循环
假设人工审查员不同意智能体的分配。作为一个查看智能体分配标签的人,我将问题从“准备实施”切换为“需要信息”,并在线程中添加评论说明为什么它被错误分类,例如因为关于是否应该为新功能添加设置存在歧义。

这就是外部循环变得有趣的地方。外部循环智能体每天运行一次,查看所有已被分流的问题。当它运行时,它会发现我手动调整了标签并给出了原因。

完整的改进问题分流技能
由于外部循环智能体技能是通过代码智能体运行的,它会接收我提供的反馈,并生成差异来更新分流技能。

一旦该差异合并,它就会反馈回驱动内部循环智能体的技能中,下次智能体运行时,技能应该会工作得更好。

很想知道这是否对大家有帮助。我们使用自我改进循环来管理 Warp 开源仓库,并提取了其背后的框架供其他人采用。早期版本在这里。
## 相关链接
- [Zach Lloyd](https://x.com/zachlloydtweets)
- [@zachlloydtweets](https://x.com/zachlloydtweets)
- [54K](https://x.com/zachlloydtweets/status/2066908445425496348/analytics)
- [Full triage-issue Skill](https://github.com/warpdotdev-demos/issue-triage-loop/blob/main/.agents/skills/triage-issue/SKILL.md)
- [Here is a sample repo](https://github.com/warpdotdev-demos/issue-triage-loop)
- [Full GitHub Action](https://github.com/warpdotdev-demos/issue-triage-loop/blob/main/.github/workflows/triage-new-issues.yml)
- [Full improve-triage-issue Skill](https://github.com/warpdotdev-demos/issue-triage-loop/blob/main/.agents/skills/improve-triage-skill/SKILL.md)
- [Early version here](https://github.com/warpdotdev/oz-for-oss)
- [Upgrade to Premium](https://x.com/i/premium_sign_up)
- [11:39 PM · Jun 16, 2026](https://x.com/zachlloydtweets/status/2066908445425496348)
- [54.6K Views](https://x.com/zachlloydtweets/status/2066908445425496348/analytics)
- [View quotes](https://x.com/zachlloydtweets/status/2066908445425496348/quotes)
---
*导出时间: 2026/6/17 15:10:38*