Streamlit's CEO Adrien Treuille on building blazingly fast and interactive tools people love

Adrien shares his journey from making games that advance science (Eterna, Foldit) to creating a Streamlit, an open-source app framework enabling ML/Data practitioners to easily build powerful and interactive apps in a few hours.
Angelica Pan

Listen on these platforms

Apple Podcasts Spotify Google Podcasts YouTube Soundcloud

Guest Bio

Adrien is co-founder and CEO of Streamlit, an open-source app framework that helps create beautiful data apps in hours in pure Python. Dr. Treuille has been a Zoox VP, Google X project lead, and Computer Science faculty at Carnegie Mellon. He has won numerous scientific awards, including the MIT TR35. Adrien has been featured in the documentaries What Will the Future Be Like by PBS/NOVA, and Lo and Behold by Werner Herzog.

Connect with Adrien

Show Notes

Topics Covered

0:00 sneak peek/Streamlit
0:47 intro
1:21 from aspiring guitar player to machine learning
4:16 Foldit - games that train humans
10:08 Eterna - another game and its relation to ML
16:15 Research areas as a professor at Carnegie Mellon
18:07 the origin of Streamlit
23:53 evolution of Streamlit: data science-ing a pivot and
30:20 on programming languages
32:20 what’s next for Streamlit
37:34 On meditation and work/life
41:40 Underrated aspect of Machine Learning
43:07 Biggest challenge in deploying ML in the real world

Transcript

