Replies: 5 comments 3 replies
-
I did have a look, when the FieldIndexer actually is used. As far as I can see, it is only used once by the IMO we should start to use it instead of making it faster. So basically if you hardcode eg: IMO real world would be eg: |
Beta Was this translation helpful? Give feedback.
-
eg: My tocP does this to "find all tiddlers, where the
IMO it should be something similar to
Which imo would significantly speed up the whole thing, because the initial filter-run @Jermolene ... Would it make sense to extend the |
Beta Was this translation helpful? Give feedback.
-
There may be a other Filter Operators that could be improved. We would have to have a look, which one of them also deals with fields as their primary parameter. I've long lost the overview, due to the amount (166) of operators we have atm, that do similar things. :/ |
Beta Was this translation helpful? Give feedback.
-
I read the code of https://github.com/hmans/miniplex (less than 1000 loc) I find ECS is like:
So TW's filter expression is already simillar to ECS. Only difference is ECS will cache result of each query. This works when there are many same query. But we probably don't have many same filter expressions, so caching is useless. So I'm moving my attention to: |
Beta Was this translation helpful? Give feedback.
-
ECS is about making tons of indexer, and re-run function that observing changed indexers. TiddlyWiki is now re-run filter expression when any tiddler changes, and let widget itself decide re-run rendering or not, but filter is already run, we can't save filter's execution time. With archetype ECS, or we can say it as "with tons of indexers", an archetype for filter in Sidebar-Recent will be And archetype ECS also means remove indexer when no query is observing it. So in Tiddlywiki this will means when no UI is using that filter, it's related indexer is removed, and recreated when Recent tab is opened next time. What if user tend to switching between sidebar tabs frequently? Then tons of indexer will create and destroy frequently too. So there is always a trade off, in a huge wiki, we can't guarantee archetype ECS can always provides boost. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Entity component system with archetype Can filter entity with very fast speed.
And those components are similar to tiddler fields, so maybe we can apply this (only to the indexer is sufficient) . This may also improve filters like tag filter.
I learned about this time ago. Just happen to think about this after dinner, may add more details later.
Beta Was this translation helpful? Give feedback.
All reactions