Autocomplete

Since Google introduced the Autosuggest (or Autocomplete) search form on their toolbar, everyone wants to do the same on their websites. Developers have created Ajax autosuggest scripts which are supposed to help the user and present in real time (as they type) some possible results based on the first few character texts entered. Everybody agrees that this is a great feature to enhance the user experience.
Lot of different scripts can be found on the internet and may be freely used. However, scripts usually use the database as the search engine. Scripts do not call databases directly but calls web-servers where other scripts get results from another database. It is a simple solution and fast enough for small services, with small numbers of queries and not a lot of records in database. However, for bigger traffic and long lists of words to suggest, this would be useless.

For that reason, we developed a specialized application (Autosuggest server), which does not use the database as a search engine. Lists of words are stored in CSV files, which are loaded into the memory while the application starts. Web application could retrieve data directly from Autosuggest server using Ajax techniques. Data is then returned in JSON format, in either alphabetical order, or sorted by rank. Every entry into the input file may have assigned "rank" which could be for example word popularity. In addition, the entries may have assigned properties - any textual data, which is always returned with the results. Autosuggest also lets you filter out results (this feature is explained in the example below):

Autosuggest may serve simultaneously many different subsets of words in different languages. Every language has to have a prepared alphabet file (that file also contains some rules of characters equity). We have prepared alphabet files for major languages (English, German, French, Spanish, Russian, Italian, Greek, Dutch, Turkish, Ukrainian, Bulgarian and Polish).


Example no. 1 - here we have an Autosuggest box, which suggests German town names (almost 15 thousands towns could found). Data is returned alphabetically with property (property has assigned "kreis" name) after typing at least 2 letters (this is the general rule)


Example no. 2 - French major cities (7500 entries)


Example no. 3 - Russian cities (you have to use Russian keyboard)


Example no. 4 - Spanish cities - here you can sort results by population (population is treated in this case as rank factor)



Example no. 5 - this example demonstrates "filters feature" - in first box you may choose a US state's name. After that, in the second box, only cities or districts from selected states will be shown. If you do not select a state, cities from the whole USA will be able to be selected. You can also choose to sort by population.

State: City:

Example no. 6 - most popular last names in the USA (over 150 thousands entries)