Note: Transcriptions are provided by a third-party service, and may contain some inaccuracies. Please submit any corrections to angelica@wandb.com. Thank you!
Adrien:
The state of the art is often like, "I'm going to send you an email and just do a one-off exploration in Jupyter notebook and tell me the answer and paste it into a PowerPoint presentation." Like that's a lot of how the rest of the company interacts with the data science team and the machine learning team. And that's kind of insane. It's so inefficient. And so I think that the aspiration that I have for StreamLit it is that almost as a byproduct of existing workflows, the engineers working on those teams are empowered to sort of bring their work directly. Inject it into the entire company and allow the whole company to make decisions and predictions and stuff in the same way that they can. I think it would have a big, big, big impact, and it already is starting to.
Lukas:
You're listening to Gradient Dissent, a show where we learn about making machine learning models work in the real world. I'm your host, Lukas Biewald. Adrien is the CEO of Streamlit, and a good friend of mine. Before Streamlit, he founded Foldit, which is a famous crowdsourcing project that enlisted millions of gamers to solve real scientific challenges. He also served as AI Project Leader at Google X, and the VP of Simulation for the autonomous vehicle companies Zoox, and was an Assistant Professor of Computer Science at CMU. I can't wait to get to all these things with them.
Lukas:
I was kind of wondering how to do this, it doesn't feel like... It'll be just like talking to an old friend. But I think it's inevitable that that's what it's going to feel like. And I don't know exactly the best place to begin. But I thought it might be interesting for you to tell a little bit of the story of your career. Like I know that when you were younger, you're super into music, and you're a great guitar player, then I think you got into graphics? Now you're doing like a really interesting company. And you've done some deep learning. So how does it all fit together? Like what is the arc of Adrien's life?
Adrien:
Yeah, well, the arc is that I keep changing what I'm doing. Half of the time, because I realized that there's something else even cooler that I want to do and the other half of the time because I realize I'm never going to be good at whatever it is I'm doing right now. So when I was in high school, I wanted to be a guitar player. And I ended up going to this like jazz club, those kind of really hot in the 90s in New York called Smalls and seeing this like totally epic young guitar player named Kurt Rosenwinkel, who became very famous, subsequently. But at the time was a little less well known.
Adrien:
And I was like a high schooler who didn't shave or know anything. And I went up to him, and I was like, "Excuse me like Mr. Rosenwinkel, would you please teach me how to play guitar?" And he was like, "Yeah come to my place. It's like in Brooklyn, like tomorrow or whatever." So okay, so I go there, and he becomes my guitar teacher. And it was like, absolutely one of the most inspirational episodes in my life. Because here was someone who just lived in a musical dimension that I couldn't believe, basically. And I was so inspired every time I took lessons with him.
Adrien:
And I was like, "I can do this." I even asked him, "Do you think I could be a professional guitar player?" He was like, "Yeah, I think you could." At one point I was like, "Hey, do you think like.... How often do you practice?" And he was like, "About 12 hours a day." And I was like, "12 hours a day? Are you kidding me?" And he's like, "Yeah, I only practice when I feel like it." And I was like, "Oh, wow, I am not going to be a professional guitarist." So that was me realizing I was not going to be a professional guitarist.
Adrien:
And then I wanted to do international relations. And I became disillusioned with that. And I got into math. And I ended up becoming a professor at Carnegie Mellon and working on both basically machine learning problems and big data problems. And we had jobs running for hours, every single night and for days on end, actually. And that was really fun. I actually loved it. And we were using Python, NumPy. All these things that are now very much part of the Zeitgeist, we were using them, like pre1.0, when why would you use Python instead of a MATLAB or something like that in those days?
Lukas:
And what were the... Before that you made Foldit? Right, which I think is one of the most interesting... And maybe do you want to talk about Foldit and what happened there?
Adrien:
Yeah definitely. I think that was, if the guitar one was an example of me realizing I was never going to be that good at it. I think Foldit was an example of me seeing something else really cool and jumping at it. And so what happened was, I had been working on this numerical stuff. And then right at the end of my PhD, some basically, biochemical biochemistry professors and I, and they got this group together. And we had this idea of, let's create a computer game out of protein folding.
Adrien:
And so it was... First of all it's a really easy first thing scientific question, because it just so happens that it's like very difficult to create simulations of protein folding, takes a lot of computational power to solve. It also is a problem with like enormous real world consequences. Because in short, proteins are these machines in your body that carry out the basic functions of life, their shape determines how they do that. And folding is how they get that shape. So understanding how proteins fold and why they fold into certain shapes is like literally like the origami of life itself.
Adrien:
And so here is this super interesting scientific problem, very difficult to solve by computers, we had this line on this, like totally crazy, kind of fantastical take on it. Which was, let's turn it into a computer game which may or may not be fun, much less had any kind of scientific impact. And we just ran with it. And we did it. And it kind of blew up. Over a million people contributed to this really profound scientific problem all over the world.
Adrien:
Some of the best Foldit players in the world, were people who scarcely thought they had a scientific bone in their body. And all of a sudden, they're at the top of the leaderboard. And the BBC is calling them up and asking them to interview them. This really happened.
Lukas:
And so, wait, the game though... I mean, the game just because people may have trouble imagining this. I mean, I played this game, I was not good at it. But if it's like you're trying to rotate and manipulate these, like molecules, basically.
Adrien:
Yeah, yeah.
Lukas:
Why can a person do this but a computer can't do this.
Adrien:
Yeah. Well, okay, if your initial intuition was the rules of why can you recognize a face? Well from a computer's perspective, it's like, super hard to recognize a face. You need this giant neural network, and you need to like measure all these things, and it can involve all these things until you really need like, in a sense, you might say millions of equations are stacking up in order to create this, like face recognizer. And yet, we can do it instantly. And similarly, in the case of a protein, technically speaking, there are this geometric number of pairwise atom interactions that are going into it, and these atoms they sometimes repel one another, they attract one another as the case may be. And so it creates this like, network of sort of attractive and repulsive magnets, basically, and then the ultimate shape is some kind of stasis.
Adrien:
So you would look at that problem and think, like this crazy math equation to solve what it actually would look like. And yet, the scientists who work in this field develop an intuition that's very definite. And in fact, they could say, "This looks like a real protein that we learned... We know it's shaped through a crystal structure." Or, "This looks like a protein that was designed badly by a computer." So in essence, it had this similar flavor, which was that like, over time, you could actually build an intuition for what looks right, and what doesn't. And that was like the ur-idea that led us to believe that potentially that intuition could be essentially trained.
Lukas:
Here, you're training humans, actually, through a game.
Adrien:
Yeah, that's right. That's right. And that's actually a really fun process. And incidentally, the way that we train them, this actually gets into the game thing, is you actually build a simulation. Well, we had a simulation of how proteins fold, and then you let people play with it. And in essence proteins, they are physical objects, like they're a little different from the ones that we normally play with, because they're suspended in water and stuff. But if you pull on them, they resist in some places, and then they don't like to bang into themselves and stuff.
Adrien:
And so as you play with them, and as you sort of flex them and pull on them, there is an intuition to the game about how these things work. It's like no different than playing with Play-Doh or Silly Putty, at some point, you start to understand the underlying material. And you don't have to... It's not completely new, when you press on it, what's going to happen. And so in a funny way... The long story short is that I think it was hailed as sort of a certainly a sort of milestone in attempting to build a giant, large scale sort of human computer, computational complex. And also, we were able to publish papers in Nature and in some cases, and in PNAS and other great news, with insights that have been derived from the players. So that was great. But for me, one of the most fun things was actually that phase of like, how can we build an actual game that gives millions of people the intuitive sense for what this thing is? And is it possible to hand them that and then have them sort of understand it and crack it?
Lukas:
And then didn't you make a... You made a second game too, right, that actually-
Adrien:
Yeah. Yeah we created a second game called EteRNA. And that also actually, we published. Similar idea. It was a scientific discovery game, we enlisted a bunch of people, both these games are going strong, actually. So you can play them both right now. And the real innovation in EteRNA is that rather than just do everything in simulation on a computer, we were actually using high throughput synthesis to build the molecules being designed by the players. And so in essence, your score was determined by a tiny little high throughput experiment that was run, which I just think is so cool. And a lot of interesting stuff comes out of that. And you don't need a simulation for one thing.
Lukas:
So how did it work? The players would propose molecules and then you would synthesize them?
Adrien:
Yeah, they would propose molecules, they would initially they would vote on them. The thing is that the cost of these experiments keeps going down. And so that actually means that the games are being designed against this, like super Moore's Law kind of change in biochemistry in terms of like, what is possible to synthesize, how fast, what kind of experiments can you run? What information you get back? That's all shifting underneath the game until we were actually redesigning the game over time as these things changed.
Adrien:
But yeah, in essence, they would design them, they would vote on them, we would synthesize them, we would share the results with everyone, everyone would get a score, everyone would look at what everyone else's molecule did. And then-
Lukas:
And what would the score come from?
Adrien:
... Rinse and repeat. So the score was... So, okay. First of all, rather than working on protein folding, we were working on RNA folding. And spoiler alert COVID-19 is an RNA virus. And in fact, it turns out that like Moderna this company, that's famously one of the contenders to create a vaccine for COVID-19 is an RNA research company. So as it turns out, that actually RNAs have at least shoved aside if not, in some ways to plant in proteins as being a molecule of like intense interest by biochemists and pharmaceutical companies. As a sort of chemical substrate with which to build a whole new class of drugs that could potentially, essentially enter your body and then interact on a super deep like quasi-computational level with what it sees, in a chemical sense.
Adrien:
So we were using RNAs this time round, which has slightly different properties than proteins they tend to be bigger in some ways, and they're bendier, they're more flexible. And so what we would do is, we would say, "Try to create an RNA that folds into this particular shape." And initially, the shapes were essentially just things we invented, that we thought RNAs could plausibly fold into. And then over time, they became actually more pharmaceutically interesting. And in fact, the most recent challenges on EteRNA do have to do with COVID actually, directly.
Adrien:
If this sounds intriguing to your listeners, I think it would be super cool if you guys take a look and play around with it. And it's very, very current, actually. But yeah, we gave them a shape. They were trying to build RNAs, in other words, designed sequences of nucleotides, that would naturally fold into that shape. We would take the most highly voted molecules and synthesize them and then basically figure out what shape they folded into, which you can do. And then we would basically use a sort of root mean squared error, distance function to tell you just like in machine learning, to tell you like how close you were to the shape. And so the neural net, as it were, the black box is the human mind. But other than that, it was just same thing, a loss function an input function. And so and then you just do this thing over and over again. And ideally, through some kind of human based, Gradient Dissent, little plug, in the community would improve. And lo and behold, they did. So that's just so cool.
Lukas:
But I guess where are we at now? Because think about games like Go that are so well studied. And computers getting better than humans. Have artificial neural nets surpassed Gradient Dissent, human neural nets at this point?
Adrien:
Yeah, yeah, yeah. So basically, yes, actually, in a way, but the other thing is that the game design shifts. And so it's just as... It's similar to the real world. Yes, we have better neural nets, but it doesn't mean that we're all out of a job yet. If anything, it means that new jobs are being defined. And so and if that sounds glib, it actually did kind of happen that way into like microcosm of these games. Which is to say that like, it tended to be the case that felt like raw let me beat a computer at this task was not the most interesting thing that came out of it. And in any case, it was a moving target because there is a universe of researchers trying to create better and better algorithms and using neural nets for that matter, and a lot of other statistical stuff.
Adrien:
And so that boundary kept shifting. But in my opinion, the really interesting thing about having a large number of humans like in playing this game, and basically talking about it on the forums and sort of creating a community around it, was that they ultimately came up with interesting ideas and shifted the game design and sort of did this like human element. Which is like, what other interesting stuff can we do here. So for example, at one point, some of the players in EteRNA basically noticed that certain motifs, like putting certain nucleotides in certain patterns was more likely to create a stable RNA.
Adrien:
And this is just like a purely human thing. It wasn't something that we were like necessarily looking for. And then we were able to like basically rigorously prove they were right. And that's starting to cross into like science, basically. And so just we have not automated that yet. So those are the kinds of things that I think ultimately, to me, are the like, more important outcome. Rather than just like, we temporarily beat the best computer algorithm in 2003 at this very specific computational task, which was ultimately not going to be a winning formula.
Lukas:
When you became a professor, what was your research areas? What were you interested in?
Adrien:
Yeah, there was always these two pieces of it, which were, if not... They weren't really in conflict, but they didn't really connect. So one of them was creating computer games, we actually created a bunch that did all kinds of interesting things. We created computer games that like, allowed us to, like capture a ton of information with my student, Alex [Linpacker 00:16:39]. Tons of information about how artists draw faces. And we actually put out a game on iOS where you could like draw celebrity faces and then try and guess a celebrity. It was like, based on Draw It game, or something, I forget what it was called. Got a bunch of people to play that.
Adrien:
And so we were literally like paying Google AdWords get people to play our games to create these like esoteric scientific datasets to study these like recondite questions, which is so cool. Such a just a weird thing to do, I guess. And pretty weird compared to the other professors. And at the same time, we were also like writing papers on basically applying machine learning methods to crazy graphics problems. We were like applying machine learning to smoke simulations, and to the light transport equations. We were running... It was like whiteboards full of equations. And it was running jobs on clusters that literally took days or weeks to run.
Adrien:
And so we were doing hyper-parameter searches, and all this stuff that's now suddenly cool. So those are the sort of dual worlds that I guess, probably similar to you, there's always been this pull towards on the one hand, like math. And just, the like austere perfection, that just fine of that. And then also just creating things that people want to play with, or use and sort of the delight in like creating products, basically.
Lukas:
Well, I want to jump ahead to StreamLit to give it the time it deserves. But we are skipping over a whole bunch of other amazing things that you did. But I'd love to hear the story, in your words of coming up with StreamLit, because I feel like I watched some of it. And it appeared to me like it almost just like popped into your head is sort of a complete idea that was sort of like immediately awesome. So I'm curious to know what the experience was for you.
Adrien:
Yeah. Well, it didn't quite happen that magically. It's funny that on the one hand, I was working on like machine learning problems and numerical math. And on the other hand, I wanted to build products for people and like build communities around those products. And weirdly, I feel like those two things have come together in this product called StreamLit. Basically, what string does is it lets machine learning engineers and data scientists build little interactive artifacts that allow them to share their data sets, their models, with their prediction for the future, etc, with one another and inside of organizations and also with the world.
Adrien:
It's an app library for Python programmers. And we can go into actually why it turns out that's actually a really important thing, both for like people who want to show off their skills, but also in big corporations that need to like export machine learning into the whole company. It turns out that they both need this sort of superpower that StreamLit provides.
Adrien:
But how it came about was, I had worked on a project at Google that got canceled, very like heartbreakingly to me. And it was a very public failure. If you choose to look at it that way. In retrospect, like all my failures, were my successes. And all my successes were not necessarily successes. So but it's kind of the story you're telling yourself at the time. And so I took it really hard, basically. And I then took a job that I wasn't like super excited about, in dating parlance, you might call it a rebound. And then I eventually basically took some time off.
Adrien:
And I started just writing code, which had long been a passion. And a friend of mine named Lukas Biewald was like, "Hey, dude, let's go into the woods and like an Airbnb, and we'll write cod together." Which I thought was the coolest idea. So we went to the woods, and we started writing neural nets, you and me. And that was one of several projects. I'd also been working on a stock market simulation, which actually also came out of conversation with you, Lukas?
Adrien:
Well, the funny story there is I'm like, "Lukas, I think that like..." I'm telling him over dinner. So I'm telling you some like statistical properties that I thought the stock market might have. And I remember you were just like, "Adrien do not invest on this assumption people. Lose their shirt thinking stuff like this." And I was actually like, really touched. I was like, "First of all, I had no intention of actually investing." And I was like, "I'm not even like, well enough organized to do that." But like, I was like, "Wow." Like kind of touched, like Lukas is like really looking out for me here on this math conversation, we're having.
Adrien:
So, I was working on a bunch of fun products like that were kind of mathy. And that also you needed to be able to play with stuff and see it. And so basically, naturally coming out of that workflow I just was dissatisfied with everything else out there. So I started writing my own tools that allowed me to basically take Python scripts I was writing and turn them into little interactive artifacts that would allow me to like play with them and see their properties more tangibly. Than just like changing a number and rewriting the code or writing a loop and then running it 6,000 times. And that need kind of just snowballed. Like, I'm skipping the part where we had some heartbreaking pivots and stuff. And I'm happy to go into that too. But it is true that on some level I wanted it, a bunch of my friends wanted it. Some people who eventually became my co-workers were like, let's all work on this together. Some big companies started using it investors started-
Lukas:
Wait, wait, wait, wait.
Adrien:
Yeah.
Lukas:
Don't skip the heartbreaking pivots. I mean, that's like why we do these things.
Adrien:
Okay, okay, okay, yeah. Running into a wall at 90 miles an hour.
Lukas:
Were their paths because it really seemed to me like, I feel like I watched you kind of come up with this idea that it seems like it's the idea that's the core of what you have now. I'm actually kind of surprised to learn that there was...
Adrien:
Well, okay, yeah. So the pivot was, it all comes down to you throwing me off, first of all, showing me the way Lukas, and then throw me off my game. So what happened was, I started using Streamlit, as a way to understand these stock market simulations actually. And the key thing was that once you build this model, like you want to be able to change parameters really easily, and then see how that affects the model. And obviously, if the model's a straight line, it's not like super interesting. But when it's like... You get it. When it's something that's really just computations happening. And especially, it's like a non-trivial simulation of the future, there is crazy... I mean, it's one of the principles of like dynamical systems theory, like you can change a number a tiny little bit, and all of a sudden totally different things start to come out, and where are these bifurcations and stuff.
Adrien:
And so it's really fascinating, and worlds get created. And that was the original version of StreamLit. And in fact, if anything, we've come back to that. But what happened was, you invited me to go out in the woods and code neural nets and stuff. And at the time, Weights & Biases was you were ahead of me, in the sense that I think you'd started a company already. But it was pretty like rough. Like you were like, "Okay, let's use Weights & Biases for this project." And in like, five minutes, you were like, "It's not working, forget it. We're not using Weights & Biases."
Adrien:
And so yeah, so for all of you, people who think the Weights & Biases are so polished and perfect, I can remember days, it was still very much early. So anyway, we were doing this neural net stuff together. And I was like, "Oh, this is really cool." And I think I probably got like a little FOMO about, like how cool your incipient company was. And so I kind of started to work more on deep learning style applications for Streamlit. And when we initially fundraised, we sort of had a superposition of two products in some ways.
Adrien:
And what basically happened is that we had some signal that was positive, like people were using it, and not just because we were bugging them every day. But we also just didn't have as much signal as we wanted. And we, in some parts of the company early on, we like... A company wanted us to install StreamLit internally, we put a ton of effort into it. And then like it was crickets after we did this, like big install for them.
Adrien:
And so I remember talking to one of our investors who's like, super highly respected has been around the bush and he like, invited me for coffee and he was like, "Adrien what are your milestones? Don't just send us investor updates, or like, we're still building." And that's a little tough and we were still building and searching basically, and we were post fundraise, so it wasn't like, we were just totally in like bushwhacking exploration mode. Like there was some kind of clock that was ticking. So we actually wrote a huge slide deck, which was like everything that the product can become.
Adrien:
And we shared it with everyone who was using Streamlit. And we basically gave them like an hour long interview. And we'd like data scienced the whole thing. And we were like "How much would you want this feature, that feature, that feature." We like clustered them and everything. And actually it so happened that really the thing that people were most excited about was also the thing that had been actually kind of the ur-original thought, which is that you want to, once you've built a model, or once you've bought a simulation, or once you've built actually even like a non-trivial data set, you want to be able to rapidly like interrogate it, potentially in sort of ad hoc manner.
Adrien:
So you want like arbitrary code, and you want it to elegantly do that without... And that's a different product category than just like Tableau or something, it's a little bit more computational. And we realized we should make this an app framework, sort of basically, a Shiny for Python, and you just have sliders and widgets, and it needs to result in a webpage that's interactive. And I resisted it until I was worn down by my co-founders. And then we all just agreed to do it. And we just went long on that. And we launched it, and it found resonance, basically. So that's the story.
Lukas:
Interesting. So what did you add to it to make it do that? Because I feel like when I first saw it, I thought, "Oh, this is Shiny."
Adrien:
Oh, really? Well, you could have saved me six months, dude. Yeah, well, the basic thing was whether we are going to have widgets. And then the next thing, which is like yes, in React a widget is you just say there is a widget and suddenly it exists. So why is that so hard? One of the reasons why it's so hard is because if you really commit to like writing an app framework, then it implies a whole bunch of things down the line about how you'd expect the product to work. So it's not like lines of code for the prototype doesn't translate into like how easy it is to get to from product perspective. The other thing is that, and this starting to get a little nerdy, but there was a question of like the event model.
Adrien:
And one of the things that makes... Actually the thing that... Why is it hard to make a little app around your machine learning model. Why can't you just whip together a little Flask app with a React front end, and it's like, boom, it's done. And basically, the reason is because... Well, actually it is because app programming is actually really hard. And the hard thing about is that you have these events coming in, there's a whole event model, and then there's a state model, and then these things need to not mess one another up. And it needs to always reflect things properly.
Adrien:
And that turns out to be such a hard problem, even for humans to like wrap their head around that we're still seeing major advances every couple of years in terms of just from an API perspective. How to not make that like a nightmare of complexity. And so, if you bolt on to that in a naive way, oh, and there's also a neural net, and it's like God knows what it's doing. And there's these giant datasets, and there's thousands of neural nets, and you can... It really becomes insane. And so we came up with this, I would say interesting and constrained perspective on this, which is basically, let's forget, let's throw out everything we knew about our programming, and just pretend it's a Python script. And it just runs from top to bottom, just as you would write a Python script. And then everywhere you say numLayers equals five, you're allowed to say NumLayers equals slider.
Adrien:
And so if you'll notice that at no point did you actually say that there was an event. At no point did you say, "Oh, there's a state that gets modified in this way, when you get an event from this slider, you just said NumLayers equals slider." And so that was kind of like, how do we get to that? And so we figured out how to get to that it implies some constraints on like what we can do in terms of the apps that we create. But it also like massively, massively simplifies the thought process that you have to go through to create an app. And the way we phrase the product now is like, "Turn your scripts into apps."
Adrien:
Which usually when you think of creating an app, it's like create an app from scratch, or lay out all the widgets and then implement it. But if you just think of it as like turning your scripts into apps, then it's like a much more natural workflow. A lot of people didn't think StreamLit was that cool. And then they like, tried it and then like, within five minutes, they're like, "Okay, it's super cool. I'm going to tweet about it or something." That's certainly contributed to a lot of basically natural growth that's not mediated by marketing, or it's just kind of endemic or endogenous to the community itself.
Lukas:
Yeah, but I have to say we watch this stuff quite closely at Weight & Biases, and it does seem like you have maybe the hottest program that data scientists and machine learning people use. So, congratulations.
Adrien:
Yeah, well, I mean, that's really kind I have to say, it's been really fun. And when you're on the inside, you're always sort of focused on the worst case scenario? How could this go wrong? And how are we going to tell the employees if this doesn't land and all this kind of stuff? So it's really like nice to hear someone say that.
Lukas:
So I'm curious, one of the things that's always driven me crazy about working with you is you always want to try some new programming language. And I'm always kind of like, "Can't we use Python? Like a language that it's like, well documented that you actually know better than me?" I'm kind of curious where you land on that now that you're doing a lot of Python. Like, do you aspire to create this this type of construct in other languages?
Adrien:
Totally, totally. Our investors are going to like hate to hear this. In no way does this benefit the bottom line at all. But, I mean, actually, someone from the Haskell community tweeted, we should see what we can learn from StreamLit and I was like, "That was the best compliment in the world." Because those guys are hardcore dude. And actually had we written StreamLit Haskell, there's like all these cool optimizations we could have done because a lot more about the program in Haskell, basically I mean. And in Python, you know nothing going on. You can just like, literally change the direction of gravity in like one line of code.
Adrien:
And I was watching your podcast, by the way, and I saw Jeremy Howard say that Python can't possibly be the future of machine learning, which I unfortunately don't agree with. I wish that were true. And he was, I guess, a big Julia proponent. And I do think actually, the key concepts in StreamLit actually are not specifically Pythonic, that thing that I was telling you about where you just sort of think of your programming script, and there's no events and stuff. I mean, you could write it in JavaScript, you could write it in Julia, and I just think it'd be super fun to do that. So hopefully, somebody will create enough profits that I can legitimately spend some time doing that. I think that'd be so fun, and if you want to with me in the woods. I guess that's the part you hate.
Lukas:
That does sound like fun. I get to learn Julia. Or Elm. Have you considered Elm integration?
Adrien:
Oh, my God, I love Elm. Don't get me started.
Lukas:
What else do you dream of with the app? Like, do you sort of feel like the structure is done? Or are there sort of like big things that-
Adrien:
No, no, no, there's like really big things that are missing, actually. We've actually been calling this fulfilling the open source promise, which is to say that the way that we allow you to build apps is like I, in some ways, like so new, that a lot of things that are kind of obvious how to do in a traditional framework don't carry it over to StreamLit necessarily. Basically, the way that works is that people do... StreamLit is great for some use cases. And then you can hit a brick wall, but you're like, "Oh, and I also need to have persistent state that carries over from session to session. How do I do that?" There's no way to do it.
Adrien:
And yet, when we sold this thing to the world and we told them what we wanted it to be, we said, "Hey, this is a general purpose app framework that's specialized for machine learning and data science. But you should feel confident in using in all these use cases." And particularly now, I mean, StreamLit, it's part of the standard of data science workbench at Uber, and it's being used by a bunch of big, sophisticated companies, and people are really pushing on its limits in many directions at once.
Adrien:
And we know that we lose people, because they're just like, "I can't do this in StreamLit. I can't I can't go forward." So we've set ourselves this task, which is called fulfilling the open source promise, which is basically take the big things that you can do in other frameworks that you can't do in StreamLit and just address them one by one. But not... I mean, we could actually do that in like five days, if we wanted to just like throw the can at it. But you want to do it elegantly you want to do it... I mean, that sounds very, like glib or cliché. But if for nothing else is part of the fun to actually think about, like what's the real way of doing this properly with regard to this thing.
Adrien:
We released custom components, which is like a plugin system that allows you to take like arbitrary React apps, or React or other kind of web components, and plug them into your StreamLit app. So that like dramatically opens the sort of footprint of possible things you can do because it's now like as big as React on some level, and react is sort of everything. And now we are adding way more visual customization, and notably, on October 15, we are releasing by far the biggest and most profound thing, which is single click to play of any StreamLit app. So the thing that you've been working on your laptop and the thing that you may have shared with the world, laboriously by putting it on Heroku, or on JCP, or something, you can now literally push a button, and it at a URL that everyone can see.
Lukas:
Does that mean that you have to leave your laptop open for that URL to keep-
Adrien:
Yeah, no, no, no, no, no. That's actually a cool product, too. And I people have asked for that product. There was actually an executive at Twilio, who became like, obsessed with StreamLit, he was like, "I just want to be able to extend in a slack message, this app, like what I'm looking at my screen to my coworker. But I don't want like put the entire thing on a third party server, and I don't want to..."
Adrien:
And actually, there's a really cool... I love that idea. I keep trying to tell everyone what, "We should really do this." I feel like people would just be like, "I'll pay, I'll pay five bucks for that." Let's reflect this app off of the StreamLit servers.
Lukas:
Wait, it's so funny, because I always use this weird thing that Twilio makes where it can kind of reflect stuff off my server. So Twilio's sitting on the thing that I use for that purpose.
Adrien:
I know.
Lukas:
You should tell that executive, I forget what it's called. But it's like a bouncing thing in the cloud, where you can have a stable URL.
Adrien:
Lukas let's keep this between you and me and monetize it. Let's cut this part out of the... No I'm kidding. Yeah, I think that would be a cool product. But the way that the sharing works is we instantiate your app. So there's actually, a lot of the work is taking your requirements.txt file and taking other kinds of your app requirements and stuff and building an environment that reproduces your app, and doing so in a way that's like sane and non infuriating. But on the other hand, it's also taken a lot of work to build this thing. And one of the reasons why we feel confident, building it is because so many people are building it themselves in like, a super ad hoc way.
Adrien:
And actually, companies are building it themselves, too. And in many cases, just being like, "Can you build this for us?" So it's like we don't feel like we are... In a way we don't really feel like we're blazing a path at all, we just feel like we're sort of standardizing what everyone's doing. And then hopefully just making it like, way easier to do. So. Yeah, that's why we think it's a really cool feature. And if you want it to be private... If it's public for free, if you want to be private, it's a paid feature. And that's actually the next step for StreamLit. So we'll see how it goes.
Lukas:
Nice. Congratulations. One thing I wanted to ask you about, I don't know if this is too far out of left field. But another thing that's been notable knowing you is how interested you are in meditation. And I was wondering if that connects to the work you do at all, in StreamLit. If you're kind of like working life is connected to the, I guess, like the... Would you call it spiritual?
Adrien:
Yeah, yeah, yeah, yeah.
Lukas:
That's something you're interested in.
Adrien:
What a delightful question. The funny thing about meditation is, it's impossible to tell whether it's goddamn working or not. So I can't answer your question. At the time when my projects had been canceled, and when I was forced to reckon with a definition of Adrien that didn't just involve like, creating cool projects that everyone loved one after another without... And I suddenly became very interested in meditation.
Adrien:
And so maybe I was seeking a challenge that I could win. And no one can tell whether you're winning or not at meditation. And or maybe a self for the pain in life. And it actually just wasn't my project being canceled, which is fine. But there were a number of like, personal things in my life as well, that were just really painful. And I think that I did something that everyone does, which is that I took what were legitimate problems, you might say, in my life, and I extrapolated from them, more problems, and then I extrapolated more problems. And I essentially constructed like a prison in my mind. This is sort of kind of a Buddhist way of looking at things. And I think that it's like a very, very natural thing to do. And it actually happens constantly, like every second and it's very harmful, basically, in the sense that, if nothing else, it's sort of taking you away from what's actually happening.
Adrien:
I think discovering meditation showed me that you could dissolve those extrapolations. And in fact, that life wasn't quite as bad as it seemed, that my personal problems weren't as insoluble as I thought. And that way more than Streamlit or anything professional has altered the direction of my life. In essence, I do believe that meditation and it's not the only thing, but meditation can help bring you like a little bit more in contact with reality. I also think probably one of the most important things you can do as a product designer slash really anythinger is be in contact with reality. And it's not as easy as you think. Or at least, I thought, to do that, and therefore there might be a parallel there. But it's impossible to know.
Lukas:
Have you continued to meditate through running Streamlit? Or has it become less relevant?
Adrien:
Yeah. Well yes, it became less relevant. And also my life became worse again, I became super depressed when I started again, and now I'm feeling less depressed. And I also started taking antidepressants. Antidepressants is like a good 30 minutes of meditation a day easy. And it only takes two seconds. For me meditation looks like spending a little bit of time every day, just observing my mind construct, and then destroy and construct and destroy infinite problems and solutions and fantasies. And taking a little bit of time every day, and just remembering that that's A, happening and, B, not actually connected with anything real. To me anyway, it's kind of a joy. And it's kind of like a good thing to remember. It's like, remembering to enjoy everything else in life that's worth enjoying, it's just easy not to do and probably a good thing to do.
Lukas:
That is a good sell for meditation. So we always end with two questions, I'm kind of curious how you'll interpret them. And the first one is, what is an underrated aspect of machine learning that you think people should pay more attention to?
Adrien:
There's a lot of people who are very focused on this idea that we're all going to lose our jobs and the computers are going to make all the decisions. And I think that a much more plausible outcome for machine learning, as we understand it today, is just to massively increase our ability to like measure the world, basically. Not just have a security camera, but actually know how many people are walking by and how fast they're walking by, and whether they're men or women and cars, and all these kinds of things. And understand what appliances are plugged into your wall, and all this kind of thing.
Adrien:
So I think that like, in essence, looking back on this time, we're going to feel like 2019, 2018, we're going to hit the informational bedrock, like we didn't know anything that was going on in the world before 2018, relative to the future. And I think that that perspective, which is that it's like we're opening our eyes, and seeing what's happening in the world, at a totally new level of resolution is actually going to be a much more apt description of what the machine learning revolution brings.
Lukas:
Interesting. All right. Interesting answer. And the final question is simple. It's basically what's the biggest challenges that make it hard to take machine learning models and deploy them in the real world?
Adrien:
I think every machine learning tools entrepreneur will tell you that it's whatever their company is doing.
Lukas:
And I think that's a totally legitimate answer, by the way.
Adrien:
So I suppose you'll tell me it is experiment tracking and hyper parameter search and-
Lukas:
How would you answer that? And I think it's legitimate, you're clearly solving a huge pain point for people. What is that piece that requires Streamlit?
Adrien:
Yeah. So I saw this at Google, at Google X. I saw this at Zoox, at [inaudible 00:47:37]. It's the machine learning teams and the data science teams are actually the gatekeeper to this really fascinating and exotic storehouse of stuff. Like data sets and models, and predictions of the future. And that is actually very difficult for other people to get at. The state of the art is often like, I'm going to send you an email and just do a one off exploration in Jupyter notebook and tell me the answer and paste it into a PowerPoint presentation. Like, that's a lot of how the rest of the company interacts with the data science team and the machine learning team. And that's kind of insane.
Adrien:
It's so inefficient. And so I think that the aspiration that I have for StreamLit is that almost as a byproduct of existing workflows, the engineers working on those teams are empowered to sort of bring their work directly. Inject it into the entire company and allow the whole company to make decisions and predictions and stuff in the same way that they can. I think it would have a big, big, big impact and it already is starting to.
Lukas:
Yeah, awesome. Well, thanks, Adrien. It's great to talk to you.
Adrien:
Well it's really fun.
Lukas:
When we first started making these videos, we didn't know if anyone would be interested or want to see them, but we made them for fun. And we started off and making videos that would teach people and now we get these great interviews with real industry practitioners. And I love making this available to the whole world so everyone can watch these things for free. The more feedback you give us, the better stuff we can produce. So please subscribe, leave a comment engage with us. We really appreciate it.