From 357f8a8008a720fedbf76bcbd1414d7f417c1e90 Mon Sep 17 00:00:00 2001 From: LoopX Agent <337587101+loopx-agent@users.noreply.github.com> Date: Sun, 8 Nov 2026 14:05:44 +0800 Subject: [PATCH] docs(blog): explain bounded context reads and process costs Signed-off-by: LoopX Agent <337587101+loopx-agent@users.noreply.github.com> --- .../public/blog/context-delivery/index.html | 54 +++++++++++++++---- apps/presentation/site/public/blog/index.html | 4 +- .../blog/zh/context-delivery/index.html | 54 +++++++++++++++---- .../site/public/blog/zh/index.html | 4 +- 4 files changed, 92 insertions(+), 24 deletions(-) diff --git a/apps/presentation/site/public/blog/context-delivery/index.html b/apps/presentation/site/public/blog/context-delivery/index.html index f7acaef6df..38f7c61099 100644 --- a/apps/presentation/site/public/blog/context-delivery/index.html +++ b/apps/presentation/site/public/blog/context-delivery/index.html @@ -1,16 +1,17 @@ -An Agent needs a way to look things up, too · LoopX +An Agent needs a way to look things up, too · LoopX - + -
← All articles

Context delivery

An Agent needs a way to look things up, too

Follow one voice task through progressive reads, JSON Pointers, exact sharing, compaction-cycle deltas, and complete recovery.

-

Long-running work accumulates material: the original goal, later constraints, attempted routes, failed experiments and current progress. Sending everything again on each continuation repeats more and more content; keeping only a summary can make the original basis of a decision difficult to recover.

+
← All articles

Context delivery

An Agent needs a way to look things up, too

One voice task, from choosing facts to fitting the first read, preserving exact values, and recovering without replaying work.

+

Long-running work accumulates material: the original goal, later constraints, attempted routes, failed experiments and current progress. Sending everything again on each continuation repeats more and more content; keeping only a summary can make the original basis of a decision difficult to recover.

LoopX's context delivery separates these jobs: preserve complete sources, read the facts needed for the current decision, expand supporting material around questions, and reuse unchanged structures exactly within a valid compaction cycle.

-

This article describes the native Codex path in released LoopX 2.2.0. Supported POSIX Codex App/SSH sessions and new benchmark heartbeat trials default to context delivery; saved off remains effective and explicit off is available. When enabled, complete content is saved first and the Agent receives a reading entrypoint for current facts. See the 2.2.0 release notes for publication and validation scope. The synthetic measurements below retain their original source and experimental conditions.

-

Think of a capture as a complete book. An index locates its chapters; a JSON Pointer addresses a place inside it. Progressive reading determines how deeply to open the material now. Differential delivery determines what can be reused on the next continuation.

+

The core native Codex path ships in LoopX 2.2.0. Supported POSIX Codex App/SSH sessions and new benchmark heartbeat trials default to context delivery; saved off remains effective and explicit off is available. When enabled, complete content is saved first and the Agent receives a reading entrypoint for current facts. See the 2.2.0 release notes for publication and validation scope.

+

Think of a capture as a complete saved snapshot, like a book whose edition is fixed. An index locates its chapters; a JSON Pointer addresses a place inside it. Progressive reading determines how deeply to open the material now. Differential delivery determines what can be reused on the next continuation.

+

This November 8 revision also follows the first-read, staged-scope, transport and numeric-fidelity changes merged after 2.2.0, checked at source 611019243e. Those sections describe that source snapshot, not an upgrade already installed everywhere. The original teaching measurements and archived research results below retain their earlier versions and conditions.

Follow one task: give an assistant voice input

Suppose an assistant needs to understand a voice note and reply in its original chat. Its complete material contains the goal, provider constraints, privacy requirements, acceptance and a long discussion of alternatives. This is a teaching example; the example program below generates the complete data in an isolated directory.

capture.json
@@ -114,6 +115,9 @@ 

See requirements first, then open their evidence

The implementation returns supporting_material_pointer, locating the outcome in the original capture. Call that returned prefix $P: append /requirements/2/agent_review/note for the explanation, or /requirements/2/agent_review/evidence_refs for evidence references. Use this capture's prefix rather than copying an array position from another file.

