Mahal Systems

Overview › 2Tools › a.Refactoring

Refactoring

Refactor & combine. 3 optimizations.

  1. i.

    Better qualityLower costMixed performance

    Tier 1 · hygiene · changes tool surface, context · tool use agents · 32 sources, 23 measured

  2. ii.

    Rewrite the tool surface: names, schemas, descriptions

    Change what the model sees of each tool without touching its implementation: a distinct name, a strict schema (enums, required fields), and a description with fixed sections (what it is for and when to use it versus sibling tools, defaults and limits, error modes, side effects), plus a usage example for complex parameters.

    Better qualityMixed costMixed performance

    Tier 1 · hygiene · changes tool surface · tool use agents · 18 sources, 8 measured

  3. iii.

    Choose how the agent acts: typed tools, code execution, or shell, matched to the model and task

    Decide the action interface deliberately, by model and by task, and provision what it needs.

    Lower costMixed quality

    Tier 3 · tuning · changes tool surface, model · tool use agents · 22 sources, 10 measured

Before you go...

Build better agents, weekly

Our latest research, performance benchmarks, optimization strategies, and updates around AOT development.

One email a week, nothing else. Unsubscribe anytime.