Tokenmaxxing: My Claude Code Workflow
Milan Jovanović · 2026-06-24 · 10м 48с · 12 678 просмотров · YouTube ↗
Топики: ai-loop-engineering
🎧 Аудио
📝 Summary
model=deepseek-v4-flash · prompt=summary-v7 · 4 501→1 298 tokens · 2026-07-20 12:09:02
🎯 Главная суть
Milan Jovanović за три недели потратил ~70 миллионов токенов в Claude Code на тарифе $100/мес (5x max) и выработал workflow: идея → дизайн-документ → дробление на подзадачи → параллельные сессии агентов в отдельных git worktrees → goal command для завершения → PR на ревью. Такой подход позволяет ускорять итерации ценой снижения качества кода (verbosity, лишние абстракции), но экономически оправдан, пока действуют субсидии провайдеров.
Разделение работы как с человеческой командой
Milan предлагает начать с идеи и создать дизайн-документ — описание архитектуры, стиля кода, требований к качеству, инфраструктурных компонентов, подхода к деплою. Затем документ разбивается на мелкие подзадачи, каждая из которых передаётся отдельному агенту в отдельной сессии. Это имитирует руководство реальной командой разработчиков, но с многократно ускоренным циклом обратной связи.
Контроль качества и goal command
Чтобы агент не производил «slop», используется команда goal — она заставляет агента продолжать работу до выполнения цели. Milan передаёт каждой подзадаче описание задачи и набор ограничений: работать в отдельной git worktree (копия репозитория на файловой системе), писать тесты и добиваться их прохождения, по завершении создать Pull Request. Результат — несколько PR, которые нужно проверить. Для критичных участков требуется отладка, для тривиальных — достаточно ревью кода и интеграционных тестов.
Компромиссы по качеству кода
AI-сгенерированный код склонен к излишней многословности: много комментариев, лишние абстракции (например, интерфейсы с одной реализацией только ради моков при unit-тестировании). Milan считает, что для критичных сценариев важнее интеграционные тесты. Плата за скорость — более замусоренная кодовая база, но если разработчик сознательно режет лишнее, «slop» можно избежать.
Экономика токенов и самоокупаемость
За три недели Milan израсходовал токенов на сумму ~$1850 по API-ценам Anthropic, заплатив лишь $100 ($200 на 20x max, но быстро вернулся на $100). Он называет это tokenmaxxing — максимизация использования токенов, пока действуют субсидии. При этом он использовал лишь ~75% недельного лимита. Такой арбитраж экономически оправдан, но Milan прогнозирует, что субсидии долго не продлятся (как уже случилось с GitHub Copilot).
Self-hosting: пока невыгодно
Некоторые рассматривают самостоятельный хостинг LLM (например, DGX Spark за ~$5000), но Milan считает, что это не стоит затрат: за $5000 можно почти два года пользоваться Claude Code на 20x max ($200/мес), а локальные модели не дотягивают до уровня Opus или Fable, к тому же медленные и неудобны в масштабировании. Исключение — если критична приватность данных. Однако для полноценной работы кодового агента на команду потребуются десятки тысяч долларов на железо.
Дополнительные находки: skills, Claude.md, hooks
Milan начал проект без заранее заготовленных skills — он попросил агента выявить повторяющиеся задачи и превратить их в навыки. Файл Claude.md (или agents.md) тоже сгенерирован самим агентом по запросу. Также он использует hooks — скрипты, запускающие тяжёлые тесты перед каждым коммитом, что экономит ресурсы GitHub Actions при параллельной работе.
Аппаратные ограничения
При запуске 5–10 агентов параллельно возникает нехватка RAM. 32 ГБ оказалось недостаточно, поэтому Milan приобрёл два 32-гигабайтных модуля (удвоение ОЗУ), отмечая, что цены на RAM сейчас аномально высоки (купленная 4 года назад 32 ГБ стоит вдвое дороже). Это «знак времени»: спрос на ресурсы для AI-агентов растёт.
📜 Transcript
en · 2 256 слов · 29 сегментов · clean
Показать текст транскрипта
In this video I wanted to spend a little time to talk about my approach to software development using cloud code and in the past two or three weeks I think I've spent around 70 million tokens using cloud code so I've learned quite a few things that work for me and I want to share my workflow with you in this video. Here's my cloud code desktop where you can see my token spend starting from June 4th which is when I started using this. Today is June 22nd so I've been using it for almost three weeks and in that time I've spent around 70 million tokens give or take. I've been using the $100 plan which I believe is called 5x max. I was on the 20x plan for a little while while Fable was available but they took it away and there was no point in continuing on that plan so I had downgraded. Now you can see some days were more useful than others but in the past couple of days I think I've dialed down the approach. It works really well and produces good results for me. Here's the workflow that I apply when using cloud code. So number one, you need an idea. What are you going to work on or what are you going to build? So as I said, I start with an idea and the first thing I want to do is produce a design document. So there just contains the high level description of what I want to build in a little more technical detail. So here I would define things like architecture, code style and quality constraints, maybe infra components if I'm adding something new to the system. We could also talk about the deployment approach. and whatever else I think is necessary to fulfill the design that I want to achieve. So once we've got our high level definition in place, we can then take that and use it to break down our high level feature into smaller sub tasks. So let's say we've got a couple of sub tasks here and these are my actual work units that I'm going to hand off to the agent. Now, what I figured out that works really well for me is to hand off each of these sub tasks. to a coding agent in a separate session. So now this becomes one session and I just expand across how many tasks I have. When you think about it, this isn't all too different from how you would lead a software development team in the real world. So I'm effectively just replicating what already works in the real world using agents. Except with this, our feedback loop is a lot faster as we can produce a large amount of code in very short amount of time. Now, this is also where I want to comment. on how you can actually rein in the ai and stop it from producing slop because it's very easy to fall into this trap of thinking that you are being productive because you're generating a large amount of code it's very far from the truth now i do want to comment on how i actually get the agents to work on something until it's done and this is by using the goal command in cloud code i think this is an implementation of what's called a loop although there's also a loop command it's all a bit confusing but nonetheless when i give it a goal it's going to continue working on this until it satisfies the goal this is where you can actually make it produce the desired results so what you do is you take your task description and feed it to the goal command and then it's really important that you come up with a bunch of constraints now depending on your use case these constraints can vary what i do is tell the agent to work in a separate git work tree this is basically a copy of your repo on the file system and then the agents can work in parallel on separate work trees now this is obviously very resource intensive but it allows you to parallelize the work as much as possible Now what I also tell you to do is write tests and make sure they pass and when everything's done I want it to create a pull request that I can then review. So the end result of this is I now have a lot of pull requests to review and make sure that everything is in order. Of course if I'm working on something machine critical I definitely want to go in and actually debug the code. But if it's something trivial that I've done myself dozens of times before, then I'm going to just review the code and make sure I have proper integration tests in place to be sure that this is working correctly. Now, a couple of trade-offs that you're going to make with this approach. is code quality is going to suffer. Now you have to ask yourself if this is something that you are okay with. The benefit being that you're now able to iterate much faster and produce working solutions in less time. This also doesn't mean we're going to produce bad code, what people would call slop. It's just that AI generated code tends to be more on the verbose side. And if you don't spend quite a bit of time reeling it in and telling it to remove unnecessary parts, you're going to end up with a code base that's quite verbose, full of comments, with possibly many unnecessary abstractions. For example, interfaces with just a single implementation that don't really do much except help unique testing using mocks, which in my opinion is not that valuable because you want to be integration test for your most critical use cases. Now this entire approach can be described with a single word that I'm going to just call token maxing. I totally did not invent this. I've probably seen it used dozens of times, but it's effectively what I'm trying to achieve here. I want to use the maximum number of tokens that's available to me while all of this usage is subsidized. And this is also one of the reasons why I've been less active on YouTube than usual. I've been working on a big project, as you can see by the token spend. that I hope to talk about more in the coming weeks. I also became a dad past month, so sleep is now scarce and finding time to work is even more difficult. And as you can see by my background, I've moved apartments and I'm still setting up the new studio. A lot of things going on at the same time and not enough time to work on videos. And hopefully all of this gets better sooner rather than later. Now, I mentioned that this usage is subsidized and I actually took my token spend. and gave it to chat gpt i didn't want to give it to claude on purpose just to see what chat gpt is going to tell me and it took the input and output token costs from anthropics documentation now these are api costs mind you and i'm using a subscription which is subsidized and it came up with the figure of about 1850 dollars of token spend in the past three weeks now mind you i'm paying a hundred dollars a month give or take we get this much in token spend and i'm not even maximizing my token usage as much as i should be i've only figured out how to properly do this in the past couple of days just to give you a reference i've managed to use up about 75 percent of my weekly limit which is something that i haven't been able to do in the past two cycles so this time around i'm really leaning into it and just trying to maximize my token usage on the 5x plan of cloud code i've explained my high level workflow What about some low-level details? For example, some people are going to ask what about cloud skills. I started out not using them after a week or so on working on this project. I just asked the agent what are some repetitive tasks that I keep asking you to do. And can you turn those into skills? And I think that's how you produce actually useful skills. You figure out the pain points while you work and turn those into repeatable skills that the agents can use. I also did not have a Claude MD or an agent's MD present when I started working on this. This is also something I asked Claude to generate for me. And one thing that Claude also has is hooks. I wasn't aware of this and it's something that it suggested I should add and I'm using it just to run some extra heavy tests before every commit and this is coming in handy because it's saving me a lot of usage in GitHub Actions because I was running into timeouts and resource issues with running so many agents in parallel. Now another problem you're going to run into when using this workflow and to give you an idea I usually have like five to ten agents running in parallel working on different aspects of my code base and one roadblock that I hit was the available RAM on my system. It turns out that coding agents are incredibly resource hungry. And right now I've got 32 gigabytes of RAM, and this forced me to perform an upgrade. I opted for two 32 gigabyte sticks, which is going to double my effective RAM. And you really don't want to know how much I spent on these. Like the prices of RAM are basically insane. What I can tell you is that the 32 gigabytes that I bought, I think four years ago. are now worth double the amount that I paid at the time, which is unheard of in the world of computer components. But I guess this is the sign of the times that we are living in. Also, here's what it looks like when I get a bunch of results from my coding agents as pull requests. that I now have to sit down and review. I think this is about nine or ten pull requests. I go through all of them one by one, and almost all of these are based on some documentation that I had wrote previously in the repo and use that as the baseline to produce the actual pull request. Now, as I already mentioned, I got nearly $2,000 of usage out of $100 a month plan, and I don't think this is going to last for a while. We already lost GitHub Copilot subsidies and sooner or later, the other providers are going to have to follow. So some people are exploring things like self-hosting large language models and currently there's a popular djx spark machine which is selling for almost five thousand dollars and you can run some local models on here but in my opinion this is currently not worth it even with all the subsidies in place, because $5,000 is almost two years of code usage on the 20x max, which is $200 a month. And don't expect that you're going to be running anything close to Opus or Fable level models. And even then, your local models are going to be just incredibly slow and a pain to work with. Who should actually be exploring this path? Well, as I said, privacy. is a big concern when using AI from popular providers and running local models gives you a lot of autonomy and obviously full control over where your data ends up. Now, to actually be able to run something useful in terms of a coding agent and then scale that across a team, you're looking at a big spending bill to make that happen. Maybe you don't need like half a million or a million dollars. build a small data center you definitely need to spend multiple tens of thousands of dollars on hardware to be able to run these models locally now take all that with a grain of salt as i haven't really been into the self-hosting space which is something i'm going to explore and make videos on all of that in due time my conclusion is that with the economics that we have in place today taking into account the subsidies the cost of hardware and the local models that we have available it's still not worth it at least to me, be exploring this avenue. But I definitely think you should not be closing the door on this, especially if you care about privacy and owning your data. Hope that at least something I shared today with you is valuable and you can maybe use it in your own work. I'm definitely late to this game of properly using coding agents, so I'm still learning things myself as I go and I'm going to be sharing them here with you as I gain more insights. If you found this video valuable, go ahead and smash the like button right below. Thanks a lot for watching. I really appreciate it. And until next time, stay awesome.
⚙️ Pipeline jobs
| Stage | Status | Att. | Updated | Error |
|---|---|---|---|---|
| download | done | 1/3 | 2026-07-20 12:08:40 | |
| transcribe | done | 1/3 | 2026-07-20 12:08:47 | |
| summarize | done | 1/3 | 2026-07-20 12:09:02 | |
| embed | done | 1/3 | 2026-07-20 12:09:04 |
📄 Описание YouTube
Показать
Get my Claude Code SKILLS for Clean Architecture: https://milanjovanovic.tech/templates/claude-code-skills/?utm_source=YouTube&utm_medium=social Want to master Clean Architecture? Go here: https://dub.sh/clean-architecture Want to master Modular Monoliths? Go here: https://dub.sh/modular-monolith Join the .NET Architects Club: https://www.skool.com/mj-tech-community-5418/about Get the 2026 .NET Developer roadmap here → https://the-dotnet-weekly.ck.page/2026-roadmap At API rates, last month of AI coding would've cost me ~$1,850. I paid $100 — and this is the exact workflow. In this breakdown I get into "token maxxing": how I push a $100/month Claude Code plan to its limit by treating coding agents like a real software team. I cover writing a design doc first, splitting features into subtasks, running 5–10 agents in parallel across git worktrees, and using the goal command with constraints (passing tests, clean pull requests) to keep the AI from producing slop. I also get into Claude Code Skills, CLAUDE.md and AGENTS.md, hooks for pre-commit testing, the RAM upgrade I was forced into, and whether self-hosting local models is worth it yet. Who it's for: developers using Claude Code or any coding agents who want a faster, more deliberate AI coding workflow — and anyone curious about the real economics behind subsidized token usage while it lasts. Check out my courses: https://www.milanjovanovic.tech/courses Read my Blog here: https://www.milanjovanovic.tech/blog Join my weekly .NET newsletter: https://www.milanjovanovic.tech Chapters