After assembling the voice task into the existing typed acceptance structure, its complete original capture is 57,014 bytes and necessary view 5,107 bytes. All 10 requirement descriptions remain complete, together with unmet/stale/independent-verification facts. The original 57,014 bytes also remain intact. Supporting history and long explanations have exact expansion addresses.

Relationship navigation can suggest which outcomes to inspect first using task dependencies, shared acceptance, sources and evidence. Incomplete relationships widen scope, and contrary evidence from other routes stays accessible. Navigation helps order reading; the Agent still determines what affects this decision.

+

Read scope before the decision that depends on it

+

The voice integration also has a timing question: when must the Agent inspect every allowed write path? In the November source, selection and ordinary claim preparation can replace a long write_scope list with an exact expansion address in the original capture. Stops and approval requirements remain directly visible. If choosing the speech adapter depends on whether its files may be edited, the Agent must open that scope before choosing. The ready decision supplies the complete current scope; claiming the task still checks ownership and scope atomically.

+

This changes when detail is read. It neither grants permission nor removes a required check. The regression uses 220 synthetic paths to exercise a long scope list; that is a stress fixture, not 220 product rules. Reading the list adds a call when it is needed, and the ready-stage list remains complete. Scope change and validation · checked implementation.

Share exact records within one delivery

A task can appear in both current work and a queue summary. Repeating an identical complete record adds no fact.

The native necessary view can retain one complete task and reference it elsewhere:

@@ -188,9 +192,36 @@

When enabled, the default output is a reading entrypoint

A continuation reference pins its selection: follow its next_command to EOF and return to the original recovery reference to change Pointers. Very small budgets may retain the explicit file/digest interface. The teaching measurements above use that compatible interface and retain their original conditions.

+

The first response has to arrive complete

+

A short command can return a large response. For the voice task, the first read must deliver the current decision, required reads and a way to continue. If the tool truncates the response, the Agent can lose the instruction for recovering the missing material as well.

+

The November source therefore budgets the complete serialized JSON response in UTF-8 bytes, including quoting, page metadata and navigation. --page-bytes limits content bytes; --max-page-output-bytes limits the whole response. With no explicit output budget, generated linked first reads and attached native context-project --initial-read pages use a 12,000-byte fallback. Ordinary bulk/recovery readers and the saved task-selection recipe retain their existing budgets.

+

When the complete starting selection needs multiple pages, the attached reader tries an independently complete opening containing the decision and read obligations. It uses that opening only if the entire response fits; the rest stays required through remaining_read_command and its page cursors. A cursor is the returned byte offset for continuing the same selection. If the opening cannot fit, ordinary same-capture pagination remains available. For a missing or unwritable context store, recovery likewise retains the original capture.

+
# Explicit budgets on a current returned reader reference:
+loopx --format json quota context-read \
+  --reference-file "$RECOVERY_READER_REFERENCE" \
+  --select "$POINTER_A" --select "$POINTER_B" \
+  --page-bytes 12000 --max-page-output-bytes 12000
+
+

These two limits can have the same value while the returned content is smaller: framing takes space too. Twelve thousand bytes is a fallback for an unknown tool boundary, not a universal optimum or a guarantee that the host retains those bytes in later model input. Smaller pages may require more calls and repeated framing. After truncation, recover the affected range from the same capture with a suitable explicit budget; do not repeat task admission or external work. First-read change and validation · checked reader.

What was saved, and what the model has read

The delta codec answers: can the verified old file reconstruct the exact current file? The native captured_file path verifies the complete saved baseline, version and scope. It does not require the model to have read the old file, reached a selected page’s EOF or sent an ACK. Each baseline is itself a complete version, so the model need not replay a chain of deltas first.

Progressive reading answers a different question: which facts does this decision need? In the voice illustration, suppose the next continuation adds sample 3 while the privacy constraint remains unchanged. Consider a missed-read counterexample: the Agent skipped the required privacy constraint, or can no longer establish it after compaction. Before sending audio externally, it must recover /goal/constraints through the current entrypoint and honor the existing authorization boundary. It can read that fact directly, without first draining the old baseline. A saved file or an unchanged field does not replace the necessary read.

+

Count the trips and the copies, too

+

