<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>Forem: Olaleye Aanuoluwapo Kayode</title>
    <description>The latest articles on Forem by Olaleye Aanuoluwapo Kayode (@d_great_oak).</description>
    <link>https://forem.com/d_great_oak</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F1231996%2F3698c46b-199f-4bdd-9999-3c433b9baae7.jpg</url>
      <title>Forem: Olaleye Aanuoluwapo Kayode</title>
      <link>https://forem.com/d_great_oak</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/d_great_oak"/>
    <language>en</language>
    <item>
      <title>From Chatbots to Agents: 5 Architecture Shifts Breaking the "Stochastic Parrot"</title>
      <dc:creator>Olaleye Aanuoluwapo Kayode</dc:creator>
      <pubDate>Tue, 10 Mar 2026 10:45:43 +0000</pubDate>
      <link>https://forem.com/d_great_oak/from-chatbots-to-agents-5-architecture-shifts-breaking-the-stochastic-parrot-f2p</link>
      <guid>https://forem.com/d_great_oak/from-chatbots-to-agents-5-architecture-shifts-breaking-the-stochastic-parrot-f2p</guid>
      <description>&lt;p&gt;Read the original research paper &lt;a href="https://arxiv.org/abs/2510.04871" rel="noopener noreferrer"&gt;here&lt;br&gt;
&lt;/a&gt;&lt;br&gt;
For the last couple of years, the machine learning community has been playing the exact same game: pour more data and compute into a transformer, and watch it get smarter. It’s the classic "Scaling Law" playbook, and honestly, it worked incredibly well.&lt;/p&gt;

&lt;p&gt;Until it didn’t.&lt;/p&gt;

&lt;p&gt;As we try to push LLMs into open-ended, messy, real-world environments, we are hitting a hard ceiling. We’re officially watching the end of the "stochastic parrot" era the phase where models just give us passive, one-shot predictions based on whatever static prompt we hand them.&lt;/p&gt;

&lt;p&gt;The frontier has moved. We aren't just scaling model size anymore; we are scaling test-time interaction. AI is moving away from being a reactive text generator and turning into an autonomous agent that can actually think, verify, and act.&lt;/p&gt;

&lt;p&gt;As a systems engineer looking at how we build and deploy these things, this transition completely rewrites our infrastructure playbook. I just finished digging into the research on agentic reasoning, and here are my five biggest takeaways on what this means for the systems we’re building next.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Moving from "Guessing" to the "Think-Act" Loop
Traditional models are basically autocomplete on steroids. You ask a question, and the model blurts out the most statistically probable next words in a single pass.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Agentic systems completely flip this on its head by separating the internal "thinking" from the external "doing."&lt;/p&gt;

&lt;p&gt;Think of traditional AI like someone shouting out the first answer that pops into their head. Agentic AI is more like a professional drafting an email, reading it over, spotting a mistake, fixing it, and then finally hitting send.&lt;/p&gt;

&lt;p&gt;Instead of just spitting out an answer, the model uses an internal scratchpad (a latent reasoning space). It plans ahead, catches its own potential failures, and verifies its logic before making a move. Reasoning isn't just a side effect of generating text anymore; it’s the core engine of the system.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;AI That Codes Its Own Tools (The LATM Framework)
Right now, if an LLM doesn't have a specific API to do a task, it just apologizes and fails. They are stuck in a closed loop.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Agentic reasoning breaks us out of that through "Self-evolving Tool-use." When a powerful agent hits a bottleneck it can't solve, it doesn't just give up. It autonomously writes a new Python script to solve the problem, packages it up as a function, and hands it off to a smaller, cheaper model to actually run.&lt;/p&gt;

&lt;p&gt;Instead of handing the AI a pre-written API, we are essentially teaching it how to build its own tools on the fly.&lt;/p&gt;

&lt;p&gt;The Engineering Reality: From a backend perspective, this is both amazing and a complete nightmare. If an AI is writing and executing its own scripts in real-time to solve edge cases, how do we handle CI/CD? We are going to have to engineer entirely new, ultra-secure dynamic sandboxes just to let these agents experiment without taking down production.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;We Need to Stop Hoarding Data (Optimized Forgetting)
If you work in AI right now, you know everyone is obsessed with RAG (Retrieval-Augmented Generation). We just keep shoving more and more embeddings into massive vector databases. But this paper suggests we’re looking at memory all wrong.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;In an agentic system, memory isn't just a passive storage bucket. The model actively learns to manipulate it.&lt;/p&gt;

&lt;p&gt;Using frameworks like Memory-R1, agents use reinforcement learning to manage their own cognitive load. They use a "Memory Manager" to figure out what to keep, update, or crucially delete to reduce noise, while an "Answer Agent" uses what's left to actually solve the problem.&lt;/p&gt;

&lt;p&gt;The Engineering Reality: This proves that "optimized forgetting" is the actual future. We need to stop building bottomless storage buckets and start engineering intelligent memory filters.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Agents Talking to Agents
We are moving from isolated chatbots to collaborative ecosystems (Multi-Agent Systems). In this setup, one agent’s output isn't just text for a human to read; it’s a prompt that triggers the internal thought process of another agent.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;You end up with specialized roles: Coordinators breaking down tasks, Executors writing the code, and Evaluators auditing the work for logic flaws.&lt;/p&gt;

&lt;p&gt;The Engineering Reality: This completely breaks how we handle AI safety right now. Today, we mostly just filter "bad text" right before it reaches the user. But if agents are planning long-term goals and secretly communicating with each other in the background, those text filters are useless. We have to figure out how to audit their reasoning loops, not just their final outputs.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Thinking Harder, Not Just Training Longer
For me, the biggest takeaway is the shift toward scaling test-time compute.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Instead of trying to teach the model absolutely everything before it's deployed (offline pre-training), we are building systems that spend more compute during inference. It's the difference between studying for a year but only having 5 minutes to take a test, versus studying for a month but having 5 hours to carefully work through every question.&lt;/p&gt;

&lt;p&gt;The industry is moving toward GRPO (Group Relative Policy Optimization). Instead of needing a massive, separate "judge" model to grade the AI's homework, GRPO lets the model learn complex reasoning just by comparing a bunch of its own generated answers to see which path works best.&lt;/p&gt;

&lt;p&gt;The Architecture Shift: A Quick Reference&lt;br&gt;
To visualize how drastically our infrastructure demands are changing, here is how the static Chatbot era compares to the new Agentic reality:&lt;/p&gt;

&lt;p&gt;How it computes:&lt;/p&gt;

&lt;p&gt;The Chatbot Era: Single forward pass&lt;/p&gt;

&lt;p&gt;The Agent Era: Multi-step search &amp;amp; reasoning&lt;/p&gt;

&lt;p&gt;How it learns:&lt;/p&gt;

&lt;p&gt;The Chatbot Era: Offline pre-training&lt;/p&gt;

&lt;p&gt;The Agent Era: Continual &amp;amp; self-evolving&lt;/p&gt;

&lt;p&gt;Memory:&lt;/p&gt;

&lt;p&gt;The Chatbot Era: Short-term context window&lt;/p&gt;

&lt;p&gt;The Agent Era: State tracking &amp;amp; memory editing&lt;/p&gt;

&lt;p&gt;Goal:&lt;/p&gt;

&lt;p&gt;The Chatbot Era: Reactive (You prompt, it answers)&lt;/p&gt;

&lt;p&gt;The Agent Era: Explicit, long-term planning&lt;/p&gt;

&lt;p&gt;The Bottom Line for Engineers&lt;br&gt;
Agentic reasoning is taking us from building "text interfaces" to building actual "functional partners."&lt;/p&gt;

&lt;p&gt;But the technical hurdles are massive. We have to figure out how to keep a model coherent over weeks of execution without its memory collapsing. And more importantly, we have to ask if our current governance and audit protocols are ready for systems that plan, learn, and collaborate without us in the loop.&lt;/p&gt;

&lt;p&gt;The era of the stochastic parrot is wrapping up. It’s time to start building the agents.&lt;/p&gt;

&lt;p&gt;Originally published on &lt;a href="https://medium.com/@olaleyeaanuoluwapokay/why-we-need-to-stop-building-chatbots-4ca947db1239" rel="noopener noreferrer"&gt;Medium&lt;/a&gt;. If you are building agentic systems or scaling AI infrastructure, let's connect via my &lt;a href="https://linktr.ee/oak.eth" rel="noopener noreferrer"&gt;Linktree&lt;/a&gt; to keep the conversation going!&lt;/p&gt;

</description>
      <category>ai</category>
      <category>softwareengineering</category>
      <category>machinelearning</category>
      <category>generativeai</category>
    </item>
    <item>
      <title>Why I Moved My ML Model from Flask to AWS Lambda (A Student’s Guide to $0 Hosting)</title>
      <dc:creator>Olaleye Aanuoluwapo Kayode</dc:creator>
      <pubDate>Thu, 22 Jan 2026 04:41:35 +0000</pubDate>
      <link>https://forem.com/d_great_oak/why-i-moved-my-ml-model-from-flask-to-aws-lambda-a-students-guide-to-0-hosting-3mmf</link>
      <guid>https://forem.com/d_great_oak/why-i-moved-my-ml-model-from-flask-to-aws-lambda-a-students-guide-to-0-hosting-3mmf</guid>
      <description>&lt;p&gt;Some months ago, I built a machine learning model to predict diabetes risk using the Pima Indians Diabetes dataset. It was a standard student project: a Jupyter notebook, some Scikit-learn code, and a Random Forest Classifier. It worked perfectly on my laptop.&lt;/p&gt;

