DEV Community

Cover image for Information Trust: How Do AI Coding Agents Know What Is True?
spine-framework
spine-framework

Posted on

Information Trust: How Do AI Coding Agents Know What Is True?

When I began building software with autonomous AI agents, I assumed that providing good documentation would help prevent engineering mistakes.

It turns out that documentation introduces an entirely different problem.

How does an agent know whether the documentation it's reading is true?

Documentation is not necessarily knowledge

While developing Spine Framework with Devin, I encountered situations where the agent performed work based on stale documentation.

This led me to question some of my own assumptions about engineering documentation.

Consider a situation where an AI engineer encounters four different sources of information:

  • The application's current implementation.
  • Technical documentation describing how the application works.
  • An architectural decision describing how the application should work.
  • Historical information from previous engineering sessions.

What happens when these sources disagree?

The implementation could contain a bug. The documentation could be outdated. The architectural decision could have been superseded. The historical information could describe an abandoned approach.

Simply providing the agent with more context doesn't resolve the conflict.

Information availability versus Information Trust

I began thinking about this as an Information Trust problem rather than simply a documentation problem.

Making information available to an agent is relatively straightforward. Establishing whether that information is authoritative, current and applicable is considerably more challenging.

I started asking a different set of questions:

  • Where did this information originate?
  • What evidence supports it?
  • Does it describe what exists or what should exist?
  • Has it been superseded?
  • How should conflicting information be resolved?

These questions became increasingly important as the application grew and engineering decisions accumulated across multiple development sessions.

The problem with remembering everything

There is considerable interest in giving AI agents better memory.

But remembering everything isn't necessarily desirable.

Imagine an agent retaining every architectural discussion, every proposed solution, every abandoned implementation and every engineering decision without understanding the distinctions between them.

We've given the agent more information without necessarily improving its understanding.

An engineering knowledge system needs to distinguish between exploration, decisions, verified implementation and historical context.

Otherwise, yesterday's discarded idea can become tomorrow's engineering instruction.

Engineering the environment

This experience gradually changed how I thought about working with autonomous software engineers.

Rather than focusing exclusively on writing better prompts, I began focusing on engineering the environment in which the agent operates.

For me, that environment consists of three interconnected elements:

  • Foundation: The architecture and infrastructure upon which the agent builds.
  • Knowledge: The information the agent needs to understand the system and its engineering intent.
  • Skills: The procedures the agent follows when performing engineering work.

Each has a different responsibility, but they need to evolve together.

An architectural improvement may require updated documentation. An engineering failure may reveal a missing skill. A contradictory source of information may expose a weakness in how engineering knowledge is maintained.

Can engineering experience accumulate?

The question I'm increasingly interested in is whether we can make the engineering environment improve through experience.

When an agent encounters a problem, should resolving that problem be the end of the work?

Or should we also examine whether something needs to change in the architecture, knowledge or engineering procedures to reduce the likelihood of the problem recurring?

The objective isn't simply to complete the current engineering task. It's to improve the conditions under which future engineering tasks are performed.

An open question

I'm still exploring these ideas. I don't consider Information Trust a solved problem.

I'm particularly interested in how other developers working extensively with autonomous engineering agents are addressing it.

When your agent encounters contradictory information, how does it determine what to believe?

How do you prevent abandoned decisions from resurfacing?

And how do you ensure that what your agent learns today actually improves the engineering work it performs tomorrow?

I'd love to hear how others are approaching these problems.

This article reflects my own engineering experiences and was drafted with AI assistance.

Top comments (0)