Multi-Model Routing for Office AI Agents: A Practical Engineering Guide

    This article explains why office AI agents are moving from a single self-built model to a multi-model setup, and how to make that shift work in production. It covers a capability-based model registry that hides vendor differences, a four-layer routing strategy (rule-based, auto scoring, explicit user override, and fallback), an explainable quota multiplier for billing, and the observability and evaluation metrics needed to tune routing. It also outlines a generic cloud architecture and key takeaways for teams building similar systems.

    1. Why Office Agents Are Moving to Multiple Models

    Over the past year, agent products for office scenarios have largely shifted from a “single self-built model” to “multiple models running side by side.” This change is not driven by one factor but by three types of pressure stacking up.

    The first is capability-boundary pressure. Office tasks span a wide range: long-document summarization, table extraction, cross-system workflow orchestration, code and formula generation, and multi-turn clarification dialogue. These tasks place completely different demands on long context, structured output, and tool-call stability. No single model can lead on every dimension at once.

    The second is cost pressure. An office agent is a high-frequency, long-context, tool-heavy workload, so its token consumption is far higher than that of ordinary chat. If every request goes to the same tier of model, simple tasks get over-served by a high-end model, and the bill balloons quickly.

    The third is entry-point competition pressure. When competing products already support multiple vendors and select models automatically through routing policies, a single-model product is at a natural disadvantage in evaluation. As a result, multi-model support has turned from a “technical option” into “product infrastructure.”

    It is worth stressing that going multi-model does not end with piling a model list onto the interface. The real engineering difficulty is turning “model selection” from a manual user decision into a scheduling capability that the system can measure, roll back, and audit.

    2. Capability Tiers: Structure the Model Pool First

    Before integrating any third-party model, you should establish a unified internal model-tier abstraction. A common industry practice is to tag models along three dimensions:

    • Capability: long context, structured output (JSON/Schema constraints), tool calling, multimodal understanding, code ability;
    • Cost: price per token unit, quota consumption multiplier;
    • Performance: first-token latency, throughput, rate-limit thresholds, availability SLA.

    A sample model registry structure is shown below (it expresses the abstraction only and does not point to any specific product):

    1. {
    2. "model_id": "internal-alias-001",
    3. "vendor": "vendor_a",
    4. "tier": "light | standard | strong",
    5. "capabilities": ["long_context", "json_schema", "tool_call"],
    6. "quota_ratio": 1.0,
    7. "latency_profile": "low | medium | high",
    8. "fallback_of": null
    9. }

    The key point is to hide vendor differences from the upper-layer business. Business code should be written against “capability tier + constraints” rather than a specific model name. This way, when the model lineup or price multipliers change, the business side needs no changes.

    3. Routing Strategy: From Manual Selection to Automatic Scheduling

    The value of multiple models is only fully released once the routing strategy matures. Practical strategies usually come in four layers.

    The first layer is rule-based routing. It hard-maps by task type, for example, sending summarization tasks to the light tier and cross-system workflow orchestration to the strong tier. It is simple to implement and highly explainable, making it suitable as a fallback baseline.

    The second layer is Auto mode. A scheduler scores and selects a model based on request features (context length, whether tool calling is needed, output format constraints) and real-time metrics (current rate limiting, latency percentiles). Sample logic:

    1. def route(req, registry, metrics):
    2. cands = [m for m in registry
    3. if set(req.required_caps) <= set(m.capabilities)]
    4. if not cands:
    5. return registry["default_fallback"]
    6. def score(m):
    7. s = 0.0
    8. s -= req.est_tokens * m.quota_ratio * 0.01 # cost term
    9. s += 0.3 if m.tier == req.min_tier else 0.0 # capability term
    10. s -= metrics.p95_latency(m.id) / 1000.0 # latency term
    11. s -= 5.0 if metrics.is_throttled(m.id) else 0.0
    12. return s
    13. return max(cands, key=score)

    The third layer is explicit user selection. Keep the ability to override manually for cost-sensitive or compliance-sensitive scenarios, but the interface should label the quota consumption multiplier so users have an intuitive expectation of “how expensive it is.”

    The fourth layer is degradation and fallback. When the preferred model is rate-limited or times out, the system automatically switches along the fallback_of chain while ensuring tool-call context is not lost. This layer determines the lower bound of product availability.

    4. Billing and Quota: Make the Multiplier an Explainable Resource Language

    Multiple models inevitably bring differentiated billing. Engineering practice does not recommend exposing “how much per million tokens” directly to users; instead, abstract it as a “quota consumption multiplier”: take one tier of model as the baseline of 1.0, and convert the rest proportionally. The benefit is that when the model lineup changes, the user’s mental model stays the same.

    Three things are needed to support this: first, estimate and display the quota before a request; second, make bill details attributable by task and by model; third, when offering operational measures such as limited-time promotions or new-user trials, multiplier adjustments must have version records to avoid billing disputes.

    5. Observability and Evaluation: No Measurement, No Optimization

    A multi-model system must build two paths: an offline evaluation set and online canary. Offline, use a fixed task set (summarization, extraction, table QA, workflow orchestration) to run accuracy and format-compliance rates; online, use A/B splitting to observe task completion rate, human-takeover rate, and average quota consumption.

    Metrics should cover at least: routing hit rate, degradation trigger rate, first-token latency P95, quota cost per task, and tool-call failure rate. These metrics are also inputs to routing weights, forming a closed loop.

    6. General Implementation Advice from the Baidu AI Cloud Perspective

    If an enterprise wants to build similar capabilities on Baidu AI Cloud, it can adopt a combination of general cloud product categories: use a container platform to host the scheduling service, use a message queue to smooth peaks and support asynchronous long tasks, use object storage to store evaluation sets and conversation archives, and use log services with monitoring and alerting for attribution and rate-limit warnings. Keep the model integration layer pluggable, so adding a model only requires registering capability tags and multipliers, without changing business code.

    7. Conclusion

    Competition among office agents has shifted from “model strength” to “scheduling efficiency.” Being multi-model is only the entry ticket; what really creates a gap is whether capability tiers are clear, whether routing is measurable, whether multipliers are explainable, and whether degradation is reliable. Get these four things solid, and expanding the model lineup will become a product advantage rather than an operations burden.