Part 3 · From Working Demo to Useful Product

Scheduled Tasks: A Cost Trap

Agent runs tasks on a schedule — accumulate context or rebuild? One choice, 10× cost difference

THE QUESTION THIS PAGE ANSWERS

ANSWER FIRST

What is the key idea behind “Scheduled Tasks: A Cost Trap”?

Agent runs tasks on a schedule — accumulate context or rebuild? One choice, 10× cost difference

DECISION RULE

Make the claim earn its place. Use this page as a decision aid, not a definition to memorize. Connect the idea to one real task, one observable result, and one failure that would change your mind.

TRY NEXT

Write one question you could answer with evidence after trying this idea.

WATCH FOR

A conclusion that sounds complete but leaves the key assumption untested.

Reuse Session vs. New Session
Reuse Old Session
Run 1Run 12Run 24
$7.20
24h Total Cost
$0.60
Last Run Cost
New Session Each Time
Run 1Run 12Run 24
$0.72
24h Total Cost
$0.03
Cost Per Run
Drag "Days Running" to See the Difference

成本计算器

7
24 times
$50.4
Reuse Session Total Cost
$5.0
New Session Total Cost
10x
Cost Multiplier
Why Reusing Sessions Causes Snowballing Costs

Context Accumulation Process

1
Run 1: context = System Prompt + current conversation ≈ 2,000 tokens
2
Run 2: context = all of Run 1 + current conversation ≈ 4,000 tokens
3
Run 10: context = all of Runs 1–9 + current ≈ 20,000 tokens
4
Run 24: context = all of Runs 1–23 + current ≈ 48,000 tokens. You pay for all those historical tokens on every request!
New session = starting from zero every time. Run 24 costs exactly the same as Run 1, because no historical context is carried. Scheduled tasks don't need memory: just summarizing today's news is enough — there's no need to know what was summarized yesterday.
For scheduled tasks, always create a new session — never reuse the old one. This single choice can make the monthly bill differ by 10×. Most scheduled tasks don't need context memory; new sessions are both cheaper and more stable.

How “Reuse Session vs. New Session” changes an answer

“Agent runs tasks on a schedule — accumulate context or rebuild?” shows that a model does not process the “word count” we see. It processes Token pieces. Tokenization affects input length, how much context fits, and how much computation a request consumes.

Length, information, and context are different

As “Agent runs tasks on a schedule — accumulate context or rebuild?” grows, separate three questions: how many Tokens the text becomes, which pieces can change the current decision, and whether older material has fallen outside the context window. Removing repetition is often more useful than simply making the window larger.

Keep what can change the decision

Use “Agent runs tasks on a schedule — accumulate context or rebuild?” as an A/B test: keep the same question while removing repeated background, compressing format, and trimming irrelevant history. Compare answer quality, latency, and Token count.

From “Reuse Session vs. New Session” to “Drag "Days Running" to See the Difference”

“Reuse Session vs. New Session” grounds the problem in “Reuse Old Session Run 1 Run 12 Run 24 $7.20 24h Total Cost $0.60 Last Run Cost New Session Each Time Run 1 Run 12 Run 24 $0.72 24h Total Cost $0.03 Cost Per Run”. “Drag "Days Running" to See the Difference” then moves it toward “成本计算器 Days Running: 7 Executions Per Day: 24 times $50.4 Reuse Session Total Cost $5.0 New Session Total Cost 10x Cost Multiplier”. Together, they show that the lesson is not just a conclusion to remember, but a claim with conditions.

Carry the judgment into the next situation

For long text, keep what can change the conclusion before compressing format and history. A larger context is worth its cost only when the added information is useful.

  • “Reuse Session vs. New Session”: Reuse Old Session Run 1 Run 12 Run 24 $7.20 24h Total Cost $0.60 Last Run Cost New Session Each Time Run 1 Run 12 Run 24 $0.72 24h Total Cost $0.03 Cost Per Run
  • “Drag "Days Running" to See the Difference”: 成本计算器 Days Running: 7 Executions Per Day: 24 times $50.4 Reuse Session Total Cost $5.0 New Session Total Cost 10x Cost Multiplier
  • “Why Reusing Sessions Causes Snowballing Costs”: Context Accumulation Process 1 Run 1: context = System Prompt + current conversation ≈ 2,000 tokens 2 Run 2: context = all of Run 1 + current conversation ≈ 4,000 tokens 3 Run 10: context = all of Runs 1–9 + cu…

The final “Why Reusing Sessions Causes Snowballing Costs” brings the discussion to “Context Accumulation Process 1 Run 1: context = System Prompt + current conversation ≈ 2,000 tokens 2 Run 2: context = all of Run 1 + current conversation ≈ 4,000 tokens 3 Run 10: context = all of Runs 1–9 + cu…”. The useful thing to carry forward is knowing which judgments must be revisited when input, scale, or risk changes.

Mark as learned Your reading progress updates automatically
← PreviousNext →

Keep reading

The next useful article in the thread.

ARTICLE DISCUSSION

Leave one useful thought here.

Keep the idea that clicked, the question that stayed open, or a small note for the next learner.

Discussing Scheduled Tasks: A Cost Trap From Working Demo to Useful Product
3discussionsArticle discussion · synced with the Circle
View in the learning circle
AM
Asha MorganContent editor
INSIGHTField note

I turned one judgment from this article into a small experiment I could run today. Knowing what to observe next is more useful than simply remembering the conclusion.

ARTICLE DISCUSSION7 helpful
LH
Lin HarperIndie developer
INSIGHTInsight

After reading this, I first looked for the conditions behind the idea instead of copying the method into a project. That order made the later trade-offs much clearer.

ARTICLE DISCUSSION5 helpful
KM
Kiki MooreProduct operations
QUESTIONQuestion

When this judgment reaches real work, which constraint should be added first? I am curious which step matters most between reading and the first practical attempt.

ARTICLE DISCUSSION4 helpful