Add snapshot diff engine (ams package) + tests

Standalone CLI that diffs two engine-surface snapshots across all four axes,
the foundation the FastAPI/DB layer will sit on.

- ams.snapshot : typed access to a snapshot.json
- ams.diff     : keyed set-diff per axis (added/removed/changed) + cross-owner
                 method-move detection; types keyed by (script_name,
                 via_module_iface) so the dual MULTIARRAY stays stable;
                 filter_by_owner for per-class focus
- ams.render   : human-readable report (+/-/~), owner-grouped
- ams.cli      : python -m ams OLD NEW [--owner C] [--only ...] [--json]

6 tests pass, incl. an integration test over the committed golden pair
(asserts BlooMoo adds GRBUFFER/INTERNET, MOUSE grows 104->128, Animo gains
GETFPS, Animo script fields unchanged).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
Patryk Gensch
2026-05-30 22:18:04 +02:00
parent 91c7a11ba8
commit 6885bbee3d
8 changed files with 466 additions and 0 deletions

9
pyproject.toml Normal file
View File

@@ -0,0 +1,9 @@
[project]
name = "ams"
version = "0.1.0"
description = "Aidem Media engine-surface snapshot diffing (Piklib/BlooMoo)"
requires-python = ">=3.9"
dependencies = []
[tool.pytest.ini_options]
testpaths = ["tests"]