/xedni

This project implements an inverted index, which is commonly used to provide full text search.

Primary LanguageGo

Inverted Index API

Introduction

An api that implements an efficient search functionality using inverted index. Rather than map a document object to an array of the terms it contains, inverted index maps a term to an array of the documents that contains it. In other words the inverted index contains the frequencies of each words in each document.

Getting started

Build and run locally

git clone https://github.com/tsvetinaSpasova/xedni.git 
cd xedni
make go-run

To create index from a document

cd examples
./index.sh

To search index for terms

cd examples
./search.sh

Run tests

make go-test

Run benchmarks

make go-bench

Advantage of Inverted Index

  • Inverted index is to allow fast full text searches, at a cost of increased processing when a document is added to the database.

Useful links

References

Special thanks