作为交互器的逻辑引擎
Logic Engines as Interactors
摘要:
我们介绍了一种新的程序设计语言的结构,互动,支持面向代理的观点,编程是一个简单的,独立的,自主的积木之间的对话。我们将Interactors定义为逻辑引擎中的答案生成和细化的抽象,从而产生表达性语言扩展和元编程模式,包括Prolog动态数据库的仿真。被调用者中基于回溯的答案生成与调用者中的“前向”递归之间的映射使得被调用者的搜索过程的不同分支之间能够进行交互,并且为涉及组合生成和无限答案流的算法提供简化的设计模式。Interactors通过yield语句扩展了Ruby、Python和C#等语言结构的多个coroutining块返回,它们可以模拟函数语言中的一元结构和变形。关键词:广义迭代器,逻辑引擎,面向代理的程序设计语言结构,与有状态对象的互操作,元编程
英文摘要:
We introduce a new programming language construct, Interactors, supporting the agent-oriented view that programming is a dialog between simple, self-contained, autonomous building blocks. We define Interactors as an abstraction of answer generation and refinement in Logic Engines resulting in expressive language extension and metaprogramming patterns, including emulation of Prolog's dynamic database. A mapping between backtracking based answer generation in the callee and "forward" recursion in the caller enables interaction between different branches of the callee's search process and provides simplified design patterns for algorithms involving combinatorial generation and infinite answer streams. Interactors extend language constructs like Ruby, Python and C#'s multiple coroutining block returns through yield statements and they can emulate the action of monadic constructs and catamorphisms in functional languages. Keywords: generalized iterators, logic engines, agent oriented programming language constructs, interoperation with stateful objects, metaprogramming
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。