AI-512 : refactoring