Papers
Topics
Authors
Recent
Search
2000 character limit reached

Context-as-Action (ConAct) Overview

Updated 5 July 2026
  • Context-as-Action (ConAct) is a framework that treats context as an active medium for driving intelligent system actions by integrating state assembly, program execution, and autonomous interaction.
  • Its architecture employs write-time context assembly, governed sandboxed wisdom programs, and proactive goal stream state machines to ensure efficient and reliable operations.
  • Formal results in ConAct demonstrate reduced token costs, correctness through declarative wiring, and proactive dominance over reactive models, enhancing system performance.

Context-as-Action (ConAct) is the view that context is not merely passive input to an intelligent system but an operational substrate through which the system acts. In its most explicit formulation, ConAct is “the operational principle that the Context intelligence layer itself is the primary vehicle for action: assembled context drives program execution, emits structured interaction content, and advances goal state machines without waiting for user prompts” (Magarshak, 21 Apr 2026). Related work develops closely aligned formulations in which context management becomes a callable tool in software engineering agents, a first-class action space in mobile GUI agents, a managed operating environment for enterprise multi-agent systems, and an action–consequence memory for embodied control (Liu et al., 26 Dec 2025, Liu et al., 18 Jun 2026, Vishnyakova, 10 Mar 2026, Lian et al., 23 Jun 2026).

1. Core definition and agent model

In the ConAct formulation of the Context layer, the environment state is an evolving typed append-only stream graph GG governed by SPACER, and the agent is defined as M=(S,A,π,J)M=(S,A,\pi,J). The state SS is the goal stream instance vv’s position qT(v)q_T(v), its attributes αT(v)\alpha_T(v), and its neighborhood N(v)N(v) in GG. The action space AA includes two kinds of operations: composable wisdom-program executions pWp \in W at phases M=(S,A,π,J)M=(S,A,\pi,J)0, and proactive goal emissions M=(S,A,π,J)M=(S,A,\pi,J)1, such as options arrays, governance affordances, and clarification prompts. The policy M=(S,A,π,J)M=(S,A,\pi,J)2 is declarative wiring over typed streams and phase ordering; it selects programs and emits structured content deterministically from graph state when guards M=(S,A,π,J)M=(S,A,\pi,J)3 are satisfied. The objective M=(S,A,π,J)M=(S,A,\pi,J)4 is to reach terminal states M=(S,A,π,J)M=(S,A,\pi,J)5 in minimal expected turns and cost, subject to governance and safety constraints (Magarshak, 21 Apr 2026).

This definition departs from reactive query-response chatbots. In the ConAct agent model, context manipulation itself constitutes the action space: the agent acts by assembling context, routing governed capabilities, and emitting structured interaction content without awaiting a prompt. The paper’s RL/POMDP framing makes this explicit by identifying the policy as a deterministic mapping from graph-derived state to program executions and proactive emissions, with uncertainty residing in background events and user choices rather than in the context mechanism itself (Magarshak, 21 Apr 2026).

A broader formal vocabulary appears in context engineering work. “Context Engineering 2.0” defines context as M=(S,A,π,J)M=(S,A,\pi,J)6 and context engineering as a transformation M=(S,A,π,J)M=(S,A,\pi,J)7, where M=(S,A,π,J)M=(S,A,\pi,J)8 is composed from context-processing operations M=(S,A,π,J)M=(S,A,\pi,J)9 such as collection, representation, fusion, selection, sharing, and dynamic adaptation (Hua et al., 30 Oct 2025). This suggests that ConAct can be read as a particular operationalization of context engineering in which those operations are not merely preprocessing steps but decision-bearing acts.

2. Architectural mechanisms

The canonical ConAct architecture in “Context” rests on three mutually reinforcing mechanisms. The first is write-time context assembly. Context is assembled from typed graph state via Grokers’ denormalization index as a deterministic pure function of graph state. The paper’s hierarchy distinguishes PERMANENT, SESSION, COLD, and DYNAMIC blocks. PERMANENT holds the goal system prompt and is stable for the goal type’s lifetime; SESSION holds enriched typed attributes and is stable between semantic changes; COLD holds a multi-level summary tree for sessions resuming after the KV-cache TTL has expired; DYNAMIC holds wisdom-program-selected context per turn. Absent semantic change, bytes in PERMANENT and SESSION are identical across turns (Magarshak, 21 Apr 2026).

