Refactoring in gd::TextFormatting and gd::InstructionSentenceFormatter