AI News HubLIVE
In-site rewrite1 min read

What broke when I let an AI agent modify its own Python code for 144 cycles

This article presents zmb_audit.py, a zero-dependency Python static analysis tool, and explores an experiment where an AI agent modified its own code over 144 iterations. The tool identifies orphan modules, unresolved calls, and code rot, while the experiment revealed multiple failure modes.

SourceHacker News AIAuthor: ArthurDev

Notifications You must be signed in to change notification settings

Fork 0

Star 0

BranchesTags

Open more actions menu

Folders and files

NameName

Last commit message

Last commit date

Latest commit

History

1 Commit

1 Commit

LICENSE

LICENSE

README.md

README.md

zmb_audit.py

zmb_audit.py

Repository files navigation

A zero-dependency, standalone static analysis tool for Python codebases.

Overview

zmb_audit.py scans any target Python repository using Python's standard library ast parser to identify structural governance risks and code rot:

Orphan Modules: Finds Python modules that exist in the codebase but are imported by nothing.

Unresolved Attribute Calls: Detects suspicious method calls across files to missing or renamed symbols.

Kernel Guard Status: Verifies whether git pre-commit hook protection is active.

Installation & Requirements

Requirements: Python 3.8+ (Stdlib only — no pip dependencies required).

Setup: Download zmb_audit.py and run it directly.

Usage

Audit current directory

python zmb_audit.py

Audit specific repository path

python zmb_audit.py /path/to/repository

Output results as structured JSON

python zmb_audit.py /path/to/repository --json

Exclude specific custom directories from scan

python zmb_audit.py /path/to/repository --exclude legacy_code experimental

Deep-Dive Report

For full empirical analysis of 8 autonomous self-modification failure modes and production reachability instrumentation:

👉 Read the ZMB Failure-Mode Report

Resources

Readme

MIT license

Activity

Stars

0 stars

Watchers

0 watching

Forks

0 forks

Report repository