Skip to content
ImagineWorld

Introducing Neuro-Symbolic AI – the Next Level of AI

node_idnode-book_neuro-symbolic-ai_chapter-05-introducing-neuro-symbolic-ai-the-next-level-of-ai
node_typechapter-node
schema_profileworld.chapter_node.v1
statusactive
entropyhigh
manifoldworld
domainimagineworld.net
authorityinforms
layercorpus
chapter_num5
chapter_titleIntroducing Neuro-Symbolic AI – the Next Level of AI
pillar_membershipA — predictive_processing_active_inference + D — neuroscience_anchors
governed_byCORPUS
constitutional_citationCONSTITUTION
local graph

Chapter 5 — Introducing Neuro-Symbolic AI – the Next Level of AI

Section titled “Chapter 5 — Introducing Neuro-Symbolic AI – the Next Level of AI”

5 Introducing Neuro-Symbolic AI – the Next Level of AI

Section titled “5 Introducing Neuro-Symbolic AI – the Next Level of AI”

Throughout the previous chapters, we discussed how the primary motivation behind artificial intelligence (AI) is to model human intelligence into computer systems. Over the years, we have witnessed the innovation of many algorithms and techniques that improved computer cognitive and logical processing machines. In Chapter 2, we introduced symbolic AI as one of the first research efforts targeted toward achieving this highly desirable accolade. We discussed how symbolic AI has enabled us to embed world-knowledge constructs (logical rules) into our computer systems. However, the symbolic AI process has proven to be rather cumbersome and expensive. Researchers have also discovered that symbolic AI programs tend to lose accuracy as more rules are represented in the program. To circumvent the tedious process of symbolic rule representation, the field shifted its focus to more data-driven techniques.

Neural networks (NNs) and deep learning (DL) have solved multiple complex tasks, allowing us to push the boundaries of machine intelligence. Especially in computer vision and large-scale pattern recognition tasks, DL has shown itself to be wildly successful. Still, these algorithms struggle to extract and understand the compositional structure from the underlying data. Deep networks are unable to reason about the patterns that they learn. As such, explaining relationships between the different objects of a specific problem is a task that deep networks struggle to complete. While deep networks have closed the gap between machine and human intelligence, this limitation proves that we are still far from fully modeling human intelligence. One of the differentiating factors between man and machine is our ability to reason about common-sense knowledge—more specifically, our ability to understand concepts and their implications. The human brain can rapidly create complex associations. For example, seeing someone with headphones on, we automatically assume they probably cannot hear us if we speak to them. Introducing Neuro-Symbolic AI – the Next Level of AI

This chapter aims to introduce the emerging concept of neuro-symbolic AI (NSAI), familiarize us with the different mechanics surrounding this innovation, and help us understand why NSAI is being seen by many as the way to go for future AI developments.

The first objective of this chapter is to understand the journey that led to the innovation behind NSAI. Next, we will learn the conceptual intuition behind NSAI. The main objective here is to understand the rationale behind NSAI research. Following this, we will discuss the different components encapsulated within the NSAI process. Learning the other ingredients and how they fit together is critical to correctly understanding how to design a robust NSAI architecture. Finally, we will briefly overview the principal techniques in the NSAI space.

This chapter will go through the following topics:

  • Understanding the intuition behind NSAI
  • Defining NSAI
  • The components of an NSAI architecture

Bridging the intelligence gap between man and machine is our destination—the holy grail. The challenge of solving the physical brain’s complexity has intrigued researchers for years. Over the years, we raised and answered numerous questions; nonetheless, one question still prevails. Scientists know that we cannot understand the brain’s function to its entirety, especially its ability to develop common-sense knowledge—which essentially boils down to multiple complex associations that the brain can extract.

Defining common-sense knowledge

Common-sense knowledge is any knowledge that becomes almost second nature or apparent to us. For example, if we see a chair, we can practically assume we can sit on it. If we see a bed, we know that we can lie on it without falling through the mattress. The director of the MIT-IBM Watson AI Lab, David Cox, defines common-sense knowledge as “all of the implicit knowledge that we have that is never written down anywhere.”

Solving the issue of having machines not just learn common sense but also fully understand it (and its underlying knowledge) seems to be the next step for the new generation of AI techniques. Machine-enabled knowledge understanding is the objective.

