text_formatter: change to simpler k-v when no tty