Before You Rewrite a Power Plant Application, Recover the Rules That Keep It Running
A modernization field guide for energy technology leaders responsible for undocumented, business-critical software
The first deliverable in a legacy application modernization effort should not be replacement code. It should be evidence that your team understands what the application does, what depends on it and which behaviors the business needs to preserve.
For an energy technology leader, that changes the starting question. Instead of asking, “How quickly can we rewrite this application?” ask, “What must we know before changing it?”
The answer requires five connected forms of evidence: recovered business rules, application dependencies, validated specifications, tests and expert confirmation of operational intent. Together, they create a basis for controlled change—not simply a faster route to new code.
What a two-day application revival demonstrates—and what it does not
A large European energy producer depended on a mission-critical application used to manage power plant infrastructure. The application was more than two decades old, undocumented and impossible to maintain safely. The central problem was not coding speed. It was the inability to understand, govern or reproduce changes across similar assets.
Publicis Sapient used Sapient Slingshot, our enterprise AI software development platform, to coordinate agents across decompilation, refactoring, business logic extraction, documentation generation, testing and validation in a single workflow.
The application was revived in two days, with clean, modern code and full documentation. Automated code generation, test creation and validation delivered documented time savings. An opaque system became an understandable application that could connect to additional applications and sites, establishing a foundation for more repeatable software development.
This was an application engagement, not a complete power plant transformation. The two-day outcome describes the revival of that application. It should not be interpreted as a timeline for replacing plant-wide systems, transforming physical infrastructure or completing every operational assurance activity associated with a broader program.
The transferable lesson is coordination: recovering logic, documenting it, changing code and validating the result belong in one connected process. Speed matters when understanding survives the transition.
1. Recovered business rules: make behavior explicit
Before replacing functionality, require a readable account of the rules embedded in the existing application.
Technical discovery should surface the conditions, calculations, exceptions and decision paths that shape behavior. Where decompilation is needed, treat the recovered implementation as evidence to investigate—not as a complete explanation of business intent.
For each material rule, build a record that answers:
- What inputs does the rule use?
- What conditions cause it to run?
- What output or decision does it produce?
- Which exceptions or overrides affect it?
- Where was the rule found, and what remains uncertain?
Keep recovered behavior separate from proposed improvements. Otherwise, a rewrite can quietly combine two different decisions: how to reproduce existing functionality and whether that functionality should change.
Evidence to require: a reviewable rule inventory with traceability to the implementation and explicit gaps. An inferred explanation should remain labeled as an inference until validated.
2. Application dependencies: establish the boundary of change
A rule is not fully understood if the team cannot explain what supplies its inputs or consumes its outputs.
Map the application’s relationships with other applications, data sources and workflows. Identify authoritative sources, shared definitions, integration points and downstream consumers. Include dependencies mediated by people, not just software connections.
An enterprise context graph—a persistent map connecting systems, data, rules, workflows and dependencies—can help organize these relationships. But a connected map is only as trustworthy as the architecture, lineage and definitions beneath it.
Ask which relationships are confirmed and which are assumed. Where different teams interpret the same information differently, resolve the meaning before carrying it into a new implementation.
Evidence to require: a dependency map that explains the likely impact of the proposed change, identifies affected owners and makes uncertainty visible. A list of interfaces alone is not enough.
3. Validated specifications: turn discovery into an agreed contract
Generated documentation makes recovered logic easier to inspect. It does not, by itself, establish that the team has captured the right requirements.
Use discovery findings to create specifications that describe expected application behavior in language engineers and subject-matter experts can both review. Connect each material requirement to its supporting rule, dependency and acceptance criteria.
Distinguish three things:
- Observed behavior: what the existing implementation does.
- Confirmed intent: what accountable experts agree the application needs to do.
- Approved change: what the modernization effort is deliberately altering.
This separation is especially important when existing behavior and current expectations disagree. Do not silently resolve the conflict through code generation. Record it, assign an owner and obtain a decision.
Evidence to require: specifications with traceable support, reviewed definitions, recorded decisions and a visible list of unresolved questions. Documentation becomes a working contract only when its meaning has been validated.
4. Tests: demonstrate preservation and intentional difference
Tests should provide evidence against the agreed specifications, not merely show that the replacement application executes.
Design validation around material rules, dependencies and exception paths. Where comparison is possible, use existing behavior as a baseline while distinguishing behavior that must be preserved from behavior approved for change.
Require a clear connection between requirements and tests. For each important behavior, the team should be able to show what was tested, the expected result, the actual result and how any difference was resolved.
Be careful when code, specifications and tests are generated from the same recovered interpretation. Agreement among those outputs is useful, but it is not independent confirmation that the interpretation reflects operational needs. Expert-reviewed expectations remain essential.
Evidence to require: repeatable tests tied to validated requirements, recorded outcomes and explained differences. Test creation and validation should remain connected to discovery rather than becoming a downstream handoff.
5. Expert confirmation: establish why the behavior matters
Technical discovery and subject-matter review answer different questions.
Discovery reveals how the application is structured and how its logic connects. Experts help explain why a rule exists, when an exception matters and how people compensate for limitations outside the application.
Neither replaces the other. Human recollection alone can miss implementation details. Technical analysis alone cannot recover institutional knowledge that was never encoded or documented.
Combine structured reviews with observation of real workflows. Ask users to demonstrate how they handle exceptions, which information they trust and where manual workarounds influence outcomes. Capture those findings as structured context linked to the relevant rules and specifications—not as meeting notes disconnected from engineering work.
Evidence to require: confirmation from accountable application and operational experts that the specifications represent required intent, with disagreements and assumptions recorded. Expert review should shape discovery and testing throughout the engagement, not serve as a ceremonial final approval.
Readiness checklist: is the recovered logic understood well enough to change?
Use this checklist for the specific functionality you intend to modify. It is a decision aid, not a substitute for your organization’s release and operational controls.
- [ ] Scope is bounded: We can name the application functions being changed and what remains outside the engagement.
- [ ] Rules are recoverable and reviewable: Material logic is documented, traceable and understandable beyond the original discovery team.
- [ ] Dependencies are mapped: We know the relevant inputs, outputs, authoritative sources, downstream consumers and human handoffs.
- [ ] Meaning is agreed: Critical definitions are consistent, or differences are explicitly documented and owned.
- [ ] Specifications are validated: Observed behavior, confirmed intent and approved changes are clearly separated.
- [ ] Tests support the specifications: Material rules and exception paths have repeatable checks with recorded results.
- [ ] Differences are explained: Unexpected outcomes have been resolved or explicitly accepted by accountable owners.
- [ ] Experts confirm operational intent: Review includes real workflows and workarounds, not only official documentation.
- [ ] Uncertainty is controlled: Open questions have owners, and unresolved issues affecting the proposed change prevent approval until addressed.
- [ ] Understanding will persist: Rules, decisions, tests and dependencies will be maintained as the application evolves.
The threshold is not that every line has been rewritten. It is that the team can explain the proposed change, demonstrate what it preserves and identify who has confirmed that the result supports the operation.