&lt;p&gt;But when I wanted to deploy it so a friend could actually use it, I hit a wall.&lt;/p&gt;

&lt;p&gt;The standard advice on the internet is usually "Just Dockerize it and run it on AWS Fargate" or "Spin up an EC2 instance and run a Flask server."&lt;/p&gt;

&lt;p&gt;For a student developer in Nigeria, that advice is dangerous.&lt;/p&gt;

&lt;p&gt;The "Always-On" Problem&lt;br&gt;
An EC2 instance is like a generator that you leave running 24/7 just in case someone wants to turn on a light switch once a week. You pay for it every second it runs.&lt;/p&gt;

&lt;p&gt;If I deployed my Diabetes Predictor on an EC2 t3.medium, it would cost me money even at 3:00 AM when nobody is using it. Operating on a student budget with unpredictable exchange rates, "low cost" isn't just a preference—it's a requirement.&lt;/p&gt;

&lt;p&gt;I needed an architecture that was "lazy"—one that only wakes up when it has work to do.&lt;/p&gt;

&lt;p&gt;Step 1: The "Easy" Part (Training the Model)&lt;br&gt;
First, I trained the model using a Random Forest Classifier. This part was straightforward. I used the standard dataset from the UCI Machine Learning Repository.&lt;/p&gt;

&lt;p&gt;Here is the core of the training logic I used:&lt;/p&gt;

&lt;p&gt;Python&lt;/p&gt;

&lt;h1&gt;
  
  
  Import Libraries
&lt;/h1&gt;

&lt;p&gt;import pandas as pd&lt;br&gt;
from sklearn.preprocessing import StandardScaler&lt;br&gt;
from sklearn.model_selection import train_test_split&lt;br&gt;
from sklearn.ensemble import RandomForestClassifier&lt;br&gt;
from sklearn.metrics import accuracy_score&lt;br&gt;
import joblib&lt;/p&gt;

&lt;h1&gt;
  
  
  Load Dataset &amp;amp; Preprocess
&lt;/h1&gt;

&lt;p&gt;data_url = "&lt;a href="https://raw.githubusercontent.com/jbrownlee/Datasets/master/pima-indians-diabetes.data.csv" rel="noopener noreferrer"&gt;https://raw.githubusercontent.com/jbrownlee/Datasets/master/pima-indians-diabetes.data.csv&lt;/a&gt;"&lt;br&gt;
columns = ['Pregnancies', 'Glucose', 'BloodPressure', 'SkinThickness', 'Insulin', 'BMI', 'DiabetesPedigreeFunction', 'Age', 'Outcome']&lt;br&gt;
df = pd.read_csv(data_url, header=None, names=columns)&lt;/p&gt;

&lt;p&gt;X = df.drop('Outcome', axis=1)&lt;br&gt;
y = df['Outcome']&lt;/p&gt;

&lt;p&gt;scaler = StandardScaler()&lt;br&gt;
X_scaled = scaler.fit_transform(X)&lt;br&gt;
X_train, X_test, y_train, y_test = train_test_split(X_scaled, y, test_size=0.2, random_state=42)&lt;/p&gt;

&lt;h1&gt;
  
  
  Model Training
&lt;/h1&gt;

&lt;p&gt;model = RandomForestClassifier(n_estimators=100, random_state=42)&lt;br&gt;
model.fit(X_train, y_train)&lt;/p&gt;

&lt;h1&gt;
  
  
  The most important part for deployment:
&lt;/h1&gt;

&lt;p&gt;joblib.dump(model, "diabetes_predictor.pkl")&lt;br&gt;
Most tutorials stop here. They tell you to save the model and... good luck. But a .pkl file on my hard drive doesn't help anyone.&lt;/p&gt;

&lt;p&gt;Step 2: The Pivot to Serverless&lt;br&gt;
I decided to rip out the idea of a dedicated server. I didn't need an OS; I just needed a place to run model.predict().&lt;/p&gt;

&lt;p&gt;Here is the architecture I designed to keep costs at effectively $0.00:&lt;/p&gt;

&lt;p&gt;The Storage: I uploaded my diabetes_predictor.pkl file to an Amazon S3 bucket. (Cost: Pennies).&lt;/p&gt;

