<?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: Harsh Soni</title>
    <description>The latest articles on DEV Community by Harsh Soni (@harsh06).</description>
    <link>https://dev.to/harsh06</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%2F3948600%2Ffd4e0406-19e3-4fd5-b2e9-05a2ed315567.jpeg</url>
      <title>DEV Community: Harsh Soni</title>
      <link>https://dev.to/harsh06</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/harsh06"/>
    <language>en</language>
    <item>
      <title>Building PR Sentinel- A Multi-Agent AI Code Reviewer</title>
      <dc:creator>Harsh Soni</dc:creator>
      <pubDate>Wed, 17 Jun 2026 04:42:03 +0000</pubDate>
      <link>https://dev.to/harsh06/building-pr-sentinel-a-multi-agent-ai-code-reviewer-nh8</link>
      <guid>https://dev.to/harsh06/building-pr-sentinel-a-multi-agent-ai-code-reviewer-nh8</guid>
      <description>&lt;p&gt;When I started my MS, I realized pretty quickly that I missed having real code reviews. The kind where someone actually catches the stuff you didn't think to check.&lt;/p&gt;

&lt;p&gt;At my previous company, there was always someone to catch the dumb stuff, a poorly named variable, a query that'd blow up at scale, an access control you forgot to check. In grad school, building coursework projects and personal side projects, that safety net was just... gone. It was just me and my code.&lt;/p&gt;

&lt;p&gt;With all the AI and RAG buzz going on, I figured — why not build it myself? That's how PR Sentinel started: a selfish tool, built because I missed having someone look over my shoulder.&lt;/p&gt;

&lt;p&gt;Here's what it actually took to build it.&lt;/p&gt;




&lt;h2&gt;
  
  
  The Architecture: Three Agents, One Review
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F53hy650evmwhfu1m1es8.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F53hy650evmwhfu1m1es8.png" alt="Architecture Flowchart" width="800" height="842"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The first real decision was: one AI agent or multiple?&lt;/p&gt;

&lt;p&gt;I went with multiple, and not just for the architecture points. LLMs hallucinate. Ask one model to simultaneously check for SQL injection, N+1 queries, &lt;em&gt;and&lt;/em&gt; whether your function names make sense — and it'll do all three badly. So I split the job into three focused agents:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Security Agent&lt;/strong&gt; — hardcoded secrets, injection vectors, broken access controls&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Performance Agent&lt;/strong&gt; — N+1 queries, un-optimized loops, memory leaks&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Quality Agent&lt;/strong&gt; — DRY violations, naming, modularity&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Each agent runs independently using &lt;strong&gt;LangGraph&lt;/strong&gt;, with &lt;code&gt;asyncio.gather()&lt;/code&gt; firing them in parallel. The results come back to an aggregator node that assembles the final review. Compared to running them sequentially, this cuts total latency by over 60%.&lt;/p&gt;

&lt;p&gt;But the architecture decision was the easy part. Getting it to actually &lt;em&gt;work&lt;/em&gt; that took a while.&lt;/p&gt;




&lt;h2&gt;
  
  
  What Actually Broke (A Lot)
&lt;/h2&gt;

&lt;p&gt;Before I even got to multi-agent stuff, I wasted serious time just deciding which LLM API to use. Claude? Gemini? Every API has different configurations, different rate limits, different quirks. I kept switching and re-learning each time.&lt;/p&gt;

&lt;p&gt;Then came LangGraph itself. Understanding the cycle behind it, adding nodes to the graph, wiring up tools, setting conditional edges, etc. I genuinely messed this up multiple times. The docs make it look clean. It is not clean when you're building it.&lt;/p&gt;

&lt;p&gt;The first thing that broke in a way I didn't expect: &lt;strong&gt;tool calling wasn't working&lt;/strong&gt;. The agents were reviewing the changed files just fine, but they weren't exploring the rest of the codebase using the embedded vector store. Meaning: no real context. Just surface-level feedback on a diff.&lt;/p&gt;

&lt;p&gt;I didn't catch it for a while. It was only after I sat down and actually read through the generated reviews carefully that I realized they were missing the bigger picture. When I dug into the code, it turned out to be a typo — a misspelled key that caused the tool to silently return nothing. No error. Just nothing.&lt;/p&gt;

&lt;p&gt;That's when I learned the importance of logging at every single step. Obvious in hindsight. Painful to learn.&lt;/p&gt;




&lt;h2&gt;
  
  
  The Thundering Herd: Fixing the API Stampede
&lt;/h2&gt;

