continue icon indicating copy to clipboard operation
continue copied to clipboard

Terminal Context Missing Last Few Lines

Open asus-ocis opened this issue 1 year ago • 4 comments

Before submitting your bug report

Relevant environment info

- OS:windows
- Continue version:v1.0.8
- IDE version: VSCode 1.100.0
- Model: GPT-4o

Description

When the VS Code terminal window is full, the @terminal annotation does not include the last two lines of the terminal's content as context for the LLM. This results in incomplete information being sent, which can lead to inaccurate or incomplete responses from the LLM.

To reproduce

  1. Open the terminal in VS Code. Adjust the terminal window size to make it smaller, ensuring it can display fewer lines of output.
  2. Navigate to a directory with a large number of files and subdirectories. For example: dir
  3. Ensure the directory contains enough files to fill the terminal screen completely.

Image

  1. Use the @terminal annotation to reference the terminal's content.
  2. Click "The contents of the terminal"

Image

  1. Observe that the last two lines of the terminal are not included in the context sent to the LLM.

Image

Expected Behavior The terminal should include all lines of the output, including the last few lines, when referenced using @terminal.

Actual Behavior The last few lines of the terminal output (e.g., XLiuDev.7z and PS D:\download>) are missing when the terminal is full, causing incomplete context to be referenced.

Impact If the last few lines of the terminal contain critical information, such as error messages or important output, the LLM will not receive this data. This can lead to inaccurate or incomplete responses from the LLM, as it lacks the necessary context to provide meaningful assistance.

Log output


asus-ocis avatar May 09 '25 07:05 asus-ocis

@asus-ocis are you still seeing this on the newest release? There were some PRs that could have effected terminal output, although I think more towards input

RomneyDa avatar May 27 '25 00:05 RomneyDa

@asus-ocis are you still seeing this on the newest release? There were some PRs that could have effected terminal output, although I think more towards input @RomneyDa

Yes, I am still seeing this issue on continue v1.0.10. I have just tested with the latest release and the problem persists. I’ve attached a screenshot for your reference. The output is still missing the last few lines.

Image

asus-ocis avatar May 27 '25 07:05 asus-ocis

This issue hasn't been updated in 90 days and will be closed after an additional 10 days without activity. If it's still important, please leave a comment and share any new information that would help us address the issue.

github-actions[bot] avatar Aug 26 '25 02:08 github-actions[bot]

This issue was closed because it wasn't updated for 10 days after being marked stale. If it's still important, please reopen + comment and we'll gladly take another look!

github-actions[bot] avatar Sep 06 '25 02:09 github-actions[bot]