acceptodds
Under review as a conference paper at ICLR 2027

Composable Causal Control of Structured Code Editing

Abstract

A language model must apply an editing rule to a source program when it edits code. We test whether internal-state interventions can control the rule and source features separately in Qwen3.5-122B-A10B. We keep the visible prompt and supplied Edit/old prefix fixed. We replace internal states with states recorded from other runs, which we call donors. Replacing states at instruction tokens changes the editing rule but preserves source features. Replacing states at old-code tokens changes source features but preserves the rule. Applying both interventions produces the combined target. The generated replacement differs from either donor’s complete output. We then test whether the interventions also transfer unwanted donor information. We change the rule donor’s source program and the source donor’s editing rule. The outputs still retain the intended combination. The same procedure works across four tested code structures: straight-line code, multiple-return branches, nested branches and dataflow chains. We also reuse the same recorded states across two recipient programs. These interventions transfer a different data-dependency graph within the same statement layout. We then restore downstream residual states from a reference run. This restoration recovers recipient source features while keeping the changed rule. In a separate study, we change states associated with externally supplied plans. These changes affect the model’s choice between inspecting and editing code. We also test how the supplied action prefix affects sensitivity to the plan-state intervention. Supplying a policy branch reduces the sensitivity of the next-token distribution in 5 of 6 task families.

open until 14 Dec 2026

est. 32% chance this paper gets accepted at ICLR 2027.

Reject 68%Accept 32%

What do you think this paper will get?

All positions stay anonymous.

Related papers

Loading the map…

Discussion (0)

Sign in to comment.