← Back to Artificial Intelligence
cs.AI

Extracting hidden rules from legacy code for AI agents

Sanderson Oliveira de Macedo, Ronaldo Martins da Costa

May 18, 2026

Legacy systems embed business rules and architectural decisions that live in code, data, and institutional memory rather than formal documentation. Reversa addresses this by orchestrating specialized agents to map, analyze, and synthesize these implicit rules into traceable operational specifications with explicit confidence marking and human validation gaps. The framework runs as a Node.js CLI and was tested on a COBOL-to-Go ATM migration, producing 517 classified claims, 53 behavior scenarios, and a 9-of-11 task reconstruction plan. The authors position this as a contribution to reverse engineering and LLM-agent workflows rather than claiming empirical superiority, and propose evaluation metrics for coverage, traceability, and utility.
Published as Reversa: A Reverse Documentation Engineering Framework for Converting Legacy Software into Operational Specifications for AI Agents arXiv:2605.18684
Read the original paper →