Some delivery cost occurs before the model sees anything. The Python CLI asks the TypeScript owner to prepare a view and receives its response. Each such request and reply is a local process round trip, also called an internal RPC. A CLI command can make several of these trips.

+

For an already verified saved capture, the November source can return the first selection directly with progressive delivery on and cycle deltas off. The selection already names the needed facts; precomputing a root index first adds an unnecessary trip. Review, writeback instructions and recovery still point to the same original decision.

+

The author’s fixed synthetic SQLite sequence in #8298 covers the first selection, review and writeback-contract reads. Its report at 775394bd8d, integrated with 94b91e48aa, records:

+
+ + + + + + + +
MeasureBeforeAfter
CLI calls43
Internal RPCs54
RPC transport326,204 B271,741 B
Selected first-read content8,046 B8,046 B
Complete CLI stdout32,846 B33,060 B
+

One fewer command did not make every layer smaller. The selected content was unchanged, and navigation made stdout slightly larger. These are the author’s process measurements, not a new performance run on this article’s source snapshot or a model-token result.

+

A second duplication occurred inside a response: full native delivery sent the same projected body as both typed edits and delivery.context. The producer now sends it once across the Effect bridge, and the Python adapter reconstructs the ordinary full shape. Delta still carries its own edits. In #8285’s author record, the affected SQLite response fell from 53,999 to 38,225 B; the sequence including the guard, native hook, a rejected hash and same-capture retry fell from 1,021,975 to 1,006,203 B. Stage outputs and call counts matched. Producer · adapter.

+

Both changes remove repeated transport while retaining the task’s requirements. Their end-to-end value still depends on later reads, recovery, actual model input and cache use, output, elapsed time and accepted work. Local wire bytes cannot stand in for those costs.

Recover missing context while preserving the original work

After host compaction, a subsequent work Turn builds a new complete baseline. Original goals, requirements and sources remain available for necessary reads.

If compaction, missing pages or truncated output interrupt an unfinished Turn, recover missing facts from its original capture while retaining task, effect and settlement identity. If a voice result was already sent but its receipt was lost, recovering context must not become sending the result again.

@@ -201,6 +232,9 @@

Recover missing context while preserving the original work

