🤔
Smart Token-Saving Hacks for AI Agents (Without Losing the Magic)
Must be nice if your company has an endless budget for AI tokens, but for a hungry startup like us? Token cost-efficiency (a.k.a. the terrifying monthly bill) i...
hhlee
2026-09-11
🤔
Mission Ready: Setting Up the Ultimate Dev & Ops Workspace for Our Secret Agents
At Stew, we're sharing how we set up and utilize our environment for agentic coding. The AI landscape moves at breakneck speed—our own workflows shift dramatica...
hhlee
2026-09-09
🗞️
[Update] Give Stock and Uploaded Photos an AI Makeover with 'Generative Edit'
You can now refine and reuse the images you already have—no need to toss them out and start over. With the newly added 'Generate Edit' feature, the image curren...
Junwoo
2026-09-01
🎓
Why You Pick a Shorts Template, Make Three Videos, Then Never Use It Again
Search for Shorts templates, and you’ll find an endless supply of free options. But after downloading one and making about three videos, many creators find them...
Junwoo
2026-09-01
🎓
Automating shorts is easy—getting them consistently great every time is the real challenge
If you search for shorts automation, you’ll find endless workflow tutorials that promise everything at once: script generation, images, voiceover, even upload. ...
Junwoo
2026-08-06
🎓
Before You Pick an AI Video Editor, Decide *What* You Actually Want to Make
When you read those “Top 5 AI video makers” listicles, they usually bundle all the trendy tools together, compare pros and cons, and highlight key features.But ...
Junwoo
2026-07-02
🤔
Before you get a quote for one AI video, ask yourself this: "How many times will I want to repeat this?"
The first message we usually get from people asking about AI video outsourcing is almost always the same. It all boils down to one question: “How much is it?” I...
Junwoo
2026-06-19
📣
How a Franchise Café Automated Its Digital Signage Videos (and Saved a Lot of Time)
Running Videostew has given us a front-row seat to the challenges faced by potential customers across all kinds of industries.And there’s one topic that always ...
Junwoo
2026-06-12
Must be nice if your company has an endless budget for AI tokens, but for a hungry startup like us? Token cost-efficiency (a.k.a. the terrifying monthly bill) is always front and center. Sure, high-end models get the job done brilliantly and pick up on every nuance, but we’re constantly obsessing over how to squeeze way more work out of leaner, more affordable models.
How AI Costs Actually Work
The cost of the LLMs powering our AI agents boils down to a pretty simple equation:
Cost per token (by model) x Total tokens (input + output) = Total Cost
Most folks already know that the price per token varies by model, and that token count roughly scales with word count.
The real kicker, though, is how those tokens actually pile up. You might think, "Hey, if I just keep my prompts short and the answers brief, I'm good, right?" Well... not quite. It comes down to how LLMs work under the hood. To put it bluntly: LLMs have no consciousness, no memory of your relationship, and zero clue who you are or what your project is about. They literally just tokenize text, run it through the model, and spit out a response.
So, to keep conversations flowing naturally, AI agents secretly bundle the entire backdrop—the current environment, project details, and everything you've said up to that very moment—with every single request. Yep, you're not just sending your latest prompt; you're resending the whole story every time. If you started out chatting about today's weather, wandered into random small talk, switched to coding, and then pivoted to marketing... guess what? That initial weather chat (and the AI's response to it!) is still hitching a ride on your latest marketing prompt.
Here’s a simple way to visualize how tokens stack up per round of Q&A:
To make it even more accurate, it looks something like this:
That entire trail of previous conversation hitchhiking on every single request? That's what we call the context.
To be fair, modern AI agents have gotten smarter: they compress context, prioritize recent messages, and leverage caching to trim down the bill. But here’s the catch—context compaction itself requires summarization, which is another computation (and definitely not free!). We'll dive into that in a bit. But at the end of the day, despite all the clever workarounds, this is fundamentally how AI conversations run behind the scenes.
That’s why folks who don't know this yet often dread hitting "New Chat"—nobody likes repeating themselves, right? So they end up piling task after task into a single thread until the scrollbar literally begs for mercy. Sure, the AI will still spit out an answer somehow, but spoiler alert: you’re burning through a ridiculous amount of wasted tokens behind the scenes.
Here at our AI video platform, we tackle this context bloat in a few smart ways to keep things lean and fast. You don’t need to obsessively monitor "How heavy is this chat session right now?" every two seconds. Just adopt a few simple habits, and you'll be golden.
Maximizing Prompt Caching (Work Smarter, Pay Less)
As we covered the basics above, modern AI providers don't tokenize and re-calculate every single word from scratch every time. Once a conversation is rolling, the AI servers simply tack on the new calculations onto the existing pre-computed state. This delivers lightning-fast responses—and it's called Prompt Caching. Even better? Cached prompts come with a massive discount compared to raw computing costs. "Wait, so can I just keep chatting forever without worrying?" you might ask.
Well, there's a catch! Prompt caching can be pretty picky about when it kicks in. Typically, follow-up messages need to happen within a tight window (often under 5 minutes), the model and reasoning depth must stay identical, and there can't be any sneaky changes to system instructions or memory. Mess up just one of these? Poof! The cache breaks, the AI recalculates everything from scratch, and your bill shoots right back up.
Flip that coin, though, and you’ve got a superpower: play by these rules, and you reap all the sweet caching benefits. If you're orchestrating multiple AI video agents for different editing tasks, the real pro move is to review quickly and fire off the next prompt in a tight rhythm before the cache expires.
Tie this in with our context discussion, and the winning formula is crystal clear: Start a fresh session whenever you switch topics (to prevent context pollution and cache waste), but keep the momentum going when you're on the same topic so you can ride that prompt caching wave all the way to the finish line.
Splitting Side Quests from the Main Mission
When you're deep in the zone building features, bugs rarely show up alone. They bring friends—backend logic, authentication, user data, UI quirks, and ongoing tests are all tied up in the same boat. Ignorance was bliss in the old days, but modern AI agents are sharp: while working on one task, they'll happily point out every other fire burning in the background. It’s so tempting to think, "Let me just quickly fix this tiny bug before getting back to the main thing." (Spoiler: It’s never quick!)
When this happens, you need to be ruthless: set those side quests aside and stay laser-focused on the main mission. This prevents your context window from getting polluted with unnecessary noise, saving precious tokens. At the same time, you'll want to log those newfound bugs immediately so they don’t slip through the cracks.
Here’s what that workflow looks like visually:
There are plenty of ways to sideline these tasks. You could simply jot them down in a separate markdown file, or do what we do—sync them directly with GitHub Issues. By creating a quick documentation habit to capture side issues in a standardized format (context summary, potential risks, etc.), you can tackle your main problem first, then circle back in a brand-new, clean session with a crystal-clear context window.
Hierarchical Documentation Management
As mentioned in our previous post, whether it’s manuals, global guidelines, or internal docs, keeping a hierarchical structure is a game changer. Sure, shoving 1,000 lines of security, billing, ops, coding standards, and testing rules into a single global guideline might technically "work." But force-feeding your AI agent all that irrelevant data in every single prompt? That’s a fast track to burning through tokens for nothing.
Instead, keep your global guidelines lean—stick strictly to the core essentials. Store domain-specific knowledge in dedicated sub-documents. The trick is making sure files don’t get lost in the void: use your entry-point document (like your global prompt/guidelines) to create clear links, pointing out exactly which doc to reference for what.
Here’s a quick example of how you can structure it:
AI agents are equipped with a clever mechanism called "tool calling," allowing them to dig up extra information entirely on their own. First, the agent checks the essential global instructions. If it realizes that tackling the task at hand requires reading additional documentation, it pulls those docs in as needed. By accessing only the bare minimum required for the immediate job, it keeps token waste to an absolute minimum—saving both time and compute power.
However, invoking a tool call to pull in documents still eats up turns and precious tokens, and whatever the agent reads once stays in its context window for the rest of the conversation. Our golden rule? Frequency is king: "Keep what's needed almost every time in the entry doc, and tuck what's only occasionally needed into external docs." For documents used even less frequently, keep them tucked away in
/docsand let the agent pull them in via direct reference only when the moment strikes.Time for Spring Cleaning: Taming the Memory Guidelines
When you're collaborating with an AI agent—say, when you're barking firm commands or bumping into recurring hiccups—the agent might suggest or automatically append memory guidelines. Translation? That memory prompt will now hitch a ride on every single future conversation. While global guidelines are visible in documents and easily tracked with commits, memory guidelines can silently pile up in the shadows, quickly turning into the #1 culprit behind token bloat.
While it's fine to let the agent gather memories naturally during daily work, we run routine tune-ups whenever we put our global guidelines on a diet. We promote frequently used, genuinely helpful memories into the official global guidelines, while ruthlessly pruning one-off memory guidelines that have already served their purpose.
Work Smarter: Splitting the Router and Heavy-Lifter Models
Using top-tier, high-performance models (like Fable or Astra) feels like magic: you type less, the AI gets the hint instantly, makes fewer mistakes, and nails the job on the first try. But let's be real—high performance equals a heavier bill. That's why smart efficiency is the name of the game.
In reality, when you run an agent-driven workflow, at least half of the work boils down to routine file reading, searching, tool calling, minor tweaks, and log checks—no genius-level reasoning required. That’s why we set a mid-tier model (like Sonnet or Terra) as our default daily driver, letting it automatically route tasks to a high-performance model only when things get truly complex. Think of the default model as your smart receptionist—handling the routine flow and calling in the heavyweight specialist only when it really counts!
Mid-tier models might not always solve the hardest problems directly, but they’re sharp enough to tell whether a task is a breeze or a beast. They can even realize midway, 'Wait, this quick fix is actually a rabbit hole.' While a featherweight model could handle pure traffic routing, we prefer mid-tier powerhouses because they don't just point fingers—they roll up their sleeves and get real work done too.
Here’s where AI agents get truly clever: sub-agents. Think of it like spawning a mini-assistant within your own workflow. The main agent spins up a dedicated sub-session, hands off a specific task, and waits for the finished result. Since an active session can't dynamically swap its underlying model mid-conversation, sub-agents are our secret backdoor to switch gears on the fly.
And the perks go way beyond just swapping models! When a sub-agent digs through dozens of files and runs multiple trial-and-error tests, all that messy troubleshooting stays locked inside its own workspace. Only the clean, final answer makes it back to your main timeline. It’s like keeping all the behind-the-scenes editing bloopers out of your polished, final cut.
We set up a golden rule that goes something like this: "If a task feels heavy, complex, or security-sensitive, summon a high-performance sub-agent, hand over the context, and delegate the battle plan. Wait for its strategy, then execute the code strictly to spec." Tweak these handoff triggers as you go, and you'll find the sweet spot for your pipeline. Once dialed in, you never have to second-guess whether a task is too big—your default agent handles the groove, delegating heavy lifting to top-tier brains automatically.
Go All-In on Subscription Plans (Trust Us)
Most API pricing hits you with pay-as-you-go paywalls. Subscription tiers, on the other hand? While they come with plan limits, those caps are often way more generous than burning through raw API credits. Providers love building brand loyalty through tiered pricing (and pocketing unspent capacity), which means smart creators get way more bang for their buck.
If you're dealing with structured, bulk processing rather than back-and-forth chatting—like categorizing or summarizing hundreds of files in one go—batch API processing is a hidden gem. Completely separate from standard subscriptions, it often cuts costs by up to 50% compared to standard pay-as-you-go rates. Who doesn't love half-price computing?
Many CLI tools offer a one-off execution mode, and most major AI providers (excluding Claude) actually include the tokens consumed here within your existing subscription plan instead of charging extra.
This unlocks massive potential for workflows like Skills. Imagine running a code review where you spin up an independent secondary model to debate and cross-validate the results with the primary one. Sure, you could build this via traditional APIs, but the real pro move is routing these tasks under your flat-rate subscription to squeeze out maximum ROI.
Wrapping Up
Running cutting-edge AI models doesn't mean your budget has to bleed. Here’s the quick cheat sheet to keep your costs lean and your workflow razor-sharp: