-
Notifications
You must be signed in to change notification settings - Fork 34.8k
Open
Labels
feature-requestRequest for new features or functionalityRequest for new features or functionalitylanguages-guessingLanguage guessing issuesLanguage guessing issues
Milestone
Description
Testing #129436
On my machine it takes around 300ms
for the language classification to compute. However some of our users have a slower machine, so here are some ideas on how to make sure to not slow down when users that are just scribbling in an untitled editor.
- Do not classify when less than 20 characters present (unless to reset mode if file has auto detected already) - Done in microsoft/vscode-languagedetection@b024b29
- Increase debounce from 300ms to 600ms (this will still not be a noticeable lag when the user stops typing, pastes) - Done in Improve performance of language detection #130006
- If you have already run the classification
n
times and every time you are unsuccessful maybe stop trying and only on larger changes run - If you already auto detected a language - great! Do not be so aggressive then, only if a big change to the file content happened
Both 3 and 4 require some knowledge about what is a bigger change to a file. We can figure something out. Maybe @bpasero has ideas
Metadata
Metadata
Assignees
Labels
feature-requestRequest for new features or functionalityRequest for new features or functionalitylanguages-guessingLanguage guessing issuesLanguage guessing issues