&lt;p&gt;Once I got agents running in parallel, a new problem showed up: all three would fire their API requests at the exact same millisecond, immediately hitting Gemini's rate limits with &lt;code&gt;429&lt;/code&gt; and &lt;code&gt;503&lt;/code&gt; errors.&lt;/p&gt;

&lt;p&gt;The fix was an exponential backoff with &lt;strong&gt;randomized jitter&lt;/strong&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;random&lt;/span&gt;
&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;time&lt;/span&gt;

&lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;call_with_gemini_retry&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;fn&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt;&lt;span class="n"&gt;args&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="o"&gt;**&lt;/span&gt;&lt;span class="n"&gt;kwargs&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
    &lt;span class="n"&gt;MAX_RETRIES&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;5&lt;/span&gt;
    &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="n"&gt;attempt&lt;/span&gt; &lt;span class="ow"&gt;in&lt;/span&gt; &lt;span class="nf"&gt;range&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;MAX_RETRIES&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
        &lt;span class="k"&gt;try&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
            &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nf"&gt;fn&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="o"&gt;*&lt;/span&gt;&lt;span class="n"&gt;args&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="o"&gt;**&lt;/span&gt;&lt;span class="n"&gt;kwargs&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="k"&gt;except&lt;/span&gt; &lt;span class="nb"&gt;Exception&lt;/span&gt; &lt;span class="k"&gt;as&lt;/span&gt; &lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
            &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;503&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt; &lt;span class="ow"&gt;in&lt;/span&gt; &lt;span class="nf"&gt;str&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="ow"&gt;or&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;429&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt; &lt;span class="ow"&gt;in&lt;/span&gt; &lt;span class="nf"&gt;str&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
                &lt;span class="n"&gt;delay&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt; &lt;span class="o"&gt;**&lt;/span&gt; &lt;span class="n"&gt;attempt&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="n"&gt;random&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;uniform&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
                &lt;span class="n"&gt;time&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;sleep&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;delay&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
            &lt;span class="k"&gt;else&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
                &lt;span class="k"&gt;raise&lt;/span&gt; &lt;span class="n"&gt;e&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The jitter part is what actually matters. Without it, all three agents back off by exactly the same amount and collide again on the retry. The random offset staggers them just enough.&lt;/p&gt;

&lt;p&gt;And yes — free tier API limits are brutal. If you're building something like this, pick your model carefully before you start hammering it with test PRs.&lt;/p&gt;




&lt;h2&gt;
  
  
  Incremental RAG: The Accidental Optimization
&lt;/h2&gt;

&lt;p&gt;For the agents to understand the full codebase — not just the diff — I integrated &lt;strong&gt;Pinecone&lt;/strong&gt; as a vector database. Every file gets chunked and embedded, so agents can semantically search for relevant code before writing their review.&lt;/p&gt;

&lt;p&gt;The naive approach was re-vectorizing the entire repo on every PR. That lasts about two test runs before you look at your usage bill and reconsider your life choices.&lt;/p&gt;

&lt;p&gt;So I built incremental ingestion instead. When a webhook fires, the backend looks at the &lt;code&gt;files_changed&lt;/code&gt; payload, deletes only the old embeddings for those files, and re-embeds the new versions:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="n"&gt;file_path&lt;/span&gt; &lt;span class="ow"&gt;in&lt;/span&gt; &lt;span class="n"&gt;changed_file_names&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
    &lt;span class="nf"&gt;delete_file_chunks&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;file_path&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;namespace&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

&lt;span class="n"&gt;updated_files&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;fetch_specific_files&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;repo_url&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;changed_file_names&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;ref&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="n"&gt;chunks&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;chunk_files&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;updated_files&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="nf"&gt;store_chunks&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;chunks&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;namespace&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This keeps Pinecone in sync with the repo while cutting token usage by over 99% compared to full re-ingestion.&lt;/p&gt;

&lt;p&gt;There was also a subtle bug here I didn't catch for weeks: I was reading from the main branch during ingestion instead of the PR's head branch. Most of my test PRs only had modified files, not new ones — so it never surfaced clearly in the logs. New files were just silently skipped. Fixed it eventually, but it's the kind of bug that only shows up when the conditions are just right to hide it.&lt;/p&gt;




&lt;h2&gt;
  
  
  GitHub App Auth: Making It Actually Installable
&lt;/h2&gt;

&lt;p&gt;The original version used a hardcoded Personal Access Token. Fine for local testing, completely unusable if anyone else wants to use it — they'd have to hand over their own tokens.&lt;/p&gt;

