<?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: Andy | AI产品专家</title>
    <description>The latest articles on DEV Community by Andy | AI产品专家 (@aipmandy).</description>
    <link>https://dev.to/aipmandy</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3837226%2Fd067649f-676c-49c6-a4d0-1d0b67acab0a.png</url>
      <title>DEV Community: Andy | AI产品专家</title>
      <link>https://dev.to/aipmandy</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/aipmandy"/>
    <language>en</language>
    <item>
      <title>DNA Memory: Making AI Agents Learn, Forget, and Evolve Like a Human Brain</title>
      <dc:creator>Andy | AI产品专家</dc:creator>
      <pubDate>Sat, 21 Mar 2026 21:36:47 +0000</pubDate>
      <link>https://dev.to/aipmandy/dna-memory-making-ai-agents-learn-forget-and-evolve-like-a-human-brain-2he7</link>
      <guid>https://dev.to/aipmandy/dna-memory-making-ai-agents-learn-forget-and-evolve-like-a-human-brain-2he7</guid>
      <description>&lt;p&gt;Most AI memory systems solve only one problem: &lt;strong&gt;storage&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;They help an agent remember previous messages, retrieve context, or search old notes. That is useful — but it is not the same as &lt;strong&gt;learning&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Human memory is not a database.&lt;/p&gt;

&lt;p&gt;It has structure.&lt;br&gt;
It forgets.&lt;br&gt;
It reinforces what matters.&lt;br&gt;
It summarizes patterns.&lt;br&gt;
It turns scattered experiences into reusable judgment.&lt;/p&gt;

&lt;p&gt;That is the idea behind &lt;strong&gt;DNA Memory&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;GitHub: &lt;a href="https://github.com/AIPMAndy/dna-memory" rel="noopener noreferrer"&gt;https://github.com/AIPMAndy/dna-memory&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  The problem
&lt;/h2&gt;

&lt;p&gt;If you have worked with AI assistants or autonomous agents for a while, you have probably seen the same failure mode:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;the agent stores too much low-value information&lt;/li&gt;
&lt;li&gt;old context accumulates without prioritization&lt;/li&gt;
&lt;li&gt;repeated mistakes are not converted into durable lessons&lt;/li&gt;
&lt;li&gt;user preferences are remembered inconsistently&lt;/li&gt;
&lt;li&gt;"memory" becomes a dump, not an evolving system&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Most memory layers are built like logs.&lt;br&gt;
Very few are built like cognition.&lt;/p&gt;

&lt;h2&gt;
  
  
  What DNA Memory tries to do differently
&lt;/h2&gt;

&lt;p&gt;DNA Memory is a lightweight memory evolution system for agents.&lt;/p&gt;

&lt;p&gt;Instead of treating memory as a flat key-value store, it treats memory as something that should move across layers and change in importance over time.&lt;/p&gt;

&lt;h3&gt;
  
  
  1. Three-layer memory architecture
&lt;/h3&gt;

&lt;p&gt;DNA Memory uses three layers:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Working memory&lt;/strong&gt;: temporary context for the current task or session&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Short-term memory&lt;/strong&gt;: recent important facts, preferences, and lessons&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Long-term memory&lt;/strong&gt;: stable knowledge and high-value patterns&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The goal is simple:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;not everything deserves to become long-term memory.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h3&gt;
  
  
  2. Reinforcement and forgetting
&lt;/h3&gt;

&lt;p&gt;Memories are weighted.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;used memories can be strengthened&lt;/li&gt;
&lt;li&gt;stale memories can decay&lt;/li&gt;
&lt;li&gt;low-value memories can eventually be removed&lt;/li&gt;
&lt;li&gt;stable, important memories can be promoted into long-term memory&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;That makes the system closer to how humans actually retain knowledge.&lt;/p&gt;

&lt;h3&gt;
  
  
  3. Reflection
&lt;/h3&gt;

&lt;p&gt;The most important part is not storage — it is &lt;strong&gt;reflection&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;DNA Memory includes a &lt;code&gt;reflect&lt;/code&gt; step that reviews high-value short-term memories and looks for repeatable patterns.&lt;/p&gt;

&lt;p&gt;That means agent experience can gradually become:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;a preference rule&lt;/li&gt;
&lt;li&gt;an operational skill&lt;/li&gt;
&lt;li&gt;a recognized failure pattern&lt;/li&gt;
&lt;li&gt;a reusable long-term memory&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  4. Better recall
&lt;/h3&gt;

