AIWiki
Malaysia

Machine Learning

Machine learning is a subfield of artificial intelligence in which systems improve their performance on tasks through experience — by automatically learning patterns from data rather than following explicitly programmed rules.

4 min readLast updated May 2026Foundations

Machine learning (ML) is the scientific study of algorithms and statistical models that enable computer systems to improve their performance on a specific task through experience. Rather than being explicitly programmed with rules, an ML system is given examples (training data) from which it infers a model that can generalise to new, unseen inputs.

The term was coined by Arthur Samuel in 1959 in the context of a checkers-playing program that improved its strategy through self-play.[^1] Today, ML underpins most commercially deployed AI, from spam filters to medical imaging diagnostics.

Learning Paradigms

Supervised Learning

The system is trained on labelled examples — input-output pairs — and learns a mapping function. Common tasks include:

  • Classification — assigning inputs to discrete categories (e.g., spam/not spam, tumour/benign)
  • Regression — predicting continuous values (e.g., house prices, demand forecasting)

Algorithms: linear regression, logistic regression, decision trees, random forests, gradient boosting (XGBoost, LightGBM), support vector machines, neural networks.

Unsupervised Learning

The system discovers hidden structure in unlabelled data.

  • Clustering — grouping similar data points (k-means, DBSCAN, hierarchical clustering)
  • Dimensionality reduction — finding compact representations (PCA, t-SNE, UMAP)
  • Anomaly detection — identifying outliers

Reinforcement Learning (RL)

An agent learns by interacting with an environment, receiving rewards or penalties for actions. RL produced landmark results including AlphaGo (2016) and AlphaStar (2019), and underlies modern RLHF (Reinforcement Learning from Human Feedback) used to align LLMs.

Self-supervised / Foundation Models

A modern paradigm where models are pre-trained on massive unlabelled corpora using proxy tasks (e.g., predicting masked tokens). The resulting representations transfer well to downstream tasks. Large language models such as GPT-4, Claude, and Gemini are trained this way.

The ML Pipeline

A typical production ML system involves:

  1. Data collection and labelling — the most time-consuming phase in practice
  2. Exploratory Data Analysis (EDA) — understanding distributions, correlations, and anomalies
  3. Feature engineering — transforming raw data into informative input representations
  4. Model selection and training — choosing an algorithm and fitting it to training data
  5. Evaluation — measuring performance on held-out data (accuracy, F1, AUC-ROC, etc.)
  6. Hyperparameter tuning — optimising model configuration
  7. Deployment — serving predictions in production (REST API, batch inference, edge)
  8. Monitoring — detecting data drift, performance degradation, concept drift

Common Pitfalls

  • Overfitting — model memorises training data but fails to generalise
  • Data leakage — information from the test set contaminates training
  • Class imbalance — biased predictions when one class heavily dominates
  • Distribution shift — training and deployment data differ in important ways
  • Spurious correlations — model relies on coincidental patterns rather than causal features

Evaluation Metrics

| Task | Primary Metrics | |------|----------------| | Classification (balanced) | Accuracy, F1-score, AUC-ROC | | Classification (imbalanced) | Precision-Recall AUC, MCC | | Regression | RMSE, MAE, R² | | Ranking | NDCG, MAP | | Clustering | Silhouette score, Davies-Bouldin |

Key Libraries and Frameworks

  • scikit-learn — gold standard for classical ML in Python
  • XGBoost / LightGBM / CatBoost — gradient boosting; dominant in tabular-data competitions
  • TensorFlow / Keras — Google's deep learning framework
  • PyTorch — Facebook's deep learning framework; preferred in research
  • Hugging Face Transformers — pre-trained transformer models for NLP

References

  1. Samuel, A.L. (1959). "Some Studies in Machine Learning Using the Game of Checkers." IBM Journal of Research and Development, 3(3), 210–229.
  2. Mitchell, T.M. (1997). Machine Learning. McGraw-Hill.
  3. MDEC (2023). State of AI in Malaysia 2023. Malaysia Digital Economy Corporation.