&lt;p&gt;I transitioned to a proper &lt;strong&gt;GitHub App&lt;/strong&gt; architecture. Now the server holds an RSA private key. When someone installs the app, GitHub sends an &lt;code&gt;installation_id&lt;/code&gt;, and the backend dynamically signs a JWT and exchanges it for a scoped, 60-minute access token.&lt;/p&gt;

&lt;p&gt;The user clicks Install. That's it. No token configuration, no API keys shared.&lt;/p&gt;

&lt;p&gt;The GitHub docs for this flow are... fine. But there are enough gaps that I spent more time on this than I expected. If you're building a GitHub App for the first time, set aside extra time for the auth layer.&lt;/p&gt;




&lt;h2&gt;
  
  
  What I'd Do Differently
&lt;/h2&gt;

&lt;p&gt;Honestly? I'd explore different RAG architectures more carefully before building. The current chunking is naive — splitting by character count means a function can get cut in half, which degrades retrieval quality. I want to replace it with AST-based chunking using &lt;code&gt;tree-sitter&lt;/code&gt;, so chunks always align with complete functions and classes.&lt;/p&gt;

&lt;p&gt;I'd also spend more time upfront thinking about which model actually fits the use case — balancing capability, rate limits, and cost — instead of swapping APIs mid-build when the limits hit me.&lt;/p&gt;




&lt;h2&gt;
  
  
  The Moment It Clicked
&lt;/h2&gt;

&lt;p&gt;After all of that, the wrong API choices, the silent typos, the accidental re-vectorizations, the weeks-long PR branch bug, there was one moment that made it worth it.&lt;/p&gt;

&lt;p&gt;I opened a test PR. The Pinecone namespace updated. One agent fired. The review came back. It worked.&lt;/p&gt;

&lt;p&gt;And then I wired up the async multi-agent flow and watched all three fire simultaneously.&lt;/p&gt;

&lt;p&gt;That was the moment. Seeing the thing actually work! Not as a demo, but as a real system doing what it was supposed to do, made all the broken stuff feel like it had a point.&lt;/p&gt;




&lt;p&gt;If you want to try it on your own repos, the &lt;strong&gt;&lt;a href="https://github.com/apps/sentinel-pr-reviewer-bot" rel="noopener noreferrer"&gt;PR Sentinel GitHub App&lt;/a&gt;&lt;/strong&gt; is publicly installable. The source code is on my &lt;a href="https://github.com/harshh06/automated-pr-reviewer" rel="noopener noreferrer"&gt;GitHub&lt;/a&gt; if you want to dig into the implementation.&lt;/p&gt;

</description>
      <category>automation</category>
      <category>rag</category>
      <category>ai</category>
      <category>python</category>
    </item>
    <item>
      <title>I built an AI agent that texts me LeetCode and system design summaries every morning, here's exactly how</title>
      <dc:creator>Harsh Soni</dc:creator>
      <pubDate>Sun, 24 May 2026 09:06:59 +0000</pubDate>
      <link>https://dev.to/harsh06/i-built-an-ai-agent-that-texts-me-leetcode-and-system-design-summaries-every-morning-heres-3lb3</link>
      <guid>https://dev.to/harsh06/i-built-an-ai-agent-that-texts-me-leetcode-and-system-design-summaries-every-morning-heres-3lb3</guid>
      <description>&lt;p&gt;Here's my problem: I study something once and completely forget it exists until the moment I actually need it, usually mid-interview, when it's too late.&lt;/p&gt;

&lt;p&gt;I wanted to fix this without adding another thing to my already full plate. So I built two things:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;An automated script that runs every morning at 8am, picks random topics from everything I've studied, and sends me a plain-text summary to iMessage. No app to open, no habit to build, it just shows up.&lt;/li&gt;
&lt;li&gt;An interactive study agent using Antigravity CLI that I can talk to anytime. I ask it to quiz me, it quizzes me. I ask it to fill gaps in my notes, it tells me exactly what's missing.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ftugvb7t0fckui6cqskqg.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ftugvb7t0fckui6cqskqg.jpeg" alt="iMessage screenshot" width="736" height="1600"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The cool part: I take notes in &lt;strong&gt;Obsidian&lt;/strong&gt;, and instead of syncing or exporting anything, I used symlinks to point the AI directly at my actual Obsidian files. Edit in Obsidian, agent sees it instantly. One source of truth.&lt;/p&gt;

&lt;p&gt;Here's exactly how I built it.&lt;/p&gt;




&lt;h2&gt;
  
  
  The morning automation
&lt;/h2&gt;

&lt;p&gt;The script itself is straightforward.&lt;/p&gt;

