Modify logging functions to support formatted string using text-format