&lt;p&gt;The Compute: I wrote a Python function using AWS Lambda.&lt;/p&gt;

&lt;p&gt;The Front Door: I connected it to Amazon API Gateway to give it a public URL.&lt;/p&gt;

&lt;p&gt;Step 3: The Deployment Code&lt;br&gt;
This was the tricky part. You can't just copy-paste your Jupyter Notebook into AWS Lambda. You have to write a "Handler" that knows how to talk to S3.&lt;/p&gt;

&lt;p&gt;I had to write a script that pulls the model from S3 into the Lambda's temporary storage (/tmp) before it can make a prediction.&lt;/p&gt;

&lt;p&gt;Here is the actual code running in my Lambda function (which is also in my GitHub repo):&lt;/p&gt;

&lt;p&gt;Python&lt;br&gt;
import json&lt;br&gt;
import boto3&lt;br&gt;
import joblib&lt;br&gt;
import os&lt;br&gt;
import numpy as np&lt;/p&gt;

&lt;h1&gt;
  
  
  Initialize S3 client
&lt;/h1&gt;

&lt;p&gt;s3 = boto3.client('s3')&lt;br&gt;
BUCKET_NAME = os.environ.get('BUCKET_NAME', 'my-diabetes-model-bucket')&lt;br&gt;
MODEL_FILE_NAME = os.environ.get('MODEL_FILE_NAME', 'diabetes_predictor.pkl')&lt;/p&gt;

&lt;p&gt;def load_model_from_s3():&lt;br&gt;
    """Downloads the model from S3 to the /tmp directory"""&lt;br&gt;
    download_path = f'/tmp/{MODEL_FILE_NAME}'&lt;br&gt;
    if not os.path.exists(download_path):&lt;br&gt;
        s3.download_file(BUCKET_NAME, MODEL_FILE_NAME, download_path)&lt;br&gt;
    return joblib.load(download_path)&lt;/p&gt;

&lt;p&gt;model = None&lt;/p&gt;

&lt;p&gt;def lambda_handler(event, context):&lt;br&gt;
    global model&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;# 1. Load the model if it's not ready
if model is None:
    model = load_model_from_s3()

try:
    # 2. Parse the incoming JSON body
    body = json.loads(event['body'])

    # Extract features matching training columns
    features = np.array([[
        body['Pregnancies'], body['Glucose'], body['BloodPressure'],
        body['SkinThickness'], body['Insulin'], body['BMI'],
        body['DiabetesPedigreeFunction'], body['Age']
    ]])

    # 3. Predict
    prediction = model.predict(features)
    result = int(prediction[0])

    return {
        'statusCode': 200,
        'body': json.dumps({'prediction': result})
    }

except Exception as e:
    return {
        'statusCode': 500,
        'body': json.dumps({'error': str(e)})
    }
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;The "Ibadan" Constraint: Battling Latency&lt;br&gt;
The hardest part wasn't the code; it was the latency.&lt;/p&gt;

&lt;p&gt;When you use Serverless, the function "goes cold" if nobody uses it for a while. The next time someone clicks "Predict," AWS has to spin up the environment, download Python libraries, and load the model.&lt;/p&gt;

&lt;p&gt;On my first test, it took 4 seconds to get a result. On a slow 4G network, that felt like an eternity.&lt;/p&gt;

&lt;p&gt;The Fix: I learned a counter-intuitive trick from the AWS docs: Increase the memory to save time.&lt;/p&gt;

&lt;p&gt;I bumped the Lambda memory from 128MB to 512MB. I wasn't just getting more RAM; I was getting more CPU power. The function started loading in under 1.5 seconds.&lt;/p&gt;

&lt;p&gt;Because AWS bills by the millisecond, the faster function actually cost me slightly less money than the slower, weaker one because it finished the job so much quicker.&lt;/p&gt;

&lt;p&gt;Conclusion&lt;br&gt;
This project taught me that Cloud Engineering isn't just about making things work. It's about making them viable for your specific constraints.&lt;/p&gt;

&lt;p&gt;By moving to Serverless, I built an app that can scale to thousands of users but costs me nothing when it’s idle. For developers in emerging markets, mastering these "frugal" architectures is a superpower.&lt;/p&gt;

&lt;p&gt;Check out the full code on my GitHub: &lt;a href="https://github.com/OAKVISUALZ/Prediction-of-Diabetes/" rel="noopener noreferrer"&gt;https://github.com/OAKVISUALZ/Prediction-of-Diabetes/&lt;/a&gt;&lt;/p&gt;

</description>
      <category>aws</category>
      <category>python</category>
      <category>serverless</category>
      <category>machinelearning</category>
    </item>
  </channel>
</rss>
