AIPLAug 30, 2023

Natlog: Embedding Logic Programming into the Python Deep-Learning Ecosystem

arXiv:2308.15890v1h-index: 21
Originality Incremental advance
AI Analysis

This work addresses the problem of combining symbolic and neural computing for researchers and developers in neuro-symbolic AI, though it appears incremental as it builds on existing embedding techniques.

The paper tackles the integration of logic programming with Python's deep-learning ecosystem by designing interaction patterns between language constructs, enabling logic-based constructs to leverage Python tools. They demonstrate effectiveness through applications like orchestrating JAX and PyTorch pipelines and generating prompts for GPT-3 and DALL-E using logic grammars.

Driven by expressiveness commonalities of Python and our Python-based embedded logic-based language Natlog, we design high-level interaction patterns between equivalent language constructs and data types on the two sides. By directly connecting generators and backtracking, nested tuples and terms, coroutines and first-class logic engines, reflection and meta-interpretation, we enable logic-based language constructs to access the full power of the Python ecosystem. We show the effectiveness of our design via Natlog apps working as orchestrators for JAX and Pytorch pipelines and as DCG-driven GPT3 and DALL.E prompt generators. Keyphrases: embedding of logic programming in the Python ecosystem, high-level inter-paradigm data exchanges, coroutining with logic engines, logic-based neuro-symbolic computing, logic grammars as prompt-generators for Large Language Models, logic-based neural network configuration and training.

Foundations

The foundational work for this paper's niche, ranked by how specifically the neighbourhood builds on it — not by global fame.

Your Notes