karthink / gptel

A simple LLM client for Emacs
GNU General Public License v3.0
1.04k stars 111 forks source link

org-mode output is not properly formatted #238

Closed dasoju closed 3 months ago

dasoju commented 3 months ago

Hi I am using gptel with gemini and i see that the formatting of org-mode is not looking right for example, in middle of my conversation, i asked a question "can you recommend a package", it gave an answer with some options, but the alignment of the subheadings is off, as you can see in the snapshot below

image

karthink commented 3 months ago

I updated the Org formatting in b634f05f. Please test (with the same or similar input to Gemini).

dasoju commented 3 months ago

also tables are getting garbled, for example, please see below image

of course, once i go into the table and TAB, i get a better output, wondering if this can be fixed image

karthink commented 3 months ago

of course, once i go into the table and TAB, i get a better output, wondering if this can be fixed

The tables are inserted as they are received from the LLM, there is no text processing going on.

dasoju commented 3 months ago

Thanks for the fix, the formatting looks good now, basically as below image

karthink commented 3 months ago

Very well, I'll close this issue now.

Auto-aligning tables is not planned for gptel, but you can do it via gptel-post-response-functions or gptel-post-stream-hook. If you are interested in writing this hook function and need help please create a new issue.