Replies: 19 comments
-
Hey how's it going? Currently it is not too big of a cost speed wise to execute when a character is entered. What is the root problem you are looking to solve? |
Beta Was this translation helpful? Give feedback.
-
I believe he's suggesting the opposite. He'd like a delay between characters entered before Flow attempts to compute the query. |
Beta Was this translation helpful? Give feedback.
-
Yeah but I am trying to explore the root issue that @qjcXu is looking to solve. |
Beta Was this translation helpful? Give feedback.
-
For example, the function of a plug-in is to request an interface to return the corresponding content. When I input the 4 characters of flow in sequence, if I don’t add the input anti-shake, there will be an extra 3 program executions, but this is Not necessary, because my purpose character is flow, not f fl flo. |
Beta Was this translation helpful? Give feedback.
-
Alfred has a similar function that waits for user input to stop for a predetermined amount of time before execution of results. |
Beta Was this translation helpful? Give feedback.
-
Yeah, similar to this function |
Beta Was this translation helpful? Give feedback.
-
Is this feature to help with your plugin @qjcXu ? If so what's the issue currently? |
Beta Was this translation helpful? Give feedback.
-
My plugin is to request interface and return data For example, the user's purpose is to get the translation result of flow, but it will send three extra requests f fl flo , these three requests are unnecessary. |
Beta Was this translation helpful? Give feedback.
-
Aside from the request being unnecessary, it doesn't really impact user experience though right? |
Beta Was this translation helpful? Give feedback.
-
I just updated my plugin to fix this, but inevitably, the user has to wait a certain amount of time before requesting the interface again. I think it still affects the user experience a bit. |
Beta Was this translation helpful? Give feedback.
-
What's the impact though letting the plugin just make those requests? @Garulf how do your plugins that need to make API requests handle this? I would imagine they also make requests per keystroke too? |
Beta Was this translation helpful? Give feedback.
-
I too don't understand the problem this would solve. The results are very fast so why can't you handle rate limiting or response in your plugin @qjcXu ? |
Beta Was this translation helpful? Give feedback.
-
In my latest released version I solved this problem. I found that the logic of the launcher to start the plugin is to trigger a new execution of the plugin every time a character is entered, so my solution is to determine whether the current is continuous input only by storing the start time of the last plugin, but this is very affect the user experience. If you add the input anti-shake function to the input box of the launcher, this can record whether the current input is continuous, and the experience will be better. |
Beta Was this translation helpful? Give feedback.
-
I do have added an anti-shake function very long ago. However, it is a very short interval (40ms) to accommodate debug experience and backspace. I feel like it's more reasonable for plugin to have their own antishake function because sometimes we have some plugin that users would like to get response as soon as possible (calculator, etc.). |
Beta Was this translation helpful? Give feedback.
-
Hope this feature is available as an optional feature! |
Beta Was this translation helpful? Give feedback.
-
How long the interval do you think is reasonable? 200ms? |
Beta Was this translation helpful? Give feedback.
-
Yeah, if achievable. Hopefully this time is also optional, but it defaults to 200ms |
Beta Was this translation helpful? Give feedback.
-
I can understand if ultimately this is to deal with API rate limiting but so far plugins just have users sign up to the service and set up an API token or display the warning to the users if they don't. Let's move this to discussion, in the scenario that this needs to be implemented, we need to flesh out a design that this feature is isolated to individual plugins, ideally to facilitate for plugin itself to implement as required without user intervention. |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Is your feature request related to a problem? Please describe.
Each time a character is entered in the input box, the program will be executed once
Describe the solution you'd like
My idea is to add an anti-shake function to the input box, and then trigger the execution of the program after the input is completed, instead of triggering the execution of the program every time a character is entered.
For example, if a character is input again within n milliseconds after each input of a character, the execution of the program will not be triggered, and if no more characters are input after n milliseconds, the corresponding program will be executed
This feature can be set as an optional feature if implemented.
Beta Was this translation helpful? Give feedback.
All reactions