Stop Prompting, Start Delegating — Ross Cefalu & Dex Horthy, Factory
Read full transcript 51 segments
-
Going to get started here shortly. Hey, I am Ross. I am a member of the technical staff at Factory. For those of you who do not know, Factory makes AI coding agents for the enterprise. Our coding agent is called Droid. It specializes across the entire SDLC. But today, I'm going to be talking about a new product we've been working on called Work Streams. Work Streams is the evolution of our long-running agentic workflows. So, I don't know how many people here are familiar with Factory, but we used to have a product or we still do have a product called Missions. This was our first iteration of what would it mean to have agents run pretty autonomously for days, even weeks at a time. Obviously, we launched that or not obviously, we launched that in January and the models have evolved quite a lot since then. And so, Work Streams is this next evolution of all of our harness research, model evolution, and what we've seen really work for our customers.
-
So, before I do get started, I know Kyle, who's also from Factory, and Julia, who is somewhere around here, have Factory codes and various things. There will be a collaborative portion at the end if people want to download Factory, give it a try. We have codes for free. Wanted to call that out at the beginning just so people had time if they'd like. So, really the idea behind a Work Stream is that most work is not these one-off tasks that people prompt agents for. At the end of the day, you really just want to give a direction and ultimately have the agent orchestrate that, handle delegating tasks, deciding should this be a sub-agent? Should this be a new task? How should I break down PRs? You know, ultimately as the models get smarter and smarter, more and more of this becomes implementation details that we believe should and ultimately be abstracted away from the end developer. Uh, what it is not is saying the humans are completely out of the loop. Ultimately, it depends how you use a work stream and what you're trying to go into, which I'll I'll talk into next.
-
But I think we still view that the human developer is there to guide the work streams, provide directions, set up the scaffolding. Um, but they really shouldn't have to think about like how to break down PRs, how to think about, you know, oh, should I do this first? Should I do that first? They should really have this really smart, we think of it, you know, almost like an engineering manager they can converse with, and that engineering manager can go down to their team and delegate the work. So in this concept, we call it an orchestrator. So really at a high level, a work stream is a chat with a orchestrator, and that orchestrator is really deciding how any everything gets implemented. Uh, there's a lot of lot of things behind the scenes that go into how that actually works, and actually someone else from Factory uh, I think believe tomorrow we'll be going more detail. But at a high level, it should feel like you're having a conversation with this really smart engineering manager and they are then delegating to your agents. Um, and you can kind of see this on the side here where the orchestrator will communicate with the agents. The agents will then communicate back. They can surface up details. Depending on how you set up your work stream, sometimes the orchestrator will just handle all the questions from the agents. If you want to be a little more hands-on, you can kind of jump in and you know, founder mode if you want to call it that and really kind of get in the nitty-gritty with each of the agents. But uh, again, it depends how you want to use a work stream.
-
Which goes into nicely here. So I think there's obviously other products in the market that are trying to accomplish the similar thing and I think what we want to specialize in on work streams are these six core workflows that we found really work or well, five core ones and then the ability to kind of customize it uh to your needs. Uh, so the one that we've seen uh probably the most use cases internally is just a core development partner. So internally, I have a work stream set up for I I lead our apps development and so anytime I really just want to clean up bugs, I just have one work stream for that. I have an orchestrator that really has context across our entire how I like to fix bugs, what bugs I think are important. Um, and really I can kind of just delegate essentially how many bugs I wanted to fix uh because ultimately like the bottleneck then becomes like okay, we're now just dealing with like a lot of you know PRs and everything like that. Uh, but ultimately I can trust that development partner to kind of carry out my wishes around how to fix bugs, you know, especially in an app surface it's not always exactly clear.
-
Uh, and so we do have a concept of a shared file system which I'll go into later, which you can think of it as a collaborative space for both agents, humans, um and your orchestrator to kind of build this shared understanding about how you're trying to accomplish your task. Um, another one is a very hot button topic right now obviously is vulnerability discovery and remediation. There is and I'm kind of hinting at all these core components I'll get into later, but one big component of a work stream is the ability to set up automations within them. So anyone who's ever you know you build an app typically there's maybe or a surface or anything like that. There is this initial hill climb to get the feature out and then some of the things start to become these background automation tasks and we wanted to build that natively into work streams from the get go where you can essentially tell your orchestrator hey, this is going to be a pretty continual task. I want you every day to go you know scan the code base for the latest vulnerabilities or things like that. Um, it can also be hey do a sweep of our bug reports and triage the most important issues and then that orchestrator will surface uh the issues to me or if I ask it to just go clean up um the issues itself, but we find this is really helpful for vulnerability issues because again it's just you need that level of autonomy where ultimately at the end of the day we and for some of these we just auto merge them given obviously sometimes the complexity or simplicity.
-
Uh, but at the end of the day the engineer really should be there just to click approve on a PR if ultimately that's the final gate. Uh, migrations. So anyone who's ever whoever used our early missions products this was the most popular use case by far where I have X code base and maybe some coding language I want to get it in another. I have this legacy service I want to modernize it into something else. This is by far the most hands off use case. I've seen these run for weeks at well yeah, I'll say weeks at a time. Uh, and really they're designed for the human to be as pretty out of loop as possible with a heavy planning stage. So we wanted work streams to be adaptable to sometimes, you know, you really do need a big planning stage up front and then you can trust the agent to kind of build these validation loops. Um, that's ultimately how we kind of view migrations is building these automated validation loops, um, again, that your work stream can handle automated research and discovery. This is probably my favorite use case of work streams are just really long-running agents in general. I think auto research is another term that I obviously was popularized, uh, but really just defining the objective function and then letting the agent hill climb on it. I think it's going to be an increasingly popular way of doing work, especially around UI, UX performance, um, optimizations, and really anything where ultimately you're really just trying to optimize a set of numbers. Uh, agents don't get tired and ultimately they're really good at, uh, hill climbing on those types of things. And what we wanted to build into work streams is the ability to maintain coherence across really long runs. Uh, we found with some other auto research tools and things like that, ultimately you need to be a
-
little more prescriptive and really make sure that the agent is kind of not deviating too far from your initial expectations over a long time. And again, I'll I'll talk about this in a second, but, uh, the shared file system is really our core concept there is trying to build, you know, the equivalent of what would a Notion project look like if it was collaborative across humans, agents, or well, your orchestrator agent, humans, and then obviously everyone doing or all the agents doing the work. Um, AI development automation, I think almost every PR at Factory is just thrown through a work stream at this point as a as a get go, um, which I find really interesting because obviously we have our own internal, um, QA that runs on all of our PRs, but we found that everyone, especially like more senior engineers, have particular things they want to look out for. And you can't obviously customize a generic code review bot that will scan for everyone's preferences. And so for example, I have a really strong preference to make sure we don't have any performance regressions. And And I have a work stream that's basically taking any PR that touches um UI files and running it through kind of my pre-configured workflows for uh performance regressions.
-
And I know everyone's kind of tried to you know encapsulate that of like what does it mean to kind of have these In the age of AI code review, what does it mean to still have maybe these nuances and like how do you incorporate human tastes and preferences and things like that without necessarily having to scale you know you'd spend all your time doing code review with uh you know I've seen a work stream crank out 100 PRs in a day and ultimately you need another work stream to uh handle that volume and so you know it's a little bit of you create you know create a great solution you have to find a great uh defense against it. And then custom. So that's the fun part of work streams. They build upon almost every open standard that's available. You can customize them. You can create an orchestrator to behave pretty much however you'd like, delegate however you'd like. Um this is where we think developers are going to have a lot of fun and especially a lot of our you know bigger customers pre-configuring these workflows for their employees uh to come in and just have like a great experience off the bat. So I'll kind of go through this a little faster um but how setup works is ultimately you have to decide where this system's going to run.
-
Uh we have a handful of compute options across uh you know BYOM, our own uh ephemeral cloud sandboxes, a local uh my favorite part of work streams is they can pair all of these together in any which way you want. I can have a local orchestrator delegating to my Mac Mini at home and also delegating to a series of cloud sandboxes that it's spun up for you know simple tasks. I can obviously do the reverse where I can set my home computer up as a BYOM machine and then delegate past. Ultimately we just think this idea that everything's cloud, everything's local, everything needs to be on prem, everything needs there. It's just you need to have the flexibility and we wanted to design work streams from the ground up to make sure it it was adaptable. Uh pick a starter which was kind of what I mentioned earlier. Uh confirm the goal. I think we find the best thing is you really should just chat with your orchestrator to start. What are you trying to do? What are you trying to go after? Um, I find the most fun I have with work streams is the less I say up front and the less prescriptive I am, I get some of the most interesting results. Um, I think, you know, if you're too prescriptive, I think you're going to end up constraining what the agents can do and in some cases, uh, I want to say the agents are smarter than me, but I think they're less maybe blinded by my biases or expectations or I'm thinking that we need to solve something in this way and I think when you set up a system that really can operate autonomously for long running periods, it's really beneficial to let it come to its own conclusions, um, obviously with guardrails, but I think the best results we've seen is where you really provide this directionality goal and less prescriptive on exactly how to
-
achieve it. Obviously, unless you, you know, specifically know. Um, yeah, some more questions and then yeah, I think the final thing is how involved do you want to be and so this pairs with all of them that at the end of the day, development workflows are very unique. Some people want to be, I've seen people, you know, jumping into each orchestrator chat. I think where is the photo? Uh, so yeah, you know, if you have your agents right there, you know, jumping into each one, really treating it like each agent is its own session. I've seen, I personally just talked to the orchestrator and kind of close all the other panels, um, and trust that things are going to, you know, work out well but ultimately I think the one thing we've learned is you need to adapt to people's workflows and there is no, at least in my opinion, no right way to build software today. I think there's a lot of great ways, but ultimately it depends what you're doing, how you're doing, how you prefer to work and honestly what you just enjoy. Um, you know, it's one thing to say you can take your hands off the wheel, but if you like your hands on the wheel, that's I think it's crazy to say otherwise. So here's a little high level, uh, diagram, but really this is essentially everything I've been sharing earlier just maybe in a nicer picture. Uh, the one thing I wanted to call out are the automations and the shared folder. So you can think of these as these shared context spaces across all of the agents working.
-
The shared folder can be plans, notes, handoffs uh it is interesting because depending on how prescriptive you be, are you are, sometimes the the agents like to communicate in fun ways that I don't exactly not not to not a not a that type of way I don't understand, but in a way that is you know very adaptive and you can see really this like really cool coordination happening. Um and then sometimes I actually prompt a lot of my agents to say in this shared folder keep a space for us and that's where I want the notes a lot more structured. I want the notes a lot easier for me to follow versus when it's the agents communicating, it's actually pretty interesting patterns that emerge. Um but yeah, ultimately this can be outputs images plans specs learnings for my code review workflow. I actually have a folder for each person on my team who I have basically learned preferences and learned uh maybe areas where I think they often make mistakes and so I think it's kind of building this shared understanding that ultimately now my orchestrator can just pull that in whenever I send a PR.
-
And then on the back end as I was kind of saying, the agent can delegate across any environment, team, etc. And then at the end of the day you get um PRs. That's ultimately the output I think we're optimizing for. We have some internal workflows where people are using this for non-technical work, but I think ultimately really where we're headed initially is you'll get a list of PRs. We have uh yeah, and then you get to review them right in the app and hopefully merge them. So kind of been hinting a lot of these. Ultimately the orchestrator's job is to coordinate the agents. So we give it a series of tools. I don't think these are the exact tools, but it's representative of the tools that the agent has to basically create agents, ask what they're doing, receive a message, interrupt an agent, and create an automation. And really the only job of the orchestrator is to make sure that you are having an enjoyable development workflow and that things are getting done. They really should not be doing any work. Sometimes it is helpful if you just have a quick question, but really they should be delegating as much as possible. And I think what that allows you to do is main maintain and always on partner to ask questions. I think people have tried to figure out how do you do this with side chats and you know multiple sessions and things like that. I think our solution is that the orchestrator should always be available and really just delegate everything out so that when you come in you're not really interrupting anything.
-
Um and the agent can figure out if it needs to go uh interrupt or do anything else. The agents so these you can think of as the closest semblance to like what sessions have existed for you know maybe the the better part of the last year where you can configure them the model skills MCPs you know basically any open standards you want. They report back to the orchestrator. Um they can be long-lived. I've seen some agents that honestly kind of outlive um you know maybe not you know a week's worth of work. They can be throwaway agents. Really this is again somewhat how you prompt the agent and also how you um you know what you're working on. Machines yeah I talked about this a little earlier but we believe that really this should work across any type of environment that you were doing development in and it should work. You shouldn't be constrained just cuz you started in one and you need to delegate to the other. If you have you know and sometimes in a corporate setting you have information that has to live on specific types of BYOM machines but you really want to be able to fan out other work across kind of an ephemeral cloud compute plane um and then ultimately maybe you have some files locally you need to orchestrate or the orchestrator needs access to. And so really we want it to be adaptable. I do find that the scalable cloud compute is really the best way to run this at scale. Um I think the best a lot of the best results from work streams come from being able to fan out work across 10 20 30 40 different um agents and each one of those agents typically will run on their own machine and so this is something where we are
-
seeing that you know how can you make sure that you have this type of scalable compute infrastructure and we think it's going to be uh increasingly important to make sure uh as we kind of get into this next layer of agentic orchestration. The shared folder. So I wanted to talk a a a good bit about this. Um one thing we learned with missions which was our our first foray into agentic or you know long running orchestration is that maintaining coherence um especially as you make the objective function less and less defined is quite hard. Uh obviously if you create a long running agent you say I want to get this number smaller it can kind of maintain coherence because it has that north star. Uh as soon as you start saying I want to make this product better well that becomes a little more subjective little becomes you know what is better sometimes maybe removing a feature is better but you don't want to remove the feature you know it's all these things where you need to kind of understand preferences and tastes and kind of these like micro interactions you might have with the orchestrator where it suggests something and you're like no I really care about this well you don't want to have to keep saying that and so the shared folder is our kind of thought on how I guess large scale projects will be orchestrated across humans agent humans and agents um in the long run and so the agents can write up to the shared folder the orchestrator can write up to the shared folder obviously humans can read it and then everyone can obviously pull down from the shared folder and the agents are prompted to basically use this as a source of truth um and actually sometimes it is how they
-
communicate so they can communicate with each other but also it's very helpful if multiple agents are working on one project to be able to basically write everything up and then everyone can pull everything down. Uh you get into some fun like race conditions but I think we've solved that in a pretty some fun interesting ways and actually it's pretty amazing how adaptable the agents are to like understanding when something feels out of date and then kind of basically asking the other agent to update it and everything like that. Uh I think it's one of those it's one of those things where I think yeah agents really are quite adaptable to for their ability to handle what I think used to be maybe blocking edge cases where it's like oh this would never work um they're just they're just quite smart. I think the general rule of thumb is if a human would kind of understand that then at this point we find that especially for large scale collaboration agents are sometimes better. And as I said the ultimate end result is a pull request and so at the end of the day you'll get a list of pull Um you'll be able to review it directly in our app. Uh we've built some really fun stuff when it comes to actually viewing these pull requests, um around like semantic diffs, walkthroughs, validations because as easy as as easy as it might be to say that oh, you know, you need to read through the code, you need to understand what your agents are doing.
-
When the work stream is populating, you know, hundreds of PRs, um potentially a day, really you need to pull up the level of understanding to what humans can kind of quickly go through. And we find what we've built with walkthroughs, which I don't know if I have in the slides, but I have a example of later, uh is really a great way to do that. And I think you really have to start rethinking code review at scale when you start, you know, kind of implementing these types of solutions. And so I think baking work stream or pull requests into work streams from day one was something we just realized you had to do or else you uh actually the first version of work streams did not have any of this and we ended up with a lot of draft pull requests that were not merged. And that's, you know, not good for anyone. The final thing, I think, final thing, automations. So as I said earlier, you don't want the human to have to keep going into the chat every day and saying, hey, can you go check my inbox and see or what not inbox? Can you go check our linear uh and see if there's any new bug reports? A lot of that is pretty monotonous. You can put that on autopilot. And so automations are built directly into a work stream where either the human can suggest that and say, hey, I'm, you know, every day, yeah, every weekday at 9:00, summarize the open to-dos.
-
Uh what I find most powerful is actually the orchestrator can create these automations as it kind of discovers the workflows that you're doing. Uh it obviously again, depending on how hands-on you want to be, we'll ask for your approval, but I think people often find that you get used to these micro frictions of just everyday doing something. And really the goal of the orchestrator is to try to make this as smooth as possible. And we find giving it as much powerful as much power as possible to really create um these new types of what's the right word? Kind of these new types of workflows for you and then be like, hey, wouldn't this be more helpful? So, in the hands-on portion, which I don't know, by a show of hands, does anyone actually have factory up with a work stream possibly able to be working on? Okay, all good. I can I'll do more of a live demo of that. I was uh prepared for this. Um Hey Dex.
-
This is also Dex. He'll be around to help as well. If anyone does like to get started, we do have Dex and Kyle um who would be happy to answer any like maybe specific questions if you need help getting started as we go. Um let me see if I can make this bigger. Um Oh, the fun of live demos. Good fun. While I debug this in the background cuz this was working earlier, uh does anyone have any specific questions or anything in particular they would like me to go deeper into uh when it comes to work streams and what we've seen work? Any thoughts? Anything that people find very interesting? >> Uh yeah. Do you use different models for the review from the >> Yes. So, the models can be configured across the different agents and the orchestrator. I believe right now it is constrained to a orchestrator model and a worker model. Um the next evolution I believe we want to let the orchestrator essentially delegate to the model of choice um obviously cuz you might and then each uh sub agent or agent can then delegate to sub agents which then can have their own models. And so really our typical suggestion is your highest level orchestrator is your state-of-the-art model and then you cascade down as the work gets simpler and simpler.
-
>> This is fine. Okay, perfect. We're going to do this locally then. Um Um yes, I believe that we can share that. Yeah, that sounds great. Um okay, perfect. So let's we're going to run this locally. Um Is it a workflow that provides the engineering pipeline? Yes. Yeah, so this it really adapts to the workflows you have. So we have people who are using it kind of really who want to automate the SDLC. And I think what that creates is you can have this planning stage where you just suggest to your agent I want to make things, you know, faster, better. I need to solve this customer pain point. And it will first present you with a series of plans, specs, kind of how you define them. And then you can approve those and delegate off all the way to PR review where then you can have automations that essentially review the code and then if you're feeling risky, auto merge or obviously get people to to merge those code pieces.
-
Um perfect. Kyle, do you have any good demos we could run possibly? Oh Dex. I think that would be amazing. I think you have a loud enough voice. >> What? >> Do you have a loud enough voice? >> Uh oh, I can I can Is this one Is this one hot? Can you guys hear me okay? What's everybody? I am Dex. I work with Ross and Kyle. Formerly I was the CEO of Human Layer, but we have now joined forces. While he's getting that set up cuz like I can show you all basically what a work stream What would you rather see like one from scratch or like what does a work stream look like after it's been running for a while with all the pieces going?
-
Okay, all right. I did not make out any of that in any manner, but I'm going to do the thing I said I was going to do and we're going to see how it goes. Give Ross a break. I know he's been cooking for what is it like 40 minutes on stage. I've done one 40 minute talk in my entire like life of doing talks and I think 20 is 20 is the is is where I run out of steam. Let's see. All right, can you guys see this? Nope. Display. Actually, we'll move this over. Are you just mirroring, Ross? >> Yeah, mirror. >> Okay. Let's see what we got. Incredible. Okay, cool. So this is a work stream I've been working on for quite a while now. It's got And I can zoom this in a little bit maybe.
-
I'm working on a specific feature for factory, actually a work streams related feature, but I'll close the sidebar just so we can see this a little bit better. So I have my orchestrator. It's been running for basically since like roughly two weeks ago I started all this work, so it's got a ton of different agents, all of whom are have been working on various bits of research and things like this. And then Has anyone heard of like RPI or Crispy like this like methodology of like context compaction with agents? So yeah, I've been using the shared file system to track all of my RPI docs, so we have like research on like some road map stuff. We have like a product requirements document of like the thing we're going to build. And then we have like a whole stack of PRs. So there's, you know, 22 merged PRs from here and five draft PRs and two open PRs.
-
I did have like 30 open PRs or 10 open PRs, but then the CI team told me that we should stop thrashing all the review bots. So but I have this thing. It has a rule of like, hey, have two open PRs at any given time. Keep an eye on them, watch them, update them or merge in the issues with them. So it's like I can just come in here and like check So this is a specific agent, but I'll go back to the orchestrator and I can say like let's check on the open PR statuses. And we'll see what we got. And then yeah, we have the PR review in the PR view in here I I'm a huge fan of. I basically don't even review PRs on GitHub anymore because it just surfaces all of the interesting stuff. Looks like this one was approved and was small enough to be eligible for auto merge. So but other things that this this work tree so it's going to check on that. We'll jump back. Other things that this thing is managing is like basically like our product requirements docs and like being able to work with the team and like kind of align on what are we going to build and what is it going to look like. And so, like, I can send this to my team and get feedback from product, from other engineers who have a lot of opinions, and then also had my work stream walk through, like, building out the technical design of, like, what are the database tables going to look like and, like, what order are we going to do all this work? Because this is, like, probably, like, 20,000 lines of code for this feature, of which we've done, you know, a few thousand so far in the last couple days. It's a lot of planning up front.
-
So really powerful like workspace to have a long running large project and manage the contacts with your team. So let's see what it said about our PRs. So can merge now, approved, all checks pass, ready to merge. Let's merge and promote the next draft into an open slot. Uh that's really the basics. I don't know Ross, did you do you have do you have something you want to show off? Should I just do like creating one from scratch? Do people have questions so far about like how we're using this and like why it's dope? Yes. >> Yeah. >> There's PRD, there's tech design, there's how do we break it out into slices. Ah that's a great question. Um so it's actually it's not visualized here. That's actually a thing that we were talking about like kind of baking into the UI more so. Uh I'm using a open source skill that you are welcome to grab which um let me just unplug quickly cuz I'm going to switch to my browser and who knows what tab is open.
-
Um oh I know what tab is open cuz I opened this. Um all right here we go. We're going back. Um so this is currently still in the like human layer skills repo, but we're going to get this like packaged up and and probably some somehow merged into factory, but it's basically a single skill that has all of the stages of of product design uh and and building built into it. This is how I like to build, but the idea with Work Streams is not to bring opinions about how your SDLC works. It's to give you the right building blocks so that you can kind of codify in skills and prompts how your team likes to work and then you have the shared file system as a source of like shared context between agents. You have the orchestrator and then you have the automations feature which allows you to kind of say like hey every hour check on the open PRs and if there's merge conflicts go fix them or thing things like this. That's like the most generic like simple automation. I don't actually think I have that. Um create an automation so that when PRs are ready to go they get merged.
-
Um cuz I I I left this last night. I came back to it and I was like, hey, this PR is ready to merge. I'm like, okay, well, if it's approved and and everything, like why isn't it why isn't it merged? So uh we need an automation for that. Um but the other thing I think that's interesting is just like talking through how all this fits together. Um which is, you know, you have the work stream itself which is sort of the large parent object of all of this stuff. And then in here you have the orchestrator which will run, you know, any number of agents, agent one, agent two, and it will sort of like archive these if their if their job is like completely finished. Um but like our agent that built that product requirements doc is still open and every time we hit a surprise during development, uh the orchestrator without being prompted is going back to my PRD agent and having it update that like description of what we're building as well. Um the other things that sit in here are the like shared file system.
-
So the orchestrator and all of the agents Um oops. The orchestrator and all the agents are basically all able to read files, write files, communicate with each other through that file system. And then yeah, we have this automation's thing. Uh which is basically the orchestrator or any agent can basically create a trigger. Like the simplest version of this is like on a cron send a message to, you know, agent, whether that's one of the individual agents or the orchestrator agent. Um and so these automations kind of talk back. There's also stuff here uh where you can um Ross, I believe do we have webhooks too? >> Yes. >> Yeah, so you can tie this up to like webhooks like if a, you know, PR review comes in with like requested changes, send it to the agent. Comes in in requested changes. I know I know this is planned, but I wasn't sure if it was out yet. Uh, send to the agent. Send to dollar agent.
-
And these are kind of like for me the the the main building blocks you need to run a giant agent swarm. You need the ability to manage a bunch of different workers. You need uh a way to wake things up, whether on a schedule or uh or in response to an event. And then you need a way for all those systems to kind of share context and share memory. Um and so when I run this, I have this orchestrator is running on one like server that is built off of a template. Uh so I'm running all this in the cloud. You can also run this locally. Um so I have a template which then every time a new agent runs, it gets a fresh template with just the repo checked out. And so the orchestrator will tell it, hey, go get that branch that the other agent was working on or like they can communicate to each other through git or however you'd like as far as like sharing work in progress. Um but every agent kind of sits on this uh in like a VM slash sandbox um for each agent. And so the template has my setup of like my skill. It's just like a bash script. Uh I can actually show you probably. Um let's see.
-
Uh yeah. So we just have all these environments on the team. And so like this one is mine and it's just got a setup script that like installs a couple tools and things like this. And then anytime an agent launches, it gets all this setup. Uh and this is like a pre-baked image. This doesn't run uh this doesn't run every time an agent launches. We bake the image one time every time you change the script. Other questions? >> Yeah. >> Yeah, what's up? >> Can we go back to the diagram? Uh this is uh the only way for agent one to know what's been done by agent two is just to look at the shared file system or is there another system that you've implemented that allows them to gain knowledge on what's been done previously? >> Um so they also talk they they can talk to the orchestrator. So they they they can send messages to the orchestrator with a tool and the orchestrator can interrupt them and inject message like steering messages into them either as they're working or or stopped. Um I can also go to one of these specific agents. Um, let's see. I can just pop into one of these specific agents and talk to it directly. I find myself 80% of the time I am talking to the orchestrator. And then every once in a while if I'm doing like a very like an interview sort of like a Matt Pocock style like grill me thing, I may just talk directly with that agent so that it doesn't have to like do two hops through the whole thing. But you can see here that this one created an automation which will check every 15 minutes.
-
Uh, and then it messaged one of my working agents that's working on like slice number five of like, hey, by the way, I made an automation that will ping you every 30 minutes or whatever it is. Um, and so it's like, yeah, you you can stop checking every 30 minutes. You will get a you will get a ping. Um, and so they they can message each other. So I can come here and like tell the orchestrator you're on screen at a fun workshop. Um, and so you can see here it sent another message of like, hey, I redeployed the site with the tech design. Um, heads up from the human. I'm on screen in a fun workshop right now. And then in the orchestrator view we'll see that it uh Um, oh, I got a message from TDD and it's thinking about it. I'll keep things quiet. Yeah, thank you. Don't post anything in Slack without me. Cheers. Uh, other questions?
-
And Ross, I don't know if you want to do you want to come help answer questions or whatever if you want to the demo. >> My my computer decided to stop working midway through, so I've been live doing that. But yeah, happy to help answering the questions while I work on this. >> Yeah, what's up? >> Yeah, that should be good. Like pretty great talk. A few months ago live software Oh god. All right. >> Yeah. >> on pushing a lot of the time invested in reviewing PRs in the upfront spend. >> Yeah. >> Can you talk a bit just from a high level how well that's worked to a new, presumably much larger team. How much of your time are you actually still spending communicating agents in chat versus letting things run after you put together a You know, documented spec for a new feature. >> All right. So first of all, why software factories fail was probably a bad name for that talk. Uh and if you watched it, you kind of understand like I actually love software factories, right? And the whole point was like not all software factories are doomed to fail, but there are things you could do that might cause your software factory to fail and I you know, here's what they are and please don't do them.
-
Uh things like going fully lights off and things like that and like losing touch with the architecture of your system. Um I will talk more about that on Thursday at the keynote um about like, hey, what's the next chapter and how's that thinking evolved? But uh overall, I think upfront planning and building like product requirements docs like this is like so much more useful on a team of 50 engineers, especially everyone's super high agency, everyone's super autonomous, everyone's building 10 different things at once. Uh, or we have these little, like, autonomous pods, and so it's, like, very useful to be able to be like, "Hey, here's what I'm thinking about this feature," and people are very active and chime in and give feedback. And, like, I even built, like, a janky, like, commenting system into here where I can say, like, "This sucks." Uh this is actually just like fun HTML trick you can do if you're doing static HTML is you could say like keep it all there's no backend to this, right? So I say this sucks, I say this is great. Uh and then this thing just stores those comments in local storage. So if I re refresh the page, I can just copy them onto my clipboard uh and then I can like paste them into my agent like this. Uh and it just tells it like, hey, the human said this about this part of the doc. Um so these are the kind of workflows and so like people would send me this. Yeah, my the short the the very long answer, but I think the short answer is that um the uh the bigger your team and the more that is happening, the more valuable it is. I mean, before it was like me and Kyle and a couple engineering contractors, and it was kind of like, "Yeah, we do this review stuff cuz we believe it's important, and we need to use the project to do it the product to do it so we can make the best product .but" I I matters even more and I mean a few
-
systems was always like the if you're at an enterprise with hundreds of engineers and hundreds of repos, this gets even more valuable. Great question. Yes. >> Yeah, what is that one? You want to show that off? >> Yeah, I can show that real fast. >> Did we fix your Did we fix your laptop? >> It is slowly getting back to sanity. I don't know what I did to it. Uh perfect. Okay, yeah. Um this is actually for a random feature I had a work stream work on. >> I was [laughter] saying I love this thing and then I didn't show them the cool part of it. >> Um so yeah, it starts off just like a normal PR review. This which should feel like GitHub. Um files change again should feel like a GitHub. But walk through is kind of our opinionated take around what we think code review should be or will increasingly become. So you can kind of click through these product changes. It should tell you, you know, where in the code did this actually happen, things like that. Um we tend to break it down of like what will the This is a UI change. So it breaks it down into what will like the user experience change and that's the product change. Um under the hood, obviously how does this all work?
-
Then you get the architecture of basically kind of walking through how these different changes happen. So this is not really like a like systems architecture. It's more like a code architecture. Like where are these changes happening? Um where were files added? Where were they modified? Where were they possibly removed? Um this is a relatively small change, so it's still pretty pretty easy to follow, but And then it breaks it down into a semantic essentially a semantic diff where it kind of walks you through each one of these changes, um what happened, where the files changed. Um obviously if there are just any normal GitHub comments and things like that that run, they'll show up where they should. Um I don't know if this is >> I'll just say like what's really cool about this grouping >> is like if you open a PR in GitHub, you usually get it in alpha numeric order. And like, I don't know if how your, how like you review code, but like when we were working on HumanLayer, it was always like, "Okay, I have to scroll all the way to like packages/db," cuz the first thing I want to read is like what new tables are we adding and what new schemas are we adding. And then I want to scroll up midway through the PR to find the API stuff. And then I always want to read the web app stuff last. But if you're just doing it in alpha numeric order, like you're going to get all the changes like way out of order. And like this is a problem that AI is actually really really good at solving of like take all the information that's here and restructure it so it's more consumable.
-
>> Yeah. And then I think the final thing for like so if this is a UI change, we always um push through a validation PR. So have the agent then walk through the exact product changes, run the app locally or well in the cloud in this case, and then send you a video of what the new change would look like. This obviously works when you're working in like a front end styled repo, but uh basically the the general concept is you should make PRs as human readable as possible. You should have as as much visual evidence as possible and as much things that allow people to get context without necessarily having to read every line of code. Um my actual like code review I was mentioning this earlier my I do then have an opinionated code review work stream that is around specific files. So I think as Dex was kind of mentioning that like there are still files that matter in my opinion. Uh but not every file should have the same level of importance. And so, how do you kind of pull out these very core files that you probably should still understand very at a pretty deep level how the code works, while pulling out the noise of, like, you know, you made a bunch of components that arguably, you know, it's the agents wrote them anyway; they're going to understand them a lot better.
-
>> Or maybe there's, like, specific patterns in the codebase that, hey, you've reviewed 30 PRs in the last month and you're like, "I keep seeing this issue," and, like, I'm happy to keep commenting on it; but, like, how do I, like, log that and make sure that, like, these things that we we know the agents have a propensity for doing, that we maybe don't think is optimal? Like how do you how do you bake your opinions into that review process uh whether it's by file or by pattern or whatever. >> I I going to say you very nicely this is my detection pattern file that's in their shared file system for reviewing front-end PRs. But basically, it's all the patterns I've noticed that I find people mess up in our codebase. Then the idea is you can pull this back. So actually, I now have a workflow that pulls this back into skills that then modify how we tell the agents how to do certain things in the codebase to hopefully make this like a self-improving loop. >> Do you talk to the AI to build this out or is this like an automation that just checks whenever you review a PR like tries to pull new insights out of your >> This was part of how I set up the This is how I set up the work stream was basically my whole goal is to build like this knowledge base and so as you review, check against our detection patterns and then I have an automation that will then try to update the skills on our repo.
-
>> Okay, software factory building blocks for the for the the world where you're not quite designing the code, but you're designing how do we make sure that the code is constantly getting better and we never have to say the same thing twice, right? >> Okay, I was about to have >> Yeah, there's there's actually an entire talk that could be given about the unreasonable effectiveness of Oxlint. Factory actually has a really good open source Oxlint rules repo that I highly recommend checking out and trying. But that's also actually like a great use case for work streams is: to have an automation that is periodically, like, going through all your pull requests and looking, like, what are the things that humans keep saying over and over and over and over again, and then turn those into Oxlint rules, or into formatter or linter rules, so that you don't have to keep telling agents that. There's even like a Jev plugin for Oxlint so you can just write a rule in in natural language and and run it. It's another like great use case for just how do you actually make a software factory that's getting smarter over time and like lowering the load on humans who have to do code review over time.
-
>> Anybody here writing in TypeScript? No, the rest of you are not writing in TypeScript. [laughter] Wait, what languages are you using? Prompts? Elixir? Okay, well, if you are writing in TypeScript, you should absolutely be using Oxlint. Factory has a great config. Also, Dylan McElroy is a principal engineer at Cloudflare. He has an awesome public repo with a bunch of rules of how to prevent uh you know, 100 agent patterns that he saw over and over again and then curated into this rule set. Um but whatever language you're in, you probably have a good linter or you can you know, vibe up one that works for you. >> Sorry. Can you say that word you keep saying and spell it? >> Oxlint. It's O X L I N T. So ox as in oxide which is like a rust thing. It's uh so rust linter for TypeScript basically. Yes. >> That is uh that is the my favorite thing that's I've working at Factory and kind of seeing the agentic codebase develop is it's all these patterns that I think engineers probably should have been doing for the last 20 years. Just it's kind of annoying to like write lint rules and keep them up to date and honestly, there's probably only one engineer who actually knew how to write them. Um code commenting, all these things I think we've realized like work streams, if you set them up correctly, can really just automate all of these codebase hygiene uh that where you do take very opinionated stances of like our codebase should work this way. Like we had an engineer who was very opinionated around use effect. We kind of viral on Twitter and we have no use effect hooks in our
-
entire codebase uh because it there's a lint rule like you actually can't add one. Um >> I forgot that was Factory that posted that. Yeah, we we were right around the same point in that journey at Human Layer. We were like how did you did you did you take the Factory post and implement that or yeah, okay. Yeah, we stole that. It was great. You guys should steal that. No, ban use effect from your codebase. >> Um, but it's all those things; like actually, as a human, it's quite annoying sometimes to figure out how to write around use effect. But the agents are quite good at that, and so you can get very opinionated without worrying about developer velocity, or you can ban things that typically you're like, "Well, this is just unreasonable." Our developers are never going to go for it. It's going to make things take too much time. And then again, the agents they get a rule, they try to run something, the lint says you can't and they write it in a better way. Um >> Should we do some more questions? >> Yeah. >> Sorry, what was the question? The question was, can you integrate the work stream concept into other harnesses?
-
>> No. I mean, I think there's concepts around like large-scale agentic orchestration that, you know, are maybe just more generalizable, but this works with like within the factory system, the work stream concepts work with Droid. Any other other questions? >> Fair. So there are I there are deterministic portions of that around like basically like code analysis that kind of generate some of these structures, but no, they are mostly like a lot of the like these are the product changes are AI telling you that these are the product changes. Um I'm actually curious, Tex, you probably have a stronger opinion on this than I do. How do you trust AI to review code? >> Uh I mean, in general, my take is like uh linters are necessary but not sufficient. Uh, AI code review is absolutely helpful to catch low-hanging stuff and find weird edge cases that humans might not have caught, but it is, it is not sufficient if your goal is to build a, like, well-architected system that will stand the test of time and you won't have to rewrite in 6 months. Um so I believe that there is a ton a ton of value in finding ways to better understand the code. I don't know the question was about like is it deterministic or not these PR walkthroughs and I think probably the one we showed is mostly generated by AI.
-
Other than that obviously the code diffs are are the actual code diffs. We're not having AI reproduce the diff in the artifact. Um, but I think whether it's deterministic or using AI, I think, or or a blend of those things, I think it's really, really important op optimize for human understanding. Like the the the thing I love about interview skills and these PRD things is, like, how do we pull as much context and intent out of the human a format that the AI can use it. And then on the other side, on the review side, it's how do we pull as much like and efficiently pull context out of the agent so that it's very easy for a human to consume. And, you know, the high-level summary may not be sufficient, but it will tell you where you need to look if you actually want to go into the weeds and look at individual files or code blocks that are, you know, super critical or core to your system. >> Yeah, I think that's two things. One, in the work stream setup, it's very important to kind of build the work stream in a way depending on how fault tolerant maybe some of these workflows are. The orchestrator can be
-
as kind of hand holdy or as hands-off as needed in a way that sometimes people do prefer smaller specs that maybe leave out certain details and you're leaving a little trust in the agent versus if you prefer saying, hey, let's make sure everything is in there. I found that the orchestrator is often very good at making sure that happens. With regards to making sure context is up to date with the code base, the shared file system, maybe anything else you might have, all of these agents are still able to access the latest git, you know commits. If you have any documents in Notion, or any of these other external file sources, and the shared folder context is while important for kind of understanding how the agents are orchestrating together they do still understand that there might be sources of truth and can prompt around, or, you know, are designed to make sure that they have the latest information. >> Yeah, I would say again like the the goal here is building blocks, not an opinionated like spec driven development process or something. You bring this you however you want to and we can we can bring you the tools to basically say like, hey, you know, once a day, check what's been built and compare it to the spec. And if the spec is if it's out of date, like tell the agents to fix it. If there was a new decision, surface it to the human. If the human made a decision, go update the spec. Like you can you can kind of fragment what would normally be like a giant prompt that might be hard for a model to follow into all these like tiny little loops that will push, you know, over time, push your feature to, uh, to production, to whatever the end state you want, whether it's migrating or building a new thing or just fixing every century alert that comes in. Does
-
that sound right? >> Yeah. >> Yes. >> So, the question... So, I'm just going to repeat the question for the live stream, but it's basically like, "Hey, we have a big agent orchestrator and it, it uses, uh, it uses git worktrees to keep agents from stepping on each other and and messing with each other's work, so they can all work in parallel." Uh how do you how do you think about that? Do you do you use worktrees these days? >> Uh I typically use delegate across like uh so for example, actually in this demo right now, each one of these agents is running in its own cloud sandbox that was spun up specifically for its run. If you are delegating across just local, then we find worktrees are quite effective. There's some limitations with worktrees, especially as I've seen this scale to, you know, 30, 40, 50 agents at once. Ultimately, worktrees don't scale as as nicely. >> Yeah, I think one of the first problems that people tend to run into is, like, if you have a really big monorepo or lots of different repos, uh worktrees are really great until you need to actually, like, run services that bind ports and have to interact with each other. And then you end up having to spend a ton of time having to wire it so that, like, it can locate all the ports that it needs and find the ones that are available, and then wire those through into the URLs for the different services to talk to each other.
-
Uh and the benefit of just like using cloud sandboxes for everything is you don't have to worry about that. Uh, so like, I have a work stream that's been running for about a week, like rewriting 100,000 lines of Go into uh TypeScript, and it's doing a bunch of like Kubernetes stuff with different services, and it's really easy to just have it tested because it can use K3Ds to like spin up a little local Kubernetes cluster and test everything locally. And to parallel path that with like lots of different agents that are working on different parts of that, and all those can like test uh the entire like service stack against everything else without having to like worry about stepping on each other's toes. And like the thing that you know, we when Dex and I were working just on our workstations all the time, you'd have like agents like killing each other's services because they're trying to like free up ports for their own thing, and they just like trample all over each other, and it >> Yeah. >> even It wasn't It It wasn't even like running services sometimes. It was just like, oh, this agent is running like the TypeScript compiler, and there's three of them, and your Mac is literally out of memory because you're running like TS Go in four places at once.
-
>> Um and I think this is actually the the example So for context, in the background when I was sitting over there, I decided to say ask our orchestrator to make our desktop app faster cuz I was annoyed that it was bugging out. Um, and so right, now Well, we have 1, 2, 3 4 5 but basically my... Especially when you're dealing with performance, having like an isolated environment where you can control all the other services running, basically anything that can be measured, the more you try to paralyze that on the same machine, you introducing noise into those measurements. Um and so it can create issues. Um you also can do things like I said to spin up 20 more. We'll see if it agrees with that statement. Uh but I was determined to see how many PRs I could get before uh this is over. We might not get to one, but we'll see. >> Question was, do we have non-technical roles using workstreams in Factory? >> Yes. Um actually across the entire gambit of technical roles. So obviously like tech adjacent, product design, things like that. Uh I know our sales like team also has started having like a workstream per account and keeping all of the context for that account in there. Ultimately we view it as just a better way to get work done.
-
>> That's awesome. I didn't I hadn't heard about that sick. >> Yeah, it's not it's definitely maybe not purpose built for our sales team right now, but I do think at the end of the day, really what you're giving people is a powerful tool to get work done. And I also have the opinion that like the best coding agents are just the best agents. And so over time, I think we see this really just transforming in a way that, you know, people are just going to work. >> And didn't didn't Troy the like head of finance, didn't he post like a long Twitter thread of all the cool he uses this for for like running running the books? >> Yep. Troy is our actually I look at our token Troy is our second highest token spender. Um >> And he's not an engineer. He's he works in finance. >> Those those Excel spreadsheets, man, they'll they'll get to you. >> Okay, we got we got four and a half minutes left. We'll do as many questions as we can. >> Let's go. Rapid fire. >> What what kind of what? >> What kind of bottlenecks? >> Oh. >> Yeah, I think PR review is definitely the that was why we really had to iterate on how to review PRs because I have uh someone on my team sent me 37 PRs to review one morning and I was like, this is simply not not going to scale that well. Uh as you can see, I'd I'm very curious how many PRs this one ends up making. But I think code review was the most obvious bottleneck. I don't know if >> It makes me feel less bad for sending you five PRs yesterday.
-
>> Oh, there's he created his own Slack channel. Just me and him. Um but sorry, I just want to make sure we get to all the questions. Um any Oh sorry. Oh, I think PR review is probably the the the biggest bottleneck initially. Um yeah, I think PR review and the ability to run agents, like a bunch of agents at once. And I think the solutions we found were making PR review more approachable for humans. And then of like cloud sandboxes and things like that to really scale across, you know, not just your laptop. Cuz I think this would truly be killing my laptop right now. Um cuz these are all running our performance harness. Uh sorry. Yes. >> Okay, so is agents are are working and learning things and wanting to make changes to your skills, how do you actually eval that and and know that the new version of the skill is actually better and is not going to cause regressions for, you know, engineers working on other things?
-
>> That's a good question. I think for performance it's the easiest because we have baseline performance metrics that we basically like on each PR I can essentially see how is the performance trending over time and like are there regressions. I think it ends up being a little context dependent of like which systems are you trying to measure. I'm a big fan of you just should be measuring everything and ultimately you need like a source of truth for whatever you're trying to hill climb on. Yes. Uh like a BYOM situation where you want to bring maybe your own cloud sandboxes or you have a machine at home or basically you want to delegate to a machine that you own that is not necessarily your local laptop. Yes. If you want to spin up like an EC two in AWS and use that that can work as well. Yeah.
-
I am going to hand this to Dex and quickly reiterate the question, but it was essentially how do you how do we thought about like multiplayer and the ability to have people collaborate. I think Dex is going to have by far the best take here. >> And I realize I'm probably not on camera here, so I'm going to come hang out on stage with you swap for the last 90 seconds. Yes. I think the idea of having I mean this was one of the things that we found was like the highest impact to how we worked. We built like prototypes of things like this in human layer where multiple people can all prompt the same session. I don't know how much I can say about what's coming, but yes, we're very excited about the idea of taking a work stream and making it collaborative among multiple people both across the documents, across talking to the orchestrator, etc. >> Ross, do we have any benchmarks that show that uh work streams in the agent swarms are uh are a great way of doing work?
-
>> So, there we have a blog post out that is basically: "So, we had Missions V1 and as we were hill climbing on what is the next version of Missions, we put out a blog post that's basically the..." There's a handful of benchmarks we essentially indexed against of how do you fan out these really long-running tasks. Um I don't remember any specific numbers, but there is a great blog post that kind of goes actually quite deeply into how we where we were, how we got to this architecture, and why it actually is better um on these various long-running tasks. Yeah, maybe final question. >> Yeah, I guess in this case they're actually all I'm curious here. Okay, so >> Let's go look at Let's go look at one of one of these. What is it doing? >> That's actually a point. Um Okay, let me load into one. Um >> Oh, I saw the word V8. That's uh that's scary. We're digging into the the node VM. Okay.
-
>> Um so I think in this case the agent actually what it decided to do is instead of spinning up maybe one or two across like just our entire repo has stuck each agent on its own particular portion of our repo. Um and I think that' s how it avoids collisions that these actually can work quite autonomously without worrying. And I think that is time. So >> Awesome. Thanks, everybody.
Summary
Factory introduces Work Streams, the next evolution of their AI coding agent platform that shifts from one-off tasks to autonomous, long-running agentic workflows. The presentation covers the core concept of an orchestrator acting as an engineering manager to delegate tasks, break down pull requests, and manage sub-agents across use cases like core development and vulnerability remediation. The practical takeaway is that developers can abstract away implementation details and micro-management, using the orchestrator to autonomously guide complex software engineering tasks while maintaining human oversight through customizable workflows and automations.