Live CEOing Ep 820: Language Design in Wolfram Language [Variables]

Transcript of a Wolfram Language design discussion (Live CEOing Ep 820) led by Stephen Wolfram with several participants. The group debates what a “variable” means in Wolfram Language, roles of variables (handles to expressions, formal/algebraic variables), conflicts between common single-letter names and built‑in symbols (E, I, N, C, K, etc.), and practical UX fixes: formal-variable glyphs/ligatures, autocompletion behavior tied to session/notebook use, coloring/visual cues, and handling of subscripted/indexed variables. Proposed strategies include: offering formal-variable completions when a formal symbol appears in the session/notebook; ligaturing E/I/N to distinct display forms when typed; providing script/alternative glyphs (e.g., script E) as autocomplete options; localized names via Module/cell context; and possible formalize utilities to convert generated symbols. The discussion records prototype testing, kernel/frontend mismatches, and next steps: further design with Front End/User Assistance and LCC.
Chapters
Hi everyone. Welcome to a Wolfram language design discussion. We are going to talk about a knotty topic which is what is a variable? And let's, let's start filling out some of what I think we should be talking about. Okay, so this is the result in part of people saying, hey, I want to. There's several different things. How can a variable be named? I might want to make this bigger. How can a variable be named? Do variables have, do variables have values, etc.
I don't understand what those questions are.
Okay, well, let me, let me give some examples here. So actually let me just make roles of variables. Okay. One role is a handle to an expression, for example, in module.
Right.
That is the, the category that I have as something that can have an own value.
Okay, Right.
And if you open, if you opened up those sections, you'll see that, you.
Know, I actually already figured this out. Good. Okay. All right. So another one is in a sense what you are thinking of. You know, there's an algebraic variable that never has an own value. I think there's a, you know, for things like axiomatic theory, we have.
You.
Know, we have some ugliness here because we're using these formal variables because we want things which can never have values because they are in a sense intermediate between these handle type things and things like, you know, for algebraic variables, we can imagine in many cases that we actually do want them to have a value. I mean, if we say solve, you know, X squared equals Y for X, we might very well want to say, you know, Y is 7 and what's X?
Right. And, and certainly, I mean, I think a more common example is, is, you know, with DSolve, where you might actually assign that solution to a variable that you then use as a function in.
Further computation or alternatively even just saying plot something where you're effectively temporarily assigning values. But you never want to do that here.
Correct.
Those are pure sort of formal variables. I mean, we've had endless conversations about formal variables and that's what led us to these dotted forms. And we have, you know, we've done that as a kind of morphological, you know, this is a morphological conveyance of meaning, not a syntactic one even in sense that we're changing the actual symbolism to, to do this. Okay, let's talk about problems. Okay, here's the problem. People want to use E as a variable. What are some, okay, let's, let's list problematic variables problems. You know, one is, you know, collisions between common variable names and built in meanings.
Yep.
That's. What's that?
So that. Yes. Right. So that'll be ein.
Yeah.
Possibly PI.
Much less likely PI. But you know, you don't really know. I mean even C has a built in meaning for us. I mean, which ones? Actually if I just do this, let's say two upper case. This is something I should know, but I don't. To uppercase of Alphabet. And let's now say to expression of that. Oh, look at that. That's exotic. And now let's say. How should I do this? Let's just. This is going to blow my system up, isn't it? If I say.
Well, did you want.
You might just.
Right, yeah. That's what I was going to suggest. Map context across those symbols. Right, So C, D, E. Right.
Say select percent, select in this.
Yep.
What's going on with I?
It evaluated to complex 0 comma 1. So it's not a symbol. So it doesn't have a context.
Makes sense.
Oh yeah, I didn't think of those. Well, D, we forgot here.
Right. Because we were thinking of things with.
Okay, yeah, so we've got a bunch of. I mean, I'm just curious here right now.
C and K. C and K don't have, you know, up, you know.
Are.
They protected or not?
I believe C is protected and K is not. But I wouldn't swear to that off the top of my head.
Okay. So none of those.
I. I don't know about K, but I was going to say that CH is because alpha has to work around that.
Ah, the. Okay, so that's one problem is people wanting to use those letters as names of things.
Right.
For which in my opinion, and well, certainly my solution, which I, I feel is. Is pretty good is right. You use an E in, you know, one of the other E's. Right. You use, you know, script. E is probably what I use more common.
Or let's imagine that we had an auto. I mean just, just in terms of the use another E idea.
Yep.
Okay. You know, that will be helped if when you typed E, you know, you got an autocomplete here that gave you the fighting chance to use another E. Not clear what E we'd want to recommend, but. But that would be a place where we could insert other E nests, so to speak.
How do you know if it's A? I mean, is it just when someone says E equals? I mean otherwise they might mean E. Yeah, absolutely.
But that means that we could still have an autocomplete that contains the ordinary E. You know, paren the. You Know, the little. This E. You see what I'm saying?
Right? So basically you want to break the rule that we need the two letters before we show a completion menu. And presumably the first completion should be just normal E and then the second and maybe third completions are other ease. And you know, and then.
The first E could be, you know, what you could have in that menu could be E. And then, you know, something like. Well, that's wrongly presented. But you know what I'm saying that E and then some, you know, formal E. I don't know, that may not be the right. Oops, formal capital E, whatever it is. I don't know whether that's the right thing that we want to recommend, but you know what I'm saying, Right, Yeah.
I mean, like I said, I mean. Right. And we, I think we should definitely include like, you know, script E or some such, just because that, that, that is functionally equivalent to a normal variable. Right. It's not protected, it's in Global. Yeah, etc.
I agree, I agree. But I mean, I think, my point is I don't know if this is the right solution. And I think people will be unhappy if they can't have a formula where things look as if there's just an ordinary E there. And. But I think, I think, I think traditional form. Yeah, go ahead.
Yeah, but I would, I think people would be equally unhappy if they, you know, copy and paste it in something that looked like E and then it didn't work, it did not have the value 2.7, etc.
Okay, let me make another suggestion here that there is a form of E that is, for example, I'm not going to make it real, but something like this. I mean, that, that's not really the what I'm suggesting, but you know, some.
Sure, yes. Style. Right. So. So we have a, you know, variable E character which look. Which is the same, which matches the E of the surrounding font, but is marked somehow as not being normal E. Right.
E variable or something like this.
Yes.
Now know that raises the question that instead of formal A and things, we could have something that's, you know, a variable. Bad name. But you know what I'm saying? Which is stylistically, you know where. Because we didn't consider that for some reason where we were doing the things with dots and so on. Why didn't we consider that having it simply stylistically different? Because we, we've increasingly.
Well, I think part of it is that you. I mean, part of it is that it. Right. That is sort of a Really? I mean, if we're going to have a whole family. Right. I mean, the formal ones are system and protected. Right. They're really quite different. And so having. Having it look different was I. Is, I think, a good thing also. I'm sure, you know, you know, we've gotten sort of less careful about ambiguous input, but, you know, we wanted things to be unambiguous.
Well, I mean, if I say, what the heck. Great. Well, this is a broken version. But. But that's. What are you.
What are you trying to control?
Equals. And it's just totally broken.
Yeah. Is that a Prototype?
Ooh.
And 14.0.
That's the kernel version.
Yeah. So it may be some sort of mismatch between your kernel version and the front end, which is still a bug, in my opinion, but not quite as horrible.
But we should note that. Okay. In any case, what am I saying here? So what I was trying to say was. You know what? I'm going to get rid of this for a second. Okay. Let's try this again. What the heck? That's so weird. Let me try a different window. Oh, my gosh, this is totally weird. Oh, sigh. Okay, well, anyway, let's see what happens if I. Okay, whatever. I don't understand why this is happening, but you know what I'm going for? I'm. I'm making a. A quantity which is now displayed differently. Right, Right.
If you're.
Right.
If you're now using a 14 one. Right. Well, yeah, you could just type it in.
Right.
I was going to say, if you're actually using a 14:1 kernel now, you could also use equal bracket.
Indeed. I'm just curious to try it. Okay, that worked nicely. Good. We've got an upbreak, you know, control equals. But anyway, this is another case where this is something different. Right, Right. And now we've got this metaphor of equals. Whatever. And it's an interesting question whether, for example, if we do so. If we do that actually. Okay, so escape. A escape is an alpha.
Yep.
What is escape? Escape. A escape.
That's formally.
I didn't know that worked. I'm sure I invented that, but I didn't know that worked.
I'm pretty sure you insisted on it.
Well, it sounds sensible to me.
It used to, in fact, that you can put the dot either before or after. Because it used to be one way, I think at the end, at least I think it. Oh, no, it used to be $. And then you insisted that we add the dot form.
Okay.
Yeah.
The docs mentioned $ in addition to mentioning dot, I hope. Yes, they do mention dot. Yeah. Okay. Okay, let me mention another thing. Okay. So this, the other thing is the famous. The famous famous variables like x sub 1 or worse, x sub I. Okay. We almost put this in to version three, but we backed it out at the last minute because we thought it was semantically troubled.
Well, it's also extra semantically troubled because we think like index now.
Well, what happens if we just say symbol of this? Okay. I mean, I think what we had in mind was could one package this up into something?
Right. So they're. Right. With the notation package. Right. There's. There's like a symbolize thing you can do with the, with the palette and probably also with the syntax, although I don't know the syntax well enough. Right. And it sort of creates an equivalent symbol and. Right. It sort of. I think it interpretation boxes it. So it's backed by a symbol, but you have something that looks like X sub I should like.
Should I load this?
Sure.
So that. Is that what I do?
I believe it's notation backtick.
It should be a packlet of Modern times.
Okay. I mean, there is a ref page if we. If we really want to dig into this. It's been a while since I've played with it, so. And, and Jason would be the real expert.
Yeah.
As the maintainer. But. Right. But I. Yeah.
I'm just curious if this. But it's worth remembering that this does work. Right. Although what it's done is something kind of bizarre. Right. And if I say characters.
Then you'll see a whole bunch of characters.
Then it's a big horrible mess.
Yes.
I wonder if that's right, by the way. The characters.
I think so. I mean, we've talked about adding a mode where it changes the interpretation, but I mean, that is absolutely right. If you want to know the byte count or the string length. Right. That's absolutely what's there.
Right.
Okay. So. But, but let's talk about X sub I and all these things. I mean, why do we not provide that as a blob, so to speak, you know, allow people to just say symbol of X sub I.
Well, for one thing, you don't say symbol of X, you say symbol of string X. Now if you want to say.
Okay, that's what I mean.
Well, I mean, right. If they think of the X and the I as two separate things that can be sort of independent, independently pattern matched.
Right.
They're. They're just not going to get that right.
Right.
Like, I imagine that the thing people want to do is they want to say X sub I, you know, colon equals I squared or something like that.
Right. Which is a separate issue. And.
But, but by the way, because you keep writing these subscripts, right, indexed of X comma I.
Right.
But what happens if I say colon equals I squared?
Well, I don't think you can, because index is protected.
But what actually, what if X equals. What if X equals a list? Can you say index of x comma 2 equals something like part.
No, we didn't hook that up.
Well, for first, you need to make it. You need to make X list, right? I define X. But it sounds like. Yeah.
Right. So index of x comma 2 will now evaluate to B.
Right? But if you say equals five, just, just try equals five, it sounds like it probably won't work, but very fine. But it could have worked and it might maybe work in the future.
What's the difference then between indexed and potential? It indexed is. Is a, is a symbolic thing.
It doesn't complain if it, if it doesn't work, basically.
Right.
And so. Well, for one thing, I don't think it takes, you know, all 1700 different syntaxes that part supports. But yes, it's intended, you know, for symbolic computations. Right. So you can, you know, right, if you have some sort of vector equation and you want to write it as a bunch of scalars, right? Then you have indexed of, you know, y comma 1 and y 2 or like in. Especially in region functions, you'll see this pop out a lot that you know, it. It gives results in terms of indexed because you have a, A, a variable that's a vector variable.
Can you give me an example? So if I, if I make a region.
So, so do. What's, what's a good example, right? You want a function where. Where. It's where you, where you say something like XY is, you know, X is in, you know, disk bracket, bracket.
Right?
Okay. Well, I mean, so if I say random point. No, what do I want to say?
You want to like, do an integral over a region, right?
So, yeah. So one example where you type, where you type this in, right, is you.
You.
You do integrate of indexed of x comma 1 plus index of x comma 2. And then you say.
Well, I could just say index of x comma 1, x is an element.
Of circle, bracket, back or that, right?
Yeah. By the way, this is used a lot also in like all the convex optimization functions and stuff.
I was not familiar with that. But that's nice, Right?
Okay, it's nice and symmetrical. So once you full simplify it. Right. If you, if you move, if you move that regular pentagon off of, you know, being centered on the origin.
Right.
You'd get a non zero answer there, obviously.
And I'm sure if I did this. Oh, no, maybe that's obvious. Doesn't have symmetry in that direction. Who knows? Oh, it's. That's at the centroid. Yeah, yeah, yeah, yeah. Okay, so where are we going with these things? So you're saying X sub I to be a variable. What? A possible solution would be to remove the protected attribute like we do with derivative for the same reason.
Well, for index.
Yeah.
And.
And subscript. Right. Subscript is not protected. Precisely. So that people can write things like, you know, x sub 1 equals 7.
Honestly though, if indexed were not protected, I, I can see so many weird things like what we just did, where you say, you know, indexed of. You have X as a list and you say index of x comma 2 equals this. And then whenever you access it with indexed, it works fine, but when you look at X on its own, it's not fine.
Oh gosh, how do I even back out of this?
You un. Unset it. Right. So equals dot.
Yeah, but I mean, for example, if that was. Had an up value that some kind of weird up value where that associated that value with X, that would probably help things.
Maybe that's what I was going to say. I don't know if up value is the right way to do it, but that's what I was going to say about the inconsistency with part is you can assign to part. And so I might expect assigning to indexed to be reflected back in the original. I guess that's more difficult though, because that, Because. Right, because if the. Yeah, yeah. As long as it's indexed of X where X is a list, as opposed to indexed of a list. Yeah.
Anyway, I mean, exotically, I could do this. I could say indexed of 55 comma I. Oh, that's interesting.
Right, because it can tell that that's clearly an atomic thing.
Okay, Okay, right.
So, so, so, so I mean, let's just do the experiment. I mean, I'm sure this will work, but you know, do X by carrot equals seven.
God, I use that syntax so rarely.
Yeah, right. And so now it. Now question mark. Yeah, and now if we clear X, then we'll clear that. I mean, of course the problem is that if, if we, if we did that, then.
Oops, Oops, what's going on here?
Did it also. It's an Abundant value for I. Yeah.
We, we, we should have used tag set. Okay, right, right. So, so there's a question of which of the two arguments do we associate it with? And you know, what happens if the first argument, if both arguments are sort of complicated things?
Yeah, well, I would imagine that the default. Okay, now we say clear X. Okay, fine. Okay, but let's. Is this everything that we are dealing with? So there is the notion it is useful to have formalized variables that can never be assigned a value where you just don't have to worry. Yeah, I mean, the real issue is.
Right, so, so, so, so, right. I mean, you know, I personally don't feel like we need a full Alphabet of these variable variables that are characters that are just like normal variables. I mean, we wanted a complete set of formal variables because. Right. We needed a complete set. They're special, they're protected, you can't assign to them, et cetera. You know, if we're going to have things that are just like ordinary variables, I feel like we should really only set those up for the things that have conflicts.
Okay, but look, look, this is the main issue. You are generating a thing. You're generating a thing, let's say axiomatic theory. Okay? The last thing you want is that axiomatic theory, which has, which needs to use variables to describe itself or for that matter, you know, a sum or an integral or a, or a parametric curve or, you know, let's just see an example of that. Let's say I say, oh, goodness sake.
Would you mind putting the cell expression for that in the chat just so I can take a look and see if there's something obvious.
Okay. Anyway, so what's a, I don't know, cycloid parametric equation. Okay, so that's another case where in principle they didn't need to be formal variables. By the way, I consider it a bug that those spaces don't look right there. And perhaps that could be passed on, please.
Yeah, which, which spaces? I'm sorry?
The ones here, they look small. They look like they're multiple thin space multiplication spaces.
Okay.
Okay, but the main point is, the main use case here for formal variables is you're putting something out where you profoundly never want its things to have values, but you don't know. You know, you're just plopping it out there. You don't know whether somebody already assigned values to A and B. Yep. And it's kind of, you know, another strategy, you know, what other. But then it's super annoying, like I've been. I'm annoyed every single time when I have to. I didn't know about this escape. A escape, but. Which is embarrassing. But you know, I'm, I'm annoyed every time I have to kind of type one of these formal variables. So for example, you know, if I type A, I mean ideally you don't.
Have to type them very often. Right. Like when, when do you normally have to type these?
Okay. A very common case.
It used to be my full time job to type these.
What's that you.
My full time job to type these. And the dot for alpha entity property tables.
Right. Yes. Well, when we were working on. Right. The, what was it? Axiomatic knot theory or curves.
I was doing topology before that. Alpha also had function spaces. Topological spaces, continued fractions.
Continued fractions. That's the one I was thinking of.
What was the case for that?
Right. We had a project.
No, I know what we did. But what was the case where you had formal variables?
It was.
Right. The statement of every theorem. Or if you had properties that were curves or functions. Right. Then we would, we would express them in functions of formal variables.
So we've got two ways to do this. Okay. Actually it's sort of interesting. Okay, so another approach would be so localizing variables, localizing names. Okay. So one approach that we have is, you know, module where you name the things you want to localize abc, blah blah blah.
Right.
Now, I mean if what you're returning are actually functions, right. Then you don't need to use formal variables. Right.
Because indeed because they're already localized because they've been named as, you know, localizing names. We can say specify what names we want to localize. That's, that's one strategy. So strategy two, which we adopt more rarely is localized names by cell, Eg, with cell context. Right.
And that's typically more often cell group. But.
Yes, right, But I mean, so another possibility which might be crazy, you know, strategy three, This is probably crazy, but I'm just going to say it anyway. See, I mean we've, we've got WFR things that, that will make formalized versions. Don't we have a WFR that does this?
I'm not familiar with that. But Ian Christopher, are you familiar with such a. Bob was supposed to be here. Maybe he's out. He, he, he, he would know.
I don't know wfr. I know the alpha code base has utilities for that.
There is one. Formalized symbols. Interesting. And there's an unformalized as well.
I mean and, and, and, and oh okay, so it didn't formalize the plus, which I guess is good.
Yeah. Well, let's see what happens if we say something like this plus N.
Oh.
What happens if we do plus?
Right. So I'm guessing. So type in an explicit global backtick and. And see if that makes a difference to the symbol. I wonder, to the resource function. I wonder if it's checking by context.
Yep. Okay.
Which for formalize is. Given the functionality of N. It's a little bit silly for formalize, but if that were a D, you know, it's not at all obvious that you would want to turn a capital D into a formal capital D. Yeah, well, except.
D is rarely an output. Capital C, different story.
Right.
Or.
Or capital O.
Indeed. Okay. But this is another strategy. That essentially is. I mean, this might be something worth putting into the system because. Okay, if formalized, what kind of evaluation is it doing? I mean, in other words, if it was a lexical thing, you could say formalize of blah, blah, blah. No, I don't know. That doesn't make a lot of sense because you might want something which dynamically returns something and then you formalize the results.
Yeah, well, yeah, let's just, you know, do a plus one plus one in one of those. Is there any holding or.
I don't think so, but let's try. Nope. Yeah.
What does it do with the multi symbol variable name? Every one of them gets formalized.
Nothing. Nothing. All right, again, let's review. Okay, where do we want to use this? We want to use this in places where we are generating a variable that. The most common cases, we're generating a variable where we want to be sure that it does not have a value, but we also would like it to be a variable that is readily typable. Now, here's the thing I can imagine. Let's say you have a formal A. Yeah. You know what we should be doing? Yeah. This is stupid. We should have done this long ago. Okay, assume you have a session that has a formal A in it. As soon as you type A, you should get an autocomplete that allows you to. That allows you to type the formal A. We shouldn't volunteer that when there hasn't been a formal A. You see what I'm saying?
Well, first question is what? What's a session and how would the.
Well, we do that right now. We do it right now. The autocompletes are affected by what you have typed previously in the session.
Sort of very, very mildly, but they are affected by it.
If you have an Obscure function. And like when I've defined look even very directly.
Right. So it's not affected by what you've typed in the session, it's affected by what completions you choose.
Oh, there it is. AZA.
Well, yes. So when. Right, because that. You've created a new symbol in the global. In the. In the current context. Right. When you use a formal A, you've not created a new symbol. Those are created at kernel launch time in C code, no less. And so the front end has no signal that you have typed in an A dot or that it's been used in some way because that symbol has always existed.
Okay, but I think it could have such a signal. It's not a kernel signal, it's a. I mean, look in the. I'm a little surprised. Is this. Is this 14.1? Yeah. Why isn't this lighting up with similar named symbol. You know why? It wasn't that symbol. I thought that lit up in code.
I have honestly no idea what you're talking about.
It's only. Right.
Oh, yes. If you click in something, it will show multiple. And you're talking about semantic highlighting. Right. So. Yes. So now create an input cell that's only per cell. So if you have an input cell with two formal A's in it or whatevers, and then you put the cursor next to 1.
We can see that right now.
Yep.
The A's are lighting up.
Yep. It's a little hard to see through the zoom, but I do see it.
Yeah. Right. Okay, Let's see. Okay, so look, this thing, which we don't have John or anybody else here to speak to this. I think John is at a Scrabble tournament.
Oh, I think he did mention being.
Out as he does.
Yes.
See if he's the world champion this year. The. Anyway.
Yeah, he's out today, so he must be at the Scrabble tournament because I know it is about now. Ish.
Okay, fair enough. Okay, so.
Yeah, I. I think. Yeah, I mean, certainly talking about, you know, whether we can. Yes. I mean, I think obviously that's a discussion we should have with John about the specifics about adding formal A to the completions at some time. I think the other thing that I would like to nail down is, you know, do we want to add these. These variable characters and how many of them should.
How many. But I don't know what. I don't know what we actually do. So I mean, in other words, if we have. And. Yeah. And how do people know when they just. Okay, so Once. Okay. There are really two modes. One is there's already been a formal A in a session. Okay. And the other is there hasn't. So similarly with an E, if there already has been a modified E in a session, then you can aggressively ask to autocomplete to that or substitute with that if there hasn't been one. So what are we going to do? It's going to be like E variable or something.
Sure.
And it's going to have some different rendering. Like it's going to be a slightly different. Well, actually that raises the question. Ok, which actually makes more sense, that maybe E when you type it in should actually turn a slightly different color and that the E that you get as an E variable should look just like the other letters. That seems to make more sense to me because the E here, I think that's a much better idea that E.
Is a different color than like F, right?
Exactly. Yes, it is. E is black. E is black because it's a symbol system symbol on F as an unknown thing.
I understand, but when it appears in A, you know, if I go EF like this, well, that's going to look completely different. Right, right. But let's say, I say. Yeah.
Right. But we don't color things in output by, you know, we don't color symbols differently in output.
Well, unless they're things like quantity symbols.
Well, that's. No, that's not a symbol.
Right.
You have. Right. We're coloring the contents of the quantity in the quantity color. But what you see right is this is a number and a string which is quantity colored.
I think we've painted ourselves into a corner here. Okay. So the question is what is the best way to get out of the corner? And to me, let's take this as a hypothesis, okay. That for those variables, for those symbols, wherever they were up, up here, right. The controversial symbols, that every one of those in output is a slightly different color in input and in output is a slightly different color. Like, like a coding literature.
I, I really, really hate that.
I was gonna say the E and the I are already double struck.
Yeah, right.
There are the. And the I are solved for output. Okay.
Yes.
The others are not. But. So as soon as you see. So what I'm suggesting is you type in an E, okay. And it's a slightly different color, but there is an E underneath that is the E variable that is just black, black or whatever it is. Blue, blue, blue, whatever it is.
Well, until you assign to it, in which case it turns becomes black.
But, but, but then Then, then look in the autocomplete, we could perfectly well say E paren variable.
You know, I, I think we would. Well, I have, you know. With what. Yes, with having, you know, the, the code assistants bring those up and having those descriptions. I, I just feel like suddenly coloring certain system symbols differently from all other system symbols is going to be very confusing.
Fair point, fair point, fair point, fair point.
So, and, and certainly I would want, you know, I would really appreciate John's input on.
Okay, let me, Let me make a different crazy suggestion.
Okay?
Okay. In the department of crazy suggestions. Okay, let's imagine that E, as soon as you type a space, turns into the, the exponential E.
Right.
In other words, as a code ligature. Now, I mean, the whole point of that would be you're going to get, you know, if you're typing this in and you think you're typing energy equals, blah, blah, blah, it's going to look really weird and you're going to realize something went wrong. Right.
Yep.
I kind of like this idea. And if you backspace it across it, it'll just turn into a capital E again. We have, we have the technology, as they've said.
Well, I mean, when you backspace.
If.
You type, you know, like hyphen greater, you know. Right. I mean, it stays ligature.
This, this would work fine. If you type E equals. Okay. And that ligatures to escape. Escape. Whoops. Escape, ee, Escape equals. And then you backspace the equals. There's no problem with that. Right.
So.
So the other thing. I haven't tried this. Can you try typing a capital in just. Okay. Because I think N is the one that you, you know, created a version of in global earlier. And so if you have like, you know, create global backtick sign.
You're going to completely destroy my session here.
You haven't used.
Sorry.
Right. And so now when you start typing sine as input.
Where is the red? Yeah, I'm surprised. Right. There should be like, red coloring when you have conflicts on context path.
No, there. But there's no conflict because it was explicitly. Oh, you mean when he typed in that new cell. Yes, yes, yes, I agree, I agree, I agree.
Which one am I getting here? That one. Why didn't I get the global one?
Because context path has system first.
I don't.
Yep.
Is that true? Yes. Okay. Okay. But, but by the way, right, My.
Point was, this is crazy. We have a mechanism by which, you know, when you have. I mean, by which the context is shown in parentheses next to the symbol.
Oh, my goodness. John has just Shown up. Are you not at a travel. At a Scrabble tournament? Oh, okay. John, are you not at the Scrabble tournament?
Yeah, I registered and I'm in my hotel room.
Okay.
It begins tomorrow.
I see.
Okay, well, we're talking about some somewhat interesting ideas in my view. Okay. This is a very basic one. If I've got a sign in a different context, surely that should be in the autocomplete, the sign with the other context.
No, that's not how we're doing contextual completion.
And just to be clear, they're both.
As you type the contexts.
Right, but, but the point, but the point is that these are both on context path.
I think we should discuss this, but I think that's not for this meeting. I think we should discuss that in user assistance. So who's PMING here? Is it caller?
Yep. Yeah, it's me.
Can you communicate that?
Yes.
Okay, just to summarize for John, we are. We've got two things we think we want so far. One is as soon as there's been an A dot, a formal A that's occurred in a session, that when you type A, just the single character A that you should get an autocomplete that includes a dot, Silent. Well, okay, so then if John is not.
Sorry, a dot for what character?
Right.
If I type in A, if there's been an A dot that appeared in.
The session, and by a dot he means formal A.
Just to be clear, if such a thing has, has appeared in the session, then when you type an A, I want to see an autocomplete that includes an A dot.
That includes a formal.
Yes, yeah, yeah, yeah, sorry, formal A.
Don't, don't, don't say A dot. It suggests you're typing a dot somewhere.
Yeah, yeah, yeah. Right. Ok. Okay. Formal A. Okay, Then these are the symbols.
So that. Yeah, and I mean, let me, before we go on to that, let me just raise a question. So if I open a notebook that happens to have a formal A in it, does that count as it having been in the session?
I would think yes. I think at the drop of a, of a formal hat, we should assume that A might be a formal A. But you know, because most people will never see a formal A anywhere.
Okay.
John, does that sound like a reason, like a doable thing?
Doable, Yes. I mean, I assume that we're talking beyond 14:2 because we don't have enough time for the 14:2 features that we need to do yet alone.
Right, okay. We're talking about the future. Yes, don't worry about which. We're trying to solve a. A collection of sort of some chestnut. Old chestnuts. We're trying to. Finally. I don't know what you do with old chestnuts. What do you do with old chestnuts? Do you eat them? Probably not. How do you. How do you dispatch old chestnuts?
I think it's a bad metaphor. Given that I would consider throwing them out. So that's probably not the metaphor you want.
Okay, fine. The. Okay. The second thing is we're dealing with these variables, and when somebody says E equals 5.6 and then they get some message. My suggestion is why not ligature E, capital E. When you type an equal sign, just turn it into the exponential E and people will immediately see it's wrong and know what happened. And then with the E, we would have an autocomplete that gives you the E variable, which has a different. Slightly different visual appearance. That is something you can use as a thing that looks like capital E. Does that make any sense, John?
I'm just thinking about the I. I. I'm not.
And then just to be clear, he's not saying that, you know, they're right. There's nothing special about equal sign. He's suggesting that, you know, the moment you have a token capital E and the cursor is not next to it, that it somehow turns itself into an exponential E. Yeah, I.
That's. That's the interest. That's the part that I was going to raise is. Yeah. The cursor not being next to it.
Okay. Anyway, that is just a thought. I mean. Okay, but let's see. What about the other variables? Go ahead.
I was gonna say, while we're having, you know, thoughts along these lines, you know, it's probably worth considering going the other way as well. You know, if you type lowercase E that it offers to give you the E. That is 2.7.
Why not? Yeah, why not? It's a good idea.
Well, I can think of reasons why not.
What? That it's annoying.
When you type that, it shows up in a standard quintic.
What do you mean?
Ax to the 5th plus bx to the 4th, etc down to e. Sure.
So what I.
The point being that there are cases where E gets used for.
Oh, yeah, yeah, yeah, yeah, we know. But I mean, my point is, we're only suggesting, John, that there's an autocomplete that offers you the other E. Right.
So he's. He's. We're. Yes. Before we went to this ligature discussion and we were Saying, well, we need, for these guys, we need to have a E and then an E variable or capital E variable to be consistent with our naming conventions. Okay, and, and which is somehow different from a normal E which we haven't decided upon. And also that we should break the normal. You must have two characters rule for these disputed characters so that, you know, if you just type in a capital E, you get a pop up and then you can select between the E that's exponential E and the E that's a variable and maybe another e or 2 just for good measure.
In, in that list that you're showing, I'm not understanding K and N. Can you explain those to me?
These are things which are not in global context. N is like N of PI and so on.
Right. So, okay, you're not suggesting that they are treated uniformly. You're just saying there's things we should talk about.
Yes, right.
And, and these are all candidates for having a capital foo variable character added because these are system context symbols that may have properties that lead to badness if you try to use them and say solve. And obviously most, most of them or all of them are protected, so you certainly can't assign to them.
Okay, but bad things can happen if you do all. You know, I, people. I've seen people use N in all kinds of places where it really, you know, scares me. It's just going to blow up in their face somehow.
Yes.
But so what would happen is we type E, you type A plus or something and it ligatures into this E. And then the autocomplete for that E would contain an E variable which would look like a capital E more or less.
Would it contain anything?
Except that we're not sure yet.
I mean, I can see including like.
The scripts and maybe, although we might want to just suggest to people they just use E variable.
I know, Letting them know that they have, you know, different appearances, I think.
Is, well, look, I think single characters, you know, it could be the case that as soon as you've used a script character in that notebook that offers you script characters for either that single letter or all single letters.
Right, but, but for, I mean, for E and exponential E, where they're very different looking, that's fine. But for N. Right. They might want to choose something that's more different looking than whatever E variable.
I know we haven't talked about N. We talked about E and I. Okay, I think we understand ENI and what we could do with those because it's very clear. We could ligature them into Their, you know, into their sort of forms here. Right. And. But these other ones, you know, I mean, conceivably C and K. Don't C and K have display forms?
No, C of N has a display form.
I see. But we could conceivably ligature C and, And K. I think.
Perhaps, I mean, K doesn't have a display form.
It probably should have. I think those could be ligatured as a way to just clarify them. That leaves, you know, O is really not going to appear as a variable. I'm not so worried about that. I mean, it will be nice to do something there, but it's not really worrying. N and D D are both worrying. Okay, so N.
Well, N seems different to me because there, it's the one thing here that doesn't have an analog, that even a remotely similar analog in traditional math, at least not as far as I know.
That's true.
Where. Whereas D D is a little strange, but at least you can kind of say there's an analog.
Yeah.
We could replace it with the partial symbol if we wanted to.
Could we?
I'm not sure. I'm not sure if we could or not.
But no, I don't think we can because that, that, that's. This, that's.
But, but there is a traditional math discussion to be had at least. It may not go anywhere.
I mean, this is what we would be replacing. But I think that's.
I agree, but, but yeah, but I think the traditional form of D, when it returns on the value. Or I. Maybe that's D by DX and not partial D, but.
Or Y prime. But I think.
No, but no, no, no, no, no, no, no. That's. If. No, no, no, that is not D. That is derivative. Do hold of, do hold of that. See?
Yeah. Okay. Okay. A comment about N. The fact is that N is a hack as a name, you know, it would be better if it had been called numericalize, but it wouldn't have been better because we would have hated typing it all these years. Right. So having N do something a bit special like become bold or something like that would not horrify me. In other words, having an N, you know, the representation of the N that is numericalize, you know, when you see it in an expression, it's confusing to people because as, as John says, it's not a traditional notation. So having something happen slightly differently with it, you know, I just don't think will be terrible and it would avoid this confusion. And then we get to turn that N into the special N and then we have the capital N variable as a separate thing. I should probably get going, but I think we made tremendous progress here. I mean, this, this has been a chestnut that's been rotting for years, and I really think this is important progress. I think this is going to actually be a pretty reasonable solution because, you know, the experience we've had is, for example, in the, you know, a space B. Wait a minute. That's not an example. Wait a minute. Where's an example? Where's an example? We get a time sign. Oh, maybe it's on the F space G. Now, when do we get time signs? Why don't we get a time output? Oh, there.
Yeah, right. Because.
See, that's great because it immediately tells me this. I mean, I've used. I've. I've taken the hint from that a thousand times that something was wrong. Right. And I think this is a thing we've learned over the, you know, the last five years, 10 years or something, is that those kinds of hintings make sense. And so, for example.
Right. Although I, I will. I will push back on this a little bit because. Right. That is something where you would almost never intentionally type that. Whereas, you know, N of PI is obviously something that you intentionally.
Sure, sure. But if the N turns, you know, because we've got ligaturing these days that we didn't have in the past. And so, you know, if the N darkens up slightly or something like that, it's no big deal. It's just like, okay, ends just do that. But it gives you the set. But if you thought of it as, oh, it's a variable capital N, you know, you'll realize it shouldn't, you know, something's going wrong. I really like that approach.
Okay.
All right. I think we have a path here. Excellent. Well done, everybody. And I mean, the thing we haven't addressed is subscripted variables and making symbols out of subscriptive variables. But let's, let's not push our luck here.
Okay. I can hold that as a reserved topic for a future LCC agenda that.
Let's try and develop what we're talking about here in both LCC and User Assistance and see whether we can really crispen up a plan.
Okay. So you feel like we need another discussion in LCC about the six variables we just decided, or.
I think we just need to go through the details. I think that's more of a user Assistant thing.
Okay. Yeah. And I mean, I would have. Be happy to join User Assistance for if, you know, if that would be helpful in.
I think. Yes. Okay. And I. I also want to have an LCC plus John, etc and some user assistance folk about subscripted variables.
Oh, I'm always in LCC these days, so.
Yeah, we. We've just learned that you. You take things in a John direction sufficiently often that even if there's no specific John, that just having him lurk in case he's needed is a good thing.
Yeah, there was. There was some LCC meeting where you started making decisions about GRID with not a single front end person present. And I was like, that's not going to happen again.
Okay, fair enough. I remember that. Yeah. Yeah. Okay. Okay, Sounds good. Travel well, John. Talk to you soon.
Thanks.
More from Guy

Cheryl Strauss Einhorn | The Human Edge: Smarter Decisions in the Age of AI | Talks at Google

Rachel Glennerster | Innovation and the Center for Global Development | Talks at Google

Rebecca Winthrop | Rethinking the Purpose of Education in the Age of AI | Talks at Google

Dr. Robert Wachter | A Giant Leap: How AI Is Transforming Healthcare... | Talks at Google






