Automatic Adapt text format to api input

I currently designed some type of chat gpt. In the chat’s answer, for isntance it is outlining 10 ideas, i would like it to be organized like TITLE
Idea 1:
iDEA 2
" \

And so on, like to strcture the test like in chatgpt,

is there a way to do this?