Home Blog Store
Machine Learning

Machine Learning from Scratch: How Machines Find Patterns and Make Decisions

Hartono 03 Oct 2026 5 min read 234 Viewed Baca dalam Bahasa Indonesia
Machine Learning from Scratch: How Machines Find Patterns and Make Decisions

ArtonLabs colleagues, the term machine learning feels familiar by now, but many still imagine it as a magic box that can suddenly think for itself. In reality, behind the scenes, machine learning is very tidy mathematical hard work: we give the machine examples, it looks for patterns, and those patterns are then used to predict things it has never seen. You may not realize it, but every time you open a banking app and a suspicious transaction notification appears, or when a streaming service serves up a show that happens to match your taste, that is where machine learning is at work. This article discusses the basics practically, from concepts to the first steps you can try yourself.

To make your reading more focused, here is a map of this article's contents:

What Machine Learning Actually Is

The easiest way to understand it is by comparing two styles of programming. In ordinary software, you write rules explicitly: if the balance is less than the transaction amount, reject. The problem is, many real-world problems cannot be formulated as a set of rigid rules. How do you write rules that can truly distinguish important emails from fraudulent ones, with writing styles that keep changing? Here machine learning takes the opposite approach: we give examples along with their answers, and then the algorithm composes the rules itself.

The final result of that process takes various forms, depending on the need:

  • Classification models to answer questions of what type (spam or not, healthy or at risk).
  • Regression models to predict numbers, such as demand or price estimates.
  • Clustering models to find hidden groups without labels.
  • Generative models that produce new text, images, or sound, including what we now commonly call generative AI.

Three Ways Machines Learn from Data

Broadly speaking, there are three approaches you need to know. Supervised learning is the most common: the training data already has correct labels, and the model is asked to imitate that mapping. Unsupervised learning works without labels, suitable for exploration and customer segmentation. Reinforcement learning trains an agent through rewards and punishments, an approach that lets systems learn strategies gradually.

Recently, there is one additional approach that has actually become the main driving force: self-supervised learning. The model is asked to predict hidden parts of data across billions of examples without human annotation. This is where large language models and multimodal models capable of processing text, images, and audio at once were born. The mindset is the same as the three approaches above, only the scale is far larger.

A Healthy Project Workflow

The success of a machine learning project is rarely determined by the most sophisticated model. What determines it is discipline at each of the following stages:

  • Defining the business question. First formulate what decision you want to improve, not what algorithm you want to use.
  • Collecting and cleaning data. Missing data, duplicates, and anomalies must be sorted out before entering the model.
  • Feature engineering. Transforming raw data into meaningful representations, for example the average of transactions over the last seven days.
  • Training and evaluation. Use an honest data split as well as cross validation so the results are not misleading.
  • Deployment. The model must be wrapped as an API or service so other systems can call it, with realistic latency limits.
  • Monitoring. Monitor performance periodically, because data patterns can shift over time.

Tools and the Direction of Development

For those of you who want to try, the Python ecosystem is already very mature. scikit-learn remains the best starting point for classic models because its API is consistent and lightweight. pandas handles tabular data processing, while PyTorch and TensorFlow are the main choices for deep learning. On the engineering side, resource-efficient fine-tuning practices such as LoRA and PEFT make it possible to adapt large models at only a fraction of the full training cost.

There are three directions of development worth monitoring. First, automation of model selection and tuning (AutoML), which increasingly cuts down repetitive work. Second, quantization and small-sized models that can run on simple servers and even edge devices, not only in large data centers. Third, integration of models into application workflows as agents capable of calling other tools, not merely answering questions.

The Pitfalls That Most Often Bring Down Projects

Many teams are disappointed because a model looks great on a laptop, then fails completely when used. Usually the causes are classic and can be anticipated:

  • Overfitting, when the model memorizes the training data instead of capturing general patterns.
  • Data leakage, which is when information from the test data enters the training process so the evaluation score looks too good.
  • Class imbalance where important cases are actually very few in number.
  • Bias in the data that makes the model disadvantage certain groups.
  • Model drift when user behavior changes and the old model loses relevance.

Small Steps to Start Today

You do not need to wait for giant data or expensive servers to learn. Start with something simple and concrete:

  • Take one open dataset close to your work, for example sales data or product reviews.
  • Build a baseline model first, for example logistic regression or a simple decision tree, as a benchmark.
  • Record every experiment along with its metrics so they can be compared fairly.
  • Wrap the best model as a small API, then test it with genuinely new data.
  • Prepare a periodic evaluation process before thinking about more complicated models.

In the end, machine learning is not magic, but a discipline of thinking: formulating problems clearly, treating data with respect, and measuring results honestly.

ArtonLabs colleagues, thank you for following this discussion about machine learning to the end. We hope the explanation above gives you enough of a picture to start taking steps, whether as a developer, analyst, or product owner. If there is any part that still feels unclear, you want to discuss model selection, or you need guidance for your own data project, do not hesitate to send your questions through our contact page. We are happy to help you understand this technology more calmly and in a more focused way.

Hartono
Diterbitkan 03 Oct 2026