Day 38 of 100 Days of AI

Today I went through some concepts I’m already familiar with: sum of the squared residuals, mean squared error, and R-squared. These are important in assessing how good a machine learning model is. Tomorrow I’ll continue revising some key mathematical concepts before getting back into other applied ML basics.

Day 37 of 100 Days of AI

I went through a primer on histograms today, and reviewed Binomial and Poisson distributions. To my surprise, even these simple school maths concepts underly some of the most valuable machine learning classification algorithms we use today.

Tomorrow I’ll continue working through key statistics methods used in machine learning.

Day 36 of 100 Days of AI

I’m travelling for the next 6 days without my laptop so I’ll keep the posts very short given I’m on mobile.

No laptop means no code. However, I’ll work through this wonderful visual introduction to ML from the YouTube channel, StatQuest.

Key takeaways from the first two chapters:

  • Supervised machine learning is broadly just about two things: classification predictions (e.g a binary prediction of whether a particular email is spam or not) and regressions (e.g. given some number of variables, can we predict a house price?)
  • Unsupervised machine learning goes beyond that (e.g. clustering algorithms, neural networks).
  • There are so many machine learning techniques that choosing which ones to use very much depends on the problem. We can also use techniques like cross-validation (k-fold, or leave-one-out etc) to measure which technique provides the best models.

Day 35 of 100 Days of AI

Precision & Recall (aka Sensitivity)

On classification models for ML, I still confuse precision for recall and vice versa. So it was good today that I came across this handy chart that illustrates the differences.

Chart from Zeya, 2021

A good precision score is really important in areas where getting a false positive is high. For example in email spam detection, it’s bad to falsely flag an email from a friend as spam. False positives should be minimised as much as possible in this case. The precision score — the percent measure of predicted true positives relative to “predicted true positives + falsely predicted positives” — is good to know in such cases.

A good recall (or sensitivity) score on the other hand is worth knowing particularly in areas where the cost of a false negative is very high. For example if we built a model that could predict which companies were going to succeed, we don’t want a model that falsley tells us a company is going to fail and we miss out on investing in it. The recall score — the percent measure of predicted true positives relative to all actual cases of true positives — is key in that example.

I also came across this chart on Linkedin which explains the same concept even more visually.

Day 34 of 100 Days of AI

I’m sceptical about “prompt engineering” being a deep specialised thing. It felt a bit like gimmicky hype of a new job profession that would ride the wave of generative AI hype. Why? Because writing LLM prompts isn’t exact an science or precise engineering (more on this here.) However, I’m increasingly changing my view on how credible the skill really is.

Today, I read this article about innovation through prompting, which shares some cool ideas on how to use prompts and LLMs in education. What stood out to me though — and what I also think might happen — was this line in the article:

“…increasingly AIs will just prompt themselves to solve your problem based on your goals.

So actually, will prompt engineering really be a thing or will AI agents just do it?

We’ll find out soon enough.

Day 33 of 100 Days of AI

AI is going to displace lots of jobs. So should we all just retrain away from our non-AI work and specialise to work exclusively on AI?

Article from The Verge

I completed the “AI for Everyone” course today, and near the end, AI expert Andrew Ng shared a story that will be relevant to a variety of careers.

A radiologist just starting out asked Andrew for some career advice. Since AI can now read x-rays, should the radiologist just quit their profession and go into AI instead?

Andrew’s advice was pragmatic: No, you don’t have to.

Yes, you can switch careers if you wish. Some people do so successfully and there are lots of online resources that can help you retrain without spending lots of money.

However, it’s worth considering the alternative: Stay in the radiologist profession but also learn enough about AI to be able to uniquely operate at the intersection of radiology and AI. This combination could be hugely more valuable.

Image from: Subtle Medical

Moreover, AI isn’t yet good enough to replace radiologists completely. In addition, we are facing a global radiologist shortage!

Similar advice can apply to other careers. If you’re training to be a lawyer, learn enough about AI to be a leader at the intersection of law and technology. If you’re a journalist, learn enough about AI to use it in your work to create more value for the public. In my case, I’ve been operating at the intersection technology and finance for a while, but increasingly, I’m also exploring how AI can be leveraged in the venture capital profession.

Ps. Here’s a radiologist’s take. He offers another pragmatic view, posing questions such as, “who’s liable for conclusions of the AI software?”, “how much does it really help?” (good radiologists can read x-rays fast anyway), “do patients trust it?”, and he concludes that he doesn’t think AI will replace him in the near term.

Pss. This video below offers another take. The summary is: (1) AI will augment (not replace) doctors and radiologists. This will allow them to focus on more complex situations. (2) Radiologists will have to adapt and use AI to do better work. (3) We need to use AI responsibility and ethically in such a life-critical field.

Day 32 of 100 Days of AI

Experiment first. Strategy comes after.

In today’s “AI for Everyone” course material, a key highlight was an insight from Andrew Ng. He’s worked on tons of AI projects at companies like Google, Baidu, and other clients in traditional industry.

Usually, people want to dive right into strategy before building things. But his view is that if you want to develop a great AI strategy, do it AFTER you’ve had a chance to experiment and build several pilot projects. Don’t start with strategy. Start with pilots.

It’s hard to appreciate what AI can and can’t do if you haven’t yet built a series of successful small experiments. Only then does it make sense to step back and consider a broader vision and strategy of how AI can add value to a business.

So start early. Start small. Get some quick wins. And only after that is it good to consider a broader AI strategy.

Day 31 of 100 Days of AI

In today’s “AI for Everyone” video, I went through a section on a framework you can use to figure out what AI projects are worth pursuing in a business (rather than research) setting. The framework is simple. Before taking on a project, you work to answer two questions:

(1) Is this AI project feasible?

(2) Is this project valuable?

The first question involves technical due diligence and figuring out whether AI can actually accomplish a particular goal with sufficient performance.

The second question involves business diligence and ascertaining the value an AI project can create, whether that’s financial or otherwise.

Sometimes you know the answers to these questions right away. At other times, you have to build and test proofs-of-concept to get closer to a meaningful answer.

Day 30 of 100 Days of AI

Struggled to get in time to read up on AI today but watched a few videos on the train from the “AI for Everyone” course.

Key takeaways:

  • The workflow of every good machine learning project has 3 broad steps:
    • (1) Collect the data – Not all data is created equal. You can have garbage in, garbage out! So it’s important to determine what you think will be useful data.
    • (2) Train the model – Lots goes into this process. It’s part maths/science and part art/craft.
    • (3) Deploy & Iterate – Most models don’t work perfectly from the get go. You learn new things when you deploy the model in new areas, and can use those learnings to collect new data, and repeat the process by going back to step 1.

Day 29 of 100 Days of AI

I continued the “AI for Everyone” course today.

Key takeaways:

  • Deep learning, a subset of machine learning, is synonymous with neural networks (some shallow neural nets aren’t strictly ‘deep learning’, but broadly speaking, ‘deep learning’ is the catch-all term people have settled with for neural networks).
  • ML works well when you have (a) simple concepts and (b) lots of data. Hard concepts are things like trying to precisely predict what someone will think or do.
  • When working on ML projects, a good idea is to start small with proof-of-concepts early, even if you don’t have all the perfect data you’d want. You can then iterate and figure out what types of data work well, and how to build better. This is an important lesson for me and something I’ve been practising plenty. Building small projects. Running small experiments. Writing throwaway code, and only refining things later if something shows some promise.