HITrees:高阶交互树
HITrees: Higher-Order Interaction Trees
AI总结:
本文提出高阶交互树(HITrees),通过效应设计中的归纳类型和去函数化技术,在Lean中实现支持高阶效应的交互树,用于定义并行组合和call/cc等复杂语义。
摘要:
近年来,组合语义作为复杂系统形式验证的基础而兴起。特别是,交互树已成为一种流行的指称语义。交互树通过提供可重用的效应库来实现组合性。然而,它们的效应概念不支持高阶效应,即接受或返回单子计算(monadic computations)的效应。此类效应对于建模并行组合和call/cc等复杂语义特征至关重要。我们引入了高阶交互树(HITrees),这是首个在非保护类型论(non-guarded type theory)中支持高阶效应的交互树变体。HITrees通过两种关键技术实现这一点:首先,设计效应的概念,使得具有高阶输入的效应的不动点可以在类型论内部表示为归纳类型;其次,使用去函数化(defunctionalization)将高阶输出编码为一阶表示。我们在Lean证明助手中实现了HITrees,并附带了一个全面的效应库,包括并发、递归和call/cc。此外,我们提供了HITrees的两种解释:作为状态转换系统和作为单子程序。为了展示HITrees的表达能力,我们将其应用于定义具有并行组合和call/cc的语言的语义。
英文摘要:
Recent years have witnessed the rise of compositional semantics as a foundation for formal verification of complex systems. In particular, interaction trees have emerged as a popular denotational semantics. Interaction trees achieve compositionality by providing a reusable library of effects. However, their notion of effects does not support higher-order effects, i.e., effects that take or return monadic computations. Such effects are essential to model complex semantic features like parallel composition and call/cc. We introduce Higher-Order Interaction Trees (HITrees), the first variant of interaction trees to support higher-order effects in a non-guarded type theory. HITrees accomplish this through two key techniques: first, by designing the notion of effects such that the fixpoints of effects with higher-order input can be expressed as inductive types inside the type theory; and second, using defunctionalization to encode higher-order outputs into a first-order representation. We implement HITrees in the Lean proof assistant, accompanied by a comprehensive library of effects including concurrency, recursion, and call/cc. Furthermore, we provide two interpretations of HITrees, as state transition systems and as monadic programs. To demonstrate the expressiveness of HITrees, we apply them to define the semantics of a language with parallel composition and call/cc.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。