← Latest papers
💻 computer science

Do AI Coding Agents Log Like Humans? An Empirical Study

This empirical study of 4,550 agentic pull requests reveals that AI coding agents exhibit inconsistent logging patterns, frequently ignore explicit natural language instructions, and rely heavily on human developers to perform post-generation repairs, suggesting that deterministic guardrails are necessary to ensure reliable logging practices.

Original authors: Youssef Esseddiq Ouatiti, Mohammed Sayagh, Hao Li, Ahmed E. Hassan

Published 2026-04-13
📖 4 min read☕ Coffee break read

Original authors: Youssef Esseddiq Ouatiti, Mohammed Sayagh, Hao Li, Ahmed E. Hassan

Original paper licensed under CC BY 4.0 (http://creativecommons.org/licenses/by/4.0/). This is an AI-generated explanation of the paper below. It is not written or endorsed by the authors. For technical accuracy, refer to the original paper. Read full disclaimer

Imagine a bustling construction site where you've hired a fleet of incredibly smart, fast robots (AI Coding Agents) to help build and repair a massive skyscraper (a software system). These robots are great at laying bricks and wiring electricity—they can write code that works. But there's a catch: do they know how to install the security cameras and emergency alarms (Logging)?

This paper is a deep dive into exactly that question. The researchers acted like building inspectors, looking at thousands of construction projects to see if these robot workers are installing the necessary safety gear, or if they're leaving the building dark and blind.

Here's the story of what they found, broken down into simple parts:

1. The "Silent" Robots vs. The Chatty Humans

The Analogy: Imagine a human worker who, whenever they fix a leaky pipe, writes a note on the wall saying, "Fixed the leak in the kitchen at 2 PM." This helps future workers know what happened.
The Finding: The researchers found that the robots are actually quieter than the humans. In about 6 out of 10 projects, the robots touched the "notes" (logging code) less often than the humans did. They were less likely to add a note when they made a change.

However, there's a twist: When the robots did decide to write notes, they wrote more of them in a smaller space. It's like the human writes one clear note, but the robot writes three tiny notes in a row. This suggests the robots are a bit inconsistent: they sometimes forget to log, and when they do, they sometimes overdo it.

2. The "Forgetful Boss" (The Instruction Problem)

The Analogy: You tell your robot worker, "Please fix the door." You don't say, "And please remember to write a note about the door."
The Finding: The study found that human bosses (developers) almost never explicitly tell the robots to add these notes. Only about 5% of the time did a human say, "Make sure to add logging."
Even worse, when humans did give that specific instruction, the robots ignored it 67% of the time. It's as if you told a robot, "Wear a helmet," and it just kept working without one. The robots are bad at following these specific, non-urgent instructions.

3. The "Silent Janitors" (The Hidden Cleanup Crew)

The Analogy: The robots build a room, leave it messy, and the boss signs off on it. But later, a human worker comes in, quietly sweeps up the mess, and adds the missing notes, all without anyone noticing or complaining.
The Finding: This is the most surprising part. The robots aren't actually doing the final cleanup. Humans are doing 72.5% of the logging repairs after the robot has finished its work.
These humans are acting like "Silent Janitors." Instead of telling the robot, "Hey, you forgot the notes!" during the review, humans just wait until the code is merged, then they sneak in and fix the logging issues themselves. This is dangerous because it means the robots aren't learning; they are just creating a hidden tax of extra work for the humans.

4. Why This Matters (The "Black Box" Problem)

If a software system breaks in the middle of the night, engineers need those "notes" (logs) to figure out what went wrong.

  • If the robots don't log: The system becomes a "black box." When it crashes, no one knows why.
  • If humans have to fix it later: It slows everything down and creates a backlog of technical debt.

The Big Takeaway

The paper concludes that we can't just rely on talking to these robots (using natural language prompts) to make them do a good job with logging.

  • Humans rarely ask for it.
  • Robots rarely listen even when asked.

The Solution? We need automatic guardrails. Instead of asking the robot nicely to wear a helmet, we should build a rule that says, "If you don't have a helmet (logging), you cannot leave the construction site." This means using automated tools (like linters or CI/CD checks) that physically block the robot's code from being merged until the logging is perfect.

In short: AI coding agents are fast and smart, but they are currently terrible at "leaving a paper trail." Until we force them to do it with strict rules rather than polite requests, humans will have to stay up late cleaning up their mess.

Drowning in papers in your field?

Get daily digests of the most novel papers matching your research keywords — with technical summaries, in your language.

Try Digest →