UKC

Site Updates: New "Omni Search" in Logbooks

© UKC News

At the top of all logbook pages (i.e. My Logbook, or a crag) you can use a powerful new search feature to find routes or crags. The unified search box allows filtering of routes based on multiple criteria.

To get started, click the icon on the top right of all logbook pages (other than My Logbook where it is shown by default). You can enter the name of a route or crag you know, or part of the name, or part of the description, or filter based on stars, grades, first ascent details and more.

New Omni Search Feature  © UKC News
New Omni Search Feature

That's all you need to know to use the search, but if interested in all the intricacies then read on...

Anything you type in the new search will be checked against the following properties:

  • name
  • crag name
  • buttress name
  • area name
  • country name
  • first ascent potentially including dates and names, but could be one or the other or neither
  • rock type name one of eg [ granite, gritstone, sandstone, limestone, schist, rhyolite, ... ] (there are loads)
  • route type name one of [ sport, trad, winter, bouldering, aid ] (this list is complete)
  • description
  • route grade
  • tech grade

A match is found if all of the tokens of the search query match one or more of the fields. This means you can very quickly write a query that returns very few results by typing a combination of fragments of the various fields, like mal wom returns Wombat E2 at Malham as the first result because token1 (mal) matches the crag name (Malham) and token2 (wom) matches the route's name. You could be even more precise and search mal wom e2 but for this instance it's not needed. (Note that this stuff is true at the time of writing but could change if more routes are added).

The scoring of results is done by applying multipliers depending on where a match is found. The higher the field is on the list above, the more valauble a match against it is considered, so if a query matches against one route's name and another's description, the one against the name will be considered a better match and appear nearer the top. The popularity of the route is taken into account so a route with loads of ascents will be given a higher search score than one with none.

For the most part this is all anyone really needs, but there are also a few advanced options you can use if you're dorky:

  • exact-phrase matches, eg "captain nemo"
  • route-star ranges, eg *-**
  • grade ranges, eg vs-e3
  • date ranges, eg 1984-1986
  • difficulty for grade / grade quality, eg |soft|
  • regular expressions, eg /chris (?!craggs)/
  • negations, eg -crack

Exact phrase matches

Surround multiple words with double quotes to require a match on that phrase, eg "bat route" malham creates the tokens bat route and malham. Another example is roof crack stanage currently returns 45 routes, where as "roof crack" stanage returns only 9.

Route-star ranges

Asterisks get special treatment in search queries now. A sequence of them is considered to be a star rating for a route, so * is treated as 1-star, ** treated as 2-stars and *** treated as 3-stars. Typing just one sequence creates a search where the route is required to have at least that many stars, eg bat route ** will only return routes with 2 or more stars that also match the other search tokens bat and route.

Adding a dash and a second star sequence will create a range, eg *-** means "match routes with at least one and at most two stars".

Grade ranges

As above with stars, but with grades. Eg vs-e1 will match routes with a grade of either VS, HVS or E1.

Date ranges (only years)

Date ranges will check against the first-ascent date field and require the route to have been put up between the start date and the end date (inclusive). Eg 1970-1974 will match routes put up between 01-01-1970 and 31-12-1974. You should note that not all routes have had the first ascent date filled in, and these routes will be excluded from any search that includes date ranges, so you might not get the results you expect.

Difficulty for grade

Not sure what to call this so we'll use "difficulty for grade". We've calculated a value based on the grade voting system that assigns a route a value from one of:

  • |soft|
  • |benchmark|
  • |hard|

You can search for routes with these characteristics by using the special pipe syntax, eg |soft|. If you don't wrap the token in pipes, you'll just be searching the other text fields, so soft, with no pipes, would get you a match if the token appeared in the description for example and |soft| will only match against routes that have been marked as soft, and not check the other fields for the token.

A continuation of this system which uses the same syntax allows you to search for routes that are voted to be a completely different grade using the following tokens:

  • |undergraded|
  • |overgraded|

eg |overgraded|. Note that this is based on votes, so if there are no votes for a route and you include one of these tokens, it won't appear, regardless of whether it is in reality over or undergraded. Note also that whilst you can combine these with soft/benchmark/hard, doing so doesn't really make sense.

Also possible using this syntax is checking for multipitch routes using |multipitch|

These pipe tokens are a bit longwinded so you can use a shorthand version of each too:

|s soft

|b benchmark

|h hard

|u undergraded

|o overgraded 

|m multipitch 

Regular expressions

Finally we reach the most pointless feature, regular expressions - we need only add an email function and this search bar will be complete.

Regular expressions, for those that don't know, are a way of describing patterns in strings. They are a very powerful tool for searching and manipulating text, and completely unnecessary in this search bar. However, if you do want to use them, they are possible by surrounding the expression with forward slashes, eg /chris (?!craggs)/ will match any routes that mention 'chris' but not those that mention 'chris craggs'. Or e2-e3 /crap|damp|horrible/ will return you a list of probably not classic routes.

Note that pure-regex queries are not allowed due to the cost of the queries against the database. You should always add any of the other query types mentioned above if you're using a regex.

Negation

Extra finally, if you precede any token with a minus character you will negate it and require that it is not matched, eg -"mark leach" bat malham.

Some examples to get you in the mood

  • granite sport scotland **
  • peak e4-e5 |overgraded| **
  • wide crack peak grit
  • e5-e7 1970-1975

The UKH version is still being developed, but will be released soon.

Be sure to also check out the advanced crag search page which was also updated recently, and allows more specific filtering of crags.


This post has been read 2,531 times

Return to Latest News


24 Jun, 2022

Great stuff, should be very useful.

The pink text on grey background (dark mode) is very hard to read though. Poor colour contrast, especially from an accessibility perspective. Hopefully that can be adjusted so people with impaired vision (and others!) are able to read the details.

24 Jun, 2022

This is well cool! New favourite search

leonidio |soft| 8a

24 Jun, 2022

sweet !

24 Jun, 2022

This is an excellent feature, thanks for adding.

24 Jun, 2022

Can you define the regular expressions in some sort of help page as people who aren't into computing won't know what they can and can't use.

More Comments
Loading Notifications...
Facebook Twitter Copy Email