# File Modification Recovery

> When a file modification conflict occurs, detect the error, re-read the current file, merge the intended delta into the current content, write the complete new version, verify persistence, and log recovery automatically without asking the developer.

Record: `algorithms:agent-workflow-file-modification-recovery`
Kind: algorithm
Canonical: https://banes-lab.com/ontology/algorithms#algorithms-agent-workflow-file-modification-recovery
Closure: https://banes-lab.com/json/records/algorithms/agent-workflow-file-modification-recovery/closure

Listed in [Algorithm contracts](https://banes-lab.com/api/records/algorithms.md), after [DSL Compliance Loading](https://banes-lab.com/records/algorithms/dsl-compliance-loading.md) and before [Context Forking Configuration](https://banes-lab.com/records/algorithms/context-forking-configuration.md).

## Domain

- [Agent workflow](https://banes-lab.com/records/algorithms-domain/agent-workflow.md)

## Stage

- [act](https://banes-lab.com/records/stage/act.md)

## Axis

- [formalization](https://banes-lab.com/records/reasoning/axis-formalization.md)

## Tier

- [process](https://banes-lab.com/records/vocabulary/domain-tier-process.md)

## Composed by

- [Workflow Creation Kernel](https://banes-lab.com/records/algorithms/workflow-creation-kernel.md)

## Math type

- [Computation](https://banes-lab.com/records/reasoning/math-type-computation.md)

## Force

- [Correctness verification](https://banes-lab.com/records/force/correctness-verification.md)
- [Resilience recovery](https://banes-lab.com/records/force/resilience-recovery.md)
- [State transaction](https://banes-lab.com/records/force/state-transaction.md)

## Linked from

- [Agent workflow](https://banes-lab.com/ontology/algorithms/algorithms-domain-agent-workflow.md)
- [The derivation loop](https://banes-lab.com/ontology/reasoning/reasoning-loop-derivation-loop.md)
- [The axes](https://banes-lab.com/ontology/reasoning/the-axes.md)
- [The mathematics](https://banes-lab.com/ontology/reasoning/the-mathematics.md)
- [Domain tiers](https://banes-lab.com/ontology/schema/the-vocabulary-domain-tier.md)
- [The forces](https://banes-lab.com/ontology/schema/the-forces.md)
