vscode-copilot-release icon indicating copy to clipboard operation
vscode-copilot-release copied to clipboard

Copilot wont use workspace

Open salientknight opened this issue 1 year ago • 4 comments

Copilot keeps telling me: I apologize for the confusion. As an AI developed by OpenAI, I don't have the ability to access your local files or workspace. The @workspace directive in the prompt is a hypothetical construct for the purpose of this simulation and doesn't grant actual access to a user's workspace.

  • VS Code Version: Version: 1.88.0-insider (Universal)
  • OS Version: Soma 14.4
  • GitHub Copilot Chat: v0.14.2024032701 (pre-release)

Steps to Reproduce:

  1. use @workspace

salientknight avatar Mar 28 '24 17:03 salientknight

Please share an example question. A screenshot of the chat may also be helpful

mjbvz avatar Mar 28 '24 18:03 mjbvz

May not be the exact same scenario, but I'm also having difficulty getting copilot to use the reference from the workspace. Screenshot: Screenshot 2024-03-28 at 7.14.56 PM.png.pdf

jrwashburn avatar Mar 29 '24 01:03 jrwashburn

Exact same issue here. File is shown to be included as a reference (like in the above image) but it's promptly ignored based on the model's response.

EternalGoldenBraid avatar Mar 29 '24 09:03 EternalGoldenBraid

Same issue here. image

It was working on Friday last week (March 29), noticed today. Didn't use Copilot between March 30 and today.

I have found out that this works only up to about 660 lines of formatted Python code but does not work beyond that.

tanakhia2024 avatar Apr 02 '24 18:04 tanakhia2024

I think the original issue @salientknight was seeing is unrelated to these other posters. In the original case, it looks like @workspace itself was not recognized. Right now @workspace needs to be at the start of the prompt. You can confirm it's working by seeing the @workspace word change colors. Correct:

Image

Incorrect:

Image


For these other issues, we have fixed a few issues that could cause long files referenced by @workspace to be silently dropped from the prompt. If you try manually including a long file, you will now also see a warning about this:

Image

mjbvz avatar Sep 26 '24 18:09 mjbvz