&lt;p&gt;It sets the path to my Obsidian vault, walks through every folder, and collects all the &lt;code&gt;.md&lt;/code&gt; files into a list. Then it picks one randomly using &lt;code&gt;random.choice()&lt;/code&gt;, reads its content, and builds a prompt telling Gemini what to do with it: summarise this note, plain text, no markdown, keep it short.&lt;/p&gt;

&lt;p&gt;The API call goes directly to Gemini, response comes back as JSON, and I extract the actual text from &lt;code&gt;data["candidates"][0]["content"]["parts"][0]["text"]&lt;/code&gt;. Then an &lt;strong&gt;AppleScript&lt;/strong&gt; — macOS's built-in automation language — tells the Messages app to send it to my number.&lt;/p&gt;

&lt;p&gt;Run the script, summary lands in iMessage. Simple.&lt;/p&gt;

&lt;p&gt;Here's the full script:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;os&lt;/span&gt;
&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;random&lt;/span&gt;
&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;subprocess&lt;/span&gt;
&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;urllib.request&lt;/span&gt;
&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;urllib.error&lt;/span&gt;
&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;json&lt;/span&gt;
&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;time&lt;/span&gt;

&lt;span class="c1"&gt;# auto scan entire Obsidian vault for all markdown notes
&lt;/span&gt;&lt;span class="n"&gt;vault_path&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;/Users/your-username/Documents/Obsidian Vault&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;
&lt;span class="n"&gt;notes&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;[]&lt;/span&gt;
&lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="n"&gt;root&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;dirs&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;files&lt;/span&gt; &lt;span class="ow"&gt;in&lt;/span&gt; &lt;span class="n"&gt;os&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;walk&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;vault_path&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
    &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="nb"&gt;file&lt;/span&gt; &lt;span class="ow"&gt;in&lt;/span&gt; &lt;span class="n"&gt;files&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
        &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="nb"&gt;file&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;endswith&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;.md&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
            &lt;span class="n"&gt;notes&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;append&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;os&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;path&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;join&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;root&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nb"&gt;file&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt;

&lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="ow"&gt;not&lt;/span&gt; &lt;span class="n"&gt;notes&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
    &lt;span class="nf"&gt;print&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;No notes found in Obsidian vault&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
    &lt;span class="nf"&gt;exit&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

&lt;span class="c1"&gt;# pick one random note
&lt;/span&gt;&lt;span class="n"&gt;picked&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;random&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;choice&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;notes&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="n"&gt;note_name&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;os&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;path&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;basename&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;picked&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

&lt;span class="k"&gt;with&lt;/span&gt; &lt;span class="nf"&gt;open&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;picked&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;r&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;as&lt;/span&gt; &lt;span class="n"&gt;f&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
    &lt;span class="n"&gt;content&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;f&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;read&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;

&lt;span class="c1"&gt;# build prompt
&lt;/span&gt;&lt;span class="n"&gt;prompt&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="sa"&gt;f&lt;/span&gt;&lt;span class="sh"&gt;"""&lt;/span&gt;&lt;span class="s"&gt;You are a system design study assistant for an MSCS student.

Below are the student&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="s"&gt;s personal notes on &lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="n"&gt;note_name&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;.
Read them and give a concise morning summary in plain text — no markdown, no asterisks, no bold, no bullet symbols.

Format exactly like this:

TOPIC: &amp;lt;topic name&amp;gt;
WHAT IT COVERS: one line overview
KEY CONCEPTS:
1. first concept
2. second concept
3. third concept
KEY TAKEAWAY: one line the student must remember
WATCH OUT FOR: one common mistake or tricky part

Keep it short and sharp — this is a morning refresh, not a lecture.

Notes:
&lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="n"&gt;content&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="s"&gt;
&lt;/span&gt;&lt;span class="sh"&gt;"""&lt;/span&gt;

&lt;span class="c1"&gt;# call Gemini API with retry
&lt;/span&gt;&lt;span class="n"&gt;api_key&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;os&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;environ&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;GEMINI_API_KEY&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="n"&gt;url&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="sa"&gt;f&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;https://generativelanguage.googleapis.com/v1beta/models/gemini-3.5-flash:generateContent?key=&lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="n"&gt;api_key&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;

&lt;span class="n"&gt;payload&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;json&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;dumps&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt;
    &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;contents&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[{&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;parts&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[{&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;text&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;prompt&lt;/span&gt;&lt;span class="p"&gt;}]}]&lt;/span&gt;
&lt;span class="p"&gt;}).&lt;/span&gt;&lt;span class="nf"&gt;encode&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;utf-8&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

