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

Please add delay before inline suggestions

Open daniel-tonic opened this issue 2 years ago • 2 comments

During a recent frustrating moment I was trying to add additional tabs to a document. Unfortunately every time I would hit tab, CoPilot saw it as an opportunity to suggest something. Since I was hitting tab repeatedly to try to pad something, it would then automatically accept a suggestion when that wasn't my intention at all. In the end I had to accept the suggestion, then go back and put tabs in front of that, then delete the suggestion so I could do my work. I think a delay after a tab is hit to see if the user is pressing it multiple times would make sense to avoid this frustrating experience of trying to hit tabs before CoPilot decides to suggest and accept something.

Thank you

daniel-tonic avatar Mar 08 '24 18:03 daniel-tonic

If anything I think it should just be a changeable extension setting

barxilly avatar Mar 17 '24 22:03 barxilly

@daniel-tonic As a workaround, you can disable the inline suggestions:

grafik

Then you can assign a custom keyboard shortcut to "Trigger inline suggestion" (I use CTRL+SHIFT+S)

grafik

This way, you can decide when you need a suggestion and trigger it manually.

gpaddis avatar Aug 07 '24 13:08 gpaddis

Fair feature request but nothing that we have on the immediate plan.

isidorn avatar Feb 13 '25 09:02 isidorn

+1 on that one, it's hellish not being able to think for a few moments without Copilot's suggestion, let me think for a few moments, damn !

yannmichaux avatar Apr 04 '25 17:04 yannmichaux

Another vote for this. It is very distracting when in the middle of writing something and text pops up on the screen trying to take my attention away and constantly need to mentally dismiss. Even more so when you are simply pressing tab for indentation but inline suggestions were faster than you and you end up accepting multiple lines of who knows what before you even saw it pop on the screen.

Setting a longer delay solved this for me with quick suggestions. I wish inline suggestions worked exactly the same.

pkkid avatar Apr 07 '25 12:04 pkkid

Please please please implement this. A configurable delay would be the perfect middle-ground between no suggestions, and immediate suggestions on every keystroke.

Sharondio avatar Apr 09 '25 17:04 Sharondio

