Is there a way to truncate the REPL output in calva? Just closing and reopening the REPL Output window does not lead to a truncated REPL output, I suppose. I longer AI coding sessions, the REPL output fills up the context window and the current workaround is closing VSCode and start all over. But that's not my preferred solution.
Is the LLM reading the repl window content? Sounds like an interesting workflow that I want to know more about. As for truncating, if we’re talking about the repl window, it’s a text file. Select text and delete it.
I'm talking about the REPL Output window, not the repl.calva-repl file. The contents are different.
Ah, but then I wonder how it would be connected to the context window. Is it the repl output tool that feeds too many lines to the llm?
Yes, it looks like. Chats like this one are really frustrating.
And I don't see any file in the project with the content of the REPL output. Otherwise I would have truncated it myself. When I close/reopen the REPL Output view, it starts empty, but the context still fills up. So the content of the REPL Output view is not what's read by the AI.
It is rather that the repl output view and the repl output tool are populated from the same source. I think a way to handle the problem would be to make the tool limit its output to the most recent X lines. You think that would work?
yes, I don't think more than a reasonable number of lines is necessary. most of the context should be the code itself. It should be enough for a bigger stacktrace, though. Maybe about 100-200 lines. 🤔
The number could be made configurable, if need be. But for the start I think, a limit would be enough.
Please file an issue in Backseat Driver.
done!