Token Efficiency

11essays ·All tags

Architecture11 min read

Both Sides of Context Compression

Codemode-style tool gateways solved half of context compression. The other half — what happens to a tool's response after it returns — is still an open problem for the whole category. Here's a measured look at why it matters more than people think.

  • Token Efficiency
  • Mcp
  • Benchmarks
  • Agents
Architecture10 min read

Both Sides: Why Input Compression Alone Isn't Enough

Every MCP cost optimization solves either the input side or the output side. ClawQL's search → execute primitive solves both — and the compounding effect on cost, model quality, and cache hit rate is why compression numbers look the way they do.

  • Token Efficiency
  • Agents
  • Mcp
  • Llm Ops
Architecture28 min read

The Week Everything Converged: PorTAL, gRPC Transport 1.0, Stateless MCP, and OKF v0.2

Four independent developments in one week — PorTAL portable LoRA adapters, mcp-grpc-transport 1.0, MCP 2026-07-28 stateless protocol, and OKF v0.2 trust signals — each strengthen the same ClawQL architecture. Here's why that convergence matters and what it changes.

  • Llm Ops
  • Agents
  • Grpc
  • Mcp
  • Vault
  • Token Efficiency
  • Supply Chain
Architecture24 min read

The Inference Bill Nobody Can Explain

The invoice says you spent $34,000 on LLM inference last month. It doesn't say who, what, or why. A practical guide to building the attribution system that turns a billing line item into an operational signal.

  • Agents
  • Llm Ops
  • Token Efficiency
  • Telemetry
  • Security
Architecture24 min read

The API Spend That Never Compounds

Every month you run production inference, you generate training data. Most teams let it evaporate. A practical guide to building the flywheel that turns API spend into proprietary model capital.

  • Agents
  • Llm Ops
  • Token Efficiency
  • Telemetry
  • Security
Architecture24 min read

The Institutional Knowledge Tax

Every AI session starts from zero. Your team pays the re-explanation cost every single time. A structural look at what cross-session memory actually requires — and why most teams don't have it.

  • Agents
  • Vault
  • Rag
  • Llm Ops
  • Token Efficiency
Architecture32 min read

The Complete Agent Memory Stack

ClawQL's five-layer memory architecture — OKF vault, vector recall, PageIndex, CodeGraph, Onyx — and how they compose into persistent, auditable, sovereign agent intelligence.

  • Agents
  • Llm Ops
  • Token Efficiency
  • Telemetry
  • Security
  • Vault
Architecture28 min read

The Enterprise Ontology: OOP Taken to Its Logical Extreme — and Why Your AI Agents Need It

How typed entity schemas, permission-aware relationship graphs, and kinetic MCP writes transform AI agents from JSON-blob processors into typed, auditable business intelligence — with ClawQL's `.cqe` format, fixture-backed reads, LOW/MEDIUM kinetic tools, and an honest map of what is shipped vs roadmap.

  • Agents
  • Llm Ops
  • Token Efficiency
  • Security
  • Telemetry
  • Vault
Architecture26 min read

Model Escalation and Agent Coordination: How ClawQL Routes Intelligence, Not Just Requests

The architecture behind ClawQL's two-layer inference strategy — outcome-driven model escalation and diversity-measured agent coordination — and why NousResearch's independent MoA work validated what we built before they published it.

  • Agents
  • Llm Ops
  • Token Efficiency
  • Telemetry
  • Security
Architecture22 min read

Replacing LiteLLM After the March 2026 Supply Chain Compromise

In March 2026, a malicious package in LiteLLM's Python dependency tree harvested credentials from production inference infrastructure. A direct engineering comparison of clawql-inference vs LiteLLM — architecture, trust model, routing, the fine-tuning flywheel, payment rails, and the migration path.

  • Agents
  • Llm Ops
  • Supply Chain
  • Token Efficiency
  • Security
  • Telemetry
Architecture24 min read

The Twelve Layers of LLM Cost

Your inference bill is real. What's driving it usually isn't what you think. A structural breakdown of where LLM cost actually accumulates — and what you can do about each layer.

  • Agents
  • Llm Ops
  • Token Efficiency
  • Telemetry
  • Security