&lt;p&gt;A memory system is only useful if retrieval is practical.&lt;/p&gt;

&lt;p&gt;The latest version now supports:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;multi-keyword AND recall&lt;/li&gt;
&lt;li&gt;type-based filtering like &lt;code&gt;type:error&lt;/code&gt; or &lt;code&gt;type:skill&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;SQLite &lt;strong&gt;FTS5 full-text search&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;fallback search when FTS5 is unavailable&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;So instead of just dumping everything into memory, recall becomes much closer to how an operator actually searches for prior experience.&lt;/p&gt;

&lt;h2&gt;
  
  
  A small but important engineering choice
&lt;/h2&gt;

&lt;p&gt;One thing I changed recently was unifying the storage around a &lt;strong&gt;single SQLite memory store&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;That solved a very real systems problem:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;old JSON-based memory artifacts and newer runtime state were drifting apart&lt;/li&gt;
&lt;li&gt;daemon behavior and memory data source were inconsistent&lt;/li&gt;
&lt;li&gt;recall quality suffered because the active store and the historical store were split&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;After the cleanup, the system now has:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;a cleaner SQLite-based primary store&lt;/li&gt;
&lt;li&gt;FTS5 recall indexing&lt;/li&gt;
&lt;li&gt;a daemon that reads the current SQLite operation history&lt;/li&gt;
&lt;li&gt;safer &lt;code&gt;.gitignore&lt;/code&gt; defaults so real memory databases are not pushed to GitHub by mistake&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Not flashy — but this kind of systems hygiene is what makes memory layers actually usable.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why this matters for agents
&lt;/h2&gt;

&lt;p&gt;I think the next step for AI agents is not just better reasoning per call.&lt;br&gt;
It is &lt;strong&gt;better continuity across calls&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;A capable agent should:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;remember what the user repeatedly cares about&lt;/li&gt;
&lt;li&gt;learn from mistakes instead of replaying them&lt;/li&gt;
&lt;li&gt;gradually build operating taste and judgment&lt;/li&gt;
&lt;li&gt;compress noisy experience into durable patterns&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;That is where memory becomes a true product advantage.&lt;/p&gt;

&lt;p&gt;Not “more context.”&lt;br&gt;
But &lt;strong&gt;better memory behavior&lt;/strong&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Example workflow
&lt;/h2&gt;

&lt;p&gt;A useful loop looks like this:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Recall&lt;/strong&gt; related memory before acting&lt;/li&gt;
&lt;li&gt;Execute the task&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Remember&lt;/strong&gt; newly learned preferences, skills, or errors&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Reflect&lt;/strong&gt; on repeated patterns&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Promote&lt;/strong&gt; stable memories into long-term memory&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Decay&lt;/strong&gt; what no longer matters&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;That turns raw interaction history into something closer to accumulated experience.&lt;/p&gt;

&lt;h2&gt;
  
  
  What is already implemented
&lt;/h2&gt;

&lt;p&gt;Current DNA Memory includes:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;remember / recall / stats CLI&lt;/li&gt;
&lt;li&gt;reflect / promote / dedupe flow&lt;/li&gt;
&lt;li&gt;SQLite-backed memory store&lt;/li&gt;
&lt;li&gt;FTS5 recall search&lt;/li&gt;
&lt;li&gt;background daemon for automatic reflect and decay&lt;/li&gt;
&lt;li&gt;launchd-based auto-start support on macOS&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  What is still missing
&lt;/h2&gt;

&lt;p&gt;There is still a lot to improve:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;better semantic retrieval beyond keyword/FTS recall&lt;/li&gt;
&lt;li&gt;stronger Chinese tokenization and ranking&lt;/li&gt;
&lt;li&gt;richer memory graph visualization&lt;/li&gt;
&lt;li&gt;more robust migration / import / export tooling&lt;/li&gt;
&lt;li&gt;shared memory spaces for multi-agent systems&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;So this is not a finished “memory platform.”&lt;br&gt;
It is a working direction.&lt;/p&gt;

&lt;h2&gt;
  
  
  Repo
&lt;/h2&gt;

&lt;p&gt;If you are building AI assistants, autonomous agents, or long-running automation systems, you may find the approach useful.&lt;/p&gt;