This has become even more problematic with syntax color highlighting (yes, I've turned it off). But if I'm thinking sometimes it feels like I'm looking at actual changed code because it isn't dim enough. Being able to delay to N ms would go a long way.

joerohde avatar Apr 18 '25 22:04 joerohde

Please add ability to delay suggestions. Typing really becomes unusable frequently.

kolyasya avatar Apr 22 '25 06:04 kolyasya

Also please add this feature, autosuggestion is currently tooo fast and istead of helping its getting annoying,

SponeKiller avatar Apr 22 '25 08:04 SponeKiller

Hello,

I think I have to add another vote here; the increase of suggestion speed over time makes this feel like a usability regression fix as much as a feature request.

Generally, having no or slow suggestions seems much less inconvenient than having instantaneous suggestions that are not relevant. They shift the entire screen around and interrupt work. It would be preferable that the model spend the extra time checking its confidence in the suggestions.

(Regardless, thanks for all the great work on these features!)

abkarcher avatar Apr 25 '25 15:04 abkarcher

For the love of God, please add a configurable delay to the suggestions. It's nearly impossible to hit tab in Python without copilot adding a paragraph of gibberish code. Let me think!

jmesterh avatar Apr 27 '25 04:04 jmesterh

Also need this please 🙏

FredGithub avatar Apr 28 '25 14:04 FredGithub

One other workaround that we can use in the short term is toggling auto-completion on and off. The setting in keybinds is labelled "GitHub Copilot: Toggle (Enable/Disable) Completions"

Sacs avatar Apr 30 '25 16:04 Sacs

A setting like github.copilot.editor.delayAutoCompletions = 15000 ms or something would be helpful

sirwolfgang avatar May 01 '25 00:05 sirwolfgang

This is actually causing bugs in my code because the auto-completion is so fast that I often miss that it completely changed some of my code when moving my cursor around the screen. I bring it up because the following example is happening to me multiple times a week, and I feel the too fast speed to suggest completions is 100% the cause.

Providing this story as an example of the pain this is causing us. Not trying to be rude by explaining it. -- Anyway, I just spent 30 minutes trying to figure out why an exception was happening in my code. In the end, it was Copilot. I had the following schema definition in Django, and I must have put my cursor in the wrong spot, and accidentally accepted a change copilot was suggesting. This happens to me more often that it should. Usually I catch it, and its just a minor annoyance. Other times, like this one, I spend 30m trying to figure what I think I did wrong, only to get annoyed that it wasn't me at all, but the IDE being too eager to make me accept suggestions and I happened to miss it.

class CategorySchema(Schema):
    id: Optional[int] = Field(None, description='Internal category id')
    url: Optional[str] = Field(None, description='URL for the category resource')
    name: str = Field(..., description='Name of this cateogry')
    exclude: Optional[bool] = Field(None, description='Exclude this category from reports')
    sortid: Optional[int] = Field(None, description='User sort id when listing categories')

Was changed to:

class CategorySchema(Schema):
    id: Optional[int] = Field(None, description='Internal category id')
    url: Optional[str] = Field(None, description='URL for the category resource')
    name: str = Field(..., description='Name of this cateogry')
    exclude: Optional[bool] = Field(NotImplemented, description='Exclude this category from reports')
    sortid: Optional[int] = Field(None, description='User sort id when listing categories')

Normally, I can spot exception and fix them pretty easy, but Django was spitting this out (which was no help). So I got to spend time going line-by-line to figure out what the heck happend.

Traceback (most recent call last):
  File "/home/pkkid/Projects/site/.venv/lib/python3.12/site-packages/pydantic/type_adapter.py", line 270, in _init_core_attrs
    self.core_schema = _getattr_no_parents(self._type, '__pydantic_core_schema__')
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/pkkid/Projects/site/.venv/lib/python3.12/site-packages/pydantic/type_adapter.py", line 55, in _getattr_no_parents
    raise AttributeError(attribute)
AttributeError: __pydantic_core_schema__

Can you spot the bug? In the context of this change in a larger file, I couldn't. Not until I went line by line. Copilot suggested (and I accidentally accepted) a change of the None keyword to NotImplemented. One could say it's my fault for accidentally accepting this change, but I feel this is entirely the fault of suggestions popping up way to fast in our normal typing!

Please, please reconsider adding a delay option in the near future.

pkkid avatar May 04 '25 01:05 pkkid

+1

fvwanja avatar May 14 '25 14:05 fvwanja

Seems like Copilot suggestions have gotten very fast recently and now they desperately need a delay setting... this is getting out of hand. I can't even think for a few seconds... they're near instantaneous and incredibly distracting.

redtopia avatar May 14 '25 15:05 redtopia

Apparently, this conversation has been a discussion since 2022. Today I felt like I hit ESC and deleted mis-accepted suggestions more than I typed my own code!

lovette avatar May 14 '25 23:05 lovette

Suggestions in the editor the last couple of weeks is starting to get in the way. Finding myself hitting esc 90% of the time now. I feel the issue is a combination of timing and poor suggestion quality. I'd rather get a fewer suggestions with a delay.

Right now it feels like an annoying person that never lets you finish your sentence before it interrupts you. It's supposed to be a suggestion. Suggestions are supposed to come at a pause of thought! Not 20ms after I stopped typing something.

hallatore avatar May 30 '25 07:05 hallatore

could be related: https://github.com/orgs/community/discussions/17670

quangv avatar May 31 '25 21:05 quangv

I haven't tested it, but for suggestions there is editor.quickSuggestionsDelay already. (It's 10 ms by default, but you can set it to 2000 etc) Should copilot adhere to the same setting, or introduce a similar one?

hallatore avatar Jun 03 '25 06:06 hallatore

I haven't tested it, but for suggestions there is editor.quickSuggestionsDelay already. (It's 10 ms by default, but you can set it to 2000 etc) Should copilot adhere to the same setting, or introduce a similar one?

