gazetserv: Location Gazetteer Server

Table of Contents

Introduction

A gazetteer server for location names.

What is a Gazetteer?

You may be wondering, what is a gazetteer?

From the Cambridge Dictionary:

"A book or part of a book that contains a list of names of places,
usually with some additional information."

From the Merriam-Webster Online Dictionary:

"[The Gazetteer's: or, Newsman's Interpreter, a geographical index
edited by Laurence Echard] : a geographical dictionary; also : a book in
which a subject is treated especially in regard to geographic
distribution and regional specialization."

Motivation

When validating a "location" field from, say, an HTML input field, for some applications it is necessary to match that location with a set of real locations, and have the user disambiguiate the location name to an existing location in a database of world places.

Description of the Software

This software implements a gazetteer server that allows you to make a simple name query, attempts to match fuzzily the given name--taking care of such things as uppercase/lowercase differences and missing names, to some extent--and returns the matching location names, with unique ids and coordinages (longitude, latitude) for each location. The gazetteer can also return neighbouring locations as well, within a search radius.

The server speaks the XML-RPC protocol, and is written in Python (you need Python-2.3 to be able to run it). In addition, there is a command-line client to perform remote queries and tests. The server runs on Linux, but should run on any UNIX platform, and it would be simple to port it to the Windows platform.

This code was written with the purpose of validating fields in a web application. It is used actively in a production application and has received a reasonable amount of testing.

doc/screenshot-widget-entry.png

Example application widget which could be implemented with gazetserv.

About Internationalization

For now, only the country names are internationalized. The city names are english (or local).

Databases

The code currently supports free databases available for the entire set of countries around the world.

Pricing

This is not open source software. If you are interested in purchasing a copy of this software, please contact the author for pricing and arrangements. Also, if you would like to reuse the infrastructure with your own custom databases, I am available for consulting and could probably easily modify my server to support other database sources.

Installation

Dependencies

  • Python-2.3 or greater;

Author

Martin Blais <blais@furius.ca>