How can we ever model something that we do not fully understand?

Modeling human intelligence – insights from child psychology

Section titled “Modeling human intelligence – insights from child psychology”

Our target is to enable machines to reason like humans, to help machines deeply understand the characteristic of the objects within a particular problem set, to extract further information through reasoning, and to transition the field of AI from pattern recognition to cognition and reasoning. As humans, we can do much more than pattern recognition. We can imagine things, concepts, and designs. We can reason about things to plan actions and play out several scenarios that might never occur. The brain is our most complex organ. We still have a lot of mysteries to uncover about our neurology, so how can we imitate such complex functionality without us even understanding its implications?

Inspired by the aforementioned premise, researchers from the MIT-IBM collaboration decided that the best way to model this complexity was by approaching it the same way a human child develops brain function. Although we do not fully understand the human brain and its complex functionality, children still somehow develop their brains to reach such desired levels of intelligence. Throughout their brain development cycle, children manage to pick up on common-sense knowledge with very few examples. Gradually, they start forming relationships with the various objects in their surroundings and strengthen their abilities to reason about them. With a handful of instances, a baby can begin to recognize and differentiate between a cat and a dog—a task that would see an AI model requiring thousands of samples to reach accurate levels. As such, the starting point for this research becomes relatively straightforward—understanding the psychological development of human offspring. Researchers wanted to merge human psychology and neuroscience with AI.

Rebecca Saxe, a professor of cognitive neuroscience at MIT, sought to understand further how human babies viewed the world around them. How did they perceive it? How did they know it?

Babies are mainly considered relatively passive; initially, their abilities are limited. They cannot speak or walk. As with naïve machine learning (ML) or AI models, children start with slender intuition of the physical world. We then train these models by passively feeding them data points and allowing them to extract their patterns and structures. Quite like the human baby, no? Well, Saxe argues no. Babies are not born as passive entities. Babies are actively making decisions. Babies decide what they look at and what they focus their attention on. In turn, these decisions significantly impact the kinds of relationships and patterns babies can learn early on. Near-Infrared Spectroscopy (NIRS) is an experiment that studies neural activity through light. Light is shone through the subject’s scalp, and detectors are used to measure the amount of reflected light. This test determines the brain’s blood oxygenation levels, which indicate neuron activity. Using this experiment, researchers started monitoring and studying human baby cognition. Neural activity in a human baby was observed to be somewhat active. Especially when a human baby appears to be simply staring at an object, significant brain activity and development are occurring in the background. Babies might be staring at a particular thing because it might trigger different emotions (scared, surprised, or happy) or engage curiosity. A baby’s gaze masks several mental activities. Our brain develops a model of our world composed of objects, agents, and interactions. The different agents are their entities, with their model of the world and their knowledge base.

Essentially, the next step was to research the confluence of AI and psychology to understand further how to model the human brain best. Through various studies conducted by psychology researchers Michael Tomasello and Felix Warneken, we know that children construct ideas about objects and agents in the physical world. They form knowledge of how the different agents interact with each other and things in the world. But most importantly, these studies show that children can improvise and adapt this knowledge to similar but novel scenarios. Children develop intuition. Joshua Tenenbaum argues that children start developing reasoning capabilities immediately after birth. Three months after birth, a human child would have developed common-sense intuition to bridge other intelligence parts, including language and planning skills.

One of the experiments by Michael Tomasello and Felix Warneken involved a man carrying seemingly heavy books (with both hands) toward a closed closet. The man walked toward the closet and appeared to struggle to open the closet door. A child in the room picked up on the intended goal of the man and proceeded to help him by opening the closet door for him. Even though the child was not briefed on what to do, the child understood that the interaction between the man (an agent in the physical world) and the closet (an object in the physical world) was to open it and store the books inside. You can watch the experiment in action here: https://videopress.com/v/xUifKHYO.

Another point of inspiration was also drawn from observing mallard ducklings. Researchers noted how the ducklings understand the concept of similarity (or dissimilarity). If the ducklings are exposed to two similar objects (for example, two red balls) at birth, they will tend to follow or favor pairs of similar objects. Conversely, they will prefer dissimilar pairs if they are shown different things. In short, mallard ducklings are born with the intuitive ability to determine whether two foreign objects are similar. They can discover, learn, and abstract various properties and relationships that they can ultimately reason about. This task is something that, to this day, AI algorithms find rather difficult to learn.

