DeepLearning.AI NLP Learner Community Event ft. Luis Alaniz

Luis Alaniz talks about moving from economics into machine learning and NLP. He covers nowcasting and sentiment analysis in economics, practical advice on learning (build projects, don't fear math), and answers questions on data collection, labeling, and finance applications.
Chapters
So hello everybody, my name is Luis Alaniz and I hope you are having a good day. I will be your first speaker for this NLP learner community event. I am very happy to have you here today and so without further. Presentations, I will start my presentation. So again, my name is Luis Alanis. I was born in Nicaragua. I went to primary school in Nicaragua. Then my parents moved to Belgium. So I went to secondary school there. I did a BA in economics. Then I did a Master of Science in Economics in Switzerland. Then I entered the PhD program in economics at Georgetown University. So I took a lot of economics class and mainly economic theory, micro and microeconomic theory, some financial theory, growth, business cycles, game theory, mechanism design, computational economic courses, and then math classes that are necessary for understanding the economic classes. So mainly real analysis, linear programming, convex optimization, some dynamic programming, dynamic optimization, that type of thing. Then what I used to work on and how it related to AI. I was a World bank consultant on development economics. I was measuring poverty and social indicators using living standard measurement surveys. I was modeling the impact of policies and debt relief on poverty reduction and distribution and the distribution of income. So I was doing modeling economic modeling. Then I went on to work in a private sector think tank. I was making a quarterly report economic report. I was making projections on gdp, commodity prices, inflation, money demand and that kind of stuff. I was also making consumer and investor sentiment surveys about the economy. And that's one way I started learning about nlp because I didn't felt that those surveys were conveying very good consumer and investor sentiment. I was also measuring the impact of government interventions in the economy through modeling. So a typical use case of NLP in my work nowcasting. So you follow a group of economic experts, policymakers, business leaders on social media, maybe the economic section of new newspapers and other type of media and gather their opinion about the economy. You can use the data above to make sentiment analysis which I think you have done in week one and week two of the specialization. You also can gather economic indicators with mixed periodicity from the central bank and other institutions and you can feed them. You can take that together with what I said in point two and you can make a state space model. You can estimate it and then you can apply the Kalman filter in order to do nowcast of gdp. Typically the state space model will be a dynamic factor model, but you have to take into account also the different periodicity of the data. So it will be a little bit more complicated than a simple vanilla dynamic factor model. So what led me to AI economic models That I learned rarely had an analytical solution, for example asset pricing models, optimal inventory models, growth and business cycles models, and econometric techniques like MLE or simulated gmm, simulated MLE or simulated gmm. So I was taught to find this numerical solution using matlab, but a lot of times that was very slow. So it was highly suggested to me to learn a lower level language and the main candidates for that were Fortran and C because they have very, very good performance. However, I found Python which is a middle ground between matlab and low level languages. I had to find it because my interest was in the modeling part, not in the in the numerical part and the programming part. So Python and the libraries it has was an excellent middle ground solution for me. I took courses to learn programming in Python and I found out that it was used a lot for machine learning. I took courses in the MOOC modality and machine learning and finally I learned about NLP and other advanced AI tasks. I was offered to be an alpha tester and a mentor for the NLP specialization and I was getting more and more involved in AI. So how do I keep learning? Well, what I did before was spend a lot of time in university, so formal education. But at this point in my career and as a lifelong learner, I needed a more flexible approach. So now. I learned online and it proved quite effective for my needs to acquire new skills and complement the ones that I already had without the cost in terms of time, money, being away from a stable place. So I was given the opportunity to be an alpha tester for the NLP specialization. And as I already said, that has led me to learn in a more profound way. So what I don't think works in order to keep learning is depending on what your employer does, doing, learning by doing. I don't think you will learn more things than what you already know, but you will become better in what you already do, but you won't learn more and maybe you will start getting outdated in the stuff that you learn. A lot of you asked about research areas in nlp, so right now I don't consider myself an expert in the subject. I have a good idea, but I'm not doing research. I'm not one of the guys that does research in that. But I can give you like a good sense of what it's been doing is being going on in natural language processing. So one area is natural language generation, like for example creating creative writing, that's realistic rhyme, team based poetry, for example generation of news, reviewing and summarizing research literature. Another area is natural language understanding and that's sentiment analysis, text summarization, information extraction, topic segmentation, question answering. And I think in modules 3 and 4 of the specialization you will be doing some of creative writing, text summarization. You have already done some sentiment analysis. I think that in module four you will be doing some question answering also. So this specialization will take you close to what state of the art. So that's a very nice thing. So my final thoughts on how to build a career in AI. You must be motivated, you must be curious, you must like to learn online and you have to think that it works. It's very good to join a community like this one. Don't be afraid of math and if you don't understand concepts right away, don't give up, move on and keep trying to. I will also advise to keep learning because AI is a very dynamic and changing topic. So it's important to keep up to date. Develop your own AI project. For example, start doing a web page with maybe some interactive content using what you've learned here. So with that I finish my presentation and I am open to your questions on Slack. Thank you. So someone is asking if he can have the presentation for this event. I think there is no problem with that, but I will check. So how to use sentiment analysis for nowcasting? That's a very good question. So you gather the way that you have learned in. In courses one and two, you gather tweets, you gather newspaper content. And then you use that and you apply the sentiment analysis methods that you learn in this course. And then you feed that to a model like the one I explained. And with that you can go on and do nowcasting. You can look for articles in the web on how to do that. I can also give you some, some references, but I don't think I can go into detail here because it's not like, it's not like the forum for that. But I can give you and I can lead you to new to two papers. How do I deal with the lack of labels? Well, you have to label yourself the tweets. So that's a lot of work and you need a team do that. I work with another two people, so that's the way it's done. I mean you need a team, you need to review what you are getting from the different sources, Twitter and etc. And, and that's how you do it. So what's my favorite topic on AI? What do you do? I think it's the most popular branch of AI in the future. Well, Right now I like a lot nlp, that's one of my favorite topics. But I also like reinforcement learning because in reinforcement learning you learn like you learn a bellman equation or you learn something in dynamic programming. You learn it directly from the data and you get the rewards and all that stuff. So I think that's great. Another question, what's the application of AI? Yeah, so what's the application of AI that excites me most in the economic field? I will say that reinforcement learning, I mean, for example, you can do reinforcement learning in finance in order to estimate and to predict asset pricing and choosing portfolios. So that's very exciting. But also NLP is very exciting because you can, you can also use it in finance doing sentiment analysis in order to try to predict how stocks are going to move. That's very exciting. Sorry if I'm not answering all the questions, but you are going very fast. So can you tell us. Okay, see that one? Well, to collect the data, the Data There are APIs in Twitter for example, you have the Twitter API, you have Facebook API and that tells you how you can get the data. They are very open and most, I mean most self respect websites have APIs that allow you to gather data from them. In regard to economic policy, has NLP worked been useful in creating new policy for fight things like disinformation? I think that NLP is a great tool to fight disinformation because it allows you to filter stuff that is just noise or fake news from stuff that it's actually information. So I think it's great in order to find this information. How can NLP benefit from reinforcement learning? I think it's been done, but I'm not doing it right now because I'm not. That's very, very advanced, but I'm not right now I'm not the person to ask that question because you are in the frontiers of two very specialized topics. Do weak supervision works in nlp? What is the best way to train an NLP network? In courses three and four you will learn how to train models with attention. And that's a great way to train an NA to train a model, an NLP model. Say something about building your own interactive AI website. Please elaborate. There is a specialization called. Tensorflow. In practice there they explain a little bit how you can build interactive AI websites. So how do I, how do you predict stock movements doing sentiment analysis? Normally the people who work in the, in the stock market they have, they have access to emails and stuff among them. And so they use those emails and Those data in order to make sentiment analysis and then stock predictions. And I know that that's been. How do you do you make sure that you have selected the right tweets in your training set? How do you avoid bias in the data? Well, You select a sample and you have to keep comparing your sample with the reality, with the ground truth. And that's how you, how you do it. You mentioned using the Kalman filter, what other advanced math techniques algorithm should have in our toolkit or at least to be aware. You have to be aware of dynamic optimization, dynamic programming and that kind of stuff. It's very important. What courses do you recommend in the NLP specialization? What are the top three mistakes NLP practitioners have? I would recommend all the courses in the NLP specialization and the top three mistakes. I wouldn't think that I can answer that, but maybe later. I don't know. I don't know that the practitioners, developers make a lot of mistakes. They work together and try to avoid that. Could you tell us the proportion of transactions made by AI algorithms and human beings? Do you think traders will be fully replaced by AI where traders already replaced by AI? I know that a lot of the most successful hedge funds right now are algorithmic trade funds. There is one called Da Vinci, I think, or Renaissance. No, it's called Renaissance and it performs great doing algorithmic trading. But I don't know if AI is ever going to be able to replace humans because if. Somebody gets the same model as the others, then the market adjusts and you are not able to make gains. Well, everything is an imperfect measure in economic, in economics, I mean, we don't have perfect measures. We use what we have and with that we do our best. So I think with, I think that's how we answer this question. I don't see any more questions. Yes, there is a question. Since the market adjusts to the decisions of our trading bot, do you think we need to keep training a model all the time to keep pace? I think so. I think that's the only way. And also sometimes human are better than the trade, the bots. And also I don't, I'm not a fool. I mean sometimes inside information from people who are there on the market is what works best in some cases. Have you seen NLP techniques applied and other kind of data than text? Well, NLP is text data. I mean the name says it and the techniques are applied. Also you can apply to sequence data, NLP techniques and you are going to learn that in the next courses of the specialization. Text summarization how good the latest state of the art is to summarize abstract in an abstract way. I think they're very good. I've seen models that do a great job in terms of summarizing text, but there is always room for improvement.