Paged content: follow next_command with capture digest, selection digest and byte cursor; combine contiguous content in order. Selection EOF covers only that selection.
  • Unknown or inapplicable structures: retain complete content and original read obligations rather than guessing which prose can be hidden.
  • +

    A shorter view must preserve the original values

    +

    File integrity alone does not guarantee that every projected value survived a language boundary. A staged read reproduced in November turned the integer 9007199254740993 into 9007199254740992. Two distinct acceptance records could then appear identical and share one reference. The raw capture could remain unchanged while the returned facts were wrong.

    +

    The saved native path now avoids an unnecessary replan projection for ordinary decisions and applies presentation edits to original source values when replanning is needed. The staged replan reader likewise restores original numbers, preserving integers, integral floats and negative zero. Distinct records get distinct references; an ambiguous historical reference is rejected with a route back to review, while an unambiguous one still resolves. Explicit page windows also reach the saved reader through its existing validation. These are correctness and recovery changes merged in #8319 and #8324, with synthetic public-CLI regressions; they do not establish model comprehension or task-level savings.

    Continuity and recovery

    Differential Delivery: Reuse Within an Epoch, Full Recovery on Break

    One valid cycle: complete baseline → changed facts and delta → exact reconstruction.

    New cycle or known continuity loss: complete current source → read necessary facts again.

    An unfinished Turn retains its original capture, work and settlement identity. Reading recovery does not repeat external effects.

    What the measurements establish

    The example separates three mechanisms: avoid repeatedly moving history not currently needed, combine reads that belong together, and avoid retransmitting unchanged verified structures. Complete sources, requirements and recovery connect them.

    @@ -226,12 +260,12 @@

    Multi-task and layered ablation: benefit chain and bo ANN 18h: Explore · Context off 5,766 QPS (+0.2%) -Peaked at 11.37h; repeated full-context delivery consumed main-session budget +Peaked at 11.37h; input accounting is reported separately below ANN 18h: Explore · Context on 6,020 QPS (+4.6%) -Peaked at 14.43h; progressive reads and cycle deltas preserved late-stage headroom +Peaked at 14.43h; this run's later peak does not isolate the cause ANN 18h: Explore · Context on + Stride @@ -256,7 +290,7 @@

    Multi-task and layered ablation: benefit chain and bo Counterexample 2: First-2h early-window uncached input +304.7% (0.25M → 1.00M) -Initial baseline establishment and staged discovery add upfront overhead that only amortizes over longer horizons +Baseline establishment and staged discovery add upfront work; later amortization is not guaranteed by this early window Counterexample 3: Historical Grid (lower is better) @@ -265,7 +299,7 @@

    Multi-task and layered ablation: benefit chain and bo

    -

    This dual-track audit shows why control-packet byte reduction (−74.25% / −38.54%) must not be equated with whole-episode model token savings (−12.07% uncached, −7.46% total), nor used to hide early-window indexing overhead (4.05× in the first 2 hours) or cross-task counterexamples. Context Delivery’s practical value lies in slowing context bloat across 10–18 hour runs so that, together with Stride, preserved attention converts into effective late-stage experiments (see EdgeBench late-stage breakthroughs and five-arm attribution).

    +

    This dual-track audit shows why control-packet byte reduction (−74.25% / −38.54%) must not be equated with whole-episode model token savings (−12.07% uncached, −7.46% total), nor used to hide early-window indexing overhead (4.05× in the first 2 hours) or cross-task counterexamples. The reported ANN runs contain both lower input totals and later useful experiments. That observation motivates testing whether context delivery helps sustain long research, but does not by itself attribute the outcome to saved attention, separate every interaction with Stride, or establish a gain on another task. The November source changes above were not treatments in these archived runs. See EdgeBench late-stage breakthroughs and five-arm attribution for the original research context.

    2.2.0 ships complete sources, file entrypoints, batch selection, index depth, applicable acceptance layering, exact sharing, cycle deltas and recovery. Broader decision-stage candidate, preference and Explore delivery and consistency across all entrypoints remain unfinished. Disable in Settings → This machine → Capabilities → Differential context → Codex; saved off survives upgrade. A command or new benchmark trial can use --context-delivery off. Trials do not inherit the machine switch, and existing frozen trials are not rewritten. Under the default policy, ordinary CLI, unsupported hosts and non-heartbeat benchmarks retain their full paths; an explicit unsupported on request is rejected. Unavailable hooks use full delivery. Saving configuration, actual installation and model adoption remain separate checks.

    Read the same material yourself

    example.py generates this complete synthetic voice task and invokes the existing reader, progressive projection and delta owners. It checks selected values, directory addresses, all ten requirements, shared references and complete recovery. It registers no Goal, admits or settles no Turn, and calls no model or speech service.

    diff --git a/apps/presentation/site/public/blog/index.html b/apps/presentation/site/public/blog/index.html index 9c366bed44..eca05834b6 100644 --- a/apps/presentation/site/public/blog/index.html +++ b/apps/presentation/site/public/blog/index.html @@ -35,8 +35,8 @@

    LoopX · Blog

    Engineering the long run.

    Design, engineering, and field notes on long-horizon agents.

    -

    Context delivery · Mechanisms and examples

    · Updated November 3

    -

    An Agent needs a way to look things up, too

    One voice task explains JSON Pointers, batched selection, index depth, complete requirements, exact sharing and compaction-cycle deltas, paired with ANN 18h (7,159 vs 5,753 QPS) layered byte/token ablations and early-window/cross-task counterexamples.

    Read article
    +

    Context delivery · Mechanisms and examples

    · Updated November 8

    +

    An Agent needs a way to look things up, too

    One voice task explains progressive reads, complete first responses, scope checks, exact reuse and recovery. Follow the process costs separately from archived ANN results and their early-window and cross-task counterexamples.

    Read article

    Research notes · EdgeBench and LHTB

    diff --git a/apps/presentation/site/public/blog/zh/context-delivery/index.html b/apps/presentation/site/public/blog/zh/context-delivery/index.html index 1da678d9e2..37049e44ce 100644 --- a/apps/presentation/site/public/blog/zh/context-delivery/index.html +++ b/apps/presentation/site/public/blog/zh/context-delivery/index.html @@ -1,16 +1,17 @@ -Agent 读上下文,也需要一套“查书”的方法 · LoopX +Agent 读上下文,也需要一套“查书”的方法 · LoopX - + -
    ← 全部文章

    Context delivery

    Agent 读上下文,也需要一套“查书”的方法

    从一个语音任务理解渐进式读取、JSON Pointer、精确共享、compaction 周期内的结构化差分,以及失效后的完整恢复。

    -

    Agent 做长任务,资料会越来越多:原目标、后来追加的约束、试过的方案、失败的实验、当前做到哪里。每次继续都把整份材料再塞一遍,重复会不断累积;只留一段摘要,又可能找不回决定所依赖的原话。

    +
    ← 全部文章

    Context delivery

    Agent 读上下文,也需要一套“查书”的方法

    沿一个语音任务,讲清选读、完整首读、按阶段补读、精确复用与恢复。

    +

    Agent 做长任务,资料会越来越多:原目标、后来追加的约束、试过的方案、失败的实验、当前做到哪里。每次继续都把整份材料再塞一遍,重复会不断累积;只留一段摘要,又可能找不回决定所依赖的原话。

    LoopX 的 context delivery 把这件事拆开做:完整资料保存下来,当前决定需要的事实先读,支持材料沿问题展开;同一个有效 compaction 周期内,再精确复用没有变化的结构。

    -

    本文以已发布的 LoopX 2.2.0 Codex 原生路径为准。受支持的 POSIX Codex App/SSH 会话与新的 benchmark heartbeat 默认开启 context delivery;已有关闭设置继续生效,也可以显式关闭。开启后完整内容先保存,Agent 收到当前读取入口。具体发布与验证范围见 2.2.0 版本说明;下文的合成测量仍保留原始实验版本与条件。

    -

    可以把它想成查一本厚书:capture 是完整保存的那本书,目录告诉我们章节在哪,JSON Pointer 是书内地址。渐进式读取决定这一刻翻到多深;差分决定下一轮哪些内容可以沿用。

    +

    核心 Codex 原生路径已随 LoopX 2.2.0 发布。受支持的 POSIX Codex App/SSH 会话与新的 benchmark heartbeat 默认开启 context delivery;已有关闭设置继续生效,也可以显式关闭。开启后完整内容先保存,Agent 收到当前读取入口。具体发布与验证范围见 2.2.0 版本说明。

    +

    可以把它想成查一本厚书:capture 是完整保存的快照,像一本版本固定的书;目录告诉我们章节在哪,JSON Pointer 是书内地址。渐进式读取决定这一刻翻到多深;差分决定下一轮哪些内容可以沿用。

    +

    11 月 8 日这次修订,还接入了 2.2.0 之后合入的首读、阶段化范围读取、进程传输和数字精度修复,核对源码为 611019243e。对应章节描述的是这份源码,不代表所有安装都已升级。下文原有的教学测量与归档研究结果仍保留各自较早的版本和条件。

    用“管家读语音”串起一次工作

    假设要让管家理解语音消息,并在原对话返回结果。完整资料里保留了目标、服务约束、隐私要求、验收,以及很长的方案讨论。下面是教学示意,后文的示例程序会生成完整数据,可在隔离目录复现。

    capture.json
    @@ -114,6 +115,9 @@ 

    要求先看见,证明它的材料再展开

    实际实现中的 supporting_material_pointer 给出原始 outcome 的位置。假设把这个返回前缀记为 $P,需要评审解释时,就沿它接上 /requirements/2/agent_review/note;需要证据引用时,接上 /requirements/2/agent_review/evidence_refs。前缀来自当前捕获,不能照抄另一份文件的数组序号。

    本例将语音任务装配成现有 typed owner 支持的验收结构后,完整原始捕获是 57,014 字节,必要视图为 5,107 字节。10 条要求的原文全部保留,未通过、依据过期和独立核验标记仍在;原始 57,014 字节也完整保存。 支持历史与长解释有了可展开的地址。

    关系导航还可以沿任务依赖、共享验收、来源和证据,建议先看哪些 outcome。关系不完整时扩大范围;其他路线的反证仍然可达。它帮助安排阅读顺序,最终哪些事实影响当前判断,仍需要 Agent 理解。

    +

    范围在影响决定之前读到

    +

    给语音任务接服务,还涉及一个时机问题:什么时候必须逐条检查允许写入的路径?11 月的源码允许在选择任务、准备普通认领时,把很长的 write_scope 列表换成原始捕获中的精确补读地址,停止条件和审批要求仍直接可见。如果选择语音适配器取决于能否修改它的文件,就必须先打开范围再选择。工作就绪的 ready 决定恢复完整当前范围,认领任务仍原子检查归属与范围。

    +

    这里改变的是读取细节的时机,既不授予权限,也不免除必需检查。回归样例用 220 条合成路径制造长列表;它是压力输入,不是 220 条产品规则。需要范围时,补读仍增加一次调用,ready 阶段的列表也仍然完整。范围读取改动与验证 · 核对的实现。

    同一份交付里的相同记录,保留一个完整位置

    同一个任务可能同时出现在“当前工作”和“队列摘要”里。完全相同的正文重复两遍,并没有增加事实。

    原生必要视图可以保留一份完整任务,让另一处准确引用它:

    @@ -188,9 +192,36 @@

    开启后,默认交付的是一个读取入口

    --select "$POINTER_A" --select "$POINTER_B"

    续页引用固定当前选择,沿它返回的 next_command 读至 EOF;更换 Pointer 时,回到原 recovery 引用。极小预算可能保留原显式文件/摘要接口。上面的教学测量也使用这个兼容接口,数字仍对应原实验条件。

    +

    首条响应要能完整送达

    +

    一条读取命令很短,不代表返回也小。语音任务的首读要同时交付当前决定、必读要求和继续读取的方法。如果工具截断了响应,Agent 可能连恢复缺失材料的方法一起丢掉。

    +

    所以 11 月的源码按完整 JSON 响应序列化后的 UTF-8 字节计算预算,包括转义、分页元数据和导航。--page-bytes 限制正文,--max-page-output-bytes 限制整条响应。没有显式输出预算时,生成的 linked 首读命令与附带首屏的原生 context-project --initial-read 使用 12,000 字节回退值;普通 bulk/恢复 reader 和保存的任务选择 recipe 保留原预算。

    +

    完整起始选择需要分页时,附带首屏的 reader 会尝试先交付一个独立完整的 opening,包含决定和读取义务。只有整条响应放得下才使用它;其余内容仍须沿 remaining_read_command 和后续游标读完。游标就是返回的字节偏移,用于接续同一组选读。opening 放不下时,继续使用同一捕获的普通分页;上下文存储缺失或不可写时,恢复也仍保留原捕获。

    +
    # 对当前返回的 reader 引用显式指定预算:
    +loopx --format json quota context-read \
    +  --reference-file "$RECOVERY_READER_REFERENCE" \
    +  --select "$POINTER_A" --select "$POINTER_B" \
    +  --page-bytes 12000 --max-page-output-bytes 12000
    +
    +

    两项上限可以同为 12,000,实际正文却更短,因为封装也占空间。这个值是工具边界未知时的回退值,不是普适最优值,也不保证宿主在后续模型输入里仍保留这些字节。更小的页面可能增加调用和重复封装。发生截断后,要对同一捕获的受影响区间用合适的显式预算恢复,不能重新准入任务或重做外部工作。首读改动与验证 · 核对的 reader。

    文件保存了什么,模型读到了什么

    差分编码要回答的是:用已核验的旧文件,能否准确还原当前文件? 原生 captured_file 路径核验完整保存的基线、版本和 scope,不以模型先通读旧文件、某组选读的 EOF 或一次 ACK 作为前提。每份基线本身是完整版本,也不要求模型先追完一串差分。

    渐进式读取回答另一个问题:这次决定需要哪些事实? 仍以语音示意为例,下一轮只新增了样本 3,隐私约束没有变化。用一个遗漏读取的反例检验:假设 Agent 漏读了必需的隐私约束,或压缩后已经无法确认它。准备外发音频前,仍须从当前恢复入口补读 /goal/constraints,并遵守原有授权边界。它可以直接读这处事实,无须先通读旧基线。文件已保存、字段未变化,都不能代替这次必要读取。

    +

    往返几次,正文搬了几遍

    +

    有些交付开销发生在模型看到内容之前:Python CLI 请求 TypeScript owner 生成视图,再收回响应。这样一次进程之间的请求和返回,就是一次内部 RPC 往返;一条 CLI 命令可能包含多次往返。

    +

    对已经核验的保存捕获,11 月的源码可以在开启渐进交付、关闭周期差分时直接返回首组选读。选择本身已经指出要读哪些事实,事先再生成一次根目录会多一次往返。审阅、写回说明和恢复仍指向同一份原始决定。

    +

    #8298 的作者用固定合成 SQLite 输入,记录了首组选读、审阅和写回契约读取这段序列。报告版本为 775394bd8d,已集成 94b91e48aa:

    +
    + + + + + + + +
    计量层改动前改动后
    CLI 调用43
    内部 RPC54
    RPC 传输326,204 B271,741 B
    首读所选正文8,046 B8,046 B
    CLI 完整 stdout32,846 B33,060 B
    +

    少一次命令,没有让每一层都变小:所选正文没变,导航反而使 stdout 略增。这些是作者的进程测量,不是这次文章源码上的新性能复验,也不是模型 Token 结果。

    +

    另一处重复发生在一条响应内部:原生 full 交付曾把同一投影正文同时放进 typed edits 和 delivery.context。现在生产端只跨 Effect bridge 发送一份,再由 Python adapter 还原普通 full 结构;delta 保留自己的编辑。#8285 的作者记录中,受影响的 SQLite 响应从 53,999 降到 38,225 B;包含 guard、原生 hook、一次错误摘要拒绝和同捕获重试的序列,从 1,021,975 降到 1,006,203 B。各阶段输出及调用数一致。生产端 · adapter。

    +

    这两处改动都在保留任务要求的前提下减少重复搬运。它们对完整任务的价值,仍要连同补读、恢复、实际模型输入与缓存、输出、耗时和验收成果一起判断,不能用内部传输字节替代这些成本。

    压缩或读取失败,恢复上下文,也保留原工作

    宿主发生 compaction,后续新工作轮次建立新的完整基线。原目标、要求和来源仍然存在,必要事实可以重新读到。

    如果压缩、缺页或输出截断发生在尚未结束的 Turn 内,就沿原捕获补回缺失事实,保留原任务、执行和结算身份。假设语音结果已经发送,只是回执没有读到,恢复上下文不能变成再发一次结果。

    @@ -201,6 +232,9 @@

    压缩或读取失败,恢复上下文,也保留原工作长内容跨页: 按 next_command 接读,保留捕获摘要、选择摘要和字节游标,按连续偏移组合正文。某组选读的 EOF 只覆盖该选择。
  • 遇到未知结构或不适用的来源: 保留完整内容及原有读取义务,不猜哪些文字可以隐藏。
  • +

    视图变短,原值也要保真

    +

    文件完整,不保证投影里的每个值都完整跨过了语言边界。11 月复现的一条阶段化读取,把整数 9007199254740993 变成了 9007199254740992;两份不同的验收记录还可能因此看起来相同,被放到一个引用下面。原始捕获没有变,返回的事实却已经错了。

    +

    保存的原生路径现在对普通决定跳过无须执行的 replan 投影,确需重规划时,将呈现编辑应用于原始来源值。阶段化 replan reader 同样恢复原数字,保留整数、整数值浮点数和负零。不同记录得到不同引用;历史引用若有歧义,明确拒绝并指回审阅,无歧义的仍能解析。显式分页窗口也沿现有校验进入保存 reader。这些是 #8319、#8324 合入的正确性与恢复修复,有合成输入的公开 CLI 回归支撑;它们不证明模型理解或整题成本收益。

    连续性与恢复

    Differential:同一有效周期内复用,失效即完整恢复

    同一有效周期:完整基线 → 新事实与差分 → 完整还原。

    新周期或已知连续性丢失:当前完整来源 → 必要事实重新读取。

    未结束的 Turn 保留原捕获、原工作与结算身份。恢复读取不重新执行外部副作用。

    这些数据说明了什么

    这组例子把三个收益来源分开了:少重复搬当前用不上的历史,少发本可合并的读取请求,少重复交付已经核验的不变结构。 完整来源、要求与恢复路径贯穿其中。

    @@ -226,12 +260,12 @@

    真实模型与多题消融实证:收益链路与 ANN 18h:Explore · Context off 5,766 QPS(+0.2%) -11.37h 触顶;全量上下文重复投递消耗较多主会话预算 +11.37h 触顶;输入成本在下方单列统计 ANN 18h:Explore · Context on 6,020 QPS(+4.6%) -14.43h 触顶;渐进选读与周期差分释放后程上下文余量 +14.43h 触顶;该次运行的后程峰值不能单独隔离原因 ANN 18h:Explore · Context on + Stride @@ -256,7 +290,7 @@

    真实模型与多题消融实证:收益链路与 边界反例 2:前 2h 早窗未缓存输入 Token +304.7%(0.25M → 1.00M) -早窗首次建立基线与分步选读存在前置开销,需在更长周期内摊薄 +建立基线与分步选读增加前置工作;这个早窗不能保证后续摊薄 边界反例 3:跨题 Historical Grid(越低越好) @@ -265,7 +299,7 @@

    真实模型与多题消融实证:收益链路与

    -

    这组双轨实证说明:控制包裁剪率(−74.25% / −38.54%)不能直接等同于整轮模型 Token 节省(未缓存 −12.07%、总输入 −7.46%),更不能掩盖前 2 小时早窗的前置建索引开销(4.05×)和跨题反例。 Context Delivery 的真实价值在于长周期(如 10h–18h)内延缓上下文膨胀、配合 Stride 将省下的注意力转化为后程有效实验(参见 EdgeBench 后程突破与五臂归因)。

    +

    这组双轨实证说明:控制包裁剪率(−74.25% / −38.54%)不能直接等同于整轮模型 Token 节省(未缓存 −12.07%、总输入 −7.46%),更不能掩盖前 2 小时早窗的前置建索引开销(4.05×)和跨题反例。 报告中的 ANN 运行同时出现了较低输入总量和后程有效实验,值得据此继续检验上下文交付能否支撑长程研究。但这些观察本身不能将成果归因于省下的注意力、拆清它与 Stride 的全部交互,也不能证明换一题仍有收益。上文 11 月的源码修复并不是这些归档运行的实验干预。原研究条件见 EdgeBench 后程突破与五臂归因。

    2.2.0 已交付完整来源、文件入口、批量选择、目录深度、适用验收分层、精确共享、周期差分与恢复。更广的候选、偏好、Explore 按决策阶段统一交付及全入口一致性仍有未完成部分。在「设置 → 本机 → 能力 → 差分上下文 → Codex」可以关闭,已有 off 会保留;单次命令或新 benchmark trial 可用 --context-delivery off。Trial 不继承本机开关,已有冻结 trial 不被重写。默认策略下,普通 CLI、不支持的宿主和非 heartbeat benchmark 保留原完整路径;显式请求不支持的 on 会明确拒绝,hooks 不可用时使用完整交付。保存配置、实际安装与模型采用分别核验。

    用同一份材料动手读一遍

    example.py 完整生成这个合成语音任务,调用现有 reader、渐进投影与差分 owner,逐项核对选择值、目录地址、全部 10 条要求、共享引用与完整恢复。程序不注册 Goal,不做准入或结算,也不调用模型或语音服务。

    diff --git a/apps/presentation/site/public/blog/zh/index.html b/apps/presentation/site/public/blog/zh/index.html index ef6b5ae645..57ce2e16fc 100644 --- a/apps/presentation/site/public/blog/zh/index.html +++ b/apps/presentation/site/public/blog/zh/index.html @@ -35,8 +35,8 @@

    LoopX · 博客

    长程工作的工程实践。

    关于长程 Agent 的设计、工程与实践。

    -

    Context delivery · 机制与实例

    · 11 月 3 日更新实证

    -

    Agent 读上下文,也需要一套“查书”的方法

    从同一个语音任务出发,讲清 JSON Pointer、批量选择、目录深度、完整要求、精确共享与 compaction 周期差分,并补入 ANN 18h(7,159 vs 5,753 QPS)分层字节/Token 消融实证与早窗/跨题边界反例。

    阅读全文
    +

    Context delivery · 机制与实例

    · 11 月 8 日更新

    +

    Agent 读上下文,也需要一套“查书”的方法

    沿一个语音任务,讲清渐进选读、完整首读、范围检查、精确复用与恢复;将进程成本与归档 ANN 结果分开,保留早窗和跨题反例。

    阅读全文

    研究札记 · EdgeBench 与 LHTB