Research also showed that, contrary to popular belief, humans are not born as blank canvases. Instead, we possess a pre-programmed basic understanding of the world. We are born with some innate knowledge of how the world operates. We are born with intuition about the approximation and simulation of our physical world. Researchers like to compare this concept with that of a game engine. The game engine encapsulates some knowledge of world physics and other fundamentals. It is then fine-tuned and enhanced to fit the desired world simulation. Human babies are thought to behave quite similarly. We are born with some innate knowledge of fundamental world relationships. Through life experiences (that is, newer data points), our internal “game engine” becomes more efficient in modeling real-life scenarios. As such, researchers believe that adopting specific probabilistic ideas from game engines can help advance this course.


With AI gaining more traction, in August of 2019, strong research efforts began to enable commonsense and reasoning abilities in AI systems by reverse engineering the brain of human babies. As the name implies, the recipe of neuro-symbolic programming involves two main ingredients: NNs and symbolic programming. We will explore these two ingredients using the Compositional Language and Elementary Visual Reasoning (CLEVR) example case. CLEVR is a dataset of 100,000 computer-generated scenes portraying 3D shapes (https://cs.stanford.edu/people/jcjohns/clevr/). The objective of this dataset is for AI to reason about these images and be able to answer questions regarding the said images—for example: How many spheres are in the image?

Motivated by their observations, the researchers highlighted one key aspect of the reasoning abilities of humans (and other organisms, for that matter): world knowledge. We can reason about objects because we understand the underlying structure and relationships of the said objects. Albeit potentially not entirely, we possess some knowledge that allows us to question and reason about these objects. Researchers tend to be split over whether we have innate world knowledge or can simply learn this knowledge over time. Frankly speaking, as AI practitioners, it’s superfluous. The main point of interest here is that to reason, we require knowledge—either direct or indirect. So, the first piece of the puzzle to enable machine reasoning is implementing a system to provide knowledge of the physical world to our AI model. This way, our AI can understand the dynamics and relationships of objects within its world model.

Note

The term world here refers to the problem space in which a specific AI is defined to solve a particular task.

If we recall our discussion from Chapter 2, one of the ideal candidates for this would be symbolic AI. symbolic AI allows us to provide our AI system with a structured (symbolic) representation of our problem space—the knowledge base. Nevertheless, we had already discussed how most symbolic AI approaches require tedious manual processes to define the knowledge base. We also discussed other limitations, such as the lack of scalability properties (that is, the constant need to update the knowledge base with new rules to reflect newly learned knowledge), as well as its dependency on manually defined formal rules. In our use case, as with the orange example in Chapter 2, building our knowledge base would require us to determine (through logical propositions) the various world properties. In general, we would need to manually define the various types of shapes in our world (that is, a sphere, a cylinder, or a cube), the different shape colors (that is, red, blue, or yellow), shape sizes (that is, large or small), and their texture (that is, metallic or gloss). We also need to formalize the different relationships. For instance, if two objects have the same shape, they are similar. We can immediately start to appreciate the level of complexity and abstraction required to represent our domain fully. Figure 5.1 illustrates an example symbolic AI framework for this use case:

Figure 5.1: An example symbolic AI framework

One significant issue becomes apparent in this example. If we were to show the AI a scene with a new shape (or any other of the defined properties), our symbolic AI program would fail. For symbolic AI to be efficient, these limitations must be addressed. As a result, given its ability to enable human-like reasoning and strong explainability properties, researchers sought to improve on these limitations. So, they asked themselves this question:

Can we exploit symbolic AI and improve its limitations to enable human-like reasoning in machines?

The primary angle to make symbolic AI drastically better would be to take the human effort out of the equation; thus, we would need to figure out how to design, structure, and build the knowledge base automatically. This point brings us to our second component: NNs.

As discussed in Chapter 3, one of the biggest strengths of NNs is their ability to learn complex patterns and relationships from raw datasets. These intricate patterns should, in theory, provide enough information within their neural connections to describe the world we are trying to model. In our example, we would train any NN architecture to learn complex patterns within our input. In this case, the input would be 3D shape images, with the output being the objects within the image. We show a simple architecture of this network in Figure 5.2:

Figure 5.2: An example of a NN connection

The main limitation of NNs is the lack of reasoning abilities. With the preceding network, having the network reason and answer questions on objects within the image is rather challenging. Although the NN can learn the patterns and characteristics of various things, it does not understand anything beyond that. We can train a NN model with enough training data to answer questions and enable reasoning. However, this process would require a substantial amount of both computing resources and training data.

With these limitations in mind, the question we want to answer becomes the following:

Can we exploit the pattern recognition powers of NNs to extract symbolic patterns from our data automatically?

Once we affirm this question, we can have these NNs automatically build our knowledge base.

If we take a holistic overview of the current situation, we immediately realize that the strengths of symbolic AI directly target the weaknesses imposed by NNs and vice versa. We detail a summarized overview of these strengths and weaknesses in Table 5.1, as follows: l; no Mermaid/image structured representation in OCR; see source PDF page 106 for visual content. —>

StrengthWeakness
Symbolic AIHuman-like reasoning
Explainable
Smaller knowledge base
A manual and tedious process
Difficult to scale
NNAutomated pattern extraction
Scalable
Unable to reason
Abstract and complex to interpret
Large dataset

Table 5.1: Summary of strengths and weaknesses of Symbolic AI and NNs

As such, researchers got the idea to combine these two parent AI techniques to create a hybrid AI architecture that improves upon both methods.

Defining NSAI

NSAI (or neuro-symbolic AI or neural-symbolic or subsymbolic-symbolic AI) is a composite AI framework that seeks to merge the domains of Symbolic AI and NNs to create a superior hybrid AI model possessing reasoning capabilities.

Mainly pushed by the MIT-IBM collaboration, the NSAI architecture seeks to combine the features of both its parent techniques, as outlined here:

In Symbolic AI, we must implement the knowledge base, and then the AI (driven by an inference engine sitting on top of the knowledge base) can be used to answer questions

In NNs, we train the model to arrive at the correct answer autonomously

As such, the hybrid NSAI architecture is designed so that a NN is used to automatically build the part of the knowledge base required to answer user questions. So, what does the NSAI paradigm look like when applied to our 3D shapes example? Let’s have a look: Figure 5.3: A schematic example of the hybrid NSAI architecture

In the preceding diagram, we show the components within the NSAI architecture that combine the NN domain with that of Symbolic AI. We further summarize the steps involved in this architecture, as follows:

  1. Train a NN on the images to learn and understand the various properties and relationships that define the shapes within the images.
  2. This network is used to generate the knowledge base.
  3. In our example, user questions are submitted as plain English text. We need another natural language processing (NLP) process to transform these questions into symbolic propositions.
  4. The symbolic propositions are fed into the symbolic inference engine (SIE).
  5. The SIE provides an answer.

We can look at the NSAI concept using a similar mindset to the initial Symbolic AI approach. The main target objective remains to provide machines with knowledge of the world. We still want to enable machine intelligence through machine reasoning by allowing the machine to map symbolic relations.

When designing an NSAI system, the thought process should still focus on how best to enable the machine to understand its problem space thoroughly. However, our approach to generating the world’s symbolic knowledge differs. In retrospect, the Symbolic AI paradigm remains quite strong. Maybe its failure resulted from Symbolic AI being too ahead of its time. In the same way that DL was significantly limited and held back by computing hardware technology, maybe Symbolic AI was being held back by a lack of software focus. As such, the perspective when building an NSAI framework versus a Symbolic AI system should not vary drastically.

In an NSAI architecture, we still need the SEI to handle user requests and yield results. NNs are simply leveraged to allow greater scalability, flexibility, and reliability in the knowledge base underlying the SEI. This is not to say that building an NSAI system is a trivial task. Correctly defining the suitable architectures and bridging between the different components is critical. In any AI architecture, we heavily rely on inputs of one component being the direct output of another. Still, in NSAI, this concept is even more evident, given its hybrid nature.

Although NSAI is still a relatively niche and emerging field of study, researchers from the MIT-IBM collaboration and Google’s DeepMind have already contributed interesting research concerning NSAI architectures. In this section of the chapter, we will further explore and discuss some of these main NSAI architectures that have been proven effective.

The main objective of the Neuro-Symbolic Concept Learner (NSCL) architecture is to produce a model capable of learning to identify objects in an image and parsing and understanding their semantics and linking relationships [3]. NSCL is based on the concept that humans can understand visual concepts through their ability to bridge between vision and language. For example, let us assume we are shown a photo of a blue elephant. We immediately identify that the “object” captured in the picture is an elephant. We also understand that the color of the said elephant is blue. Somehow, we can symbolize visual objects into their constituting properties, such as color. Recall that this process is essentially the human brain taking in a visual concept and splitting it into several symbolic propositions. That is how we can think of the word blue when we see blue. Furthermore, our mind can join the relationships between our vision and senses with language and semantics. The result of this ability is a mind that is spatially and referentially aware—a mind that can comprehend the physical world.

NSCL seeks to replicate this complex processing through a concept that the authors call object-based scene representation. In simple terms, this concept means that given a particular image, NSCL can identify and segregate the objects within that image and reason about them. NSCL can achieve this remarkable feat through a three-step hybrid model composed of an image parser, a question parser, and a symbolic executor. The NSAI architecture we previously discussed (refer to Figure 5.3) is based on the NSCL model. The NSCL model was trained using the aforementioned CLEVR dataset (that is, a set of images, questions, and their respective answers). Let us dive deeper into the sub-models of NSCL.

The image parser sub-model is a form of NN designed to learn from the images and the provided question-answer pairs provided. The NN defined in this research was based on a mask region-based convolutional NN (R-CNN) using the ResNet-34 model architecture for object recognition and segmentation (that is, masking). This model also enables spatially aware learning and other contextual relative properties such as object size. Newer implementations also use Meta’s Detectron2 model (Meta’s computer vision platform provides several object detection and segmentation models—refer to https://ai.facebook.com/tools/detectron2/).

There are no labels involved throughout the training process. Instead, the NN learns to infer object representations and other visual concepts (such as the color and shape) of the said objects to create the image annotations themselves. Next, the NN starts learning more straightforward concepts, such as differentiating between two colors or contrasting shapes. Also, the network begins with relatively simple scenes, showing a small number of shapes (or even a single shape). From there, the NN adopts an incremental learning strategy whereby the complexity of the visual concepts is increased. For instance, the NN might now focus on understanding more complex attributes based on spatial and relational awareness cues (for example, object X is on top of object Y).

Finally, the network could join and understand more complex questions involving multiple visual cues. For example, given a scene with numerous shapes of varying colors, the model is asked to give the color of the large cylinder to the right of the blue sphere. This training process mimics how we typically teach the human brain—especially babies. We adopt a curriculum that sequentially increases in difficulty and complexity, and where the next topic or concept continues to build on top of the previous one.

One of the main challenges surrounding the CLEVR dataset is understanding natural language questions to provide an accurate answer. For the NSAI model to reason and answer queries, it must first understand the object and scene properties (achieved by the first sub-model) and the question. In the NSCL architecture, the latter was accomplished using a custom Domain-Specific Language (DSL).

What is a DSL? A DSL can be thought of as a computer language that serves the purpose of a specific domain. Unlike a language such as English (which is a general-purpose language), a DSL only makes sense (and can be understood) by experts in a particular field. Some DSL examples include the web’s HyperText Markup Language (HTML) and Structured Query Language (SQL) for database management systems.

The researchers of NSCL built their DSL for understanding questions, reasoning about visual concepts, and coming up with an answer. The DSL allowed definitions for properties such as FILTER (filters out objects based on the parameter—that is, FILTER(BLUE) will filter out all blue shapes) or QUERY (allows us to query a specific attribute of a particular object—that is, QUERY (OBJ1, SHAPE)). A full list of the operations defined by this DSL can be found at http://nscl.csail.mit.edu/data/papers/2019ICLR-NSCL.pdf. The model selected for this NLP task was a bidirectional Gated Recurrent Unit (GRU). The GRU is responsible for the semantic parsing of the original natural language question into the DSL executable statement. Introducing Neuro-Symbolic AI – the Next Level of AI


The final sub-model to this hybrid process is the symbolic executor. For this last part, we require the parsed executable program from the DSL semantic parsing step and a trained image parser for object masking. The objective of this module is to take these artifacts as input and generate the corresponding answer based on learned object visual concepts. In the NSCL architecture, the symbolic executor is said to be quasi-symbolic. Unlike a fully symbolic AI system, the NSCL symbolic executor does not perform Boolean operations on the knowledge base. Instead, this symbolic executor relies on probabilistic computation to generate differentiable results. In short, every object in the scene is given a probability value representing the likelihood that that object is selected to be part of the final output. For the sake of comprehension, we illustrate this entire process (in a simplified manner) in Figure 5.4, as follows.

Figure 5.4: An overview of the NSCL architecture (source: adapted from Mao et al.)

The CLEVR dataset proved essential in setting a standard for NSAI research, providing a valid reason for going after NSAI research and a virtual platform to evaluate the solutions globally. After the development of NSCL, researchers took the concept of NSCL and CLEVR a step further. The CoLLision Events for Video REpresentation and Reasoning (CLEVRER) dataset (http://clevrer.csail.mit.edu) was introduced to build upon the CLEVR dataset by moving from images to videos [4]. As with CLEVR, CLEVRER is based on computer-generated 3D shapes. The dataset includes several 5-second videos showing objects moving around, colliding with each other, entering the frame, and exiting the frame. This dataset introduces an interesting variable in the equation of complex reasoning—causality. Given a video, we are now exposing the NSAI model to a whole new spectrum of relationships based on cause and effect. For example, objects can collide with each other, so we might want to ask the model to tell us which objects have collided. The authors even targeted a more complex composition, asking the network if a different scenario or event had occurred, would the same objects still have collided?

The existing network architectures could not reason about these more complex queries because of a lack of physics knowledge. Therefore, the Neuro-Symbolic Dynamic Reasoning (NSDR) architecture is the NSCL model with an extra sub-model as a physics engine. Researchers refer to this new sub-model as the Dynamics Predictor (DP) since its central role is to learn and understand object force propagation (that is, how force is produced and transferred between objects).

Based on a Propagation Network (PropNet) model (a learnable physics simulation engine based on DL—refer to http://propnet.csail.mit.edu), the DP module can model and predict the trajectory and positional reference of different objects and, therefore, can mathematically compute expected collisions from crossing trajectories. Another benefit enabled by PropNet is that it can approximate object motion even with missing information. This property is crucial to the CLEVRER dataset since an object can move in and out of frame. Thus, we could still approximate the object’s trajectory, understand its cause and effect on the other trajectories, and reason about it. This module of the model also serves the purpose of explainability, besides enabling deep reasoning capabilities ranging from descriptive (such as NSCL—colors and object counts) to predicting the next event. In addition to counterfactual reasoning (how would the outcome change if a new event were to happen), the model can also explain why an external event would have prevented a collision (for example, the external event would have disrupted the trajectory of an object that would have crossed paths with another object).

The DP sub-model is, perhaps, the main attraction to the NSDR architecture. However, this is not to say that the other sub-models were left unchanged from the NSCL model. Instead, we will discuss the changes to the remaining sub-models to make the newer NSAI architecture play nice with CLEVRER.

The hybrid approach’s first step is learning to make sense of the inputs. In the NSCL architecture, we had an image parser module that served the purpose of object masking. In NSDR, our inputs have now changed from a single image to a collection of images (frames) to form a video. NSDR considers every single frame of every video individually. In turn, NSDR still uses the same mask R-CNN network implemented for the NSCL model to perform object masking on every frame. Every clip in the CLEVRER dataset is composed of 25 frames. Hence, for every clip, the mask R-CNN must be executed 25 times. Introducing Neuro-Symbolic AI – the Next Level of AI


The questions in CLEVRER contain longer (and more complex) sequences than those of CLEVR. As such, the original sequence-to-sequence (Seq2Seq) model used by NSCL was replaced with a more modern architecture based on the Long Short-Term Memory (LSTM) encoder. Nevertheless, the question parser of NSDR works quite similarly to the NSCL one. We use the LSTM network to translate an English query into a functional program based on custom DSL.

As the name implies, a Seq2Seq model takes in a sequence as its input and outputs another sequence. The sequence can be anything from text, characters, pixel information, and time series. Examples of Seq2Seq models include translation models (given a phrase in one language, the model will output its translated version to another language), image captioning (a sequence of pixel information as input and a sequence of text as output), and text summarization (a sequence of text as input and another sequence of text as output).

Perhaps the second most prominent change in the NSDR architecture compared to that of NSCL lies within this module. If you recall, the symbolic executor (SE) program of NSCL was quasi-symbolic since it was based on probabilistic computations. This change shifts the learning focus from the SE program onto the video parser and the DP modules. Given its fully symbolic nature, the role of the SE program is purely to generate the respective answer based on the outputs of the previous modules. The answer is formed through an iteration of functional programming steps (filtering and logical operations). You can see the following diagram [4]:

Figure 5.5: An example SE program of NSDR

In recent years, another NSAI architecture—the Neural Logic Machine (NLM)—has started to gain some popularity within the research community. The NLM is an NSAI architecture (as shown in Figure 5.6), presented and unofficially maintained by Google (https://sites.google.com/view/neural-logic-machines). We discuss this architecture further in the following section. [figure outside: Figure 5.5] [figure outside: Figure 5.6]

The NLM architecture is a fully differentiable approach capable of first-order logic. The NLM process starts with logical predicates describing a fixed collection of objects. The first task of the NLM is to extract the various object properties and relations from the given logical propositions. The result of this can be thought of as our knowledge base since they define the properties of our world objects and their mutual relations. These predicates can be of three main types, as follows:

  • Binary—Defines some object relationships. For example, BELOW(X, Y) means that object X is below object Y.
  • Nullary—Defines global properties. For example, ALLMATCHED() means that all objects match each other.
  • Unary—Defines individual object properties. For example, TRANSPARENT(X) means that object X is transparent.

The neurons in a NN perform all their computation through tensors. A tensor is a data structure that encodes multidimensional arrays and performs mathematical operations on them. A tensor can be used to represent data with complex relationships such as images and text. Therefore, the NLM architecture represents these logical propositions as probabilistic tensors whose respective logical rules and connectives are transformed into neural operators. Through a forward propagation approach (consisting of several highly abstracted Multi-Layer Perceptrons (MLPs) performing several expansion and reduction operations), the NLM can achieve first-order logic deduction, discovering more profound object properties and relationships. In short, the NLM process starts with a set of predicate logic statements, performs logic deduction, and generates conclusive object concepts. NLM has succeeded in a few applications, including pathfinding (finding the most optimal route between two points), array sorting (arranging the elements in an array in a specific order), and the block world problem [1]. You can see an overview of the NLM architecture in the following diagram:

Figure 5.6: An overview of the NLM architecture (adapted from Dong et al.[2])

NSAI is the new kid on the block in the field of AI. NSAI is considered by many as the next level of AI, or the new AI revolution, mainly due to its ability to equip machines with human-like reasoning capabilities.

This chapter started by venturing through human psychology’s vast and exciting realm. We briefly explored the human reasoning process and discussed how humans and other beings develop the ability to understand and reason about physical world objects early on. Common-sense knowledge seems to be an innate skill that humans possess—or at least one that we can learn autonomously to a certain degree. We then dissected the hybrid NSAI model into its constituent parents: Symbolic AI and NNs. NNs seem to have granted Symbolic AI a second chance to prove itself as a worthy contender for achieving the original motivation behind AI systems—reaching human levels of reasoning intelligence in computers. Further, we also discussed the NSCL, NSDR, and NLM architectures, the main current frameworks behind NSAI research efforts.

In the following chapter, we will discuss further the obstacles and opportunities of NSAI, some of its implications, and the future direction of NSAI research.

Following are a few resources for you to dive deeper into the concepts discussed in the chapter:

  1. Principles of artificial intelligence, Nilsson, Nils J., 1933.
  2. Neural Logic Machines in International Conference on Learning Representations, by Honghua Dong, Jiayuan Mao, Tian Lin, Chong Wang, Lihong Li, and Denny Zhou (2019).
  3. The Neuro-Symbolic Concept Learner: Interpreting Scenes, Words, and Sentences From Natural Supervision, ICLR 2019, by Mao, J., Gan, C., Kohli, P., Tenenbaum, J.B., and Wu, J..
  4. CLEVRER: CoLlision Events for Video REpresentation and Reasoning by Yi, K., Gan, C., Li, Y., Kohli, P., Wu, J., Torralba, A., and Tenenbaum, J.B..
  5. Neuro-Symbolic AI: An Emerging Class of AI Workloads and their Characterization by Susskind, Z., Arden, B., John, L.K., Stockton, P., and John, E.B..