Coder Social home page Coder Social logo

Comments (5)

davidbannon avatar davidbannon commented on May 30, 2024

Well, a wildcard search is certainly possible but much, much slower.In your example, we'd need to pick up a, perhaps, a 50K note that starts with "exact" and ends with "string". And every combination between.
Might be appropriate to provide an "Advanced Search" that lets you do things like that I'd not do it to the standard search function as I suspect it would make it unusable.

David

from tomboy-ng.

mlncn avatar mlncn commented on May 30, 2024

As per #34, i think search just has to use an index. Searching for non-contiguous words has been the default when not using quotation marks since Alta Vista and continues in things like Spotlight on Mac. And again, case-insensitive and search for all words (without requiring them to be exactly next to each other) is both how old Tomboy works (with survivable performance even with my ... now 16,791 notes) and how modern applications work. Completely offload the work to a proper indexed search and things can fly!

I'd still recommend case-insensitive search which assumes independent words and not a phrase even if it made it completely unusable at my scale. Usability first, and then scale.

from tomboy-ng.

davidbannon avatar davidbannon commented on May 30, 2024

Hmm, Tomboy does not do wildcard search, it just looks for notes that contain both the words mentioned. In either order. So, search term "exact string" will register a hit in a note that says "..and the string is exactly..". Thats relatively easy to implement but will probably require a bit of rework of the search unit.
And indexes ? An index is useful if you have a subset of the content indexed. But if you want to index free form text then your index ends up being substantially bigger than the text. There is some saving by not indexing generic words such as "and; but...". And some benefit in a on disk index because it can be searched faster than the note but the maintenance cost has to be considered.

The meta data structures I currently keep in memory are, sort of indexes. But only index metadata. If memory footprint did not matter we could do all sorts of things .....

from tomboy-ng.

davidbannon avatar davidbannon commented on May 30, 2024

OK, I have checked in code that allows user to search on the exact combination in the edit box OR find notes that contain all the words but not necessarily in that order.
This check-in also fixes a significant problem in the search tools but at the expense of performance. Further research is indicated.

from tomboy-ng.

davidbannon avatar davidbannon commented on May 30, 2024

Just checked in code that speeds up that search by factor of 100, now searches my test note directory of a 100 notes in about 35mS on my 'medium' speed laptop.

from tomboy-ng.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.