Go back

Pedro Domingos: Tensor Logic Unifies AI Paradigms

87m 48s

Pedro Domingos: Tensor Logic Unifies AI Paradigms

Pedro Domingos, a computer science professor, has been working to unify various AI paradigms into a single solution, which led to the development of Tensologic. Tensologic introduces a new language that merges tensor algebra and logic programming, offering automated reasoning, efficient syntax, and scalability on GPUs. The language aims to provide a universal approach while ensuring the right level of abstraction for AI tasks. By unifying symbolic AI, deep learning, kernel machines, and graphical models, Tensologic presents a comprehensive solution towards achieving the goal of a master algorithm in AI.

Transcription

17052 Words, 94171 Characters

Tensologic Unifies not just symbolic AI and deep learning, it also unifies things like kernel machines and graphical models. I'm Peter the Mingus, I'm a professor of computer science at the University of Washington in Seattle and a long time machine learning researcher. And my dream from my PhD onwards has always been to unify all the different paradigms of AI into a single one. My PhD unified two of them, my best non-research unifies a couple others of them. I wrote this book that turned into a big best seller surprisingly called the Master Algorithm that is precisely about this goal and where we are towards that goal. And my latest work which this this this podcast will talk about is a new language called Tensologic that I would say for the first time brings this dream of a unified representation, a unified solution to AI within reach. So if you want to find out, you know, how are we going to do that? What's this podcast? You know, I can set the temperature to GPT to zero and it still hallucinates and I can I can have a I can have a poor deductive system that hallucinates all kinds of things. So to me like those are separate separate problems. No, very good. So precisely the problem or one of the problems with GPT is that it it hallucinates even when you set the temperature to zero, what the hell, right? I want to have a mode right? Not I but like every Fortune 500 company, if it's going to use AI needs to have a mode where the the logic of the business is just to bathe. The security isn't file layer, the customer doesn't get like to et cetera. We got to have that ore add in that they will not take off, right? And transformers can do that. Tensologic can do that precisely because in this, you know, reasoning, animating space, you know, mode that I just described. If you set the temperature to zero, it does purely deductive reasoning. And by the way, the temperature can be different for each rule. Tensologic is just based on this to me, gobsmacking observation that an Einstein under rule in in the logic programming are the same thing. There is this thing called predicate invention, which is discovering new predicates, discovering new relations that are not in the data, but they explain it better. I would say that, you know, in some sense, discovering representation like that is the key problem in AI is the holy grail. What was Turing's achievement that we now take for granted? Turing's achievement was for which is deservedly famous, right? Is to postulate this notion of a universal machine. The amazing thing about computers is that the universal machine, which in his time was a and it was completely counterintuitive notion. What do you mean a machine that can do everything? The typewriter can type, you know, like the sewing machine can sell. You're telling me there's a machine that can type with one hand and so with the other. What are you talking about? So like, this is the genius, right? So first step, you want to have this property of having a machine that can do anything. What we're missing to be able to do what the universe does and evolution does is universal induction. What is the Turing machine equivalent for induction for learning? That's what I'm after. MLST is supported by cyberfund link in the description. Hey folks, I'm Amar, product and design lead at Google DeepMind. We just launched a revamped vibe coding experience in AI studio that lets you mix and match AI capabilities to turn your ideas into reality faster than ever. Just describe your app and Gemini will automatically wire up the right models and APIs for you. And if you need a spark, hit I'm feeling lucky and we'll help you get started. Head to ai.studio/build to create your first app. The idea of having to traffic and squishy people in order to make our systems go is not immediately appealing. Let's put it that way. This episode is sponsored by prolific. Let's get few quality examples in. Let's get the right humans in to get the right quality of human feedback in. So we're trying to make human data or human feedback. We treat it as an infrastructure problem. We try to make it accessible. We're making it cheaper. We effectively democratize access to this data. I'm a longtime fan of machine learning street talk. In fact, I was a fan of it before it was big. Just like I was doing deep learning before it was big. So very close analogy. So you should definitely watch machine learning street talk. It's one of the best ways to not only learn about machine learning, but to find out about what's going on at a deeper level than you see everywhere. And that is very important. So you should definitely subscribe to machine learning street talk. Professor Pedro Domingos, it's amazing to have you back on MLST. I've lost count of how many times I've had you on the show now. So it's amazing to have you back. The main reason that we've invited you today is you've just released a brand new paper, a very exciting paper called Tenselogic, the language of AI. And fields you said take off when they find their language. So you gave the example of calculus in physics and Boolean logic when designing circuits. What's the idea behind this paper? Well, Tenselogic in many ways is the goal that I've been working towards my entire professional life because I really do strongly believe that a field cannot take off until it has really found its language. And Tenselogic, I believe, is the first language that really has all the key properties that you need in the language of AI. For example, it has automated reasoning right out of the box. Like, for example, prologue has, right? The classical language has had the number of things that we just took for granted that transparent and reliable reasoning you didn't even have to worry about. It was just already available, right? At the same, that you don't have that in PyTorch at all, right? You have all these hacks to try and do reasoning on top of it. At the same time, the lisp and the prologues they never had the auto differentiation, the ability to learn, like, one of the beauties of the current moment in many ways is that you barely have, you look at most papers, people barely talk about the learning because it's already implemented under the hood. So you want that as well, right? And you want the scalability on GPUs is the other thing that things like, like, you know, PyTorch and TensorFlow and what not give you. There was no language before they have all of these and there's a number of others, but these maybe are some of the key ones. So TensorFlow logic is basically a language which has the name implies is a marriage, a very deep unification, not just some superficial combination of the tensor algebra that deep networks are all built out of and the logic programming that symbolic AI is built out of. There's only one construct in tensor logic and it's the tensor equation. You can do everything with tensor equations. Are you saying that there's only one language of AI because certainly in some fields, like physics, you gave the example of calculus. I mean, yeah, like, you know, almost all of calculus. I mean, almost all of physics, you know, involves quite a bit of calculus. There are other fields where actually there are kind of multiple multiple languages that play, you know, almost equal roles. I'm wondering if you think that is tensor logic going to be 85, 90 plus percent of the way that we should be talking about and thinking about AI or will be, will be kind of a mixture of different, different languages. That is a very good question and in fact, we know very well in computer science that there's no one programming language that is better for everything. There's just people who think it is, right? Everybody has their favorite language that they believe, you know, is the universal solvent, but it never really is. So we, and we know also for fundamental reasons, like, you know, going back to, you know, Shannon and whatnot, that there is no language that is the most, you know, pity for anything you might want to say, right? Having said that, right? Physics is a good example because calculus is so fundamental, you know, Feynman famously said that he thought in calculus, right? And the thing that I found with tensor logic is that, you know, I don't know how much of AI it's going to be or how much it should be, but what I have found in many ways to my surprise is that in some ways, tensor logic is more than just a programming language. It really, I think, captures the fundamentals of what you need in AI, in a way that going in, I didn't think was possible. All of tensor algebra can be reduced to this operation, which, you know, going back to physics is called the Einstein summation, right? Einstein summation was something I was introduced by Einstein when he was working on relativity and got tired of writing summation signs. It was all about tensors, right? General relativity is all about tensors, and he jokingly called it his great contribution to mathematics. But the bottom line, and, you know, there's this great paper by Tim Rocktashel or, or, you know, a blog post saying, Einstein is all you need. And truly, you can do all of the planning with just Einstein, all of the matrix multiplications and, you know, tensor products, all of that are instances of Einstein. On the one hand, on the other hand, in symbolic AI, it's all about rules, right? And tensor logic is just based on this, to me, gobsmacking observation that, and Einstein and the rule in the logic programming are the same thing. They are actually the same thing. The only difference is that one is operating on real numbers, and the other one is operating on Booleans, but, you know, that's just a different, you know, atomic data type, right? And then on top of that, so to summarize, at this point, I think that it would be, I look at all different things that I and others have done in AI, and I think it would be crazy to not do these things with tensor logic. There may be other better things coming, you know, after, but at this point, I would say, tensor logic would probably be better for what people are doing across the board. But hey, that's me. I may be a little biased. First of all, shout out to Tim Rock-Tasher, I read that blog post from 2018 earlier that you were referring to. But I suppose the thought occurs that, if it is mostly about Einstein and, you know, you might make the argument, why do we need an abstraction when we already have a great abstraction in Einstein? So, folks now can use PyTorch and, you know, Jax. What exactly does your abstraction allow them to do that they can't do with PyTorch? No, very good. It does several things. So, first of all, and this is going to be an increasing order of importance. The syntax of Einstein in these language, there's also this package called INOPS, is incredibly clunky. So, at a very basic level, tensor logic is just a much pith here, more compact, easier to write and understand way to write Einstein's. And, you know, physics and mathematicians famous like to say that a good notation is half the battle. So, this might not seem like a big deal, but my experience is that you can just think better and faster once you have this notation that like this funky procedure call with these indices and these arrows and these arguments. It's a nightmare. And, you know, the syntax of tensor logic is like you write a nine sum like you would write a rule. There's a tensor equation with a tensor on the left hand side and this join of tensors on the right hand side. So, this is one aspect. Another very important aspect and one that I think could prove decisive is that people don't use Einstein much because it's not very efficient. Under the hood, it's not as efficient as you, you know, sometimes I, you know, this could be done so much better, right? But I've done some of programming of this and that wound up, even I wound up not using Einstein because it's so slow and clunky. And, all of that can be fixed. Once you have this one abstraction of the tensor equation and you implement it on kuda, for example, you can optimize the heck out of it and you'll just be able to, you know, Einstein will finally be able to reach its potential, right? But, actually, none of these things are actually the most important part. The most important part is that the, the Einstein, as we know it, is only good for tensor algebra. Tensor logic is a language where the same construct does all the symbolic and all the numeric parts and any mix and variation between them, including learning the symbolic part and whatnot. These are all things that are in some world just didn't exist, right? You talk about the people who knew Einstein, whether in AI or mathematics or physics, and they just had no idea that any of this had anything to do reasoning. You look at all the ways that people are trying to do reasoning today and just want to pull out your hair. Let me ask a very concrete, you know, in some sense I'm a simple, simple man. I need like a very concrete example because I completely agree with you, which is that the symbols we use, the language we use are just simplicity is so fundamental to our ability to like reason at higher and higher levels. So let's take one example, you know, from your paper, which is a logical or, logical or of a bunch of values is equivalent to an Einstein, within a heveside, you know, function applied to it. Like you get this example, right? The or just to be precise, what I did in, you know, maybe this is an important piece of context. So if you look at, so the simplest form of logic programming is data log, right, which is the foundation of databases, right? You know, most SQL queries are variations on data log rules, and data log rules are composed of two things, joints and projections, right? This is like databases 101. And what I have done is I have generalized joint and projection to numeric values. There's this thing which I define called the tensor joint and the tensor projection, which when the tensors are Boolean becomes the regular symbolic database one. But now the numeric version has all these things as special cases, and by the way, it's also more general than the Einstein, right? So another benefit of this is that it actually goes, goes beyond the Einstein. Now, an or, right, the way you get an or is, is, is by having more, is just isn't so, how do you get an or in prologue or data log is by having, you know, multiple rules with the same head? And then those rules, and then they implicitly being disjoint, right? So if I have A, F, B, C, and A, F, D, E, then that means A, F, B, C, or D, E. And the same thing happens here. And you could also, of course, just put that on mall in the same equation, because like, you know, it might be more convenient, just like, well, A, B, plus C, D, right? So doing an or is a completely, you know, straightforward thing, but it's really not where the main action is. It's in the tensor joints and tensor projections. Thank you. Like for laying all that out, completely agreed, makes sense. I just want to, the very example I was giving is that and I'm some over a particular index of Boolean values, then with a heveside function applied to it, which is just a, you know, zero, if it's less than zero or one of its greater than zero, is equivalent to a logical or of the over that same index. Oh, yes, sorry. I see. I understand your question. So again, it's more than that. It's, it's a, it's a DNF, right? It's not just, so DNF is a junction of normal form. Yeah, exactly. And so what happens is they're like, you know, like the Einstein is, so in Umeric land, right, a dot, think of a dot product, right? A dot product, right, is just a sum of products, right? Which in Boolean land will be a disjunction of conjunctions. If more than one is true, you get an M, there is greater than one, which is, you need to pass it through a step function to reduce all the various greater than one back to one. Yes. But my question was more like, okay, I have these two different representations of the same, the same operation, at least at the element level, like an, an Einstein over an index followed by a have a side on that element is equivalent to an or overall the same Boolean values of that, of that index. And I guess, and my question or per element. So my question to you is, I give up one thing, which is instead of having a single symbol, which is kind of like an or, I've now got two operations, you know, Einstein have a side. And there are many examples of that, right? Like I can build every single circuit out of NAND gates. I think we discuss this like, yeah, exactly. Or, or I can have like other kinds of gates. And it's useful to have other kinds of gates. So in your, in your language, do you foresee people not having syntactic sugar, like an or operator, which under the hood is, Einstein have a side, or would they still retain those? It's just that the fundamental, you know, the most basic, you know, constructs of the language are tenser logic. We can do everything with NAND. So why do we need high level programming languages at all, right? The point, so there's two things that you want the language to be. First of all, you want it to be universal. So you can, for some things you don't, but in general, right? For AI, surely you want the universal language. You want something to be incomplete and to be large, and the tenser logic is that. But then this is actually the most important and most difficult part. You want something that is that the right level of abstraction for the things that you want to do. And NAND definitely is not. And I can show with a lot of examples that I have in the paper, for example, you can, you know, code a transformer in a dozen tensor equations as opposed to a vast mass of code, right? And then what happens when people have a language that suits their needs is that then they just get used to that. They often wind up using it for even for things that it wasn't the perfect thing for. But at their point, it's what they're comfortable with. So my guess is that the end of the day, people are just going to do everything in tensor logic. And they know, you know, in the back of their heads that yes, they are or is going on here and you could think of them as or's. But they just think of them as giants and projects and tensor equations. Very good. And by the way, you can implement transformers and anything else in tensor logic. It's so easy, in fact, that I fed your paper into Claude code. And I got it to implement the whole lot this afternoon. And maybe I'll publish that on GitHub if folks want to have a look. But it's quite straightforward. But just to get the trajectory a little bit here, Pedro, you're famous for writing this master algorithm book. And in that book, you spoke about all of these different tribes in machine learning, you know, like Bayesian folks and logic folks and kernel methods and neural networks and all of this. And I guess do you see this as a step towards unifying these things together? Because now in tensor logic, you can actually create a composition of different modalities of AI. And it just works. But this might seem a bit weird to people. I mean, can you explain what that might actually look like? Absolutely. So in a way, the master algorithm was laying out my agenda, right? Was asking the question, what is the master algorithm? I did say at the outset, I'm not going to give you the master algorithm in this book. I'm just going to tell you where we are and why I think this is the central goal of AI. I would say that tensor logic is that answer. Tensor logic, we haven't talked about that yet. But tensor logic unifies not just symbolic AI and deep learning. It also unifies things like kernel machines and graphical models. The things that graphical models, for example, are built out of and then you can compute probabilities with them. They are a direct-- I didn't do this on purpose, but it just fell out. The factors that graphical models are made of, those are just tensors. And then the marginalization and summation, sorry, the marginalization and the point-wise products that are what probabilistic matrices made of, they are just tensor joints and projections on those tensors that represent potentials in the case of vision networks and conditional distributions. So at this point, we do have this very simple language where you can do the entire gamut of AI, which honestly, I didn't think this was going to be possible going in. I thought the answer would be much more complicated. Now, is this the master algorithm? Tensor logic per se is not the master algorithm because it's just a language. I would say that it's the scaffolding on top of which you can build the master algorithm. Now, tensor logic is not just the language, it's also the learning and reasoning facilities under the hood. So, for example, one of the best things about tensor logic is that the autograph is incredibly simple because there's just one construct, is the tensor equation and the gradient of a tensor logic program is just another tensor logic program. So this is all there. So the learning and the reason got all there. However, you know, what I would say is that this is not the master algorithm per se, but it's what we need to produce and I intend to produce it on a short order. You've described a language and certainly if components of that language are tearing complete, that's a big vexed issue. We'll come back to that a little bit later. But because of computational equivalence, we can, you know, from an express ability point of view, we can describe anything in the universe. So we've got this framework. But to me, the challenge in AI is structure learning, right? So as well as being able to express stuff, it's being able to adapt to novelty and create perhaps from building blocks that we already have a new structure to allow us to do something useful in that domain. And I can't quite make that leap with with your technology yet. So how do we do the meta thing where we actually build the tensor logic constructions to represent the kind of world that we're seeing? Oh, very good. So I actually go into that in the paper, you know, but briefly, the paper is just, you know, an informal introduction to these ideas. In that logic programming, right, is the field that deals with discovering rules from data. But it does this by things like greedy search or being searched and it's very large, you know, search persons. It's extremely inefficient, right? Which is actually one of the things that killed it, even though it could do all these things that people aren't deploying are just painfully rediscovering. Intensor logic is one of the best parts of it. The structure learning falls out of the gradient descent. The gradient descent actually does structure learning. And then on top of that, this is actually the best part as far as the learning is concerned. There is this thing called predicate invention, which is discovering new predicates, discovering new relations that are not in the database that explain it better. I would say that, you know, in some sense, discovering representation like that is the key problem in AI, is the holy grail. Everything that we know, you know, like when you look at it at the world, right, you don't see pixels, you don't see photons hitting your retina, right? You see objects. The objects are invented predicates, all the way up to science, right? The most like Newton's genius was to introduce a new quantity, which is force and energy and entropy and all these et cetera, et cetera, right? So in, in tensor logic, that also just happens by gradient descent, right? It's, it's, you know, it's hard to believe, but why, let me just give you a hint as to why this is the case. There's this other thing that is folded into tensor logic, which is tensor decompositions, right? And tensor decompositions are a generalization of matrix decompositions. And if you think about matrix decompositions to take that simple case, what a matrix decomposition does is it takes a matrix and decomposes into two new matrices that together are more compact, but essentially reproduce the same data, right? And there's a generalization of that to tensors called the Tucker decomposition, there's others, but the Tucker one is, is the most relevant one here. And so if you write in tensor, to answer your questions very directly, if you write in tensor logic, a rule schema, you know, including, you know, a, a data tensor on the left hand side. And by the way, your entire data can just be reduced to one tensor embedded as one tensor. We can touch on that later, but you write a rule expressing that as a function of a few other tensors, and the gradient descent, just as in matrix factorization, will discover the best values for those. And then if you want to, for example, then discretize it, say, like, I'm going to threshold this and make it boolean again, you will see what is the concept that that learned, or you can leave it in, in, in, in, in, in, in, in, in, in, in numeric form. So the learning is actually extraordinarily powerful. I've always thought, and, you know, I think, you know, a lot of people in deep learning really believe this, that, you know, gradient descent can do amazing things, provided you give it the right architecture to operate on. And in a way, what all these million papers are about is about finding the right architecture for gradient descent to operate on, and of course, transformers are greatly forward, but I think transfer, I think, you know, tensor logic is an even greater leap forward. How so? Because for example, I can picture, suppose we, we, we want to get rid of Python. So like, I'm over here in, you know, PyTorch, and, and I've described all my, my layers, kind of in the clunky syntax. And, and said, I'm like, no, now I have, you know, the tensor logic, you know, GitHub programming language. Let me go do there. I'm still going to construct my layers, right? So, because like, for example, you do, of course, you allow for the, the, you know, non-linearities, right? So after every I'm some, I can apply whatever kind of non-linear function I want to rel you or sigmoid or whatever else, right? That's still going to be described in my program. It's like I'm going to have this shape, I'm some followed by this linearity feeds into this shape, followed by, so I'm still going to have to do that kind of like, you know, structuring of the network, if you will, it's up now in tensor logic. In my opinion, that's one of the biggest limitations right now is these are all just defined in-cantation structures that people have come up with. Like, let's put in a dropout layer here and this kind of layer there and there. We don't actually allow the machines to learn the overall topological structure. We only allow them to, to find weights within that structure. No, but okay, I understand your question, but tensor logic does allow that. You know, step one, you can, you can encode a multi-layer perceptron, the entire multi-layer perceptron, and I do that in the paper with a single tensor equation. All the layers provided that they all use the same non-linearity can be encoded in one equation, okay? Number one, you can also have different equations for different layers or typically sets of layers, you know, to your however way you please. But for the point of view, structure discovery, the thing to realize is that if you create, if you set up one of these very general equations that you can intensify logic, that in some sense it can, it's a very broad classes of architecture. Then what the learning does is it discovers the architecture within that space, right? Which if you think about it at some level is what a neural network when you compare an ordinary multi-layer perceptron with a set of rules, right? A multi-layer perceptron is, is, you can take, in fact, there was a system called K-band in the early days that did this very clever. It initialized a multi-layer perceptron with a set of rules because each neuron is a rule, right? But it's also more flexible because now you can have weights, right? But, you know, a neuron, a single neuron can represent a conjunction and therefore a layer can represent a junction and so forth. So when you're learning weights in an ordinary neural network, you can actually see it as learning the structure of a set of rules. What Thincyl logic is doing, this is at a more powerful level, like that was just propositional, and now this is at the full level of, of, of generality of, of first autologic. But you can learn the structure and then, of course, then there's more than one way to do that. And you can also decide how black and white you want the structure to be, what you want to leave as weights, what you want to discretize. But this, this structure itself can be learned by taking a tensor equation. A tensor equation is a very general thing, right? When you learn the weights of those tensors, that, the, that materializes to a specific network structure. Yeah, so I, I understand that. Let me bring this back to, like, to the folks who are familiar with, you know, PyTorch or traditional techniques. What you described is, yeah, I can just create a fully connected, you know, network with however many layers I want and then let SGD, you know, find all the weights. That doesn't work. Like, it doesn't work in practice and it's not going to work with tensor logic. You know, it's just a different representation of the same fundamental problem, which is there's too many degrees of freedom. It's not going to learn anything useful. This is why so much alchemy goes into structuring, you know, constrained networks to have certain, you know, built-in, you know, inducted bias, right? No, absolutely. So to take another example, you can also do an entire convent net in just one tensor equation. And, and, you know, the quintessential example of, like, yes, complete connections don't work is a multi-lay perceptron for vision, right, which you replace with the covenant that actually has the local structure. That is also a tensor logic equation. Now we are saying, well, how do you choose between the covenant and the NMLP, right? Very good question. And now there's a range of things you can do. You can actually, these days, start out with a very general structure because, I mean, GPUs in large, you know, server farms are an amazing amount of pop for something like this, right? So you can almost, I would say, brute force that search provided you have the data. I'm not actually recommending to do that, right? You can also, however, and more interestingly, you can, and this is actually one of the key benefits of tensor logic is that you can write down what you believe are properties of the, say, right now, what happens in, in, in, in, in, when you, for example, program a network in Python is like, you have to commit, you say, like, here's this structure. And now, the, you know, the, the learning of the only thing that happens is the learning of the weights. Intensive logic, you don't have to do that. You can, you can just, you can set up one of these very general structures. And then you say, let me give you a bunch of equations that are things that I believe to be true about the structure, but do not completely determine it. And those just work like priors. And indeed, like soft priors, right? Those can, and then again, you can turn up the temperature on this or down and say, like, you got to obey this equation. And that one, you know, sure, you can override. And then, and then this, in my experience, this is actually what is important is that the gradient descent, instead of starting from a table or as I have this kind of soft knowledge. And then most importantly, like you, the developer, you, the AI researcher, you, you get to, this is really the essence is that it's not this, you, every, every, you know, deep learning researcher or data scientists know this is like, you don't do this a priority and then push the button and hope for the best, right? It's like, it's, there's a iterative loop of you set up the structure and then you learn you get the results and then you refine the structure. And what this does is it makes that more efficient much more because you just have to, in your interpreter, you write one more equation or you modify an existing equation. And also, the entire stack is, is, is of what you learn is much more interpretable than it was before. Is actually in some ways one of the most important properties of tensor logic is that you can understand what's going on much better than you could in two ways. One is that the code is much more transparent than the whole pile of things that you have sitting under a bunch of, you know, PyTorch procedure calls, but also the result of learning, at least if you do it in certain ways that I discuss in the paper, the result of learning is transparent in a way that a transformer just, you know, can hope to be. So we've covered some interesting topics on MLST before me. Of course, there's geometric deep learning, which is this idea that symmetries are fundamental. We've spoken with Andrew Wilson from NYU recently about soft inductive priors. And I've just spoken with Yeemar about his crate series of architectures. And I guess the prevalent idea here is almost platonistic that there are real, natural patterns. And if we kind of bias the model as you're just alluding to that, it will converge on really good representations at described reality. Now the alternative view is that reality is constructive and gnarly and that won't work. But you were talking about your Tucker decomposition earlier. And that's this idea that, you know, we might have a large sparse matrix. We might want to densify it. We might want to factorize it. And the factorization will kind of pull out some of these natural orderings, you know, of the universe perhaps. And I guess I was thinking, isn't it a bit like a GZIP algorithm? I mean, what if these factorizations are just semantically meaningless, you know, how do you know that you've got a good one? You know, great question. And you've touched on several things there. Let me start with, you know, the geometric deep learning, right? I'm a big fan of this. In fact, you know, I gave a keynote at the second I clear on something that I called symmetry-based learning, which is when some was an ancestor of geometric deep learning. I really do think that the universe possesses this fundamental symmetry. Actually, I don't think that this is known, right? In physics, right? The standard model is basically a bunch of symmetries. And this is extraordinarily powerful, right? That such simple things could be such universal regulators that you then basically can build everything else out of, right? And if you think about it, in machine learning, the problem is like, what is the learning bias that you should start from, right? Should you pull in a lot of knowledge, should you have a very, you know, very vague architecture? The thing about machine learning, and there's no free lunch theorem, right? That says, you know, if you don't assume anything, you can't ever learn anything. The thing that's amazing about machine learning is that with very weak biases, you can get very far, right? And I would submit that those weak biases, fundamentally, I think that the most important ones are these symmetries. And tensor logic is precisely, you know, I think the perfect language for expressing those symmetries, as the physicists will tell you, right? It's what they use in, like, in not the logical, you know, version, but the numeric version, right? So I think we can discover those regularities. I have some suspicions as to what they might be, but I think, you know, we're not quite there yet. But I think once we have those regulators in some sense, you know, they will play in AI the role that the standard model plays in physics, right? Now, of course, as you say, you know, there are people who say, like, oh, forget that, right? You know, going back to my Vyn Minski, right? There's like, there is no small set of AI laws or anything. It's just one damn thing after another blah, blah, blah, right? Like you're dreaming, right? And I respect that point of view, right? And, you know, we will find out empirically, but what I, if I had to guess, how this is going to play out at end of the day, it's going to be like this. The stuff that I'm talking about gives you, you know, the 80/20, you know, it gets to 80% of the way. And then the other 20% of the way, you have to do a lot of these things. You have to do a lot of hacks, et cetera, but something like since the logic still makes it much easier and faster to do those hacks than if you didn't have it. So it actually gives you benefit both in the 80% part and in the 20% part. There are folks, so you know, complexity signs. There's this guy called David Krakauer. And in his book on the first page, actually, the very first sentence, the scientific and social implications of differences between A closed reversible symmetry dominated and predictable classical domains. I think that's what you're talking about, the kind of the Roger Penrose type world, and B open self-organising, dissipative, uncertain and adaptive domains. Now, I think the latter is where all the interesting stuff in the universe is. It's where life and intelligence and all the other stuff we want to model. And could it be the case that those things are not reducible in the way that you're arguing they are? I'm where you ask that question, because this really is the crux of the matter. Also, you're probably familiar. I know you're familiar. Because we've talked about it before. Steve Law from the notion of computationally reducibility, right? Yes. And of course, the whole notion that we now understand very well that systems are, you know, many systems are chaotic and therefore inherently unpredictable, right? And, you know, complex systems and all of that. But so where does the, you know, the whole notion that, you know, more is different, right? Like very famous, you know, notion in, in, in, in, no sentence. Exactly. Which I'm a very strong believer in. So doesn't that contradict what I just said? Actually, no, right? I would say the following is, you know, from physics all the way to AI with biology in the middle. The universe is basically composed of two things. Symmetries and spontaneous symmetry breakings, right? God made the symmetries. The symmetries are the laws. As far as we can tell, none of these systems at any level violate the laws, right? Those symmetries are there. I mean, you can go into that. There's a lot to be said there. But essentially, you know, most people, the great majority of people may be accepting, you know, some, there are some exceptions. But they believe that the laws of physics apply to everything. Like my brain ablives the laws of physics, society ablives the laws of physics. The problem is that the laws of physics are useless at some point in understanding, you know, even biology, let alone psychology or sociology or AI. Why are they useless? Because we have inherited, from the beginning of the universe, a series of spontaneous symmetry breakings, right? And my brain is doing spontaneous symmetry breakings one after another continuously. And those seem, like those then some of them die out, right? Or become irrelevant, stay the same. But others balloon into very big things. And that's actually what evolution is. It's one of these things after another. And once you have that, so the computationally disability problem is that at some level, it is true that, although in principle, this is all predictable and reducible, in precedent, it isn't, right? But now here's the point. It's like, how do we handle that? Our brains know how to handle this in a way that AI doesn't. And the way they handle this, like, you predict, you computationally reduce everything you can to begin with. And I'm actually, I've talked with Steve, you know, at some length about this. And I'm actually more, much more optimistic about how much is reducible than he is. And the things are like, your overall universe is not reducible, but it's full of these irreducible pieces. And in a way, evolution is a chemical, our brain is an accumulation of these reducible pieces. So you do that. You want the machine learning to discover it. You want the inference to exploit it. But then, after that, you have to have no choice but to just keep gathering data and using that to inform your predictions, right? In a way, the physics goal of, like, I give you the initial conditions. And then I just predict, like, the, you know, the Laplace's demon dream. It is a dream. But I think that the problem that, you know, some of the complex systems people have not realized is that we don't have to do that. Ask any, you know, engineer, any aerospace engineer using a Kalman filter. What you do is you predict just what's, you know, reinforcement learning, right? He's like, you want to have a sense of where you're going. But at every step of time, you, you, you, you, you recalibrate your predictions with a new data that comes in. So you actually only need to predict things well enough to control them, to make them predictable, right? We humans are always controlling the world to make it more predictable. And this is what robots need to do as well. And this is sort of like what I'm trying to, you know, support with a language like Light and Sylogic. Increasingly more of a believer in kind of hostletters, you know, concepts, right? That there are multiple levels of description. And even within a level of description, there may be multiple languages, you know, to describe things at that level. And I think part of the lesson is, not only do we observe, like not only do we kind of observe a particular level. And sure, we try to reduce things and come up with theories at finer grain levels, higher resolution theories or whatever. But we also observe a certain layer and we're able to, by whatever sort of miraculous mechanism to almost pull out of thin air or to abduct a theory at this level. Like here's thermodynamics, somehow we came up with that, right? And even if we learn theories at lower levels or higher resolution theories, actually, most of the time you don't replace those older ones, it's like within their domain of operation, you know, Newtonian mechanics is still extremely useful for lots of things that have to do with our scale, right? Our scale by activity, GRs useful to different scale, quantum mechanics, a different scale. So we retain all these languages. And I'm hearing that tensor logic is a great language for a certain, you know, layer of description and for activities of AI. But you're not arguing that it's the language to sort of replace all other layers, right? Like you still buy into the other languages are different. I'm glad you asked that question. I am absolutely arguing that tensor logic is the language to using all these layers. And let me give you some evidence towards that. Express relativity and tensor logic. It's tensors and, you know, differentials of tensors and whatnot. That's, you know, that tensor logic does that out of the box. Do the same thing with quantum mechanics. Do the same thing with all these others, with all the different pieces of AI that I know. And why is that possible and why this tensors logic do that? Again, I think this gets at a very deep fact about the universe, which, you know, complex systems, people and physicists have suspected as well, which is that the universe has this amazing property without which it would not be comprehensible that you can have a lot of complexity at one level that then organizes itself into a new level at which now a different set of, you know, laws applies, right? And you know, we do with computers is do that by design, right? But here's the key. What you want is a is a language in which to express this process, right? The whole process by which multiple levels get creative, by which multiple representations get created, including different representations at the same level, right? For example, right, you know, going back to our assignment, you know, people, many people at least and I have believed that the essence of human intelligence is your ability to switch between representations as the problem dictates. And as long as you pick one representation, you stuck yourself in the box, but at that level, tenser logic is a matter representation. It's a way to construct representations. And yeah, you know, a large language model, you know, to take every example, what has that transformer learned, right? When it looks at all that text, precisely I would say where a lot of its part come from is that it has looked, you know, it's like, you know, say a view back says, it's like it has learned this supervalidums. There's all these different pieces in different ways of doing things that it has got us from different places. And it doesn't choose between them. It's the prompting and the fine tuning and more that then pull out the parts that I better for one thing or another. So we absolutely have to do this in AI. I think it also reflects a deeper truth about the universe. I think there are going to be laws of this, you know, we're not then describing laws of the universe. And I think tenser logic at least is my best attempt at having a language in order to do both this AI and this type of scientific discovery. I also believe and I, you know, I discussed that briefly in the paper that tenser logic is not going to be just a good language for AI. It's going to be a good language for science in general. For several reasons, one of them is this, but the other one is that if you look at the difference between the equations on the page and the resulting program from implementing them, often there's a lot of complication. In tenser logic it's almost, you know, the, the tenser equation is an almost simple, simple translation of the equation on the page. So now you can just do, you know, science, you know, on a different level. Also, the logic, if you look at scientific computing, right, it's usually these tenser operations with some logic wrapped around it. Tenser logic does the tenser operations and the logic in one language. But more importantly, the logic now becomes learnable. You can now learn the logic as well. Let me just challenge you on on this because for example, like in your paper, when you got to the RNN section, right, like, you know, tenser logics can, can represent RNNs. But then you hacked in star T. You're like, oh, I need this little star T here. What's star T? Well, star T is a virtual index that doesn't create new memories. That's not tenser logic. You hacked in star T because you needed that in order to express RNNs. No, no, no, no, no, no, no, look, great questions. So there's two very important things to distinguish here. One is which star T is not but let me mention that first. The RNNs also illustrate that is syntactic sugar, right? You always have syntactic sugar because for example, in an RNN, you want to express X of T plus one, right? And I could, you know, tenser logic is doing complete, but I don't have the T plus one. I can, it's a very simple syntactic piece of syntactic sugar to add. Why wouldn't I do that? Right. Again, there's an 80-20 rule of like which of these contests you want to have. But the star T is actually completely different thing. The star T is there for computational efficiency purposes. Star T is a hint about how to implement that tensor. That saves a ton of memory, right? And you know, you know this notion of a leaky abstraction. All abstractions are leaky famously in computer science. Tenser logic is no exception. For the most part, when you write tensor logic, you don't have to worry about what goes on under the hood, but sometimes you want to. And this is precisely one of those things. The idea of the star T is that some is like, I don't, we don't have four loops anymore, right? Which is great. Forget all of that. But sometimes I don't want to be computing a new tensor or even just a new vector for every new thing that I do because that would be a waste of memory. The star T is just saying, you know, you have one vector and you reuse it at every iteration. So you have the initial X zero and the next one is over, it over writes that, right? So this, this is a piece of the language, right? You can do everything without it, but it would be silly to not use it. All right. So let me, let me push back on something because you mentioned it twice now, which is like the turning completeness. So your paper relies on like Siegelman's, you know, 1995 sort of paper. She herself now like decades later has admitted that that thing is a total toy that has no practical relevance whatsoever. Okay? Because it requires like infinite precision, rational registers that encode in a fractal way, et cetera. And by the way, in her paper, all she demonstrated was that under these infinite assumptions that she could build a particular RNN that was a universal turning machine. The problem with using that for your tensor logic is two things. One, that restricts the field over which you can have your tensors. It must be one of these fields that has like infinite precision. So infinite precision rationals or whatever. I can't using the other fields like no modular arithmetic, which is actually what runs on, you know, GPUs, for example. And secondly is it would restrict the actual structure of the weights to her universal turning machine. Therefore, it wouldn't be a general purpose tensor logic. Well, do you realize this problem? No, no, no. So actually there is no problem that let me tell you exactly why, right? And let's do this in three steps. First of all, Turing completeness doesn't matter at all whatsoever. Because the only difference between a Turing machine and a finite state machine is the infinite tape. And in the real world, there is no infinite tape. So if you can implement that pattern. It doesn't matter why do you keep mentioning it. That's part two. That is part two, right? This is actually a very interesting set of questions. So let's, let's say, let's get into parts with the light. So tensor, Turing completeness doesn't matter. What matters is that you want to be able to express any computation that you might want. That's what matters, right? You might choose a specific language for specific purposes. For something like tensor logic, you want that generality. You have that generality irrespective of Turing completeness. So this is part one, right? We can debate, but let's set this up for a second now. But you know, the way, I don't get to change the way computer sciences and Turing completeness is a shorthand for universality. I just want to show people that tensor logic is universal. And now I have a proof that tensor logic is computationally universals that does not rely on the on the seagullman construct, right? I chose to not publish in this paper because it would take too long, right? The beauty of that is that in one paragraph, I can just say, look, the ten, the equation in the seagullman paper, you can implement it here and we're done, right? I can also, you know, there's so many ways to prove that things are Turing complete. So I only, I completely agree with you and her that that construct is ridiculous, right? It's silly, right? It's, yeah, it's no practical significance. But the reason I use is like, it's just my way of telling people in one sentence that and why, you know, tensor logic is Turing complete, right? But the real action is that it helps me to share it. I'd love to see the other proof. Oh, I can, I mean, the other, so, so actually, there's even more than one other type of proof that is possible. Let me, let me tell you what, what that one is and what, so here's two, you know, not just, so three ways, there's the seagullman way, right? Another one is, you have a fine-out control with access to an infinite external tape, right? That is a much more reasonable thing in my view, right? You have a memory, yeah, the memory is infinite, but, but all that you have to do in the tensor logic is know how to access that memory. So like, it gets back, remember, a Turing machine is a fine-out control and then if and a tape, right? So if the, if the tensor logic can realize the fine-out control, which obviously it can and you give it an if you tape, then we're done, right? And then on that note, you can even just do it the following way, right? Which for example, like, you know, Dale Schurman says a great paper about this is, there, you know, people have come up with various very simple ways to set up a Turing universal, you know, computer. And one of them is there's a set of rules, right? That, you know, sets up that machine, right, without going into details. And that set of rules, you know, you can just write in tensor logic without even, you know, having to wake up from your sleep. So there you go. I totally agree with you. And I often say to people, I'm like, a Turing machine is just, and I really hate to use the word just because it just doesn't do justice to Turing, to Alan Turing. And like, the genius of his, you know, creation, the theory of computation, right? But it's just a finite control with an unbounded read write, you know, external memory. Totally on board with that, absolutely, tensor logic is a finite control. But then you need to add to it these operations to, you know, manipulate external memory, right? So it's kind of tensor logic plus some operations to deal with external read write memory, you know? I mean, so those operations are just read, right? Move left and move right. That's all there is. I know, but that's an extension of, I mean, at least in my view, I mean, I don't know if before you there was such a thing as tensor logic, I'm not sure. I know that a lot of people have talked about tensors for like a decade or, or more, but, you know, it seems like some kind of an extension to the typical, it's certainly an extension to the way tensors are used in GR. There's no read write to external memory in that. Of course, but that is why tensor logic is more than tensor in math, tensors in mathematics, right? The tensors that people in mathematics just don't do this, right? But tensor logic does because of the logic programming side, right? If tensor logic can do logic programming, then it can do everything that a computer can. Have you specified fully like all the operators and tensor logic somewhere, like on a website or something? There's only, there's only two, tensor project or three, right? There's tensor projection, right? There's tensor joint and there's universities and the linearities are crucial, right? tensor algebra is multilinear, algebra is linear, tensor is multilinear, right? Totally agree, where does the memory, where do the memory operations fit in there? Are they projections or they joins or they, oh no, I mean, like it's, they're not, they're not even projections or joints, right? I mean, think of a trivial projection where you're not summing things, you'd only have one, right? That's what I write is, right? Actually, let's not even worry about tensor joints and projects. Let's just think about, you know, propositional rules, which of course, are what you, if you want to implement propositional rules and tensor logic, all that you need these tensors with no, with no indices, with zero indices, right? So all you're dealing with, with, with scalars and the right, right? It's just, you know, a rule that says, you know, the target of the writing is on the left hand side and what you're, when write is on the right hand side. Now, to get, but to get very concluded to the issue of an infinite memory, right? What is an infinite memory? An infinite memory is just an infinite vector, right? Indexed by the memory address. That's all it is, right? And so how do you write this infinite memory and tensor logic? You just have the memory as your tensor on the left hand side. It's kind of so, you know, it's so simple, it's almost, there's nothing to think about. I'll have to, I'll have to work your signature. And then, sorry, just to finish that thought, how do you advance the tape? Well, you just increment the index and how do you, you know, move it left, you decrement the index, right? It's like, it's done. Well, could we come up with a solid example? Because we, I don't think we sufficiently describe the start-e function. So roughly, as I understand it, rather than it becoming a dimension, it becomes a transition function. So we don't need to model the full trajectory. But just to give an example, if I wanted to compute, you know, let's say I want to write a function to compute the nth digit of pi or to approximate it, would I not need to fix the size of the tensors before? Right. So the way I understand it is these things have a fixed size. How could it possibly solve unbounded problems? No, very good. So to clarify, start-e is not a function. Start-e is a notation about an index. So for example, if I have a vector, you know, like, you know, x of i, right? Or, or, for example, a matrix, m of ij, right? This occupies, you know, if i and j are reached, you know, 100, this occupies 10,000, you know, positions in memory, right? But if what I do is m ij star, right? On the left hand side of my tensor equation, then this is just, you know, instead of being whatever, 100 by 100, it's just a hundred. Because what this is saying is like, if I put the star in the j, what I'm saying is like, run through the i, right? And for every j, you, you, you, you, you, you, you, you overwrite the result, right? You can do this. You need it, you know, in either dimension, but, you know, so pick one whichever is just as like, keep, keep overwriting the results, right? So you lose your old one. So I think so. Let me put this way. m ij star is actually a vector, is a vector where the only dimension is i, j is actually just a deteriorator for a for loop. You see what I'm saying? And concretely, for example, in an r and n, this is what you want, because x, right? x i is your vector, and that j, let's call it t, right? x i t, at every new step in time when the state evolves, you don't want, I mean, you could, but in general, you just want to overwrite the old state with a new one, as in any state transition system, okay? Now, you're, you know, does this make sense? It does, but you're describing an accumulator, and is it, do you lose something by losing the history? So because if you think about, you're overwriting what went before with new information, and you're just, you know, unrolling in time, do you lose anything doing that? Of course he was. So if you don't want to overwrite it, then, then, then don't put the star in, right? But not to answer your question about pi, right? Well, how would I, you know, compute all the digits of pi, right? In, you know, infinites during machine land, right? I have a vector of the digits of pi that has a start, but not an end, right? And what the computation in tensor logic does? It computes every success, it's so like, we didn't talk about this, but there's, you know, how is inference done in tensor logic? Forward chaining or backward chaining? Forward chaining is a general, they are both generalizations of the corresponding operations in, in symbolic A. If you applied forward chaining to a set of rules that computes the digits of pi, actually just one rule, because it's very simple. What it will do is in each iteration, it will fill in the next digit of pi, right? Now, if your vector is infinite, this will go on forever as it should. If your vector is finite, well, at some point, you run out of memory, and you satisfy the number of digits, which is what we do with any real compute in the real world. I don't want to, I always get this bog down into turing issues. I think we should move on, but I think it'd be fun to talk about it, you know, more than another time, or just to work through some examples. I think I'll probably work through some examples. I think this was an interesting one. There's a strange attractor with turing conversations, and normally it goes the Schmidt-Hubit direction where, you know, the universe is finite, there's no difference between an FSA and a turing, and I felt that we actually had some information gain in this conversation. Well, actually, you know, so on that point, and this is a bit of an aside, it doesn't actually have anything to do with TensorFlow logic, so I hope you don't mind me asking, but since we have the computer science professor, like, I want to just run something by with you, you know, so I always get this kind of pushback for people. We're all safe, for example, you know, auto regressive transformers, and I mean classic auto regression, not extended auto regression, not generalized auto, just auto regressive transformers are not turing complete. Like, good, deep mind admits this, and they write a paper showing how you can extend them to become, you know, turing complete. So I'll say something like that, and somebody will be like, oh, yeah, but, you know, if I can't do 100-digit multiplication with this context size, all I got to do is just have more context, and then I'll be able to do it. And I keep making a point, here's the crucial difference, right, between, so, and you brought this up beautifully when you said, look, a turing machine is a finite control with an unbounded rewrite memory. And here's the really cool thing about those turing machines is they can run it away where they're churning, churning, churning, churning, and then they say, out of memory, and all you got to do is just give them more memory and hit continue. You don't have to reprogram them. You don't have to retrain them when you've like, increase their context size, right? That's the whole difference is that with a neural network, the traditional transformer, if you increase its context size, go back to the training board, you got to retrain it, right, because you've run out of memory. Is that a fair point that I'm making? So, this is actually extraordinarily simple, and it's to me incredibly frustrating that there's so much confusion about it, starting with computer science and theoretical computer science, and now playing out in AI and transformer land. And it just was done to this, right? You said earlier, and I violently agree that, and correct me if I'm misinterpreted, but you said, like, turing completeness is not important, but that shouldn't cause us to underrate turing's achievement. Absolutely. Turing's achievement was, for which it is deservedly famous, right? It's to postulate this notion of a universal machine. The amazing thing about computer is that the universal machine, which in his time was a completely counterintuitive notion. You're telling me there's a machine that can type with one hand, and so with the other, what are you talking about? So, like, this is the genius, right? So, first step, you want to have this property of having a machine that can do anything. This is the foundation of computer science as of computers as a revolutionary technology, right? So, point one, but point two, and getting to the transformer part, right? I don't know, and unfortunately, these confusions then build on each other and never get, it's one of those seemingly breaking, right? We went on this road of defining things a certain way, and worrying about infinity, and now we're stuck there, right? NP completeness is another example, but ignoring that. So, the problem with transformers, so like, the real problem is the following. It's piece like, oh, but if you only have this many, you know, blocks, then you can only do so many computations. The thing, for example, that in that technology programming hasn't we want is that you can learn things from very small examples. Like children do in elementary school, you learn to do addition on tiny examples, but then if needed, you can do addition on numbers of any length. Of course, your life is finite, you will never add infinite numbers, but that's not the point. Infinite is just a short hand for something that's so large, it doesn't matter how large it is. And what I want in machine learning is to precisely be able to learn to do to handle problems, graphs, structures, knowledge bases, inference problems, whatever of any size from very small ones. That's the limitation that a lot of these transformers have, and that's the one that you want to fix and can fix and tens of logic helps you do that. Yeah, and I just just to cap off the discussion about Alan Turing, because I think I think he deserves, you know, us mention this, you know, you mentioned that this was the real achievement, this university, and I mean, it wasn't just a machine to do a typing, can't do this and that. It was even within computation, right? In his time, people didn't know this. They're like, well, what if I have a machine that just has a separate read tape and a separate write tape? I don't know. Well, how about if we add two write tapes? Does that make it more powerful? What if it's read right? What if it's just a stack? What if it's lambda calculus? What if it's, there were so many myriad of, you know, lag systems, blah, blah, blah, all these different computational models, right? And nobody knew that they were all equivalent. And that was the real, you know, remarkable achievement. And to be fair, no, Turing wasn't the only one doing things like this. And precisely now we know that that all these things that are equivalent and then extensions on that power. But he's actually a really important point, right? The question that has been on my mind for decades is this. A Turing machine is a model of deduction. It's universal deduction. That's what I'm after, right? That's what the master algorithm is. And I know it exists. And again, just as you can have a million different versions of Turing machines that are all equivalent, you can have a million different versions of the master algorithm that are all equivalent. And that's okay. The point is that first we have to realize that there is one. We have to prove what it does. And then we can refine it with these syntactic sugars and whatnot. And that's all good. But the main point is having, you know, gotten the universal induction machine, which I think we are pretty close to. But Pedro, I know the answer. It's Bayesian tensor logic. No, I just can't. No, if you're Bayesian, it is Bayesian tensor logic. This is a good segue because we are talking about reasoning and deduction. And transformers, they don't really reason, right? And I think of them as a kind of collection of fractured bits of knowledge, maybe with a little bit of understanding to levels down. But we understand many levels down. And when we do reasoning, what we're doing is we are respecting all of the constraints of this epistemic understanding phylogeny thing that we have. And that allows us to build new knowledge, right? Because you can build new knowledge. You can create new things when you respect all of the understanding that you already have. And transformers don't do that. But let's talk about how this works in tensor logic. So you have this temperature parameter. So for example, you could do something akin to deduction, even in an embedding space, right? And certainly with an MLP. And this is where I was a bit confused because I can appreciate that if we have a logical model, which is in the domain of certainty, we can do deduction, right? And then if we have something like an MLP and we learn the weights and we turn this temperature parameter up, right? So it's actually introducing some degree of randomness. Why would that be anything like the kind of logical deductive reasoning we do? Would that not just do what neural networks do now, which is they just look for similarity in some embedding space and the type of reasoning it's doing isn't actually semantically meaningful at all? I would actually say that of all things in the paper, this is the most exciting and important one is that you can do sound and transparent reasoning in embedding space with tensor logic. And how come? Why is that possible? And to just sort of like give the gist of it, here's the key, right? Is, you know, think of kernel, let's go to kernel machines for just a second. And like the gram matrix, right? The similarity matrix, what is it, right? You're in feature space and it's for every pair of objects ij, the dot product of their feature representations, right? And now, if you embed all your objects, we already know who they're like, you know, there's a matrix with the embedding vector for a j object, whether it's a word or a token or anything else, right? Now, I can do the dot product of the embeddings of two objects, right? And let's suppose that all you need to vectors to keep things simple, right? And now, what happens is that if I, you know, unless, let's, for the moment, let's say, you're not even learning the embeddings yet, right? Let's say you just have random vectors, right? Your embeddings are random, right? That's actually already useful for a lot of things, but of course, it's not where the action is, right? And now, there's the following very interesting property, which is the dot product of a vector with itself is one, but the dot product of two random vectors in the high-dimensional space is approximately zero. So your gram matrix, your similarity matrix will be approximately the identity matrix, okay? And now, what happens is, like, if I have a tensilogical that operates in this way, and then it has something like a sigma nonlinearity, right? Then, then, then what's going to happen is that it's going to clean out that noise, and it turns into the identity matrix, right? And now, I have all these rules that are just operating in a purely logical mode, right? They Boolean, it's Boolean-tenses going in, meaning relations, right? And it's Boolean-tenses going out, right? So that way, you can do pure deduction in embedding space with these embedding random embedding vectors, right? That's already something interesting, but now, let's say you learn the embeddings, which of course is the whole point, right? When you learn the embeddings, what's going to happen by trying to minimize the loss function is that the embedding vectors of objects about which you tend to make the same inferences will get closer, right? Because I mean, if I'm trying to find something about one object and that one is similar, like this, like, to, you know, the gradient descent to minimize the loss is going to make them, you know, is going to increase their dot product. So you're going to wind up with the similarity matrix that has high values for objects that are quite similar, right? In the limit one, in the diagonal, and has low values for objects that are quite dissimilar. And now, if you turn the temperature parameter, meaning the stiffness of the sigmoid, right? At one extreme at zero temperature, you have a step function, and the similarity matrix is discretized back to zero one. So at the zero temperature extreme, you have pure deduction. But this is very, you see what I'm going with this? I do, because I challenge it a tiny bit. So when, when we train neural networks, we think reasoning is good. When we are building, you know, let's say we'll use the Lego analogy. So we're building these blocks. And the new understanding tree that we've created is a good one if it represents the world in an abstract causal way. So I can see how you've, you know, framed this as deduction in the sense that, you know, you've got this Boolean operation and you can, you can build from it. But what if you're building on a sandcastle? What if the, what if the component, let's say it's an MLP component? What if it just doesn't represent the way the world works? You know, so very good. So like, again, there's more than one thing you can do, it tends to logic. One of them is you can just re-implement existing things like MLPs and transformers and whatnot. And if all that you did was re-implement them, it will have all their pros and cons, right? It's the same thing, just implemented much more elegantly, blah, blah, right? What I'm talking about here and talk about in, you know, in that section of that paper is doing something different. It's not an MLP, it's not a transformer. It's actually doing these things of like, you embed objects, you embed relations in a certain way that follows from the object, you embed the rules, you embed the reasoning, right? So this is a different process. What this different process allows you to do is that when you raise the temperature, you get to do analogical reasoning. You know, you know, Douglas Osstadek came up before. Douglas Osstadek, I think, would like this because it's an analogical, like, he has this whole 500-page book arguing that all of cognition is just analogy, right? And again, this is one of the schools of thought, like this is one of the tribes in, you know, in the master algorithm is reasoning by analogy. You do reasoning by analogy because what happens is you generalize from one object to an object that has a high thought product with it. So now, now I get to borrow inferences from similar objects. And the higher the temperature, the looser, the inferences, the more analogical inferences can be. But for example, and again, Douglas goes into this and some of this book. And any mathematician, like I just, you know, turned style the other day, I just heard him say this, right? It's like, mathematicians reason by analogy. They notice similarities between things. But at the end of the day, you need to have a proof. Intensal logic in this scheme, in this particular scheme of embed, you know, reasoning in embedding space, this is just simulate the kneeling. You start out with a high temperature being very analogical, and then you lower it at the end of the day, you have a proof. It's a deductive proof that is guaranteed to be correct. But you couldn't have gotten to it because the search places are large without the analogical part, right? Okay, but I understand what you're saying. So you can generalize reasoning outside the domain of certainty. But the question I'm asking, the reason why we have metaphor and analogy is there's this incredible process of evolution and intelligence, and it's led to the coarse graining of all of these concepts that we use in our language. And there's this rich, beautiful phylogeny that kind of represents the causal reality of what's happened. And why is statistical similarity the same thing as analogy? Oh, it's not so. Again, I skipped over some steps here. It isn't, right? So analogy, so the most powerful type of analogy. So kernel machines, in some sense, are the least powerful type of analogy. It's just, oh, here's a similarity or nearest neighbor, right? I have a distance function. That's not really where the action is. The action isn't what is called structure mapping, right? Structure mapping is this thing proposed by Deidre Gantner, where you solve a problem by mapping its structure to the structure of problems that you know, right? And the canonical example is Niels Bohr's, you know, model of the atom, which came up with by an analogy between an atom and the solar system. Then, of course, his descend, the planets are the electrons. It turns out to be a bad analogy, but it was crucial in the development of physics, right? And there's also this whole sub-fueled of AI called case based reasoning, where I'm a help desk. You come up with a problem. And I don't try to solve it some scratch, because I don't need to, that would be useful. I go to my database of similar cases, and I find one, and then I tweak it. So, structure mapping is an extraordinarily powerful thing, but it's this combination of similarity and compositionality, which kernel machines, per se, don't have. But, then, the logic does. The point in the logic is that you do have all the part of the kernel machines, but all the compositionality of the symbolic AI. So, again, the structure mapping just, you know, just comes out of the box. You don't need to do anything more to have structure mapping. And all the power of analogical reason that comes with it. Yeah, can I suggest a good analogy is to add lib? Do you think that's fair? It's like you've got the general structure there, and you can plug in parts into the blank spaces, and you get a solution, right? That's one mode in which things can function, right? You can also the whole process of structure mapping of case based reasoning can actually be very rich. I can combine, for example, two big pieces, but that's one example, yeah. Oh, yeah, yeah. No, that's fair. I mean, yeah, it has this nice nested structure, you know, property. Since while we're on this topic, let me ask you about something that I was confused about in a paper. So, I don't understand your connection between hallucination and deduction or determinism. Because of my mind, you know, I can set the temperature to gpt to 0, and it's still hallucinates, and I can have a I can have a poor deductive system that hallucinates all kinds of things. So to me, like those are separate, separate problems. Like what was I just kind of misunderstood? Very good. So precisely the problem or one of the problems with gpt is that it hallucinates, even when you set the temperature to 0, what the hell, right? I want to have a mode, right? Not I, but like every Fortune 500 company, if it's going to use AI, needs to have a mode where the logic of the business is just to bathe. The security isn't violated. The customer doesn't get light to it. So we got to have that orient in that they will not take off, right? And transformers can't do that. Tense logic can do that precisely because in this, you know, reasoning, animating space, you know, mode that I just described, if you set the temperature to 0, it does purely deductive reasoning. And I think this is what almost all applications are going to have is like, there are some rules that are the mathematical truths or logic that you must guarantee will not be violated. There are the laws, right? And those have infinite temperature. And then there's all these others that are more qualitative reasoning and like more accumulating evidence, maybe stuff that you mind from the web. And those, you know, those will have lower, those will have higher temperature. And that temperature parameters, you know, can be learned. In some rules, you're not others, right? So now you have this whole spectrum between the deductive and the more, you know, or even fantasize like truly hallucinating at the far end of the high temperature, right? But precisely the point that I'm making in the paper is that, you know, at with LLMs, the best that you can get at your temperature is still a lot of hallucinations. Then there's things like rag, but all they do is retrieve. And even then you still hallucinate, right? Compare, you know, tensor logic in this mode with rag, right? And it doesn't just retrieve things. It computes the deductive closure of your knowledge, which is an exponentially more powerful thing to have, right? And with zero hallucinations. Well, it is if the model represents the world, you know, because what does hallucination mean? Or actually what does slop mean? My definition of slop is when a creative artifact is produced by something that doesn't understand. So if I understand it domain deeply, that artifact looks incoherent to me because it is generated by a process that doesn't understand the world. And it isn't even the same with tensor logic that, you know, deduction is great, but if the model isn't a good one, then wouldn't that just be hallucination as well? Oh, absolutely, but let's let's make some distinctions here, right? The only claim I'm making here because that's the only one you can make is that tensor logic at zero temperature in this mode will give you the soundless properties that logic has, right? Soundless in the technical sense of soundness. All that means is that you only reach conclusions that truly logically follow from the premises. You don't see anything about whether the premises are valid or not. If the premises were hallucinated, so will the conclusions be, right? There's like, there's no, there's no magic there, right? But there is a very important property to have. Again, if I give to a transformer, a bunch of, you know, true facts, it still hallucinates. And that's what I can guarantee will not happen in tensor logic. Now, coming up with the true facts, well, that's a different part of the game. You can write them down, you can learn them, you can refine them, you never know for sure you have the perfect model. And of course, that's more the machine learning and knowledge acquisition part, right? So I do, I think, have a very important guarantee here of non hallucination, but it's not a guarantee that, you know, that the model that you're working on and, you know, came from the real world, that's the whole other, you know, neck of the woods. Who's going to adopt this first? How are we going to bootstrap this as a community? How do you see this progressing? No, very good. So, you know, the last section in the paper is, is discussing adoption and what needs to happen and things like that. Let's suppose that everybody greased tensor logic is a beautiful, perfect language and what we need for AI. Just for that reason, that would not be enough to make it take off, sadly, right? Because, you know, there's a very, you know, things get, you know, people are still using cobalt these days, right? I'd rest my case, right? So legacy, there's this irony in computer science or in the information technology and say, like, it moves faster than anything else, but at the same time, you know, things never die, right? You can't kill them. You can't kill cobalt, right? And I really do believe, you know, I like Python, right? I program in Python. It's very nice in many ways, better than Fortran for some things, et cetera, right? Even though it was never, or numpy, if you will, but you get the point, right? It's like, for AI, it's just a terrible thing. But like, I'm a Python programmer, like, you know, general is like, like, okay, your tensor logic is nice. I'm not going to rewrite all my code, right? Forget that, right? So what is going to make it happen, right? But now, we can look at what has made this happen in the past, right? And it's several things. One is that, for example, look at how Java took off, right? Java took off at the time of the internet because it was the language of networking. Allegedly, you could debate that, but like, people wanted to do things that it was, you know, very hard to do with, you know, things like C and blah, blah, and C, right? And so Java took off, right? And we are in exactly. It was the language of embedded programs and web browsers. Like, that was the only option. Exactly, right? So, you know, there's big arguments about this, but not relevant to us here. The point I'm trying to make here is, we are precisely at also very relevant. Why did languages like listen, pro-God, you know, fall out, right? Because they were better for AI than, you know, Fortran or C, or whatever, right? Or Java, is that like, they were niche languages. And the network effects of the more widely used languages and all their aspects just completely overrode that, right? We understand that very well. Now people didn't in the 80s. But now, we're in a different ballgame now. Now, the big technology, the center of everything, is AI, right? If you have a better language for AI, that is the one that is going to, you know, have the biggest users. And moreover, if you have a language that solves the big pains, right? To adopt a new language or a new anything, right? You know, a new app, right? It needs to solve some big pain, right? Is there a big pain that tensor logic solves? Well, hell yeah, it solves. Potentially, okay? It solves. All this is subject to empirical verification, but it potentially solves hallucination. It solves the opacity, right? Like, we're in this world right now where there's like multi-billion corporations and systems that are like, they're driven by this black box. And nobody. I know, I've talked with CEOs of big tech companies that say, like, you know, I can't sleep at night because I don't know what this thing is going to do and the people who trained it have left the company and who knows it right. So if we can make a dent in that, people will converge to it very, very quickly. Also, I think when people have the experience of how easy it is to use tensor logic compared to the big pile of stuff that is lies under PyTorch and whatnot, I think that they will actually be very, very motivated to migrate very quickly. And then, you know, like, and there's several things. There's like developing the open source community and vendor competition and whatnot. But, but, you know, like, there's. There's a couple of other important things here. One of which is the following. Tensor logic is ideally suited for AI education. It's one language in which it which has very little, you know, extraneous stuff. And you can just. And you can teach the entire gamut of AI very well and do the exercise. It'll be a language that the professors, the TAs and the students will like, right? And history shows, you know, going back to things like Unix, that if you have something like that that ticks off in computer science education, then people go to industry and say, like, I want to use this because it's what's good, it's what I like. And the generation later, it's, it's, it's what everybody is, is using. And one more thing is the following. There, you, the transition to a tensor logic from, from, from Python doesn't have to happen all at once, right? You can have, for example, an I already have, actually, another half, like, again, because it's very easy to do, right? You read the paper and you like, and you do that in the next whatever 30 minutes. You can write a pre-processor that just converts tensor equations into Python. And again, all it does is I want to unmapping between the syntax of, of tensor logic and I'm some, right? Then making things efficiently, as we discussed, is another matter, but from this point of view of, of developer, you know, a uptake, right? All it does, and there's a long, long history of people doing this with different languages, right? You're like, you have a pre-processor that, that, that lets you write in three equations, but then it converts you, it converts those equations into into PyTorch or Python, or just NumPy, let's say Python, right? And then you do everything else in Python that you did before. You don't lose anything, you don't lose any of this in code. It's just that a set of things. And in particular, reasoning, have not become much easier than they were before. And then once you have this little ballipule like, oh, but I can do this. And I let me have that piece of syntactic sugar. And before you know, people are like, well, I don't need all that, you know, Python stuff anymore. I just rather live in tensor logic world. So you said about AI for education, and tensor logic, it's a declarative language, which means it's, it's the what, not the how. It's this incredible course graining that screens off a lot of unnecessary detail. But is it, is it unnecessary, I guess is the question, like, do you think that people learning about AI should know about how the underlying things work? And certainly folks working at Google, they might need to do some, um, domain specific optimizations for certain components of the machine behind the scenes. Do you think that we can screen off all that detail? Great question, but actually, let me start by correcting something. Tensor logic like, like prologue and data log has actually both declarative and procedural semantics. You can look at a tensor equation. That's actually the whole beauty of logic programming in some senses. They're like, you can look at a tensor logic equation. It's like, it's an equation. It's like Einstein's equation. It's the statement about the world. But you can also look at it and treat it as a function call. The left hand side is the call. And the right hand side is the body, which is a bunch of other calls in a way to combine them. So you can, and in fact, most of the time, in my experience, that I've used tensor logic so far, I tend to use it in procedural mode. It's a set of equations. It's a bunch of statements, like you would have in any imperative language. So very important to have to bear that in mind. Now, but to the heart of your question, which I think is very important, when you're teaching people something, I mean, I would actually say this is the tragedy of computer science education. From high school to intro courses to the most advanced things, is that you want to teach them the beauty of what you can do and the essence of the algorithms and so on. But then you and particularly they, the students, they spend all their time bogged down in all this crap, all these details where you get the symbol on wrong and the program doesn't work anymore. And they hate it. And they decide that computer science is not for them or at best they waste 10 times more time than they should. So precisely the whole point of having the right abstraction is to avoid that. Now, so I would say this is one of the best features of tensor logic is to do that for AI. Now, but you also say correctly that like, well, a lot of the time you need to go beyond that level of abstraction. And for example, from a part of you, of efficiency and so on, and a lot of things, right? But I would say and again, you know, like we won't know until tensor logic is used widely and we see what happens. But tensor logic is a language that's some level. It's like C, right? It's very low level. The beauty in my mind, again, this gets expected multiple as I like, you can use it to say very high level things. You can also to express, you can also to express the lowest level possible computations, right? Like a tensor equation is something that you can map onto a GPU with almost no change, right? And then optimize the heck out of, right? Like in fact, you know, I've joked like with folks that envy that, you know, CUDA is a nice mode, but tensor logic could be the end of that mode. I sometimes feel like, and I'm not sure exactly how much money was spent on bigger and bigger transformers, you know, deeper and deeper, you know, wider and more data and whatever transform or more parameter transformers. But it's got to be a lot like a trillion dollars or something like that. And I feel like sometimes we've spent a trillion dollars to learn yet again lessons that people could have learned if they'd have taken certain, you know, basic courses in computer science. Like I'm wondering if you sometimes feel like that and what lessons, if any, you think people should have known before spending a trillion dollars. I violently agree with that. In fact, the paradox of the current moment in AI is that on the one hand, this is super exciting, right? This is what we've worked all our lives towards, right? It's like the dream is happening. I used to tell people, you know, when I went into grad school that like one day machine learning is going to take over the world and be like, uh, what? And I'm like, see, it is taking over the world there. Take that. So on the one, you know, on a more serious note, like transformers are great leap forward. And, you know, anybody who's used a chat body is like, wow, look at the things this can do. This is great. But at the same time, this sheer amount of like wastefulness and stupidity and ignorance going on is just unbelievable. It's like, why are you reinventing? Why? I'm, for example, I've talked with people that, for example, up on the ad that do the reasoning. And many of them are very good people. So I'm not trying to, you know, pick on anybody. But it's like, oh, what is reasoning? We need to figure that out. And like, and then they say a bunch of stuff that is completely wrong. And I'm thinking to myself, why don't you spend an afternoon reading a couple of chapters of Russell and Norvig and save a hundred billion dollars in wasted compute? Please just do that, right? And in a way, you know, part of what I'm trying to do with tens of logic is make things going that direction because the current direction is just too damn painful. And it's not just that it's painful. This is going to end badly, right? People are spinning, right? In a way, like, you know, spinning all this money on data centers is not wasted because it's not like the fiber that went dark, right? We in AI have an appetite for a limited compute, right? But they're spinning all this money prematurely on stuff that isn't ready for that yet, right? The demand is probably not going to be there. And we're going to look back on to then go like, wow, 99.9% of that compute was completely wasted because of a lot of the reasons that we've been talking about in clean like you didn't know how to do reasoning. So you brute force it, et cetera, et cetera. So like, you know, we got to change the direction of this ship. It's like that that well-known quote from, you know, Matt Damon and Goodwill Hunting, right? Like, you know, to paraphrase it, you know, you've wasted a trillion dollars on an education you could have got for a buck 50 and late fees at the library. Exactly. Exactly. Well, Professor Pedro Dominguez, it's absolutely on it to have you on the show. Thank you so much for joining us. Thanks for having me. Thank you. Oh, it's a pleasure.

