Open guywald opened 5 hours ago
Thank you for filing this issue.
Please check if those costly messages really got billed. If the API returns an error, those requests should not get billed. Do not trust aider's cost estimation, it is (as stated) not reliable.
Also note that you can (and should) check your token usage before you send a prompt/request with /tokens
Issue
Sent: a costly message with a big file. Response:
A previously sent message with a larger file resulted in the following error:
The different api limits should be considered before sending a message, preventing limits breaching.
Maybe a pre-send validation hook could solve such a scenario.
Version and model info
Aider v0.58.1 Main model: claude-3-5-sonnet-20240620 with architect edit format, infinite output Editor model: claude-3-5-sonnet-20240620 with editor-diff edit format Weak model: claude-3-haiku-20240307