commonsearch / cosr-front

Frontend of Common Search. Go server for fetching and rendering results + HTML5 UI to browse them.
https://uidemo.commonsearch.org
Apache License 2.0
61 stars 13 forks source link

Phrasal search #18

Open sylvinus opened 8 years ago

sylvinus commented 8 years ago

Queries like "new york times" should search for the exact sequence of words.

Elasticsearch supports this, but it seems that if we want to mix phrase matches with regular matches we will have to do some preprocessing?

wumpus commented 8 years ago

Do you really mean "new york times" in quotes, or the query [new york times] with no quotes? (I use the contention to put query text in [] to avoid ambiguity... then quotes really mean quotes.)

sylvinus commented 8 years ago

Right! I added the Markdown formatting but let's try to stick with [] for queries indeed! I meant ["new york times"] :)

wumpus commented 8 years ago

OK with the quotes, isn't it trivial to do the necessary query parsing?

The non-quotes case is also interesting, because it's much more common. But we can talk about that another time!

sylvinus commented 8 years ago

You're right - this probably isn't a hard issue, I'll downgrade it :)

To make the issue clearer, we also need to support queries like ["new york times" 2016]

amirouche commented 8 years ago

FWIW it's called phrasal search

sylvinus commented 8 years ago

Thanks @amirouche :) Want to have a swing at it ? ;-)