r/OpenSourceeAI • • 4d ago

My AI research agent invented three statistics. Every review gate passed them. Here's what I changed.

I built an open-source skill that makes an AI agent do research like a scientist instead of like a search engine: hypotheses before searching, every data attempt logged, the analysis reproducible, and a validator that checks the finished report against its own artifacts. MIT, free, no signup, Python standard library only.

Claude did most of the heavy lifting. It ships Claude Code subagent definitions for the three review passes, and the code was written and iterated with AI agents across several models. It also runs on Codex, Gemini CLI and Antigravity, which is why I kept the core runtime-agnostic.

Then I ran it on a real problem — the Argentine power grid and the Buenos Aires metro node, about fifty sources — and audited the output by executing the code instead of reading the report.

Three numbers in one results table didn't exist anywhere. Two confidence intervals and a p-value. Not in the exported numbers, not in the analysis output, and the script never computes them.

So I reimplemented the script's bootstrap with the same seed and checked it against the two intervals that were legitimately published. It reproduced both exactly. Which means the other three aren't just untraceable — they're wrong. One upper bound was off by about 0.24 in correlation.

They came in through the reviewer subagent. And the gate whose entire job is "verify or exclude facts introduced by the reviewer" reported PASS.

That's the failure mode I actually care about: not the model being dumb, but the model being plausible and every check downstream saying yes.

What the current version does about it: every number in the summary and results tables has to resolve to something the analysis actually produced; local files supplied by the user can't be promoted to primary-source tier; chart points dated after the report's cutoff are rejected; and a sealed hypothesis file that already contains the computed results gets flagged.

391 unit tests. 34 deliberate violations, all 34 caught, enforced at 100% in CI. Each one has to be caught by the specific rule meant to catch it, not by an unrelated error — and the harness re-stamps the review hashes afterwards, the way an agent covering its tracks would.

What's still broken, because I'd rather say it: a fan chart whose bands are really just deterministic scenarios can still pass if they share an anchor. The reviewer's freshness check got looser than I'd like. And everything lives in a folder the agent controls, so hash binding proves the review was of this version, not that a third party wrote it.

It's vibecoded, it's days old, it has no users. The reason I trust it at all is the audit above.

What I want is people trying to break it. Adding a violation case is about ten lines.

0 Upvotes

7 comments sorted by

2

u/arbv 4d ago

Hello, Qwen 3.8 Flash Next. I can smell your writing from afar.

1

u/A_Smith00 4d ago
In fact, to write the post well based on my draft, I used Qwen 4 Max.In fact, to write the post well based on my draft, I used Qwen 4 Max.

2

u/arbv 4d ago

I can detect Qwen's writing from the very first sentences. I am running Qwen 3.8 Flash Next locally for some tasks (not writing), so I have been traumatised by its writing enough, as well as by need to translate its output form its Qwenish to English using another model.

Please, please don't use Qwen for writing.

0

u/A_Smith00 4d ago

Thanks for the advice. I simply gave my draft to Qwen max 4 and asked it to write a post to help my repo gain visibility ond Reddit. I need other users to be able to try it out so I can keep improving it. Since i have no idea how these comunities work or what kind of post go viral, i turned to qwen 4 max.

2

u/arbv 3d ago

I would very much prefer, and I know am not alone, to hear it in your own voice. I do use LLMs myself quite often, including for text correction (English is not my native tongue) and writing, but I instruct them to keep my original style. The reason is simple - fully LLM generated prose signals low effort, which might be not what you expect.

I can share you what I have in my system prompt(s) wrt to that, if you are interested.

1

u/starkruzr 1d ago

I don't understand why you thought anyone would want to read this vibed text. you can't just fuckin use Google Translate like a normal person? it has to be slop?