&lt;span class="n"&gt;summary&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="bp"&gt;None&lt;/span&gt;
&lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="n"&gt;attempt&lt;/span&gt; &lt;span class="ow"&gt;in&lt;/span&gt; &lt;span class="nf"&gt;range&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;3&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
    &lt;span class="k"&gt;try&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
        &lt;span class="n"&gt;req&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;urllib&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;request&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Request&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
            &lt;span class="n"&gt;url&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
            &lt;span class="n"&gt;data&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;payload&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
            &lt;span class="n"&gt;headers&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;Content-Type&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;application/json&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;
            &lt;span class="n"&gt;method&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;POST&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;
        &lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="k"&gt;with&lt;/span&gt; &lt;span class="n"&gt;urllib&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;request&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;urlopen&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;req&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;as&lt;/span&gt; &lt;span class="n"&gt;response&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
            &lt;span class="n"&gt;data&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;json&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;loads&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;response&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;read&lt;/span&gt;&lt;span class="p"&gt;())&lt;/span&gt;
            &lt;span class="n"&gt;summary&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;data&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;candidates&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;][&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;][&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;content&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;][&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;parts&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;][&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;][&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;text&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;
            &lt;span class="k"&gt;break&lt;/span&gt;
    &lt;span class="k"&gt;except&lt;/span&gt; &lt;span class="n"&gt;urllib&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;error&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;HTTPError&lt;/span&gt; &lt;span class="k"&gt;as&lt;/span&gt; &lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
        &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;code&lt;/span&gt; &lt;span class="o"&gt;==&lt;/span&gt; &lt;span class="mi"&gt;429&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
            &lt;span class="nf"&gt;print&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sa"&gt;f&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;Rate limited, waiting 30 seconds... (attempt &lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="n"&gt;attempt&lt;/span&gt;&lt;span class="o"&gt;+&lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="s"&gt;/3)&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
            &lt;span class="n"&gt;time&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;sleep&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;30&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="k"&gt;else&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
            &lt;span class="k"&gt;raise&lt;/span&gt;

&lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="ow"&gt;not&lt;/span&gt; &lt;span class="n"&gt;summary&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
    &lt;span class="nf"&gt;print&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;Failed after 3 attempts, try again later&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
    &lt;span class="nf"&gt;exit&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

&lt;span class="c1"&gt;# send via iMessage
&lt;/span&gt;&lt;span class="n"&gt;imessage_target&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;your-imessage-target&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;  &lt;span class="c1"&gt;# your phone number or Apple ID
&lt;/span&gt;&lt;span class="n"&gt;applescript&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="sa"&gt;f&lt;/span&gt;&lt;span class="sh"&gt;'''&lt;/span&gt;&lt;span class="s"&gt;
tell application &lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;Messages&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;
    set targetService to 1st service whose service type = iMessage
    set targetBuddy to buddy &lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="n"&gt;imessage_target&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt; of targetService
    send &lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="n"&gt;summary&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt; to targetBuddy
end tell
&lt;/span&gt;&lt;span class="sh"&gt;'''&lt;/span&gt;

&lt;span class="n"&gt;subprocess&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;run&lt;/span&gt;&lt;span class="p"&gt;([&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;osascript&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;-e&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;applescript&lt;/span&gt;&lt;span class="p"&gt;])&lt;/span&gt;
&lt;span class="nf"&gt;print&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;Summary sent to iMessage!&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="nf"&gt;print&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;summary&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;For scheduling, I used launchd: macOS's built-in task scheduler. You write a &lt;code&gt;.plist&lt;/code&gt; file describing three things: what script to run, when to run it, and where to save the logs. Load that file into launchd and it handles everything from there.&lt;/p&gt;

&lt;p&gt;Here's the plist:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plist"&gt;&lt;code&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;?xml&lt;/span&gt;&lt;span class="mh"&gt; &lt;/span&gt;&lt;span class="err"&gt;v&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;rsion="&lt;/span&gt;&lt;span class="mh"&gt;1&lt;/span&gt;&lt;span class="err"&gt;.&lt;/span&gt;&lt;span class="mh"&gt;0&lt;/span&gt;&lt;span class="err"&gt;"&lt;/span&gt;&lt;span class="mh"&gt; e&lt;/span&gt;&lt;span class="err"&gt;n&lt;/span&gt;&lt;span class="mh"&gt;c&lt;/span&gt;&lt;span class="err"&gt;o&lt;/span&gt;&lt;span class="mh"&gt;d&lt;/span&gt;&lt;span class="err"&gt;ing="UT&lt;/span&gt;&lt;span class="mh"&gt;F&lt;/span&gt;&lt;span class="err"&gt;-&lt;/span&gt;&lt;span class="mh"&gt;8&lt;/span&gt;&lt;span class="err"&gt;"?&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;!&lt;/span&gt;&lt;span class="mh"&gt;D&lt;/span&gt;&lt;span class="err"&gt;O&lt;/span&gt;&lt;span class="mh"&gt;C&lt;/span&gt;&lt;span class="err"&gt;TYP&lt;/span&gt;&lt;span class="mh"&gt;E &lt;/span&gt;&lt;span class="err"&gt;plist&lt;/span&gt;&lt;span class="mh"&gt; &lt;/span&gt;&lt;span class="err"&gt;PU&lt;/span&gt;&lt;span class="mh"&gt;B&lt;/span&gt;&lt;span class="err"&gt;LI&lt;/span&gt;&lt;span class="mh"&gt;C &lt;/span&gt;&lt;span class="err"&gt;"-//&lt;/span&gt;&lt;span class="mh"&gt;A&lt;/span&gt;&lt;span class="err"&gt;ppl&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;//&lt;/span&gt;&lt;span class="mh"&gt;D&lt;/span&gt;&lt;span class="err"&gt;T&lt;/span&gt;&lt;span class="mh"&gt;D &lt;/span&gt;&lt;span class="err"&gt;PLIST&lt;/span&gt;&lt;span class="mh"&gt; 1&lt;/span&gt;&lt;span class="err"&gt;.&lt;/span&gt;&lt;span class="mh"&gt;0&lt;/span&gt;&lt;span class="err"&gt;//&lt;/span&gt;&lt;span class="mh"&gt;E&lt;/span&gt;&lt;span class="err"&gt;N"&lt;/span&gt;&lt;span class="mh"&gt; &lt;/span&gt;&lt;span class="err"&gt;"http://www.&lt;/span&gt;&lt;span class="mh"&gt;a&lt;/span&gt;&lt;span class="err"&gt;ppl&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;.&lt;/span&gt;&lt;span class="mh"&gt;c&lt;/span&gt;&lt;span class="err"&gt;om/&lt;/span&gt;&lt;span class="mh"&gt;D&lt;/span&gt;&lt;span class="err"&gt;T&lt;/span&gt;&lt;span class="mh"&gt;D&lt;/span&gt;&lt;span class="err"&gt;s/Prop&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;rtyList-&lt;/span&gt;&lt;span class="mh"&gt;1&lt;/span&gt;&lt;span class="err"&gt;.&lt;/span&gt;&lt;span class="mh"&gt;0&lt;/span&gt;&lt;span class="err"&gt;.&lt;/span&gt;&lt;span class="mh"&gt;d&lt;/span&gt;&lt;span class="err"&gt;t&lt;/span&gt;&lt;span class="mh"&gt;d&lt;/span&gt;&lt;span class="err"&gt;"&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;plist&lt;/span&gt;&lt;span class="mh"&gt; &lt;/span&gt;&lt;span class="err"&gt;v&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;rsion="&lt;/span&gt;&lt;span class="mh"&gt;1&lt;/span&gt;&lt;span class="err"&gt;.&lt;/span&gt;&lt;span class="mh"&gt;0&lt;/span&gt;&lt;span class="err"&gt;"&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="mh"&gt;d&lt;/span&gt;&lt;span class="err"&gt;i&lt;/span&gt;&lt;span class="mh"&gt;c&lt;/span&gt;&lt;span class="err"&gt;t&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;k&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;y&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="l"&gt;Label&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;/k&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;y&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;string&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="l"&gt;com.harsh.sysdesign&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;/string&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;

    &lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;k&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;y&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="l"&gt;ProgramArguments&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;/k&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;y&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="mh"&gt;a&lt;/span&gt;&lt;span class="err"&gt;rr&lt;/span&gt;&lt;span class="mh"&gt;a&lt;/span&gt;&lt;span class="err"&gt;y&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;
        &lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;string&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="l"&gt;/opt/homebrew/bin/python3&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;/string&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;
        &lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;string&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="l"&gt;/Users/your-username/Documents/system-design-study/sysdesign-morning.py&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;/string&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;/&lt;/span&gt;&lt;span class="mh"&gt;a&lt;/span&gt;&lt;span class="err"&gt;rr&lt;/span&gt;&lt;span class="mh"&gt;a&lt;/span&gt;&lt;span class="err"&gt;y&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;

    &lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;k&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;y&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="l"&gt;EnvironmentVariables&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;/k&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;y&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="mh"&gt;d&lt;/span&gt;&lt;span class="err"&gt;i&lt;/span&gt;&lt;span class="mh"&gt;c&lt;/span&gt;&lt;span class="err"&gt;t&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;
        &lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;k&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;y&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="l"&gt;GEMINI_API_KEY&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;/k&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;y&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;
        &lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;string&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="l"&gt;your-gemini-api-key&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;/string&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;/&lt;/span&gt;&lt;span class="mh"&gt;d&lt;/span&gt;&lt;span class="err"&gt;i&lt;/span&gt;&lt;span class="mh"&gt;c&lt;/span&gt;&lt;span class="err"&gt;t&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;

    &lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;k&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;y&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="l"&gt;StartCalendarInterval&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;/k&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;y&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="mh"&gt;d&lt;/span&gt;&lt;span class="err"&gt;i&lt;/span&gt;&lt;span class="mh"&gt;c&lt;/span&gt;&lt;span class="err"&gt;t&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;
        &lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;k&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;y&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="l"&gt;Hour&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;/k&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;y&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;
        &lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;int&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;g&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;r&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="l"&gt;8&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;/int&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;g&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;r&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;
        &lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;k&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;y&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="l"&gt;Minute&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;/k&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;y&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;
        &lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;int&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;g&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;r&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="l"&gt;15&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;/int&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;g&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;r&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;/&lt;/span&gt;&lt;span class="mh"&gt;d&lt;/span&gt;&lt;span class="err"&gt;i&lt;/span&gt;&lt;span class="mh"&gt;c&lt;/span&gt;&lt;span class="err"&gt;t&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;

    &lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;k&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;y&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="l"&gt;StandardOutPath&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;/k&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;y&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;string&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="l"&gt;/Users/your-username/Documents/system-design-study/sysdesign-morning.log&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;/string&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;

    &lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;k&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;y&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="l"&gt;StandardErrorPath&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;/k&lt;/span&gt;&lt;span class="mh"&gt;e&lt;/span&gt;&lt;span class="err"&gt;y&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;string&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="l"&gt;/Users/your-username/Documents/system-design-study/sysdesign-morning.log&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;/string&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;/&lt;/span&gt;&lt;span class="mh"&gt;d&lt;/span&gt;&lt;span class="err"&gt;i&lt;/span&gt;&lt;span class="mh"&gt;c&lt;/span&gt;&lt;span class="err"&gt;t&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="err"&gt;/plist&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="w"&gt;

&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;One problem: launchd runs at 8am but my Mac might still be asleep. So I used &lt;strong&gt;pmset&lt;/strong&gt; to schedule an automatic wake at 7:55am every day:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;sudo &lt;/span&gt;pmset repeat wakeorpoweron MTWRFSU 07:55:00
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;One requirement — the Mac needs to be plugged in and in sleep mode, not fully shut down. Just close the lid at night and you're good.&lt;/p&gt;




&lt;h2&gt;
  
  
  The interactive study agent
&lt;/h2&gt;

&lt;p&gt;For the interactive part, I used Antigravity CLI — Google's new agentic coding tool. The idea is simple: instead of asking AI generic questions about system design, I wanted it to know MY notes and quiz me on what I actually studied.&lt;/p&gt;

&lt;p&gt;Two files make this work.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;AGENTS.md&lt;/code&gt; sits at the root of my project folder. It tells the agent who I am and how to behave — think of it as a letter you write to the AI before the conversation starts. It loads automatically every time I open that folder.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;SKILL.md&lt;/code&gt; lives inside &lt;code&gt;.agents/skills/system-design/&lt;/code&gt;.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight markdown"&gt;&lt;code&gt;&lt;span class="nn"&gt;---&lt;/span&gt;
&lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;system-design-notes&lt;/span&gt;
&lt;span class="na"&gt;description&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;Use this skill when the user asks about system design, HLD, LLD, DDIA, distributed systems, architecture patterns, or wants to be quizzed on any system design topic they have studied.&lt;/span&gt;
&lt;span class="nn"&gt;---&lt;/span&gt;

You are a system design study partner for an MSCS student preparing for software engineering interviews.

The user's personal Obsidian notes are in references/:
&lt;span class="p"&gt;-&lt;/span&gt; references/HLD/ → High Level Design notes
&lt;span class="p"&gt;-&lt;/span&gt; references/LLD/ → Low Level Design notes  
&lt;span class="p"&gt;-&lt;/span&gt; references/DDIA/ → Designing Data Intensive Applications notes

Treat these notes as the source of truth over your general knowledge.

When quizzing:
&lt;span class="p"&gt;-&lt;/span&gt; Ask one question at a time
&lt;span class="p"&gt;-&lt;/span&gt; Wait for the user's answer before responding
&lt;span class="p"&gt;-&lt;/span&gt; Compare their answer to the notes and point out specific gaps
&lt;span class="p"&gt;-&lt;/span&gt; Tell them which note/topic the answer came from

When filling gaps:
&lt;span class="p"&gt;-&lt;/span&gt; Point out what's missing or shallow in their notes on a topic
&lt;span class="p"&gt;-&lt;/span&gt; Suggest what they should add

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It has two parts — a description that tells the agent when to activate this skill, and a body that tells it how to behave once it does. When I type "quiz me on consistent hashing", Antigravity reads the description, finds a match, and loads my notes into context automatically. I never call it by name.&lt;/p&gt;

&lt;p&gt;Folder structure:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;system-design-study/
├── AGENTS.md
└── .agents/
    └── skills/
        └── system-design/
            ├── SKILL.md
            └── references/
                ├── HLD  →  Obsidian/HLD Concepts
                ├── LLD  →  Obsidian/LLD
                └── DDIA →  Obsidian/DDIA
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The notes themselves are linked via symlinks:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;ln&lt;/span&gt; &lt;span class="nt"&gt;-s&lt;/span&gt; ~/Documents/Obsidian&lt;span class="se"&gt;\ &lt;/span&gt;Vault/HLD .agents/skills/system-design/references/HLD
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This creates a pointer inside the project that points to my real Obsidian folder. The agent reads through the pointer. I edit in Obsidian. Same file, always fresh, zero maintenance.&lt;/p&gt;

&lt;p&gt;Now when I open the folder and type "quiz me on HLD", it quizzes me using my own notes — not generic internet knowledge.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fm5k8bzltqaqj1aka2ow2.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fm5k8bzltqaqj1aka2ow2.png" alt="Antigravity CLI screenshot" width="800" height="528"&gt;&lt;/a&gt;&lt;/p&gt;




&lt;h2&gt;
  
  
  What broke
&lt;/h2&gt;

&lt;p&gt;Three things gave me the most trouble.&lt;/p&gt;

&lt;p&gt;First, the Gemini API kept returning 429 — Too Many Requests — even on a fresh key with zero usage. Turned out my key was tied to a VS Code project that the Gemini extension was quietly burning through in the background. Creating a new key under a separate project fixed it immediately.&lt;/p&gt;

&lt;p&gt;Second, figuring out the Mac wake issue. launchd can schedule a script but if your Mac is asleep, it won't run. I needed pmset to wake the Mac before the script fires. And it only works when plugged in — if the laptop is on battery and closed, nothing wakes it. The fix is simple: just don't shut down, close the lid instead. But it took me a while to figure out why the automation wasn't running at all.&lt;/p&gt;




&lt;h2&gt;
  
  
  What my mornings look like now
&lt;/h2&gt;

&lt;p&gt;I wake up, check iMessage, and two summaries are sitting there. One with 5 random LeetCode problems and their approaches. One with a random system design topic from my Obsidian notes.&lt;/p&gt;

&lt;p&gt;It takes two minutes to read both. I'm not learning anything new — I'm just keeping what I already studied from fading. That's the whole point.&lt;/p&gt;

&lt;p&gt;For the interactive part, I open the terminal and type:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;cd&lt;/span&gt; ~/Documents/system-design-study
agy
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then just talk to it. "Quiz me on HLD." "What gaps do my DDIA notes have?" It responds using my actual notes. It's like having a study partner who has read everything I've written.&lt;/p&gt;




&lt;h2&gt;
  
  
  Was it worth it?
&lt;/h2&gt;

&lt;p&gt;Yes. It took a day. But, the system runs every morning without me doing anything. The only maintenance is adding one line to a text file every time I solve a LeetCode problem.&lt;/p&gt;

&lt;p&gt;If you're an MSCS student or prepping for interviews, the setup is worth it. You don't need any prior knowledge of AI agents or macOS automation. You just need a free Gemini API key from AI Studio and a few hours.&lt;/p&gt;

&lt;p&gt;The code is straightforward enough that you can adapt it to whatever you study. Swap the Obsidian vault for any folder of markdown files. Change the iMessage target to email or Telegram. Run it on whatever schedule works for you.&lt;/p&gt;




&lt;p&gt;&lt;em&gt;Built with: Antigravity 2.0 CLI, Gemini API (free tier), Python, launchd, pmset, AppleScript, Obsidian&lt;/em&gt;&lt;/p&gt;

</description>
      <category>productivity</category>
      <category>ai</category>
      <category>python</category>
      <category>beginners</category>
    </item>
  </channel>
</rss>