&lt;p&gt;GitHub: &lt;a href="https://github.com/AIPMAndy/dna-memory" rel="noopener noreferrer"&gt;https://github.com/AIPMAndy/dna-memory&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;If this resonates, I’d love feedback on one question:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What should an agent remember — and what should it deliberately forget?&lt;/strong&gt;&lt;/p&gt;

</description>
      <category>ai</category>
      <category>opensource</category>
      <category>python</category>
      <category>productivity</category>
    </item>
    <item>
      <title>How I Built an AI Investment Agent to Turn Trade Logs into Actionable Research</title>
      <dc:creator>Andy | AI产品专家</dc:creator>
      <pubDate>Sat, 21 Mar 2026 15:17:09 +0000</pubDate>
      <link>https://dev.to/aipmandy/how-i-built-an-ai-investment-agent-to-turn-trade-logs-into-actionable-research-13ck</link>
      <guid>https://dev.to/aipmandy/how-i-built-an-ai-investment-agent-to-turn-trade-logs-into-actionable-research-13ck</guid>
      <description>&lt;p&gt;Most retail investors don't really have an investing system.&lt;/p&gt;

&lt;p&gt;They have scattered notes, screenshots, a few Excel sheets, and some vague memories like:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;"I bought this because the story sounded good."&lt;/li&gt;
&lt;li&gt;"I sold too early again."&lt;/li&gt;
&lt;li&gt;"I knew this was risky, but I still did it."&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The problem is not just stock picking.&lt;br&gt;
The real problem is that most people never build a proper &lt;strong&gt;feedback loop&lt;/strong&gt; for their own decisions.&lt;/p&gt;

&lt;p&gt;That is why I built &lt;strong&gt;&lt;a href="https://github.com/AIPMAndy/ai-invest-agent" rel="noopener noreferrer"&gt;ai-invest-agent&lt;/a&gt;&lt;/strong&gt; — an open-source AI investment review system designed to help investors record trades, review decisions, and turn messy trading behavior into structured learning.&lt;/p&gt;
&lt;h2&gt;
  
  
  The problem I wanted to solve
&lt;/h2&gt;

&lt;p&gt;Most investing tools focus on one of these:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;market data,&lt;/li&gt;
&lt;li&gt;portfolio tracking,&lt;/li&gt;
&lt;li&gt;news aggregation.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;But very few tools focus on a more important question:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;How do you actually improve your investing decisions over time?&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;In practice, many investors repeat the same mistakes because they don't systematically review:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;why they entered a trade,&lt;/li&gt;
&lt;li&gt;whether the thesis was valid,&lt;/li&gt;
&lt;li&gt;whether the position sizing made sense,&lt;/li&gt;
&lt;li&gt;whether the exit decision was emotional or disciplined.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;I wanted something that works more like an &lt;strong&gt;investment reflection engine&lt;/strong&gt;, not just a dashboard.&lt;/p&gt;
&lt;h2&gt;
  
  
  What ai-invest-agent does
&lt;/h2&gt;

&lt;p&gt;At its core, the project combines three things:&lt;/p&gt;
&lt;h3&gt;
  
  
  1. Trade logging
&lt;/h3&gt;

&lt;p&gt;You can record buy/sell decisions from A-shares, Hong Kong stocks, and US stocks.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;ai-invest-agent &lt;span class="nt"&gt;--ticker&lt;/span&gt; 1810.HK &lt;span class="nt"&gt;--action&lt;/span&gt; buy &lt;span class="nt"&gt;--price&lt;/span&gt; 15.5 &lt;span class="nt"&gt;--shares&lt;/span&gt; 1000
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This creates a structured record instead of leaving the decision buried in chat history, screenshots, or memory.&lt;/p&gt;

&lt;h3&gt;
  
  
  2. AI-powered review
&lt;/h3&gt;

&lt;p&gt;The tool helps summarize your investing behavior and look for patterns such as:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;win rate,&lt;/li&gt;
&lt;li&gt;return attribution,&lt;/li&gt;
&lt;li&gt;overtrading,&lt;/li&gt;
&lt;li&gt;poor timing,&lt;/li&gt;
&lt;li&gt;recurring mistakes.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;ai-invest-agent &lt;span class="nt"&gt;--report&lt;/span&gt; 2024-01
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This is the part I care about most.&lt;br&gt;
The goal is not to make AI tell you what stock to buy.&lt;br&gt;
The goal is to make AI help you become a better decision-maker.&lt;/p&gt;
&lt;h3&gt;
  
  
  3. Stock-level analysis