Podcast Summary

Key Points:

  1. Pedro Domingos is a computer science professor at the University of Washington and has been researching machine learning for a long time.
  2. Tensologic aims to unify different AI paradigms into a single solution.
  3. Tensologic introduces a new language that combines tensor algebra and logic programming.
  4. Tensologic offers automated reasoning, efficient syntax, and scalability on GPUs.
  5. The language allows for a universal approach while providing the right level of abstraction for AI tasks.

Summary:

Pedro Domingos, a computer science professor, has been working to unify various AI paradigms into a single solution, which led to the development of Tensologic. Tensologic introduces a new language that merges tensor algebra and logic programming, offering automated reasoning, efficient syntax, and scalability on GPUs. The language aims to provide a universal approach while ensuring the right level of abstraction for AI tasks.

By unifying symbolic AI, deep learning, kernel machines, and graphical models, Tensologic presents a comprehensive solution towards achieving the goal of a master algorithm in AI.

FAQs

Tensologic aims to unify symbolic AI, deep learning, kernel machines, and graphical models into a single representation, providing a unified solution to AI.

Tensologic offers automated reasoning, compact syntax for tensor equations, efficient implementation on GPUs, and the ability to handle symbolic and numeric operations seamlessly.

In Tensologic, logical operations like 'or' are represented through tensor equations, enabling a more streamlined and comprehensive approach to symbolic and numeric computations.

Yes, Tensologic can be used to implement models like transformers in a concise and efficient manner through tensor equations.

Yes, Tensologic is seen as a step towards unifying various tribes in AI by enabling the composition of different modalities seamlessly within a single language.

Tensologic's abstraction simplifies the representation of complex operations, enhances efficiency, and allows for a unified approach to symbolic and numeric computations.

Chat with AI

Loading...

Pro features

Go deeper with this episode

Unlock creator-grade tools that turn any transcript into show notes and subtitle files.