changed AnsiStream.ansi_format to accept the template as the first argument
updated obj_str to use AnsiStream