Faiss Reference, It also contains supporting code for evaluation and parameter tuning.