Knowledge Graphs and Massive Language Models: The Future of AI
Creators: name: Saraswat, Vijay
name: Vasiloglou, Nikolaos
Publisher: name: Zenodo
Year: 2023

description: Since its inception in the 1940s, computing has been dominated by a logic-driven paradigm, with its focus on precise description of individuals, functions and relations in formal languages. Algorithms are manually specified, parameterizable by hundreds, at most millions, of variables. The natural embodiment of this paradigm for enterprise data is the semantic layer: a description of real-world data in precise business ontologies. The advent of Deep Learning has ushered in a data-driven paradigm. Here, data is "noisy, uncertain, high-dimensional" and it may be simply impossible to manually specify algorithms for desired functions (e.g. recognizing the faces in an image). But humans can specify a highly parameterized architecture, and supply (possibly self-supervised) data from which standard algorithms can discover the values of parameters that will define the desired function. Crucially, this approach scales across at least 12 orders of magnitude -- to highly complex functions that can leverage over a trillion parameters. Of all the stunning advances made in Deep Learning, perhaps the most mind-boggling are the Massive Language Models (MLMs), such as GPT4 and PALM. We now have programmable computers (language machines) that can read all the language (text, tables, images, pictures; soon audio, video, …) accessible to us, understand it, and communicate with us (somewhat) as humans do, leveraging the full plasticity of language in doing so. What do language machines mean for the semantic layer? These are early days for data-driven computer science, so a definitive account remains to be developed. This tutorial, focused on knowledge graph practitioners, will introduce MLMs and their mechanisms (prompt construction, prompt tuning, in-context learning, tool-augmentation, fine-tuning etc). It will demonstrate how MLMs can be used -- in a variety of professional domains -- to (a) generate ontologies from thin air (e.g. "generate an ontology for non-disclosure agreements") (b) generate example documents that match given ontologies, and make up plausible instances of ontologies (generate synthetic data) (c) critique ontologies (d) most importantly, extract from a document facts according to a given ontology (question answering, knowledge extraction). Crucially, while MLMs offer incredible advantages in processing language, they are not yet able to learn the deep inferencing capabilities of the full mathematical and logic-driven stack (logical inference, constraint-solving, optimization over all kinds of theories). For the foreseeable future, practitioners will need to combine precisely-developed ontologies (logic-driven) with MLMs (data-driven). In this hands-on masterclass, we show how to do this with examples from RelationalAI's Rel language. We also preview several other interesting tasks that use MLMs, such as semantic search, and automatic labeling of features with concepts from an ontology. This combination of the formal and informal is the future of AI. Jupyter Python notebooks will be made available ahead of the class showing how to do (a) through (d) above with OpenAI's GPT3.5/ChatGPT models. Participants wishing to run the code during class will need their own accounts on OpenAI. Examples will be demonstrated in real use cases. Vijay Saraswat is a Computer and AI Scientist known for his work in logic, concurrency and languages. He was previously Global Head AI R&amp;D at Goldman Sachs, Distinguished Member of the Research Staff at IBM TJ Watson, and Technology Consultant at AT&amp;T Research. Nikolaos Vasiloglou is VP of Research in Machine Learning at Relational AI. He has worked several years in the application of AI in retail, security and other domain