There were more suggestions as to how to present search results. I suggest having option to sort by relevance. It would solve more feature requests - see below. What relevance might mean - I suggest it encompasses following and in following order (which is of course subject of further discussion):
filename (if searched word is found in filename, it is definitely highest relevance and should be presented first - it is default functionality in apps like Notational Velocity etc) - (more this forum thread)
occurence in headers/bolded text/empasis etc. (in this order) (cf this forum thread)
The problem is that there really is no sensible metric for ārelevanceā in this context, so it really doesnāt make a lot of sense to offer it as an option in the system.
If there was some way to build your own ārelevance metricā within the system, possibly by reference to a set of rules which you assemble for yourself, it might have a purpose. But I have yet to find a relevance metric for searching PKM systems which is actually useful for me all the time.
Some kind of modular metric mechanism that can be used for all sorts of things? Maybe useful. But definitely outside the current scope of Obsidian as I understand it.
@LexTenebris: do not think we need sophisticated metrics for this feature. Just basic order that I suggested might be such āmetricsā (rules). E.g. when search term is part of the title of the note, we can consider it to be more important and to appear first. The same is valid for headers etc. So if searched term belongs to one of such groups, the note would appear in respective order as these groups are (= found searches in: note titles - headers - bolded - multiple occurrences etc ā¦). I believe there is general accord that words in titles, bolded etc. have higher relevance (actually, that is why they appear in title, as bolded text etc - because we consider them relevant.)
As for more complicated ārelevance metricsā, I believe it could be done later (maybe using some plugin/AI/third party app via API) as it is done in DevonThink. But I agree, it is outside current Obsidian scope now.
But simple relevance as suggested above could be easily implemented (and in fact, in basic form - in which found searches in note titles have precedence before found words in note text - is already implemented in majority of similar apps - Notational Velocity, FSNotes, The Archive etc)
Any note taking app that offers a ārelevanceā search is just the developerās opinionated answer to that question. Sure, thereās no single metric that works for all cases, but working reasonably well in a lot cases is better than not having it at all.
As I add more notes this is becoming a bigger and bigger issue for me. The search brings up way too many results even though there is a clear correct, most relevant result. Itās starting to feel a little like I am doing all the hard work with the links and tags and folders and naming conventions, etc. but I know thatās not necessary to get good results. A good search engine can rank based on interpreting the searcherās intent. I think this is a core āmust haveā feature.
An example:
I have work and personal stuff in my notes. I searched for family meeting. I had hundreds of meeting results at the top of the results (work meetings).
Exact match should be more relevant than fuzzy match.
To find what I wanted I had to search "family meetings" (quotes). That worked in this example b/c I knew exactly what I probably typed.
When I search for something, I donāt necessarily put it between quotes. I expect that close-enough matches will appear in some kind of relevant order. Currently, Obsidian shows partial matches before complete ones, making me mistakenly believe that the search was unsuccessful.
Iāve used the Help Vault as an example: searching for this is a heading without quotes seems to return no close matches, but those are actually āhiddenā behind that "ā¦and 247 matches"; if we expand it, several full matches appear further down the list.
I donāt know the inner workings of Obsidianās search. Even if I did, Iām not sure Iād be able to propose a solution. I just think it could use some more love.
Current workaround (optional)
We can always expand the results one by one, or explicitly search for a phrase using quotes. But it seems counterintuitive and unforgiving.
It would be helpful to be able to quickly see in which note a topic is discussed THE MOST. Similar to how Devonthink and Evernote can sort by ārelevanceā.
So a note that has the word āAgencyā in it 20 times would show above a note that just happens to have āAgencyā in it once.
It wouldnāt be the only way to sort results and links, the existing ones are excellent, but as a sort option.
Running into this same feature gap right now - what Iām searching for my #todo tag, I want to see the note with the most such tags in it at the top, rather than date or alphabetical sorting.
Using search you can change sort order. But there is no option to sort by frequency. what I mean is if a search keyword has many occurrences in a note. you can to be able to get that note first in sort order when searching.
+1 for the feature to have the sort option by hits for each file. The file with the most hits for a search pattern should be the first. Would be absolutly great <3 and thank you for this great software!
Hey, just here to say this is a common frustration for me too. If I type exactly the name of a note in search, there is no sort order mode that shows said note at the top of the results ā and search feels broken like this.
I have a note in a subfolder called āTimestamps/2021 Investing log.mdā.
When I use the Open Quick switcher and I type āinvesting 2021ā the note doesnāt appear in the results lists, it only appears if I type ā2021 Investingā.
Proposed solution
Make Open Quick do basic tokenization or use fuzzy logic so that when I type āInvesting 2021ā it recommends notes called ā2021 Investing.mdā.
Current workaround (optional)
I have to manually type different note variations. I cannot realistically use the directory browser on the left side because I have too many notes and it would take me forever.
Another vote for sensible search ranking. The current way Obsidian filters / sorts search results is quite frustrating!
Iām including my post to the Reddit forum here.
ā
Hello,
Iām really enjoying Obsidian! Iāve spent the last two weeks consolidating 15 years and half a dozen applications worth of writing into one, sensible, well organised set of notes. Such a relief!
The one thing that Iām quite frustrated by is Obsidianās search. Iām baffled by the fact that it allows you to sort search results by everything except relevance. For example I have a page called āX3ā in a folder called āWikiā (my default home for new notes):
if I search for āx3ā it shows up as the very last result (fair enough I had results organised alphabetically).
if I search for ātitle: x3ā (or "title: X3) it doesnāt show up at all.
if I search for āpath: x3ā itās the only result.
All the other note applications Iāve used over the years use relevance as the primary way to sort search results. Iād expect that if thereās a note called āX3ā that it would be the top result of a search for āX3ā.
I feel like I must be missing something? Am I doing something wrong? If this is just the way Obsidian works, is there a way to add relevance based search?
Search is one of the most important features for an app like Obsidian. Once Iāve made a lot of notes, I need to be able to search through them and efficiently find my old notes. The whole point of the knowledge storage system is to be able to retrieve information and ideas from the big archive I am creating.
Unfortunately, when I type anything I want to look for in the search panel, Iām getting extremely irrelevant results. They seem to match parts of the words (for example if I search for āmake it workā, the top results are my notes on writing, because the word āwriteā has āitā in it), and they seem to be sorted by file name, not by relevance.
Putting my search query in quotes helps sometimes, but that doesnāt work very well if I only remember a part of the phrase Iām looking for, or several important keywords in the note, and not the exact perfect match for a phrase.
Proposed solution
Iām not sure what to recommend here. I can only say that quality search is a key feature for an app like Obsidian, it is extremely important to be able to retrieve the notes I have created quickly and conveniently, it is critical to have search that returns the most relevant results first. So this feature should just work better.