A Hybrid Dependency-Aware Framework for Task Decomposition and Dynamic Agent Generation in Oracle-to-PostgreSQL Migration
cs.LO, cs.AI, cs.MA, cs.SE
Submitted: 2026-09-13
Updated: 2026-09-13
Comments: 18 pages, 9 figures, 11 tables, 36 references
License: http://creativecommons.org/licenses/by/4.0/
The gist: Large language model (LLM)-based database migration is often treated as direct code transformation, although enterprise Oracle systems contain heterogeneous SQL and PL/SQL artifacts with different
Terminology
Abstract
Large language model (LLM)-based database migration is often treated as direct code transformation, although enterprise Oracle systems contain heterogeneous SQL and PL/SQL artifacts with different dependencies, execution order, complexity, and validation needs. This paper proposes a hybrid dependency-aware framework that identifies migration tasks, builds a cross-file dependency graph, condenses cyclic dependencies, and uses task specifications to generate specialized migration agents at runtime. The deterministic path combines ANTLR-based parsing with typed dependency extraction, while an LLM fallback is invoked only for units that cannot be parsed reliably. On a corpus of 116 Oracle files, the pipeline produced 1,037 units with zero coverage gaps and 1,271 AST-derived dependencies. The fallback processed 165 parse-error units, recovered 496 additional validated dependencies, eliminated unresolved-dependency units, and increased resolved internal edges from 446 to 527. The graph contained four dependency-respecting phases, while cycle handling was validated separately using Tarjan SCC condensation. A complementary experiment on 1,006 PL/SQL files regenerated 623 scripts (62%), of which 380 (61%) executed successfully in PostgreSQL 16. Tables achieved about 85% regeneration success, whereas no query regenerations succeeded under the evaluated specification-mediated baseline, and procedural objects remained strongly dependent on schema context. These results motivate dependency-aware context delivery, task-specific validation, and differentiated agent routing. The paper also formalizes task-to-agent mapping, introduces monitoring and diagnostics for execution feedback, and defines a controlled comparison of monolithic, static-decomposition, dependency-aware, and dynamically orchestrated migration strategies.
Sources
- Token Optimization Strategies for LLM-Based Oracle-to-PostgreSQL Migration
- Specification-Based Code-Text-Code Reengineering for LLM-Mediated Software Evolution
- AutoGen: Enabling Next-Gen LLM Applications via Multi-Agent Conversation
- DSPy: Compiling Declarative Language Model Calls into Self-Improving Pipelines
- DSPy Assertions: Computational Constraints for Self-Refining Language Model Pipelines
- Runtime-Structured Task Decomposition for Agentic Coding Systems
- AgentBench: Evaluating LLMs as Agents
- SWE-bench: Can Language Models Resolve Real-World GitHub Issues?
- ITBench: Evaluating AI Agents across Diverse Real-World IT Automation Tasks
- Verified Multi-Agent Orchestration: A Plan-Execute-Verify-Replan Framework for Complex Query Resolution
- CrackSQL: A Hybrid SQL Dialect Translation System Powered by Large Language Models
- An LLM Compiler for Parallel Function Calling
- Reflexion: Language Agents with Verbal Reinforcement Learning
- AdaptOrch: Task-Adaptive Multi-Agent Orchestration in the Era of LLM Performance Convergence
- From Static Templates to Dynamic Runtime Graphs: A Survey of Workflow Optimization for LLM Agents
- Spec-Driven Development:From Code to Contract in the Age of AI Coding Assistants
- Agentic AI Process Observability: Discovering Behavioral Variability
- Beyond BLEU: A Semantic Evaluation Method for Code Translation
- CodeBLEU: a Method for Automatic Evaluation of Code Synthesis
Related papers
- An Information-Flow Perspective on Explainability Requirements: Specification and Verification
- A programming language combining quantum and classical control
- Causal Past Logic for Runtime Verification of Distributed LLM Agent Workflows
- Encoder-Decoder Transformers: Logical Characterizations and Periodicity
- Ultraconstructive Model Theory via Bounded Adversarial Finite Structures