ChatGPT.nvim icon indicating copy to clipboard operation
ChatGPT.nvim copied to clipboard

Added total tokens option

Open RhydianJenkins opened this issue 2 years ago • 4 comments

image

Just a personal preference, but I like to track the expense of each request so I stay mindful over how much I'm spending. I can see this being unpopular so I have defaulted it to off.

This is only shown if you add the show_total_token_spend config option.

RhydianJenkins avatar Dec 17 '22 17:12 RhydianJenkins

Happy to change the style of this if you think the "total tokens spend" could be displayed better. Open to suggestions.

RhydianJenkins avatar Dec 17 '22 17:12 RhydianJenkins

just a [34] would be good somewhere

ben-wall avatar Dec 18 '22 22:12 ben-wall

just one total token count in the top right maybe?

chrisgrieser avatar Dec 18 '22 22:12 chrisgrieser

I've updated the format of the response. Thoughts?

RhydianJenkins avatar Dec 19 '22 11:12 RhydianJenkins

Thanks for that! However, I'm not sure about it, having it in this place is not the best opinion in my opinion. I've been thinking about something similar, but first I'm going to make some refactoring of my code to return all responses from the API and display it somehow (virtual text plus a shortcut to toggle on/off those informations).

jackMort avatar Dec 19 '22 22:12 jackMort