<?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>DEV Community: Aryan Raj</title>
    <description>The latest articles on DEV Community by Aryan Raj (@aryan1092raj).</description>
    <link>https://dev.to/aryan1092raj</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.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4115827%2F4aa65af3-b55e-4428-a6e7-cc8d7cf7aa1a.png</url>
      <title>DEV Community: Aryan Raj</title>
      <link>https://dev.to/aryan1092raj</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/aryan1092raj"/>
    <language>en</language>
    <item>
      <title>Exam_tutor</title>
      <dc:creator>Aryan Raj</dc:creator>
      <pubDate>Sun, 04 Oct 2026 15:09:25 +0000</pubDate>
      <link>https://dev.to/aryan1092raj/examtutor-16c5</link>
      <guid>https://dev.to/aryan1092raj/examtutor-16c5</guid>
      <description>&lt;h2&gt;
  
  
  What I Built
&lt;/h2&gt;

&lt;p&gt;A local exam-prep tutor for my friend Nishant. He [his real problem, e.g. "studies from scattered notes and web pages and has no way to test himself"] before [course/exam]. Paste URLs or upload PDFs, then either ask questions (answered only from his notes, with sources shown) or get quizzed and graded on his own answers.&lt;/p&gt;

&lt;h2&gt;
  
  
  Demo
&lt;/h2&gt;

&lt;p&gt;[video link]&lt;/p&gt;

&lt;h2&gt;
  
  
  Code
&lt;/h2&gt;


&lt;div class="ltag-github-readme-tag"&gt;
  &lt;div class="readme-overview"&gt;
    &lt;h2&gt;
      &lt;img src="https://assets.dev.to/assets/github-logo-5a155e1f9a670af7944dd5e12375bc76ed542ea80224905ecaf878b9157cdefc.svg" alt="GitHub logo"&gt;
      &lt;a href="https://github.com/Aryan1092raj" rel="noopener noreferrer"&gt;
        Aryan1092raj
      &lt;/a&gt; / &lt;a href="https://github.com/Aryan1092raj/Exam_tutor" rel="noopener noreferrer"&gt;
        Exam_tutor
      &lt;/a&gt;
    &lt;/h2&gt;
    &lt;h3&gt;
      
    &lt;/h3&gt;
  &lt;/div&gt;
  &lt;div class="ltag-github-body"&gt;
    
&lt;div id="readme" class="md"&gt;&lt;div class="markdown-heading"&gt;
&lt;h1 class="heading-element"&gt;Exam Tutor&lt;/h1&gt;
&lt;/div&gt;
&lt;p&gt;Local RAG study partner built for my friend Nishant. Paste URLs or upload notes, then ask questions or get quizzed. Everything runs on-device with open-weight models via Ollama. No API key, no internet needed after setup, notes never leave the laptop.&lt;/p&gt;
&lt;div class="markdown-heading"&gt;
&lt;h2 class="heading-element"&gt;Setup&lt;/h2&gt;
&lt;/div&gt;
&lt;div class="highlight highlight-source-shell notranslate position-relative overflow-auto js-code-highlight"&gt;
&lt;pre&gt;&lt;span class="pl-c"&gt;&lt;span class="pl-c"&gt;#&lt;/span&gt; 1. install Ollama: https://ollama.com&lt;/span&gt;
ollama pull qwen2.5:3b
ollama pull nomic-embed-text

&lt;span class="pl-c"&gt;&lt;span class="pl-c"&gt;#&lt;/span&gt; 2. run&lt;/span&gt;
pip install -r requirements.txt
streamlit run app.py&lt;/pre&gt;

&lt;/div&gt;
&lt;div class="markdown-heading"&gt;
&lt;h2 class="heading-element"&gt;Use&lt;/h2&gt;

&lt;/div&gt;
&lt;ol&gt;
&lt;li&gt;Sidebar: paste URLs (web pages or PDFs) or upload files, click &lt;strong&gt;Ingest&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Ask&lt;/strong&gt; mode: question gets answered only from the ingested notes, with sources shown.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Quiz me&lt;/strong&gt; mode: enter a topic, get an exam-style question, answer it, get graded.&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;Sample sources to try (data structures):&lt;/p&gt;
&lt;div class="snippet-clipboard-content notranslate position-relative overflow-auto"&gt;&lt;pre class="notranslate"&gt;&lt;code&gt;https://en.wikipedia.org/wiki/Binary_search_tree
https://en.wikipedia.org/wiki/AVL_tree
https://en.wikipedia.org/wiki/Dijkstra%27s_algorithm
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;
&lt;div class="markdown-heading"&gt;
&lt;h2 class="heading-element"&gt;How it works&lt;/h2&gt;

&lt;/div&gt;
&lt;ul&gt;
&lt;li&gt;Chunk text (900 chars, 150 overlap)&lt;/li&gt;
&lt;li&gt;Embed chunks with &lt;code&gt;nomic-embed-text&lt;/code&gt; (Ollama)&lt;/li&gt;
&lt;li&gt;Cosine similarity over numpy matrix, top 4 chunks&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;qwen2.5:3b&lt;/code&gt; answers using only retrieved chunks&lt;/li&gt;
&lt;li&gt;Swap model: edit &lt;code&gt;CHAT_MODEL&lt;/code&gt; in &lt;code&gt;app.py&lt;/code&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="markdown-heading"&gt;
&lt;h2 class="heading-element"&gt;Stack&lt;/h2&gt;…&lt;/div&gt;&lt;/div&gt;
  &lt;/div&gt;
  &lt;div class="gh-btn-container"&gt;&lt;a class="gh-btn" href="https://github.com/Aryan1092raj/Exam_tutor" rel="noopener noreferrer"&gt;View on GitHub&lt;/a&gt;&lt;/div&gt;
&lt;/div&gt;


&lt;h2&gt;
  
  
  How I Built It
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Chat model:&lt;/strong&gt; Qwen2.5 3B via Ollama, runs on a laptop CPU/GPU.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Embeddings:&lt;/strong&gt; nomic-embed-text via Ollama.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Retrieval:&lt;/strong&gt; notes chunked (900 chars, 150 overlap), embedded, cosine similarity over a numpy matrix, top 4 chunks fed to the model.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Grounding:&lt;/strong&gt; system prompt restricts answers to retrieved notes; if notes don't cover it, it says so.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Quiz mode:&lt;/strong&gt; model writes one exam-style question from retrieved chunks, then grades the student's answer against them.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;UI:&lt;/strong&gt; Streamlit. Ingestion via trafilatura (web) and pypdf (PDFs).&lt;/li&gt;
&lt;li&gt;Whole thing is ~150 lines, one file.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Why Does Open Innovation Matter?
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Offline:&lt;/strong&gt; works with bad hostel wifi. After model pull, zero internet needed.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Private:&lt;/strong&gt; his notes never leave his laptop.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Free:&lt;/strong&gt; no API key, no per-query cost, no rate limit during exam week.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Swappable:&lt;/strong&gt; changing the model is one line (&lt;code&gt;CHAT_MODEL&lt;/code&gt;). [Add your real 3B vs 7B comparison, or delete this sentence.]&lt;/li&gt;
&lt;li&gt;A closed API would need billing, a key, and a connection, which is exactly what a student doesn't want the night before an exam.&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>devchallenge</category>
      <category>weekendchallenge</category>
      <category>hf26challenge</category>
    </item>
  </channel>
</rss>
