블로그

Search and URL Scheme

by Anders Kierulf

2017-02-08

The newest versions of SmartGo Kifu and SmartGo for Macintosh both include the enhanced names dictionary by John Fairbairn (GoGoD), with mini-biographies of over 4,000 players: life, career, status, teacher, Go style, and notes. Just tap on the player name above the board to see the biography.



Improved search

The names dictionary includes translations as well as alternate names, and these are now used to significantly improve searching for players. Just type in the search bar, and it will try to match any property containing that text.

You can use ! to negate, e.g. type ‘Kato !Masao’ to look for all the other players named Kato. Anything that looks like a four-digit year will be matched to the date property, and you can search for a range, so e.g. ‘1990-1994 Takemiya’ will search for games Takemiya played during those years.

For more precise searches, you can test for specific properties and conditions, and combine conditions using & (and) and | (or). For example, you can type ‘winner=Lee Sedol & result~~0.5’ to find half-point wins by Lee Sedol (spelled Yi Se-tol in the game collection).



URL scheme

This kind of search is powerful within the app, but you can now access it from other apps too, thanks to the smartgo:// URL scheme. For example, the following link will get you directly to Shusaku’s ear-reddening move:

smartgo://games?id=1846-09-11a#127

Or find all the games played between AlphaGo and Ke Jie:

smartgo://games?player==AlphaGo & player==Ke Jie

Or find cool kyu-level problems:

smartgo://problems?coolness=10 & difficulty<=1k

Recent games of Gu Li playing black against Lee Sedol:

black==Gu Li & white==Lee Sedol & date>=2012

Games that Takemiya won by resignation playing black against a 9 dan:

smartgo://games?black=Takemiya Masaki & result=B+R & rankw=9d

Games played in the Kisei or Honinbo tournaments:

smartgo://games?event~~Kisei | event~~Honinbo

Three-stone handicap games played in the ’90s:

smartgo://games?handicap=3 & date>=1990 & date<=1999

Single-digit kyu life and death problems:

smartgo://problems?difficulty<=1k & difficulty>=9k & genre~~life

Please let me know how you use this new feature, and what could make it more useful to you.

Properties and operators

Here’s the complete list of properties currently supported (SGF tag):

  • Player: player (PB/PW), black (PB), white (PW), winner (PB/PW/RE), loser (PB/PW/RE), rankb (BR), rankw (WR).
  • Game info: id (GN), date (DT), event (EV), round (RO), komi (KM), handicap (HA), oldhandicap (OH), result (RE), rules (RU), time (TM), source (SO), analysis (AN), user (US), comment (GC).
  • Problems: difficulty (DI), coolness (CO), genre (GE).
  • Special: favorite (FA), any (any game info property).

The following operators are supported (comparisons are not case sensitive):

  • == or = : Equal
  • != : Not equal
  • ^= : Starts with
  • ~~ : Contains
  • !~ : Does not contain
  • >= : At least
  • <= : At most