<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by vikrez on Medium]]></title>
        <description><![CDATA[Stories by vikrez on Medium]]></description>
        <link>https://medium.com/@vikrez?source=rss-cca42fe8ae6b------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*Su71Auj5ufEMCRvkU5foXQ.jpeg</url>
            <title>Stories by vikrez on Medium</title>
            <link>https://medium.com/@vikrez?source=rss-cca42fe8ae6b------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Thu, 03 Dec 2026 00:14:32 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@vikrez/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Building Multilingual NLP for Nigerian Languages Under a 1B-Parameter Limit]]></title>
            <link>https://medium.com/@vikrez/building-multilingual-nlp-for-nigerian-languages-under-a-1b-parameter-limit-3463c71e5758?source=rss-cca42fe8ae6b------2</link>
            <guid isPermaLink="false">https://medium.com/p/3463c71e5758</guid>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[nlp]]></category>
            <category><![CDATA[african-languages]]></category>
            <category><![CDATA[multilingual-nlp]]></category>
            <category><![CDATA[artificial-intelligence]]></category>
            <dc:creator><![CDATA[vikrez]]></dc:creator>
            <pubDate>Sun, 27 Sep 2026 17:19:50 GMT</pubDate>
            <atom:updated>2026-09-27T17:19:50.719Z</atom:updated>
            <content:encoded><![CDATA[<h3>DSN Bootcamp Hackathon 2026 — LLM/Agent Track</h3><p>Nigeria has more than 500 living languages, but most modern language models are still significantly stronger in English than they are in African languages.</p><p>That was one of the things that made the <strong>DSN Bootcamp Hackathon 2026 LLM/Agent Track</strong> interesting to me.</p><p>The challenge involved four Nigerian languages:</p><ul><li>Hausa (hau)</li><li>Igbo (ibo)</li><li>Yoruba (yor)</li><li>Nigerian Pidgin (pcm)</li></ul><p>Given a news article in one of these languages, the system had to do two things:</p><ol><li>Classify the article into one of seven topics.</li><li>Generate a headline in the same language as the article.</li></ol><p>Both tasks contribute equally to the final competition score.</p><p>Simple enough on paper.</p><p>But once I started experimenting, it quickly became a problem involving multilingual NLP, numerical instability, GPU memory, retrieval, generation quality and even notebook reliability.</p><p>Here’s how it went.</p><h3>The Challenge</h3><p>The topic labels are:</p><ul><li>Business</li><li>Health</li><li>Politics</li><li>Religion</li><li>Sports</li><li>Entertainment</li><li>Technology</li></ul><p>Topic classification is evaluated using <strong>Macro-F1</strong>.</p><p>That matters because the dataset isn’t balanced. Macro-F1 gives every category equal importance, so performing really well on common categories like politics or entertainment while struggling with smaller categories isn’t enough.</p><p>Headline generation is evaluated using:</p><ul><li><strong>ROUGE-L</strong>, which measures lexical overlap with the reference headline.</li><li><strong>BERTScore</strong>, which measures semantic similarity using a multilingual representation model.</li></ul><p>Both components are then combined equally into the leaderboard score.</p><p>So I couldn’t build a great classifier and ignore generation.</p><p>And I couldn’t generate good headlines while getting the topics wrong either.</p><p>I needed both.</p><h3>Then There’s the 1B-Parameter Limit</h3><p>This is where things became more interesting.</p><p>The scored model must contain <strong>fewer than one billion parameters</strong>.</p><p>Training, fine-tuning and inference also have to happen inside a single notebook using free GPU infrastructure:</p><ul><li>1× Tesla T4 on Google Colab, or</li><li>2× Tesla T4 on Kaggle.</li></ul><p>No externally trained competition checkpoints, clusters or high-end GPUs for the scored system.</p><p>Some of the models suggested by the competition include:</p><ul><li>mT5-small</li><li>mT5-base</li><li>AfriBERTa</li><li>XLM-RoBERTa-base</li><li>Qwen2.5–0.5B</li><li>SmolLM2–360M</li></ul><p>So compute wasn’t something I could just solve by throwing more hardware at the problem.</p><p><strong>Efficiency was part of the problem.</strong></p><h3>First, I Needed to Understand the Data</h3><p>The working training dataset contained <strong>6,068 examples</strong> across the four languages.</p><p>The category distribution looked like this:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*RzTivz_IVxw_agZmNm3OBA.png" /></figure><p>The imbalance is obvious.</p><p>Technology has only 203 examples, while Entertainment and Politics each have more than 1,200.</p><p>Again, because we’re dealing with Macro-F1, those smaller categories still matter.</p><p>The test set contains <strong>1,743 articles</strong>.</p><p>And because every article needs both a topic and a headline:</p><p><strong>1,743 topic predictions + 1,743 headline predictions = 3,486 submission rows.</strong></p><h3>I Separated the Two Problems During Development</h3><p>The final system needs to solve both tasks, but while experimenting, I found it much easier to debug them independently.</p><p>Topic classification has seven possible outputs.</p><p>Headline generation is completely different.</p><p>The generated headline needs to preserve:</p><ul><li>Meaning</li><li>Language</li><li>Important entities</li><li>News style</li><li>Conciseness</li></ul><p>And the ways those two systems fail are very different.</p><p>Separating them during development made it much easier to figure out exactly where things were going wrong.</p><h3>Topic Classification Experiments</h3><p>For classification, I experimented with TF-IDF using several configurations:</p><ul><li>Word n-grams</li><li>Character n-grams</li><li>Character-within-word-boundary n-grams</li><li>Article text</li><li>Headline text</li><li>Combined headline and article representations</li></ul><p>Character-level representations were particularly interesting.</p><p>When you’re working across multiple languages, exact word matching can become restrictive. Character patterns give you another way to capture recurring morphological and orthographic similarities without requiring identical whole words.</p><p>The resulting topic pipeline produced predictions for all <strong>1,743 test articles</strong>.</p><p>The predicted distribution looked like this:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*P8AOJiEhxWZRLjXVij8lZA.png" /></figure><p>I also used this as a sanity check.</p><p>If almost everything suddenly landed in one or two categories, that would immediately tell me something had gone wrong.</p><h3>Headline Generation Was Where Things Got Painful</h3><p>Classification wasn’t the part that gave me the biggest headache.<br>Generation was.</p><h3>My First mT5 Experiment</h3><p>mT5 seemed like a natural candidate.</p><p>It’s multilingual.</p><p>It’s sequence-to-sequence.</p><p>And I needed multilingual text generation.</p><p>So I structured the input as an instruction asking the model to generate a concise headline in the appropriate language from the article text.</p><p>The target was the actual training headline.</p><p>I started training.</p><p>The loop was running.</p><p>Everything looked normal.</p><p>Then I noticed something:</p><p><strong>The training loss was basically zero.</strong></p><p>Now, I’d love to tell you the model had somehow become perfect.</p><p>It hadn’t. 😂</p><p>Generation afterwards collapsed into invalid outputs.</p><p>So instead of trusting the training logs, I checked the model directly with a forward and backward pass.</p><p>And there was the actual problem:</p><ul><li>NaN loss</li><li>NaN gradients</li><li>No meaningful gradient updates</li></ul><p>The training loop was technically running.</p><p>The model wasn’t actually learning.</p><h3>FP16 Was the Problem</h3><p>The unstable run was using mixed precision.</p><p>So I reloaded a clean model and tried the same forward pass using FP32.</p><p>This time:</p><p><strong>Finite loss.</strong></p><p>Good.</p><p>That told me the training data and targets weren’t fundamentally broken.</p><p>The precision configuration was causing the failure.</p><p>Problem solved?</p><p>Not quite.</p><p>Because switching to FP32 introduced another problem:</p><p><strong>GPU memory.</strong></p><h3>Now I Was Fighting the T4</h3><p>The model had roughly 556 million parameters.</p><p>FP32 weights already consume a lot of memory, and then Adam needs additional memory for its optimizer states.</p><p>I was already using:</p><ul><li>Batch size 1</li><li>Gradient checkpointing</li><li>Gradient accumulation</li></ul><p>And I still eventually ran out of GPU memory.</p><p>So I switched to <strong>Adafactor</strong>, which requires substantially less optimizer-state memory for this kind of model.</p><p>The recovery configuration became:</p><ul><li>FP32</li><li>Batch size: 1</li><li>Gradient accumulation: 16</li><li>Gradient checkpointing</li><li>Adafactor</li><li>One training epoch</li></ul><p>And finally, training completed on the available hardware.</p><p>Great.</p><p>Except there was another problem.</p><h3>The Model Trained. The Headlines Were Still Bad.</h3><p>This was probably one of the most useful reminders from the whole experiment.</p><p>The model was now numerically stable.</p><p>Training completed.</p><p>But when I actually inspected the generated headlines, I still found:</p><ul><li>Repetition</li><li>Weak grounding</li><li>Repeated phrases</li><li>&lt;extra_id_0&gt; sentinel tokens</li><li>Incorrect entities</li></ul><p>So yes, training was successful.</p><p>But the actual task?</p><p>Not really.</p><p>That gave me a pretty important reminder:</p><blockquote><strong><em>Training completion is not a model-quality metric.</em></strong></blockquote><p>A model can have finite loss and successfully complete an epoch while still being terrible at the thing you actually need it to do.</p><p>You have to look at the outputs.</p><h3>So I Started Experimenting With Retrieval</h3><p>At this point, I tried a different direction.</p><p>Instead of expecting the generator to figure everything out from the article alone, what if I first retrieved similar examples from the training data?</p><p>The idea was:</p><p><strong>Article → find similar training examples → provide relevant examples as context → generate the headline.</strong></p><p>I tested retrieval using:</p><ul><li>Article text</li><li>Headline + article text</li><li>Word TF-IDF</li><li>Character TF-IDF</li><li>Character-boundary TF-IDF</li><li>Character-based retrieval produced some of the strongest similarity matches.</li></ul><p>And this is where retrieval became really interesting to me.</p><p>For a low-resource generation task, relevant examples can give the model additional language and headline structure without increasing the generator’s parameter count.</p><p>But retrieval wasn’t magically solved either.</p><p>Small changes in how I represented the text could significantly change the examples being returned.</p><p>So retrieval itself became another modelling decision.</p><h3>I Also Tested a Larger Model as a Benchmark</h3><p>During experimentation, I tried <strong>Qwen2.5–3B-Instruct</strong>.</p><p>To be very clear:</p><p><strong>This model is above the competition’s one-billion-parameter limit.</strong></p><p>I wasn’t using it as my compliant final system.</p><p>I wanted a benchmark.</p><p>I wanted to know:</p><blockquote><em>If I give a stronger generator the article, predicted topic and useful context, how much better can the generation get?</em></blockquote><p>The headlines were considerably more usable than what I had been getting from the unstable mT5 experiments.</p><p>That experimental setup reached a public leaderboard score of:</p><h3>0.56944</h3><p>Again, this is <strong>not</strong> the score of a competition-compliant sub-1B final system.</p><p>I mainly used it as a benchmark to understand what stronger generation could contribute.</p><p>Now the more interesting problem is:</p><p><strong>How close can I get to that — or improve on it — while staying below 1B parameters?</strong></p><h3>Then My Notebook Got Refreshed During Inference 😭</h3><p>Another part of ML engineering that becomes very real when you’re using free notebook infrastructure:</p><p><strong>long-running inference can disappear very quickly.</strong></p><p>I had <strong>1,743 articles</strong> to generate predictions for.</p><p>So instead of waiting until the entire run finished before saving anything, I checkpointed predictions incrementally.</p><p>That decision saved me.</p><p>During one generation run, the notebook was accidentally refreshed after hundreds of predictions had already been generated.</p><p>But the pipeline recovered:</p><p><strong>850 previously generated predictions.</strong></p><p>I only had to continue with the remaining examples.</p><p>Eventually, I got all:</p><p><strong>1,743 predictions.</strong></p><p>That one decision saved me from rerunning hundreds of generations.</p><p>Nothing fancy.</p><p>Just good old checkpointing.</p><h3>Then Came Submission Validation</h3><p>Imagine spending all that time fighting models, GPUs and notebook sessions…</p><p>…only to lose points because your CSV is wrong. 😂</p><p>I wasn’t going to let that happen.</p><p>So before submitting anything, I reconstructed the output using the official sample-submission IDs.</p><p>Every test article requires two rows:</p><p>&lt;id&gt;_topic</p><p>and</p><p>&lt;id&gt;_headline</p><p>My validation pipeline checked:</p><ul><li>Number of rows</li><li>Unique IDs</li><li>Missing predictions</li><li>Empty predictions</li><li>Valid topic labels</li><li>Headline corruption</li><li>Unexpected special tokens</li></ul><p>The experimental submission contained:</p><ul><li><strong>3,486 rows</strong></li><li><strong>3,486 unique IDs</strong></li><li><strong>1,743 topic predictions</strong></li><li><strong>1,743 headline predictions</strong></li><li><strong>0 missing predictions</strong></li><li><strong>0 empty predictions</strong></li><li><strong>0 invalid topic labels</strong></li></ul><p>Only after those checks was I comfortable uploading it.</p><p>Because even a good model can’t save a broken submission file.</p><h3>What I Learned</h3><h3>1. Low-resource multilingual NLP isn’t solved by model size alone</h3><p>A model supporting a language during pretraining doesn’t automatically mean it’ll be good at your specific task in that language.</p><p>Fine-tuning strategy, examples and task formatting still matter.</p><h3>2. If training behaviour looks weird, inspect what’s actually happening</h3><p>That zero-loss mT5 run could easily have sent me down the wrong path.</p><p>Checking the gradients exposed the NaNs immediately.</p><p>Sometimes the best debugging step is simply refusing to believe a suspiciously good number.</p><h3>3. GPU constraints change modelling decisions</h3><p>Precision, optimizer choice, sequence length, gradient accumulation and checkpointing weren’t small implementation details.</p><p>They determined which experiments I could run at all.</p><h3>4. Always inspect generated text</h3><p>Finite loss doesn’t mean meaningful output.</p><p>You still need to look for repetition, hallucination, broken language, incorrect entities and weak grounding.</p><h3>5. Retrieval looks promising for low-resource generation</h3><p>Relevant examples can give a smaller model useful linguistic and structural context without increasing its parameter count.</p><p>There’s still a lot I want to test here.</p><h3>6. Classification and generation deserve separate diagnostics</h3><p>They’re solving different problems and failing in different ways.</p><p>Debugging them independently made the whole process easier to reason about.</p><h3>7. Make long-running inference resumable</h3><p>Seriously.</p><p>Save intermediate predictions.</p><p>Your future self will thank you when Colab decides your session has had enough.</p><h3>Where I’m Going Next</h3><p>The larger-model experiment reached:</p><p><strong>0.56944</strong></p><p>But the real challenge now is reproducing or improving that performance while staying completely inside the competition constraints:</p><ul><li>A scored model below 1 billion parameters</li><li>Training and inference inside one free-GPU notebook</li><li>No externally trained competition checkpoints</li><li>Both topic classification and headline generation</li><li>Four Nigerian languages</li></ul><p>Rather than simply increasing model size, I’m more interested in exploring:</p><ul><li>Efficient fine-tuning of a sub-1B multilingual model</li><li>LoRA or other parameter-efficient adaptation</li><li>Better multilingual retrieval</li><li>Improved generation prompts and task formatting</li><li>Language-aware decoding</li><li>Better minority-class handling</li><li>Per-language error analysis</li><li>Stronger validation before inference</li></ul><p>There’s still plenty to experiment with.</p><h3>Final Thoughts</h3><p>This started as a multilingual NLP challenge.</p><p>It quickly became an engineering challenge too.</p><p>Working with Hausa, Igbo, Yoruba and Nigerian Pidgin meant dealing with multilingual representation and low-resource generation.</p><p>Working under the competition constraints meant dealing with numerical stability, GPU memory and model size.</p><p>And working on free notebook infrastructure meant thinking about things like checkpointing and recovery too.</p><p>The biggest lesson for me wasn’t about mT5, Qwen or any particular architecture.</p><p>It was this:</p><p><strong>Don’t just ask whether your model ran. Ask what it actually did.</strong></p><p>Measure it.</p><p>Inspect the failures.</p><p>Question suspicious results.</p><p>Build around the hardware you actually have.</p><p>And make your pipeline resilient enough that one notebook refresh doesn’t send you back to zero.</p><p>That’s the part of ML engineering I’m finding increasingly interesting.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=3463c71e5758" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[From Frustration to CampusPadi: Building a Platform Students Actually Need]]></title>
            <link>https://medium.com/@vikrez/from-frustration-to-campuspadi-building-a-platform-students-actually-need-9caeb39aa3ce?source=rss-cca42fe8ae6b------2</link>
            <guid isPermaLink="false">https://medium.com/p/9caeb39aa3ce</guid>
            <category><![CDATA[edtech]]></category>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[tech-startups]]></category>
            <category><![CDATA[education]]></category>
            <category><![CDATA[student-life]]></category>
            <dc:creator><![CDATA[vikrez]]></dc:creator>
            <pubDate>Mon, 06 Apr 2026 17:42:23 GMT</pubDate>
            <atom:updated>2026-04-06T17:42:23.928Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/851/1*lDgBjxmnCfdo6WfgGlliAw.png" /><figcaption>Campus life, Simplified.</figcaption></figure><p>I didn’t plan to build a startup. I just wanted to stop being frustrated.</p><p>Scattered receipts. Manual fee verification. Paying the same class fee twice by mistake. It was exhausting.</p><p>My team and I were only trying to solve a problem in our department. But as we started building, something became clear: <strong>students needed a single platform to manage their academic life.</strong></p><p>That’s how <strong>CampusPadi</strong> was born.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*6OXGoA48mQxwlT5AdXkjFA.png" /></figure><p>Today, it helps students:<br> • <strong>Manage and track class fees — </strong>a lifesaver for class reps and students alike<br> • Track academic progress with a CGPA calculator<br> • Collaborate in notes and study groups<br> • Get AI-powered assignment help with <strong>AI Padi</strong><br> • Learn deeply with <strong>AI Tutor</strong> and concept simplifiers<br> • Discover campus events and stay connected</p><p>With 90+ students testing the platform, feedback is shaping every feature.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*5gmhMUDLUk4iEu4ExSv43A.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*xMO1EuhPcj7bFBWaBUlZFQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*dMZ9FRtSgoxRByE68-FCjg.png" /></figure><p>As Mark Zuckerberg once said:</p><blockquote><em>“</em>Ideas don’t come out fully formed<em>, </em>they only become clearer as you work on them<em> </em>You just have to get started.<em>”</em></blockquote><p>Built for students, by students.</p><p>If you’re a student, take control of your campus life. <a href="https://campuspadi.com/">Try CampusPadi today</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=9caeb39aa3ce" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>