The second mechanism is a governed library of composable sandboxed wisdom programs. These are LM-generated imperative programs, reviewed and activated into a library SS0, where each program executes inside the Safebox sandbox with read-only pre-loaded immutable input, proposal accumulation rather than direct writes, time SS1 ms, memory SS2 MB, and no network except named Protocols. They are declaratively related to goal types via typed stream relations. Their composition is controlled by an execution phase algebra with phases SS3 and a partial order including SS4, SS5, and SS6 (Magarshak, 21 Apr 2026).

The third mechanism is proactive goal stream state machines. Goal streams evolve under typed attribute updates, and proactive advancement conditions SS7 inspect graph mutations and emit structured content when guards are satisfied. The emitted content includes options arrays, governance affordances, clarification prompts, and votes. Platform adapters then render these emissions as actionable UI elements, including Telegram InlineKeyboardMarkup and Apple InteractiveMessage payloads. The architecture therefore binds state inspection, governed program execution, and structured interaction into a single policy surface (Magarshak, 21 Apr 2026).

The paper’s examples make the mechanism concrete. In the document review goal, write-time assembly loads the goal prompt and enriched attributes, pre/rel-phase programs compute missing votes, agg tallies them, post constructs the options array, render maps it to platform-specific UI, and a vote.cast event can trigger promotion to Published when the threshold is reached. In the capability deployment support ticket, a proactive condition on job.completed emits “CI passed. Options: schedule deploy, request approver, run smoke tests,” after which governed programs and governance affordances carry the workflow to Deployed. In both cases, “no user question was required to advance” (Magarshak, 21 Apr 2026).

3. Formal results, efficiency, and correctness

The ConAct architecture is accompanied by six formal results. The Context Stability Theorem bounds expected per-turn LM input cost and relies on byte-identical stable blocks for prompt-cache reuse. Because cache-hit tokens are priced at 10% of full input price, the cached component approaches SS8 as semantic changes become rare relative to turn intervals, yielding a SS9 reduction relative to paying full price on the stable prefix. Under a Poisson semantic change process, the SESSION hit probability is vv0, approaching 1 when semantic-change intervals are long relative to turn intervals, and the paper reports near-100% KV-cache reuse when byte identity is preserved and the session avoids cold TTL expiry (Magarshak, 21 Apr 2026).

Program Composition Correctness states that if a phase-correct library is composed in valid phase order and each program is individually correct, then the composed pipeline is correct. Declarative Wiring Soundness states that, assuming SPACER’s event queue provides at-most-once delivery per subscription, every matching handler is triggered exactly once and no non-matching handler is triggered. These results formalize a core ConAct claim: replacing learned next-action selection with typed declarative routing and governed, phase-ordered programs can improve reliability without requiring LM calls at interaction time (Magarshak, 21 Apr 2026).

The Proactive Dominance Theorem shows that proactive agents weakly dominate reactive agents on expected turns-to-terminal-state when both have identical LM response quality when they respond. Equality holds only if there are no proactive advancement conditions or every advancement condition is satisfied exclusively by user messages. Coordination Overhead Structural Decomposition further shows that proactive coordination can be structurally eliminated, driving the coordination overhead ratio toward zero for mature systems covering the listed coordination categories, while Quality Preservation Under Proactivity states that any quality metric dependent only on deliberation turns is weakly preserved or improved because the eliminated turns are proactive coordination rather than LM-synthesized deliberation (Magarshak, 21 Apr 2026).

Cross-Platform Vote Consistency extends the correctness claims to governance. Options arrays are produced by post-phase wisdom programs, mapped to platform-native payloads by render-phase adapters, and serialized through an append-only stream log with atomic Execute transactions. The theorem states that vote tallies are platform-independent and that fork promotion fires if and only if the tally reaches the threshold, exactly once. Together with the cost theorems, these results define ConAct not only as an interaction style but as a formal program of correctness, cache efficiency, and governance consistency (Magarshak, 21 Apr 2026).

4. Human-centered and context-engineering interpretations

