My Dev Workflow for Large System using Claude Code
- Published:
- Length: 13:39
- Channel: Eugene Vyborov
- Video: https://www.youtube.com/watch?v=z_feLdNGLSA
- YouTube video id: z_feLdNGLSA
Description on YouTube
Repo: https://github.com/Abilityai/trinity Building complex AI agent platforms without breaking the code is hard. Here's the exact development workflow I use to manage Trinity - a large-scale orchestration platform with dozens of features. In this video, I walk through my proven approach for large Claude Code projects that prevents code degradation and keeps development moving fast. In this video, I cover: - Feature flow architecture - vertical slices across the full stack - Documentation structure that keeps AI agents in context - How to maintain 200K token context without running out - The feature flow analyzer sub-agent for code documentation - Testing strategies (API tests + UI integration tests) - Why this prevents hallucinations and code rewrites If you're building anything beyond a simple prototype with Claude Code, this workflow will save you weeks of refactoring headaches.
Full transcript
[0:00]Hi guys. Today we're going to have a bit of a technical video because I need to show you something that a lot of people have been asking me for a little while on how I run my development process on relatively large projects. And I'm using cloud code. I've developed a certain approach in cloud code that I want to talk about today and explain why that works for me. It actually does allow me to keep relatively complex projects that are being developed actively without breaking them and without having to rewrite the code and draw pieces of functionality and build some random
[0:34]hallucinated stuff. So I will take as an example uh my trinity project. Trinity in a brief explanation is the deep orchestration deep agent orchestration platform and infrastructure for sovereign agents. It's available on GitHub. It's public along with all of the methodologies that I'm going to be showing today. So you can go and check it out. But in essence, technically Trinity is a web application as you can see that basically manages a bunch of Docker containers that each of them is a cloud code agent with YOLO mode and orchestrating their collaboration,
[1:08]messaging, evaluations, task management, credentials, and many other things. I'm not going to dive deep into the platform itself. All you need to know is that you know this is basically like an infrastructure solution for managing multiple sometimes dozen dozens of different agents where agent is an autonomous entity running in its own docker container with access to files and the rest of that usually in the yolo mode and in this instance this is cloud code again but it doesn't have to be cloud code it can be
[1:40]other engines as well but again the point that I wanted to show you is how I manage The development of this app which is relatively big I would say it has a lot of functionality a lot of different given the agent page itself is pretty large it has radius it has regular database and it has relatively sophisticated deployment mechanism and docker management mechanism. So basically you can roll out this installation as long as you have docker you can roll out this installation entirely on your local machine or within your cloud. Now the way I work with that
[2:15]and that's time to switch over here is clo code. This is just clot code opened in the folder of this repository and always every time I start there's a special command that I use. I made this command for myself which is read docs. Simple. What I asked it to do during this command is to read some cornerstone documents that are dictating what this project is and that includes requirements architecture document describing the overall setup and architecture road map like what we have
[2:47]in the priorities. Then the interesting part we have this feature flows document or feature slices as some people call it. Um I will explain in details what it is and how that works. And then I have the deployment details, testing guide and change log. So from the change log, as you can see, I'm instructed to read on the like top 150 lines. The idea being that I'm like as I'm making changes, I'm adding more on on top of that. And then people can just basically dive in and look at how that works. So when I write this documentation, the agent is now aware of what's happening
[3:21]overall in the project, what we're building, what it is all about. Of course, Claude MD does contain a lot of this information, but it's more convenient for me to keep them in separate clear files because I just can go ahead and easily edit that myself if I'd like. And when I'm working on any particular feature, whether I'm building a new one or I'm working on the existing ones, I'm using this feature flows actively. So, what is a feature flow? as a sort of a vertical slice of functionality that goes all the way from the database and deployment to the front end describing particular feature that
[3:54]is kind of we are working on or will be working on and then there is a special agent that you also have access to all the agents and commands are shared within the repository agent is called feature flow analyzer that is designed in a way to review the code and infrastructure in those vertical slices that allows it to kind of identify all the components of the functionalities that we're working upon. And then when we need to go back to this feature and get cloud code into context of what is happening, what we're doing
[4:27]is we're just asking it to read appropriate feature flows or just tagging those feature flows themselves. feature flow analy memory feature flows here is the feature flows for the vector memory that agents have and if I want to continue working on that I'm just asking you to look into this feature flow and it will have enough context to do it but let's go through the actual process of doing something and we'll see how that works
[5:00]in practice and by the way all the related commands sub agents and feature flows are in the repository And the development process that I'm describing to you right now is also described in this development workflow file talks about exactly the same thing. So if you missed something over here then let me know and if you missed something over here then you can read it in this file. Anyway, so I wanted to work on one little fix. I recently introduced the dark mode into the application and as you can see it missed some of the parts
[5:35]of application. So some like info section of the agent and I think a couple more other sections are not yet functioning in terms of the style in the same way as the rest of the system. So let's see. So as you can see I have recently introduced this dark mode and I can switch between the dark and the light. But not all parts of the system especially on the agent page have been successfully converted to the dark mode. So that's what I want to work on today and let's do it. So we already loaded documentation. Now I'm going to load
[6:08]appropriate feature flows. So as you can see I'm giving it the feature flows accordingly and I'm asking it to review that the styles are going to match and I'm also reminding that about the principle of minimal necessary changes because if you worked with clo before it used to be very verbose and doing a lot of stuff that was not necessary. Opus 4.5 fixed that. But I'm still kind of having a habit of making sure that it's not being too proactive. I'm also giving it like a very specific page where I know the issues are and yeah, let's see what it does. Okay, so as you can see,
[6:43]it identified the specific components where it needs to be fixed. Really, it just continues fixing them. I also noticed that it's running out of context already cuz those are quite big and the files are quite big and there's a lot of them as well as feature flows are quite detailed. Obviously, we're running into this 200,000 context limitation. The list is off right now. And while it's doing its work, I want to show you how the documentation is organized and why it's organized this way. So in the application, there is obviously we take the whole of it. There's a bunch of
[7:16]layers and obviously there's like a persistence layer, there is event management cues and radius for caching and other stuff. Then there is business logic. Then there's potentially like along with the business logic somewhere in the same component there are like APIs as an interface to the world and maybe I put it over here and there's like web UI so front end specifically and then there's a whole bunch of other
[7:48]components that can be anywhere around that. So the way I approach the documentation I give it architecture MD which describes the thing overall at a high level like what is the principles of building that from every perspective and it's a high level enough description that gives an understanding of how this thing is organized. Then I'm giving it another horizontal thing which is so it's kind of across the entire app which is requirements. And so this requirements file is
[8:22]specifically to describe what business logic we're building into that. So this is what the requirements is a what and the architecture is a how. Yeah, maybe sounds like a decent analogy. So of course in addition to that we have a couple of other things such as the change log and the road map. So the road map is telling us what and what is the order of building and that can be integrated with git issues and things like that for better management. Doesn't have to be in the text file.
[8:54]It's just more convenient this way for me. And we also have change log as a dock. And we also have feature flow index. So this feature flow index is interesting because it describes it's it's basically like a directory of all the different functionalities described in the system and uh implemented in the system in in different way as I mentioned those are like vertical slices of the logic. So we can say
[9:28]use this analogy of I need to change the color of this thing. Wait a second cuz it's like yeah something like that we can look at the piece of functionality like agent page or something this way there's a page or tab on the front end there's some API and actually in this case I think API is a separate layer over here because all the UI is going through the API but then there's MCP that is also going through the same API so the right version is something like this and I have a bunch of those feature flow descriptions that are describing a
[10:02]specific piece of functionality in a full stack like a vertical slice of this and this feature flows is just an index of those. Now individual feature flows are not loaded into context simply because they will eat up the entire thing very quickly but when we need to we can load individual feature flows to work with that. Now, this gives enough of an understanding for the cloud code agent to really be aware of what's going on in the project at a high level. And then when we're diving into specific
[10:36]functionality, we're reading specific feature flows. And most importantly, when we are finished with updates or new functionality, we're updating those feature flows as with the use of feature flow analyzer agent. All right, let's take a look what's going on here. It keeps going. It actually fixed this stuff. And what happened is that it immediately because it is instructed to do so went and added this information to the change log and also updated appropriate feature flows. Now, it doesn't always do that and I don't
[11:09]always want it to do that in the first place because I may want to do some other work around that. But this fix was fairly straightforward. Yeah, as you can see, things are working as expected. And so I'm not going to stop it. It will just do the updates into the feature flows themselves. Now I could have and should have run in this case two commands. Either update docs, but it's already done. Or feature flow agent analyzer in order to actually rebuild the feature. And as you can see, we're perfect. We're almost to the full context usage over here. We left at 1%.
[11:43]And I think we are done with this demonstration since the documentation is updated. Now whatever I'm going to do in the next session all I do is I clear the context again read the docs and keep working within the same process and that allowed me to build this level of complexity of the app. You can take a look at it yourself here at the Trinity repository and keep building that and maintaining that effectively without significant issues with the development process or code degradation over time. Approach is still not perfect. and
[12:18]working on that and refining that especially painful part of that is non-breaking changes when you're doing massive refactorings but it seems like the architecture is more or less stabilized now so I don't need to do those uh a lot of the time and also wanted to mention that there are two test sets that have been created for both of them we have sub aents a test runner sub agent which is an API test runner and report generator there's a pretty big suit of those tests that it runs and then there is agent for UI integration tests. This guy opens Chrome
[12:53]on its own and goes through the local application clicking through the different functionality and validating that it's working. At the end of the day, it creates the reports with the testing and shows me where I need to pay attention. I used the same kind of approach with documentation commands and sub agent in other projects and it's working as well. Yeah, highly recommend trying that. Also forgot to mention over here some deployment and testing. So that's more of a full picture as you can see requirements architecture roadmount
[13:25]change log deployment testing documents feature flows index and individual feature flow. You can find all of the commands and sub aents and everything else in the repo and see if that works for you.