Sonar CEO: AI code scans gave 40, 11, then 18 issues on same codebase
Sonar CEO Tariq Shaukat says the same codebase scanned by Claude code yielded 40, 11 and 18 issues across runs — and most large companies will land on 'dim factories' with human oversight.
By Olivia Hart
4 min read

What's News
- The same AI scan of one codebase reported 40, then 11, then 18 issues across three runs, Sonar CEO Tariq Shaukat said at AI Dev in New York.
- Shaukat, formerly president of Google Cloud, said most Global 2,000 companies will run 'dim factories' with human oversight rather than fully automated 'dark factories'.
- The AI Dev conference was hosted by Andrew Ng's DeepLearning.ai.
- Shaukat says agents take the shortest path to an answer and lack built-in compatibility with a company's codebase.
- He expects human engineers to write almost none of the actual code but to define, verify and review it.
The same AI agent, run against the same codebase, reported 40 problems on one pass, 11 on the next and 18 on the third. Sonar CEO Tariq Shaukat cited that spread at the AI Dev conference in New York this week as the core problem facing AI-driven software development: code is abundant, confidence is scarce.
The conference, hosted by Andrew Ng's DeepLearning.ai, returned repeatedly to one tension. The software factory model — AI agents generating code at industrial scale — remains popular among AI-focused developers. But making those factories work requires careful tuning of both the models and the harnesses and context wrapped around them.
What does the variance problem actually look like?
Shaukat, formerly president of Google Cloud, used his opening talk to attack the assumption that AI can now be handed the coding job wholesale. The demonstrations of AI coding prowess all happen in pristine environments, he argued in an interview at the event.
"The model can verify a small piece of code, but verifying a million lines of code, a whole codebase, is a much, much harder thing. It still requires a lot of judgment to do that," Shaukat said.
His concrete evidence was his own codebase test. Claude code found 40 issues, then 11 on a re-run, then 18. Which run is right? One tempting answer is to ask another agent to arbitrate. Shaukat rejected that approach outright.
"I don't think you can throw more agents at a problem and expect it to have a better outcome. It's going to cost you a lot more tokens. It's going to cost you a lot of time. And what we've seen is that it doesn't always solve the problem," he said. The second agent carries the same variance, compounding the problem rather than resolving it.
His cited research — that AI judges change their verdicts when contradicted by another model, or even when asked the same question twice — frames the same weakness from another angle.
The fix, in Shaukat's view, is not more agents but encoded expertise: tell the model what specific security issue to look for, show it what a good result looks like and what it does not. "You teach the agent how to verify its own results, and build that knowledge into the harness itself. At that point, it all comes down to finding the expertise and encoding it into the harness," he said.
Can software development be fully automated?
Shaukat's answer splits by risk appetite and by system. He laid out three factory types:
- Dark factories — fully automated, no human review. Viable only for low-stakes parts of a codebase that "don't matter that much."
- Light factories — parts where regulation explicitly requires a human to review the code.
- Dim factories — Sonar's own framing. You don't check every piece, but you trust and verify: oversight of automation in low-stakes areas, more rigorous review where the stakes are high.
"I think most software inside of large companies is going to take that approach," Shaukat said of the dim factory model. For most Global 2,000 companies, the core software actually matters, which rules out full darkness for the systems at the heart of the business.
Pushed on whether so much verification implies weak confidence, Shaukat pushed back with a household analogy. "I know my washing machine cleans my clothes. Do I have to check it every single time? No. If I start finding my clothes being dirty, that's a problem. But you have the evidence," he said. Checking is evidence-gathering, not an admission of doubt.
What is left for human engineers?
Shaukat's job description for humans starts before any code exists. Engineers must define what to build, what "good" means and what "done" means, and they must plan the verification process itself. That specification covers not just function but architecture and adherence to the existing codebase.
Here he flagged a structural weakness in agents. Human developers build in a way compatible with the codebase they work in. "Agents don't know to be compatible, so they're just going to find the shortest path to the answer," Shaukat said.
For the foreseeable future, he sees a continuing role for people supplying the coding agent with the right information, the right context and the right verification steps. AI can augment most of that work, but he does not expect humans to step away entirely — particularly for mission-critical applications.
"Now, is the person writing the code? I'd expect that they're writing almost none of the actual code. But that doesn't mean you just tell it what to build and then go away and let it build," Shaukat said.
The takeaway in plain words: the human role shifts from writing code to defining, constraining and checking it — and that role survives, because the machines cannot yet check themselves reliably.
Original: deeplearning.ai
More from Olivia Hart
Show full bio
Staff writer covering people, launches and day-to-day practice in entrepreneurship, startups and venture funding at Business Bearings.
3,034 articles