
技术主管自建“agent gadget”工具,让 agent 一次性批量提问
来源标题:Agent Gadgets
一位技术主管为自己搭建了“agent gadget”本地工具,扩展了 harness 常见的“Ask a Question”工具,使 agent 能一次性提出大量问题。问题以 markdown 呈现,可放在表格中,并支持建议答案、单选和自由作答。他表示,这种工具在 PR 分诊和一次性澄清设计问题上效果显著。
以下正文同步自 Hacker News 最新,版权归原站所有,已转换为易读排版。
I’ve been thinking lately about how to improve agentic coordination on my team. We have over a dozen engineers working on as many different workstreams. As a tech lead, keeping track of all that state has gotten increasingly difficult – the job always involved a degree of strategic plate spinning, but the amount of raw output from my team has grown multiplicatively with agents, increasing coordination overhead. It’s clear there’s a ton of work ahead to recast processes to support engineers collaborating with agents at scale. One useful component I’ve stumbled into recently is what I’ve been calling “agent gadgets”.
By way of illustration: I built a local tool for myself a few weeks back which was an extension of the “Ask a Question” tool that most harnesses have built in.1 My version is better in that it supports way more questions: It’s a tool that allows an agent to ask you a ton of questions all at once, surrounded by markdown. The questions can show up in tables with suggested responses, multiple choice, free response, and so on. I’ve found this pattern transformative for PR triage and for having an agent clarify many questions about a design with me in a single pass. I call this blob-of-markdown-and-form-inputs a “canvas”, and it’s made me noticeably more productive in collaborating with agents. After using this for a few weeks, I found myself sharing this idea with coworkers in meetings, and then thought: “oh, I should package this pattern to share with everyone on my team”.
In parallel, I’ve been quite interested in what’s been happening in the mathocalypse befalling modern mathematics.2 I’ve been doing the most novice armchair sifting through some of the recent math and theoretical computer science papers, and one piece of terminology I’ve loved from these papers is the use of the word “gadget”.3 A couple of quotes as flavor text on the use of gadgets in theoretical computer science:
To describe the reduction, we follow a standard strategy of decomposing the output graph $G_\Phi$ into gadgets, which are subgraphs that correspond to various components of the input formula $\Phi$. Decomposing reductions into separate gadgets is not only helpful for understanding existing reductions and proving them correct, but for designing new NP-hardness reductions.
A “gadget” is a finite combinatorial structure which translates a given constraint of one optimization problem into a set of constraints of a second optimization problem.
– Trevisan, Sorkin, Sudan, and Williamson, “Gadgets, Approximation, and Linear Programming”
In my mind, the original meaning of gadget has this implication of something unwieldy, yet definitively “fit for purpose”, suited for a very specific niche problem. If you have the specific problem a gadget was designed for, it solves it well. Gadgets are unashamedly not intended to be general-purpose, polished, or elegant.
Contrast “gadgets” with “tools”: A tool is something that’s comparatively generic. You can give anyone a hammer and they will be able to do hammer-shaped tasks. A gadget is something that is specially crafted. Gadgets fit your exact workflow, in a way that would be unergonomic for others, but is extremely well suited to their intended purpose.
A “gadget” lets you ship a bit of a hack, but in a way where the hack is actually “worse is better”. If the gadget is legitimately useful, it gets increasingly formalized and pared into the shape of a tool. If it’s only marginally useful, it can stay in its somewhat hacky state and can be discarded when no longer needed.
Gadgets are effectively compressed “figuring stuff out”. Agents are very good at figuring stuff out, but specialization and stored procedures are a thing for a reason. Once you figure out something that works well, cache it for future use. This could be in a script that lets you skip steps, a UI that compresses information in a particularly intuitive way, or a skill that bootstraps the agent’s context window with salient information that wouldn’t otherwise be so neatly organized.
The human interface over all this is just being able to talk about the thing you compressed in plain English. When your agents have good gadgets for operating in the environment you’ve put them in, they’re much faster and more effective.
For example, we recently changed a nitpicky detail of how PRs are created at my company, in a way that disrupted uploading images to PRs. I hit this issue, and had my agent develop a workaround. Later, a coworker asked if I’d been able to solve this. I said that I had, and checked my PR-image-upload gadget into our codebase so that everyone else’s agents could use it.
To some extent, yes, this is just rediscovering “common scripts” from first principles. But I think the difference is this: with common scripts, you needed to design for humans. With agents, you can build agent-to-human or agent-to-agent gadgets that the humans operating the codebase mostly don’t need to be aware exist. Gadgets can be hackier and more disposable than a human would be comfortable with, because an agent has much more patience to execute arcane script incantations than a human does.4
These gadgets fall loosely into a few different categories:
There’s so much low-hanging fruit in sharing these gadgets, because agent harnesses are, out of the box, fairly opinionated and restricted tools. They have opinions on how you should interact. They restrict what sort of inputs, outputs, and UX are easily afforded to you. But you can build meta-harnesses around your agents, and those meta-harnesses can have essentially arbitrary UI affordances.
My team and I have been working on a coordination layer that lets us share state between people and between agents – not the Slack-like systems that have become memetic recently, but closer to Linear, where you’re storing state as a graph and doing operations on that graph. Once we created that shared state and UX layer, adding gadgets onto it became quite easy.
This has begun a virtuous cycle. For example, multi-agent, multi-round review is a really useful way of doing PR review. One of my coworkers is passionate about this style of review and is building tooling for it. I’m not as passionate about this approach (I just don’t have the interest to build a really good one myself) but I think it’s neat, and if I use his shared one, I get that utility for “free”.
In a similar way that I’ve been a big proponent of using agents to build hyper-personalized software to increase your own personal velocity, I think figuring out very low-friction ways of sharing these gadgets is a high-leverage thing to do.
For example, here are the docs for Claude’s version of this. ↩︎
In many ways, the description of mathematicians’ experience of the impact of AI on their field mirrors what happened in software engineering over the past 18-24 months. ↩︎
In the 2010s, “gadget” became synonymous with “tech device”. Those tech devices became, over time, undifferentiated glass rectangles. Thus, gadget came to have the implication of an eye-roll-inducing iteration on a stale format – but I think it’s a great word worth reclaiming. ↩︎
I cut my teeth early in my career in CLI design/UX, and making good CLI tools that humans actually want to use is not easy. ↩︎
正文由 探How 从来源站点 RSS 同步,内容未经改写;遇到排版缺失或需要图片、视频时请以原文为准。
