Control flow loop and prompt logic complete