GitHub cut Copilot inference cost about 3% by dropping unused line numbers

GitHub published what worked and what failed while optimising Copilot's agent harness, arguing that tokens per tool call is the wrong efficiency target.

Paylaş
GitHub cut Copilot inference cost about 3% by dropping unused line numbers

GitHub has detailed the changes it made to Copilot's agent harness to lower cost, along with the experiments that backfired. The company's argument: token count in a single tool call is not a meaningful efficiency measure. If a shorter tool response omits something the agent needs, the agent makes extra calls and the task ends up slower and more expensive.

The clearest example is RTK (Rust Token Killer), a utility that shortens shell output before an agent reads it. In GitHub's harness and benchmark configuration, RTK did shorten some responses, but when the omitted text mattered the model reopened the original output or reran the command. Those recovery steps added turns and carried more context forward, so on average tasks consumed more tokens and took longer. GitHub notes the result applies to the integration and workloads it tested, not to output compression in general.

A conservative compressor

Benchmark analysis showed install, build, test and lint output often carries repetitive noise, while source-like output and arbitrary command results are more likely to hold information the agent needs. That fed a selective compressor. Early versions were too aggressive: compressing git diff made agents reopen the original, so that filter was dropped. In the shipped version the agent can always retrieve the full original through a direct recovery path. Offline tasks showed no statistically significant task-success regression, and the online experiment produced a slight decrease in average cost.

The cleanest win came from the view tool, which prefixed every line of every file read with a line number. Current editing tools match surrounding code instead of using those numbers, so the formatting served no purpose. Removing it cut model-inference cost by roughly 5% in offline agentic coding benchmarks. In an online experiment with Copilot CLI users, average daily model-inference cost per user fell about 3%, with no material regression in tracked quality or satisfaction metrics.

Examples come from Copilot CLI, but the GitHub Copilot app and Copilot code review share the same harness. Full write-up on the GitHub Blog.

Devamını oku

Liquid AI تطلق أكبر نماذج LFM2.5 المفتوحة لتشغيل الوكلاء على الأجهزة

Liquid AI تطلق أكبر نماذج LFM2.5 المفتوحة لتشغيل الوكلاء على الأجهزة

أطلقت Liquid AI نموذج LFM2.5-24B-A2B كنموذج مفتوح، ويضم 24 مليار معامل إجمالا لكنه يشغل نحو 2.5 مليار منها في كل خطوة. وبحسب النتائج التي نشرتها الشركة، يولد النموذج المدرب للوكلاء الذين يستخدمون الأدوات 184 رمزا في الثانية على Apple M5 Max.

GlobalFeed Editor tarafından