Cermi Assignment AI week 3_Komalasari_2681483783

Nama : Komalasari

NIM: 2681483783

Question :

  1. What is the key difference between supervised and unsupervised learning? Provide an example for each.

  2. What is “overfitting” in a machine learning model, and why is it a problem?

  3. Describe the three main components of reinforcement learning: agent, environment, and reward.

  4. How does a training dataset differ from a testing dataset, and why is this separation important?

Answer :

1.

The key difference is labeled data. In supervised learning, the model is trained on labeled data , every input comes with a known correct output.

 In unsupervised learning, the model works with unlabeled data and must find patterns or structure on its own.

  • Supervised example: Email spam detection — emails labeled “spam” or “not spam” train the model to classify new emails.
  • Unsupervised example: Customer segmentation — a retailer feeds purchase data without labels, and the model groups customers by similar buying behavior.

2.

Overfitting happens when a model learns the training data too well ,including its noise and random quirks , instead of learning the general underlying pattern. It becomes a problem because the model performs excellently on training data but poorly on new, unseen data. In other words, it memorizes rather than generalizes, which defeats the purpose of building a predictive model. 

3.

The three main components of reinforcement learning are the agent (the decision-maker), the environment (the world it interacts with), and the reward (the feedback signal guiding its choices).

 

  1. Agent
  • Definition: The learner or decision-maker that interacts with the surroundings.
  • Role: It observes the current situation, makes choices, and takes actions.
  • Example: A self-driving car’s software algorithm or a robot learning to walk. 
  1. Environment
  • Definition: The external world or context where the agent lives and operates.
  • Role: It receives actions from the agent, changes its own state, and presents new situations and feedback back to the agent.
  • Example: A simulated roadway or a physical room where a robot moves. 
  1. Reward
  • Definition: A numerical feedback signal sent from the environment. 
  • Role: It tells the agent how good or bad an action was. Positive numbers mean success, while negative numbers (penalties) mean failure. 
  • Example: Gaining points for finishing a video game level or losing points for crashing a car. 

4.A training dataset is used to teach the model — the model adjusts its parameters based on it. A testing dataset is separate data the model has never seen, used to evaluate how well it generalizes. This separation is important because if we tested on the same data used for training, the model could simply memorize the answers and appear accurate while actually failing on real-world data (overfitting). The test set gives an

status : selesai 100%

 

Previous Post Previous Post
Newer Post Newer Post

Leave a comment