Inner weights order in dictionaries #334
AlejandroMarin-Veeva
started this conversation in
General
Replies: 1 comment 4 replies
-
That's because of depth-first traversal, at lookup keyvi 1st traverses to the highest weight, however if it finds final states on the way it returns those. If you change By design I decided to not built any kind of memory into the traversers to keep them as lightweight as possible. Imagine: if I want to return in order, I would need to remember |
Beta Was this translation helpful? Give feedback.
4 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi Hendrick, hope you are doing well! :)
I have a question related to the weights and the order of the matches in complete_multiword. In the following example:
I would expect to return first the key with the highest weight, 3, however is returning them in alphabetical order. Why is that the case?
[(1, 'a'), (2, 'ab'), (3, 'abc')]
Beta Was this translation helpful? Give feedback.
All reactions