‹ BackHN Continuity

Thread

Agents don't need memory, they need documentation

365 points · 261 comments · kmeh

  1. kaydub · · focus · HN ↗
    You don't need documentation or the 3rd party memory systems. The code IS the documentation.

    All this stuff is LLM rube goldberg machines. It just pollutes context.

    I barely use AGENTS.md/CLAUDE.md these days. And where they remain, it's super basic high level stuff.

    I'm honestly still kicking myself in the ass on many projects where I did something similar to this. I kept tons of markdown docs and decision docs. Now those things are just causing problems because they got stale. Even after having sessions of reconciling documentation, the LLM just gets confused.

    1. smokel · · focus · HN ↗
      Code typically documents the "what" and "how", not the "why".

      Why something exists, and how it connects to the outside world may be documented in comments, but more often than not it isn't.

      1. haukebri · · focus · HN ↗

        [dead]

      2. arcanemachiner · · focus · HN ↗
        And agents are pretty bad at inferring when to do, and often fall back to verbose clutterin the comments.
      3. kaydub · · focus · HN ↗
        The "why" should most often be self evident. If it's not, that's what commit messages are for. Not more markdown files and code comments.
        1. smokel · · focus · HN ↗
          Unfortunately, that is not how many software development projects work. A customer may request certain things, or the software might be part of a larger system.

          Consider working on software for a coffee machine. Why is pin 42 (GRIND) activated every now and then? Would you really want to document that in Git commit messages?

          1. kaydub · · focus · HN ↗
            Yeah, I'm going too far the other way. There are definitely legitimate reasons to comment in code and have documentation. I just feel like we're seeing a MASSIVE amount of documentation now and it's so much that it's mostly worthless.

            I'm seeing decision files that are so big the LLM can't fit it all in context on some projects. Then the LLM makes decisions that revert previous ones and later sessions don't pick that up so it sticks to the original decision. Now in some sessions, every so often I have to remind the LLM, "no, we changed that later, we do it this way now"

            And I'm seeing our knowledge base grow to a completely useless giant mess of stale, outdated, duplicated, or superfluous info. LLMs often pull unrelated info or confuse similar but different things or get old documentation for something that's been updated to new documentation in a different part of the knowledge base. And these are LLMs generating the docs. And we have LLMs and agents reconciling. But it doesn't seem to always get everything.

            For code comments, it's terrible because the comments are starting to get larger than the code. A large chunk of the comment can be discerned from the code itself. Then the comment has details on why that maybe don't quite make much sense. It's like the LLMs start using words in a specific context that doesn't really apply to the word in normal spoken english. Then it will also often include a specific JIRA ticket id, you check the JIRA ticket, you see that yeah, the code was changed because of that JIRA ticket, but it's not really related to the ticket itself, it was just a blocker. But now the comment forever links it to THAT ticket (And then now sometimes the LLM pulls in that ticket with the atlassian mcp).

Open on Hacker News to reply ↗

Unofficial Hacker News client; not affiliated with Y Combinator.