<?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: Nandish </title>
    <description>The latest articles on DEV Community by Nandish  (@psguerrillagameslgtm).</description>
    <link>https://dev.to/psguerrillagameslgtm</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%2F4232488%2F7e821874-2317-4590-b7e3-fac8dcfe06e4.png</url>
      <title>DEV Community: Nandish </title>
      <link>https://dev.to/psguerrillagameslgtm</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/psguerrillagameslgtm"/>
    <language>en</language>
    <item>
      <title>Designing an AI incident agent for 3 a.m.: making memory visible</title>
      <dc:creator>Nandish </dc:creator>
      <pubDate>Sat, 07 Nov 2026 17:08:12 +0000</pubDate>
      <link>https://dev.to/psguerrillagameslgtm/designing-an-ai-incident-agent-for-3-am-making-memory-visible-441i</link>
      <guid>https://dev.to/psguerrillagameslgtm/designing-an-ai-incident-agent-for-3-am-making-memory-visible-441i</guid>
      <description>&lt;p&gt;Picture the person who uses an incident tool. It's the middle of the night. An alert just woke them up. Customers are affected, a manager is asking for updates, and they are trying to read logs with half-open eyes.&lt;/p&gt;

&lt;p&gt;That person doesn't need a clever chatbot. They need an answer they can trust in seconds, and proof they can check.&lt;/p&gt;

&lt;p&gt;Our team built &lt;strong&gt;DejaVu&lt;/strong&gt;, an AI on-call agent that remembers how past outages were fixed. This post is about the design side: how we made an invisible thing, memory, visible and useful.&lt;/p&gt;

&lt;h2&gt;
  
  
  The engine underneath
&lt;/h2&gt;

&lt;p&gt;DejaVu's memory is powered by &lt;a href="https://github.com/vectorize-io/hindsight" rel="noopener noreferrer"&gt;Hindsight&lt;/a&gt;, an open-source agent memory system by Vectorize. Every past incident is stored in Hindsight. When a new error comes in, DejaVu &lt;strong&gt;recalls&lt;/strong&gt; similar incidents, an LLM (GPT-OSS 120B on Groq) reasons over them, and the engineer's feedback is &lt;strong&gt;retained&lt;/strong&gt; as a new memory.&lt;/p&gt;

&lt;p&gt;If you're curious why memory is different from just searching documents, Vectorize explains it well in &lt;a href="https://vectorize.io/what-is-agent-memory" rel="noopener noreferrer"&gt;what is agent memory&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;The challenge for design: memory works in the background. How do you show a stressed engineer &lt;em&gt;why&lt;/em&gt; the agent is so sure?&lt;/p&gt;

&lt;h2&gt;
  
  
  1. A live memory map
&lt;/h2&gt;

&lt;p&gt;The first thing you see is a map of dots. Each dot is a past incident, sized by how long it took to fix, and grouped by type of failure: cache, database, bad config, queues.&lt;/p&gt;

&lt;p&gt;When DejaVu recalls incidents for a new error, the matching dots &lt;strong&gt;light up&lt;/strong&gt; and lines draw out to them. You don't have to read anything to understand "this has happened before, many times." A failed fix shows as a red dot, and a newly learned incident appears as a green one.&lt;/p&gt;

&lt;h2&gt;
  
  
  2. Show the comparison, not just the answer
&lt;/h2&gt;

&lt;p&gt;We added a button: &lt;strong&gt;Compare without vs with memory&lt;/strong&gt;. It runs the same model twice, side by side. Without memory: 20% confident, a generic guess. With memory: 98%, with the exact fix.&lt;/p&gt;

&lt;p&gt;This turned out to be the clearest way to explain the product to anyone, technical or not. One glance, and the value of memory is obvious.&lt;/p&gt;

&lt;h2&gt;
  
  
  3. Proof under every claim
&lt;/h2&gt;

&lt;p&gt;The confidence ring never stands alone. Under it is a sentence in plain words, like "5 of 5 matching past incidents were fixed this way," and chips for each cited incident. On the right, each recalled incident has a card: the service, what happened, how strongly it matches, how long it took to fix, and &lt;em&gt;why&lt;/em&gt; it matches.&lt;/p&gt;

&lt;p&gt;The rule we followed: &lt;strong&gt;if the agent claims it, the screen shows where it came from.&lt;/strong&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  4. One click to teach it
&lt;/h2&gt;

