← All articles
AI efficiency

How to work more efficiently with Claude Code

What really drives Claude Code usage? Context, caching, models, agents and rework: how I would approach getting more useful work done without compromising quality.

Ricardo Sargo·7 min read
CommentWhatsAppLinkedIn

The problem starts before the usage limit appears

One of the conversations I find most interesting today is the relationship between what we spend on AI and what we actually get done. In financial markets, I learned to distinguish the cost of an operation from the value it creates. The same idea applies to Claude Code.

Imagine fixing a signup error. The agent reads the project, checks files and logs, changes code and runs tests. If the first change fails, it has to investigate again. You see a conversation, but several model requests may happen behind the scenes. That is why judging efficiency solely by prompt length misses so much.

I would start with the outcome: how many tasks were completed, worked properly and did not need to be redone? Then we can look at four factors that change the equation: loaded context, tools, processing and delivery quality.

Context: the agent's workbench

I like to imagine the context window as a workbench. Instructions, history and materials are laid out there for the model to use. The more irrelevant information that takes up space, the harder it can be to focus on what matters.

Anthropic's Claude Code documentation describes /context, /compact and /clear. The first helps you inspect occupied space, the second summarizes the conversation, and the third starts a fresh session. I would not use them reflexively. During a delicate investigation, earlier decisions, relevant files and completed checks may need to be preserved. When moving to unrelated work, carrying the whole history forward may make little sense.

There is an important distinction: free context space is not the same as remaining usage allowance. The window describes the information an interaction can accommodate; the allowance depends on the service's commercial terms. Compaction can help organize work, but it does not automatically refund usage that has already occurred.

Caching: not every token has the same weight

Imagine a project where an agent repeatedly consults the same instructions. Prompt caching enables processing to be reused for repeated parts of the input, subject to specific conditions. That can change cost and latency without necessarily reducing the number of tokens you see in the context.

This is why I would be cautious about savings comparisons based exclusively on total token counts. For API usage, for example, distinguish uncached input, cache reads or writes, and output, using the applicable prices. With a subscription, the relevant metric may be different. Compare the indicators available for your actual plan.

Here is an interesting exercise: run similar tasks in separate sessions and observe what gets repeated. Do not start changing cache configurations without understanding your provider's rules. The point is to discover what is happening, not to manufacture savings on paper.

Persistent instructions, skills and integrations

CLAUDE.md helps guide the agent through a project. I would use it for what genuinely needs to be remembered: conventions, validation commands, operating boundaries and details that are not obvious. Huge, outdated documents full of conflicting orders can become a permanent reading obligation.

A skill can hold instructions for a specific activity, such as preparing a release. MCP integrations let agents consult other systems. These are useful when they solve a real problem. Before adding another integration, I would ask: does it avoid work or simply introduce another step?

Anthropic recommends reviewing persistent instructions and integration context. My preferred approach is to keep essential rules available and introduce additional information when the task actually requires it, without removing security, authorization or validation controls.

Models, reasoning and agents: when is delegation worthwhile?

I see no reason to treat all tasks as equally difficult. Finding text in a project is not the same as investigating an authentication failure across multiple parts of a system. Model choice and reasoning effort should reflect complexity and risk.

Claude Code also supports delegating activities to subagents that can work in separate contexts. That can help when an investigation would otherwise bring lots of unnecessary material into the main conversation. But each agent makes its own requests. Creating five agents for something one could handle well may increase usage and coordination work.

I would parallelize genuinely independent activities. If one agent needs another's answer before proceeding, a straightforward sequence might be better. Either way, greater autonomy needs clear acceptance criteria. A change that saves resources but introduces a bug is not a success.

Claude Code, Codex, Gemini CLI and Dorothy Merge: what differs?

In September 2026, OpenAI published guidance about Codex with GPT-6 Astra, recommending a review of older instructions and skills to avoid loading material unrelated to the task. I find that discussion valuable because practices that worked for one model generation may not be necessary for the next.

Claude Code uses CLAUDE.md; Codex uses AGENTS.md; Gemini CLI offers GEMINI.md to guide the agent on a project. Each has its own capabilities, usage rules and workflow management. Rather than comparing only prices or context sizes, I would look at how easily we can guide the agent, verify changes, monitor consumption and integrate the workflow.

At Dorothy, this broader view of efficiency shaped the Dorothy Merge proposition: combine optimization, monitoring and attention to outcome quality. I do not consider native capabilities and an efficiency platform mutually exclusive. I care about the conditions under which each adds value. Comparisons require equivalent tools, settings and tasks; there is no universal savings percentage.

A test you can run tomorrow

Choose a small, verifiable task, such as fixing a required signup field. Set up two identical copies of the project with the same starting state and define success: the field is validated, tests pass, and nothing outside the scope changes.

On the first run, use your usual workflow. On the second, try a more directed request: “Investigate why the email field accepts an empty value. Fix only signup, preserve the layout and run the relevant tests. Report changed files and validation results.” This is an illustrative example, not the result of an experiment we have already performed.

Record the model, settings, initial context and cache conditions, total time, reported usage and manual interventions. Claude Code's documentation identifies /usage as a starting point for monitoring consumption, distinguishing API and subscription information. Repeat the test across equivalent tasks to reduce the influence of an unusual run.

To evaluate Dorothy Merge, you could add a third run under the same conditions with the integration enabled, when compatible with your environment. Compare cost or usage per successfully completed task at equivalent quality. A fast but incorrect result is not a success. An estimated cost is not an actual charge.

The kind of efficiency that matters to me

Ultimately, I do not want AI to become yet another field where people must master dozens of technical terms to get useful results. I want them to understand what they are consuming, make better choices and work with more confidence.

So I would not start by asking how to reduce tokens at any cost. I would ask how to complete more useful work without sacrificing quality. Resource savings can follow naturally from a better-designed process. That is a topic I want to keep exploring here at Dorothy Labs.

Sources and further reading

References checked on November 27, 2026.

Conversation with the author

Share your experience, ask a question or leave your thoughts on the article.

Loading interactions…

Keep exploring