Day 4/60 Reviewing AI & Machine Learning: Machine Learning Powered Apps

Today we dive into the field of applications powered by machine learning. 

ML products are more than just training a model on a dataset. They require careful consideration of data preprocessing (preparing the data), feature engineering, model selection, and hyperparameter tuning. Additionally, deploying, maintaining, and continuously improving the model in a real-world environment are critical aspects that ensure the success of ML applications. 

ML research in 2 minutes!

ArXiv - a popular electronic archive of research papers

At the time of me writing, they have nearly 2.4 million scholarly articles in the fields of physics, mathematics, computer science, quantitative biology, quantitative finance, statistics, electrical engineering and systems science, and economics.

It contains thousands of articles submitted about new models or the R&D of models in creation. 


Building a Revolutionary ML Product: From Inception to Reality


Article content

Identify a problem

  • Always begin with the user/customer experience
  • NEVER begin with the technology
  • Let the end goal and the experience of the end user determine the technology

Conduct Feasibility Study

  • Technical Feasibility: Assess whether the problem can be solved using ML. Research existing solutions and state-of-the-art techniques in the field.
  • Data Availability: Determine if you have access to sufficient and high-quality data required to train your model.

Define the OKR framework for your model

After you have determined that your problem is feasible to be tackled using ML, you should develop an OKR framework for it. It not only gives you a clear direction and assessment of it but also can be easily integrated into a team environment where everyone works towards a common objective along with clear key results. 

  • O → Objective: What does your model aim to achieve?
  • KR → Key Result(s): What metrics can truly measure the success and progress of your model that leaves little room for ambiguity?

Example: poor OKR framework for your model

  • Objective: improve user satisfaction
  • Key Results:

Here, we have set a decent goal, to improve user satisfaction. However, the key results are not measurable. We can increase the accuracy, but by how much? We can reduce the loss of the model, but by how much? Or using what algorithm? 


Now, let’s see an improved version of an OKR for a model

Example: average OKR framework for your model

  • Objective: Enhance the predictive accuracy of the sales forecasting model.
  • Key Results:

This seems very clear and strong. In the eyes of an AI engineer, it may seem strong and actionable. However, from a business perspective, it is average. Why? It could benefit from more clarity on the impact and timelines.


Example: strong OKR framework for your model

  • Objective: Achieve best-in-class predictive performance for the sales forecasting model to drive business growth.
  • Key Results:

There we go! The objective is aspirational and aligned with both the technological and business goals. The key results are specific, measurable, time-bound, and directly tied to the model’s performance and impact on the business. This leaves little room for ambiguity and provides a clear path to achieving the objective.

Data Collection and Preparation

  • Data Gathering: Collect relevant data from various sources such as databases, APIs, web scraping, or through manual data entry.
  • Data Cleaning: Handle missing values, outliers, and inconsistencies to ensure data quality.
  • Data Annotation: Label the data if necessary (e.g., for supervised learning tasks). For example, I personally use CVAT for annotating images


Article content

Data Analysis

  • Descriptive Statistics: use statistical methods such as standard deviation to understand the distribution and properties of the data
  • Visualization: create plots and charts to visualize patterns, correlations, and potential anomalies. Use libraries like matplotlib

Model Selection

  • Research Models: Explore different ML algorithms and models suitable for your problem (e.g., decision trees, neural networks, SVMs).
  • Pre-trained Models: Consider using pre-trained models and fine-tuning them to save time and resources

Model Training and Evaluation

  • Split Data: Divide your dataset into training, validation, and test sets to evaluate model performance.
  • Training

Deployment

  • Deploy Model: Choose a deployment strategy (cloud, edge, on-premises) and deploy the model to a production environment.
  • API Integration: Integrate the model with your application through APIs to enable real-time predictions.

Iterate through the build-learn-adapt life cycle

Once your model is released for customers to use, you have already went through the build-learn-adapt life cycle once! Let’s break it down:

  • Build: you built the prototype of the model. Congratulations!
  • Learn: you learned from the challenges along the way and you gained new experiences and insights
  • Adapt: with the new insights and experiences, you adapted and adjusted your model to overcome challenges or adhere to newly acquired insights.

After deployment, it is only a matter of iterating through this loop.


def build():
   return "Build your product by leveraging validated learning from customer feedback, data analysis, and iterative experiments."

def measure_and_learn():
    return "Continuously gather actionable data and insights from experiments and customer interactions. Analyze results to understand what works and what doesn’t, and refine your hypotheses."

def pivot_or_persevere():
    return "Based on your learnings, decide whether to pivot (make a fundamental change). Adapt your approach to align with validated insights and customer needs."

def innovate():
    return "Embrace innovation by experimenting with new ideas and approaches. Use the feedback loop to drive incremental improvements and stay agile."

in_production = True

while in_production:
    build()
    measure_and_learn()
    pivot_or_persevere()
    innovate()        

To view or add a comment, sign in

More articles by Tom Zhang

Insights from the community

Others also viewed

Explore topics