&lt;p&gt;Feedback has to be effortless at 3 a.m. So it's two big buttons: &lt;strong&gt;Fix worked&lt;/strong&gt; and &lt;strong&gt;Fix failed&lt;/strong&gt;. One click saves the outcome to Hindsight in the background, and the interface never freezes:&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="nf"&gt;learn_new_incident&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt;
    &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;id&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;new_id&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;service&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;ss&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;service&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;error_signature&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;ss&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="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;root_cause&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;answer&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;probable_cause&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;resolution_steps&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;answer&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;fix_steps&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;fix_successful&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;outcome&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;          &lt;span class="c1"&gt;# True or False from the button
&lt;/span&gt;    &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;time_to_resolve_minutes&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nf"&gt;minutes_since&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;ss&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;diag_at&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;
    &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;occurred_at&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;datetime&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;now&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;timezone&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;utc&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nf"&gt;isoformat&lt;/span&gt;&lt;span class="p"&gt;(),&lt;/span&gt;
&lt;span class="p"&gt;})&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Inside, this calls Hindsight's &lt;code&gt;retain&lt;/code&gt; with &lt;code&gt;retain_async=True&lt;/code&gt;. A small celebration, a toast and a new green dot confirm it worked. We also record the &lt;strong&gt;real&lt;/strong&gt; minutes from diagnosis to fix, not the AI's guess, so the learning curve stays honest.&lt;/p&gt;

&lt;h2&gt;
  
  
  5. Calm colours, red only for alerts
&lt;/h2&gt;

&lt;p&gt;Our first version had neon colours everywhere, and it felt stressful. We switched to a calm black and champagne-gold theme. Red is used &lt;strong&gt;only&lt;/strong&gt; for real alerts and failed fixes, so when you see red, it means something. Animations respect the "reduce motion" setting, and the layout works on a phone, because on-call engineers aren't always at a desk.&lt;/p&gt;

&lt;h2&gt;
  
  
  6. Fitting into a real team
&lt;/h2&gt;

&lt;p&gt;Good design also means fitting how teams already work. Our path to adoption:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Import history:&lt;/strong&gt; load past postmortems into Hindsight.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Alert in:&lt;/strong&gt; a PagerDuty or Grafana webhook sends each alert to DejaVu.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Fix plan out:&lt;/strong&gt; the cited diagnosis is posted to the team's Slack or Teams channel.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Close the loop:&lt;/strong&gt; each "fix worked" becomes memory, and a weekly &lt;strong&gt;reflect&lt;/strong&gt; report tells the team lead what keeps breaking.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Steps 1 and 4 work today. The &lt;a href="https://hindsight.vectorize.io" rel="noopener noreferrer"&gt;Hindsight docs&lt;/a&gt; cover the reflect feature that powers that weekly report.&lt;/p&gt;

&lt;h2&gt;
  
  
  What I learned
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Make the invisible visible.&lt;/strong&gt; Memory is the core of the product, so we gave it a picture.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Proof builds trust faster than polish.&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Design for the worst moment,&lt;/strong&gt; not the demo moment.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Small details that made a big difference
&lt;/h2&gt;

&lt;p&gt;A few smaller choices helped more than we expected:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Quick-pick alerts.&lt;/strong&gt; Three buttons replay common outages (cache error after a deploy, database out of connections, login rate limits), so anyone can try the product without typing an error.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;A downloadable postmortem.&lt;/strong&gt; One click writes a blameless postmortem in Markdown, because writing it is the task everyone puts off after an outage.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;A learning curve chart.&lt;/strong&gt; It shows time-to-fix for every incident, with the average dropping from 44 minutes to 6 as memory grew. It answers "is this actually helping?" without a single word.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Friendly errors.&lt;/strong&gt; When the free AI tier is busy, the app says "wait 30 seconds" instead of showing a stack trace.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;None of these are about AI. They're about respecting the person using the tool.&lt;/p&gt;

&lt;h2&gt;
  
  
  Try it
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Code: &lt;a href="https://github.com/Pratheeksh-7S/dejavu-incident-agent" rel="noopener noreferrer"&gt;https://github.com/Pratheeksh-7S/dejavu-incident-agent&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Demo video: &lt;a href="https://youtu.be/Nu_sktguGMk" rel="noopener noreferrer"&gt;https://youtu.be/Nu_sktguGMk&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Hindsight: &lt;a href="https://github.com/vectorize-io/hindsight" rel="noopener noreferrer"&gt;https://github.com/vectorize-io/hindsight&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The best incident tool is the one a tired engineer can understand in five seconds.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>webdev</category>
      <category>ux</category>
      <category>devops</category>
    </item>
  </channel>
</rss>
