NeFut Logo NeFut
Admin Login

[CS.AI] PatchOptic: Innovative Solution for Shared-State LLM Workflows

Published at: 2026-07-09 22:00 Last updated: 2026-07-10 03:15
#algorithm #LLM #Open Source

Abstract

Agentic workflows often operate over shared, structured state. Due to the limited context windows of LLMs, each model invocation typically shows only the state fragment needed for the current workflow step, a pattern known as progressive disclosure. Modern systems construct such model-facing views using grep-like keyword search, retrieval-augmented generation (RAG), abstract-syntax-tree (AST) queries, and task-specific agent skills. These methods make the read side manageable but do not define when a locally proposed rewrite is valid after it is applied back to the full state. The missing piece is a contract between local updates and global validity.

We introduce PatchOptic, an optic-inspired interface for shared-state LLM workflows. Optics are compositional bidirectional accessors that describe how views of structured data are read and updated. PatchOptic borrows this view/update intuition and realizes it through projected reads and verified structured patches. Each workflow step declares a projected read view, an authorized write region, and a patch-source region. Beyond runtime enforcement, the same declaration yields a path-level footprint that supports delegation, sub-workflow composition, and static certificates for reordering independent steps within the same phase.

We evaluate this design with PatchBench, a benchmark with 46 cases across domains. The results show that projected reads reduce reported leakage and token cost while preserving accepted-output quality under the strong actor. Runtime verification blocks declared workflow-contract violations before commit, and patch-read enforcement rejects compromised patch artifacts that use hidden sources.

Blogger's Review: PatchOptic introduces an innovative approach to handling shared-state LLM workflows by ensuring the validity of local updates and global consistency. Its enhancements in performance and security demonstrate significant potential in managing complex systems and pave the way for future designs in multi-task processing.

Original Source: https://arxiv.org/abs/2607.05483

[h] Back to Home