Code Monkey home page Code Monkey logo

autocomplete's Introduction

autocomplete

Simple autocomplete engine.
Contains of data preprocessor, and a module for blizzard http server.
Requires compiler with c++11 standart support (for example gcc4.7+)

Building procedure

cd Autocomplete
mkdir build
cd build
export CMAKE_DEFS="-DCMAKE_CXX_COMPILER=/usr/bin/g++-4.7" #this is required if your default compiler doesn't support c++11
export CMAKE_DEFS="$CMAKE_DEFS -DCMAKE_CXX_COMPILER=/usr/bin/g++-4.7" #You can specify RELEASE build here
cmake $CMAKE_DEFS ../
make

Running preprocessor

It requres file with your input data in encoding you will use further and lines splitted by \n
First you need to build autocomplete project, than

cd Autocomplete
./build/preprocessor /path/to/queries /path/to/compressed/chunks/output/file

You will get in /path/to/compressed/chunks/output/ files like

/path/to/compressed/chunks/output/file
/path/to/compressed/chunks/output/file.0
/path/to/compressed/chunks/output/file.1
/path/to/compressed/chunks/output/file.2

Running http server

Compile blizzard (and optionally install) as described in https://github.com/antmat/blizzard (Blizzard server itself require a number of libs - https://github.com/bachan/coda, http://software.schmorp.de/pkg/libev.html, http://expat.sourceforge.net/) copy config/blizzard.xml to any file
change in it section to /path/to/compressed/chunks/output/file you used in preprocessor
Change other values to desired ones (see https://github.com/antmat/blizzard)
run /path/to/blizzard/binary -c your_copied_config_file
You can add optional -d to daemonize query http://localhost:your_port/?q=qwe&cnt=10
Enjoy)

autocomplete's People

Contributors

antmat avatar

Stargazers

 avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.