A distinct but complementary line of work grounds ConAct in human-centered judgment. “When Should an AI Act?” separates Scene from Context and distinguishes both from Human Behavior Factors. Scene is the objectively identifiable configuration of background, objects, actors, activities, and their relations. Context is the user-constructed meaning through which the scene is interpreted, across spatial, temporal, interoceptive, individual, and social/cultural dimensions. Human Behavior Factors include Attitude, Perceived Opportunity, Perceived Capability, Motivation, and Trigger. The model’s conceptual flow is Scene vv1 Context interpretation vv2 HBFs vv3 Motivation vv4 Trigger vv5 Behavior. On this account, ConAct is not simply proactivity; it is action conditioned on contextual meaning and behavioral readiness (Jung et al., 26 Feb 2026).

The same paper derives five design principles: behavioral alignment, contextual sensitivity, temporal appropriateness, motivational calibration, and agency preservation. Its decision rule is restrictive rather than expansionary: agents should not act solely on Scene, should require contextual interpretability before acting, should gate interventions to natural seams, should calibrate depth and intensity to HBF state, and should preserve user control through defer, reject, modify, and undo affordances. This provides an explicit correction to a common misconception. ConAct does not mean maximal intervention; it means acting only when context supports judgment about whether, when, and how to intervene (Jung et al., 26 Feb 2026).

Enterprise context-engineering work reframes the same theme at system scale. “Context Engineering: From Prompts to Corporate Multi-Agent Architecture” defines context engineering as the discipline of “what the agent knows, sees, and remembers at the moment of action” and treats context as the agent’s operating system. In this formulation, context manages memory, allocates resources, isolates processes, and provides interfaces to tools and policies. The paper distinguishes Prompt Engineering, Context Engineering, Intent Engineering, and Specification Engineering as a cumulative maturity pyramid, and evaluates context with five quality criteria: relevance, sufficiency, isolation, economy, and provenance. It also introduces a context-rot taxonomy—poisoning, distraction, confusion, and clash—and emphasizes just-in-time knowledge logistics, privilege attenuation, capability tokens, transitive attestation, and KV-cache priming as operational mechanisms (Vishnyakova, 10 Mar 2026).

“Context Engineering 2.0” supplies a historical and conceptual backdrop. It presents context engineering as a process of entropy reduction, traces a progression from primitive computation to agent-centric intelligence and beyond, and identifies minimal sufficiency, semantic continuity, context isolation, self-baking, selection, and proactive need inference as central design considerations. In this literature, context setting is an intervention knob: choosing what to collect, compress, retain, isolate, or share is itself an action that changes downstream system behavior (Hua et al., 30 Oct 2025).

5. Implementations and empirical instantiations

The ConAct pattern has been instantiated in several domains with different action spaces and evaluation protocols. In the Qbix / Safebox / Safebots stack, the Context layer is implemented over MM streams, SPACER execution semantics, Grokers write-time enrichment, and proactive evaluation of vv6 after every graph mutation. The document review and deployment-support examples show how options arrays, governance affordances, typed subscriptions, and auto-phase programs carry goal streams to terminal states without additional user prompting (Magarshak, 21 Apr 2026).

In long-horizon software engineering agents, CAT turns context management into a callable tool integrated into the ReAct-style action space. It defines a structured workspace vv7, where vv8 is stable task semantics, vv9 is condensed long-term memory, and qT(v)q_T(v)0 is high-fidelity short-term interaction history. CaT-Generator injects context-management actions into complete trajectories to create SFT data, and SWE-Compressor, trained on 20k such instances, reaches a 57.6% solved rate on SWE-Bench-Verified, outperforming a ReAct agent at 49.8% and a threshold-compression agent at 53.8%. The paper reports stable usage around 32–35k tokens under a budget qT(v)q_T(v)1, with average token usage stabilizing below qT(v)q_T(v)2k after qT(v)q_T(v)3 rounds (Liu et al., 26 Dec 2025).