That delay option only works for regular suggestions and is ignored for copilot suggestions. Don't mind if its the same option or a second one. Just hoping to get copilot suggestions to be less aggressive.

pkkid avatar Jun 03 '25 12:06 pkkid

Please implement.

kyunussov avatar Jun 14 '25 15:06 kyunussov

Yes, please add this. This is getting so frustratring, I end up adding code that I don't want all the time.

bakura10 avatar Jun 22 '25 08:06 bakura10

+1

ceri-waterscreative avatar Jul 23 '25 10:07 ceri-waterscreative

I feel like I am seeing this complaint come up more and more. Maybe putting it all out there will help get some attention behind this request? All of these posts showcase the issue or are looking for a workaround because of this issue.

  1. https://github.com/microsoft/vscode-copilot-release/issues/11895 (June 8, 2025)
  2. https://github.com/microsoft/vscode-copilot-release/issues/11105 (May 29, 2025)
  3. https://github.com/microsoft/vscode-copilot-release/issues/1355 (June 29, 2024)
  4. https://github.com/microsoft/vscode-copilot-release/issues/13340 (June 24, 2025)
  5. https://github.com/microsoft/vscode-copilot-release/issues/8495 (Apr 24, 2025)
  6. Add a suggestion delay option in the configuration (June 2, 2022)
  7. Can I make copilot less intrusive? (Nov 12, 2023)
  8. Turn off Copilot Temporarily for inline Suggestions in Visual Studio (Sept 9, 2024)
  9. Reddit: Slow down hyperactive Github Copilot? (July 20, 2025)
  10. Reddit: Whats your preferred shortcut for disabling Copilot? (July 30, 2025)
  11. Reddit: How have you configured Copilot to be less intrusive? (May 27, 2025)
  12. Reddit: Extension: Disable Copilot Comment Completions (May 11, 2025)

At the time of writing this, there are 26 comments on this thread, putting it in 3rd place compare to other items in the backlog.

pkkid avatar Jul 30 '25 17:07 pkkid

This has gotten a LOT worse lately--as recently as a month or two ago, I found that VS Code Copilot suggestions struck a good balance of "sometimes helpful but not distracting," but recently that's shifted to almost being more annoying than helpful.

It seems like the suggestions became more of an annoyance after the newer enhanced suggestions feature was introduced (I forget what you call it internally)--the fact that it seems to operate at a scope beyond the current line is sometimes helpful, but either it's more aggressive with timing or more often wrong than the old current-line version. And the suggestion timing might have gotten even more aggressive at some point after it was introduced.

Now it seems like I'm constantly fighting with Copilot about every trivial thing, even down to when I start writing a comment or string and don't follow the exact formatting it thinks I should, or if some brackets are slightly mismatched (often the suggestion is wrong in that case, or I can't tell what's the suggestion vs. what I currently have typed). Sometimes I even have to cancel the same incorrect suggestion (for a different line) repeatedly, since it pops back up after I start typing again! So obviously the accuracy could be improved, but I think having an option to increase the delay or perhaps tweak some of the other behavior would go a long way.

ecraig12345 avatar Aug 06 '25 22:08 ecraig12345

Bump!

harley-codes avatar Aug 15 '25 14:08 harley-codes

Thank you for all your feedback and for the bump! We're actively working on this and changes will land soon on VS Code Insiders to enable delay setting configuration. We'll keep you posted!

minsa110 avatar Aug 15 '25 21:08 minsa110

Please try adding the following to your settings, which lets you control the delay (in milliseconds) before a suggestion appears after you start typing (e.g., I have set below 3 seconds):

"editor.inlineSuggest.minShowDelay": 3000,

Caveats:

  • This currently works only in VS Code Insiders + with latest pre-release version of the GitHub Copilot and GitHub Copilot Chat extensions
  • This will end up in delaying both completions and next edit suggestions
  • This feature is still under development, and we’ve noticed that the interaction between completions and NES behaves a bit differently with this setting. While we’re investigating, we'd value your feedback!

minsa110 avatar Aug 28 '25 20:08 minsa110