saoudrizwan / claude-dev

Autonomous coding agent right in your IDE, capable of creating/editing files, executing commands, and more with your permission every step of the way.
https://marketplace.visualstudio.com/items?itemName=saoudrizwan.claude-dev
MIT License
4.04k stars 381 forks source link

Everything break if we do some Ctrl-Z or Y and Claude is very slow and not cheap even with Cache #148

Closed onigetoc closed 3 weeks ago

onigetoc commented 3 weeks ago

Everything break if we do some Ctrl-Z or Y and Claude is very slow and not cheap even with Cache

After 4 small prompts et small change, it cost 51 cents and 12,184 token and 130 000 in cache. (Very light HTML change of 2 or 3 lines)

With gpt-4o-min it do not cost 1 cents but a fraction of it. Ok, it's not really your fault but i think it's doing too much task and i guess with a lot of agents actions. I guess because to make Claude so slow there's certainly a lot of agents or something like that.

Hope for the best in the futur it's just the beggining. 👍

saoudrizwan commented 3 weeks ago

Hey there, thanks for the feedback! Editing large files tends to burn through tokens, so I suggest you break your file down into smaller files if possible. I am actively working on reducing token count and with Anthropic's fast edit mode, editing large files will be a much smoother experience.

onigetoc commented 3 weeks ago

But, you may check others extensions and i do not know if the Cursor Ai IDE tools source code can be view but it's pretty fast and it's the same file structure i already got. not that big (a small projet until now with 50 to 100 code lines). Aider is fast too and Continue, But until now i do not like Continue and Aider is only from the terminal. What i like about Continue and The Curson IDE it's adding files this way to the project with @ + file name but in Cursor you see a list of files and choose from them when you enter @ and it's add/ but i prefer the short one with @ . It's best to add and remove files for the prompt to keep token low and not push the entire project everytime. Lot of token and a lot slower. For my React project, i add 2 to 4 files with the prompt for Claude (or any LLM) and it's just some 200 lines of code or less. I don't think it take that much token.

Regard

saoudrizwan commented 3 weeks ago

Cursor's edit applies uses speculative decoding under the hood, which Anthropic is coming out with soon and claude dev will be updated to have as soon as that's available. Aider uses a diff apply strategy where it asks the llm to output a diff instead of the whole file, although I've seen this output worse results. Reducing token counts is a priority right now, and referencing files/folders is on the roadmap. Thanks for your patience!