In mobile GUI automation, MemGUI-Agent makes context management a first-class action predicted by the same multimodal policy that selects UI actions. Its working context is qT(v)q_T(v)4, where qT(v)q_T(v)5 is folded action history, qT(v)q_T(v)6 is folded UI state storing exact UI-derived facts, and qT(v)q_T(v)7 is a recent self-describing step record. MemGUI-3K provides 2,956 successful trajectories and 64,430 SFT steps after filtering. The resulting MemGUI-8B-SFT achieves 23.4% Pass@1, 35.9% Pass@3, and IRR 30.2 on MemGUI-Bench, versus 9.4, 20.3, and 15.1 for Qwen3-VL-8B-Instruct. The zero-shot 235B ConAct protocol reaches 37.5% Pass@1, 62.5% Pass@3, and IRR 46.8, and the paper reports that ConAct saves about 1.5k input tokens by step 150 relative to ReAct (Liu et al., 18 Jun 2026).

In embodied control, Reflective VLA conditions each decision on a history qT(v)q_T(v)8 of observation–action–consequence triplets, where the consequence is the post-action observation after a chunk completes. Shared attention routes language, images, proprioception, past actions, and consequences through one sequence, and a block-causal mask enables parallel multi-frame training and KV-cached real-time inference. On LIBERO-Plus and LIBERO-Plus-Hard, Reflective VLA improves average success rate by 5.4 and 4.2 percentage points over a matched reactive baseline; on SimplerEnv-Bridge it reaches 78.2% versus 72.9%; and on real-world held-out camera placements it reaches 76% and 64% on box and bowl tasks versus 32% and 16% for the baseline. The ablations further state that action consequences, rather than additional context length alone, are the key to cross-environment generalization (Lian et al., 23 Jun 2026).

Although the term ConAct is recent, closely related ideas appear in older formal and perception-oriented literatures. In “Adding Context to Knowledge and Action Bases,” context is part of the evolving system state, actions are enabled by context guards, context-evolution rules update the current context, and the active TBox depends on the current context qT(v)q_T(v)9. The paper shows that verification of temporal properties over run-bounded context-sensitive KABs stays decidable and can be reduced to finite-state model checking, with weak acyclicity implying run-boundedness (Calvanese et al., 2014).

In action understanding, several lines of work operationalize the principle that context is a first-class action signal rather than a nuisance variable. “Action parsing using context features” computes segment scores from both local segment features and context features pooled from other candidate segments, and reports 0.301 per-frame accuracy on Breakfast versus 0.288 for CFG+HMM and 0.146 for a local-only DP baseline. ACAR-Net models Actor-Context-Actor relations and improves AVA v2.2 ablations from a 25.39 mAP baseline to 27.83 with HRαT(v)\alpha_T(v)0O and 28.84 with the Actor-Context Feature Bank. ActX factorizes action and context with conjugate samples and reports gains on ActionThread, Hollywood2, HACS-30, and Pascal VOC actions. ACM-Net and ACSNet explicitly separate action, context, and background in weakly supervised temporal action localization rather than forcing context into a generic background channel (Mehrseresht, 2022, Pan et al., 2020, Wang et al., 2019, Qu et al., 2021, Liu et al., 2021).

The literature also identifies important constraints and debates. In “Context,” context stability depends on accurate semantic-change detection; false positives reduce cache reuse; program correctness is assumed individually; and declarative wiring depends on SPACER at-most-once delivery and atomic Execute semantics. CAT identifies semantic drift, over-compression, and misuse of context actions as risks. Enterprise context engineering notes that the novelty of CE relative to “RAG + memory + orchestration” remains debated and that “metrics for context quality remain experimental.” Human-centered design work insists that interventions should be aligned, contextually sensitive, temporally appropriate, motivationally calibrated, and agency-preserving rather than merely proactive (Magarshak, 21 Apr 2026, Liu et al., 26 Dec 2025, Vishnyakova, 10 Mar 2026, Jung et al., 26 Feb 2026).

Taken together, these strands define ConAct as a general research program rather than a single implementation. In the strongest form, context is assembled, stabilized, routed, and emitted as action; in weaker but still related forms, context is a structured determinant of what counts as action, where action begins and ends, which policies are enabled, and when intervention is justified. The central claim across these literatures is consistent: context is no longer only what conditions action; properly engineered, it is itself the medium of action.

Topic to Video (Beta)

No one has generated a video about this topic yet.

Whiteboard

No one has generated a whiteboard explanation for this topic yet.

Follow Topic

Get notified by email when new papers are published related to Context-as-Action (ConAct).