&lt;/h3&gt;

&lt;p&gt;You can also run quick AI-assisted stock analysis:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;ai-invest-agent &lt;span class="nt"&gt;--analysis&lt;/span&gt; AAPL
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This gives you a lightweight view of strengths, risks, and key signals — useful as an input, not as a replacement for judgment.&lt;/p&gt;

&lt;h2&gt;
  
  
  The philosophy behind it
&lt;/h2&gt;

&lt;p&gt;I don't think AI should replace investors.&lt;/p&gt;

&lt;p&gt;I think AI should help investors do three things better:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;remember&lt;/strong&gt; what they actually did,&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;analyze&lt;/strong&gt; why it worked or failed,&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;improve&lt;/strong&gt; their next decision.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;In that sense, this project is less about prediction and more about &lt;strong&gt;decision quality&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;That is also why I describe it as an &lt;strong&gt;AI investment review system&lt;/strong&gt;, not just an AI stock picker.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why I made it open source
&lt;/h2&gt;

&lt;p&gt;There are two reasons.&lt;/p&gt;

&lt;h3&gt;
  
  
  First, investing systems are deeply personal
&lt;/h3&gt;

&lt;p&gt;Different people have different styles:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;value investing,&lt;/li&gt;
&lt;li&gt;momentum,&lt;/li&gt;
&lt;li&gt;event-driven,&lt;/li&gt;
&lt;li&gt;macro,&lt;/li&gt;
&lt;li&gt;long-term conviction.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;So the tool should be extensible, hackable, and customizable.&lt;/p&gt;

&lt;h3&gt;
  
  
  Second, open source creates better thinking
&lt;/h3&gt;

&lt;p&gt;If more builders and investors contribute to the project, the system can evolve into something much more useful:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;better review prompts,&lt;/li&gt;
&lt;li&gt;better reporting structure,&lt;/li&gt;
&lt;li&gt;better risk frameworks,&lt;/li&gt;
&lt;li&gt;better integrations with data sources.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Current project structure
&lt;/h2&gt;

&lt;p&gt;The repository is still intentionally simple:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;ai-invest-agent/
├── agents/           # AI agent modules
│   ├── analyzer.py   # stock analysis
│   └── reporter.py   # review reports
├── data/             # data storage
├── scripts/          # CLI tools
└── tests/            # tests
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The current focus is clarity and iteration speed rather than overengineering.&lt;/p&gt;

&lt;h2&gt;
  
  
  What I want to improve next
&lt;/h2&gt;

&lt;p&gt;A few directions I want to explore:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;better trade journaling templates,&lt;/li&gt;
&lt;li&gt;stronger review frameworks,&lt;/li&gt;
&lt;li&gt;risk scoring,&lt;/li&gt;
&lt;li&gt;portfolio-level reflection,&lt;/li&gt;
&lt;li&gt;smarter alerts for earnings and position management,&lt;/li&gt;
&lt;li&gt;cleaner English documentation and onboarding.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Why this may matter
&lt;/h2&gt;

&lt;p&gt;A lot of AI tools in investing are trying to be louder, faster, and more "intelligent."&lt;/p&gt;

&lt;p&gt;I think a more useful direction is:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;help people build a repeatable decision system.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;If AI can help investors review better, think more clearly, and avoid repeating the same errors, that is already valuable.&lt;/p&gt;

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

&lt;p&gt;GitHub:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;a href="https://github.com/AIPMAndy/ai-invest-agent" rel="noopener noreferrer"&gt;AIPMAndy/ai-invest-agent&lt;/a&gt;&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;If you're interested in:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;AI for investing,&lt;/li&gt;
&lt;li&gt;decision journaling,&lt;/li&gt;
&lt;li&gt;portfolio review,&lt;/li&gt;
&lt;li&gt;open-source financial tooling,&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;I'd love your feedback.&lt;/p&gt;

&lt;p&gt;And if you find the direction interesting, feel free to &lt;strong&gt;star the repo&lt;/strong&gt;, open an issue, or contribute.&lt;/p&gt;

</description>
      <category>opensource</category>
      <category>ai</category>
      <category>investing</category>
      <category>productivity</category>
    </item>
  </channel>
</rss>
