# Add\_faiss\_index with multiple columns

**URL:** <https://discuss.huggingface.co/t/add-faiss-index-with-multiple-columns/51303>\
**Category:** Intermediate\
**Created:** [August 19, 2023, 6:37am UTC](https://discuss.huggingface.co/t/add-faiss-index-with-multiple-columns/51303 "2023-08-19T06:37:33Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![koala99](https://avatars.discourse-cdn.com/v4/letter/k/fbc32d/32.png) [@koala99](https://discuss.huggingface.co/u/koala99)\
**Post date:** [August 19, 2023, 6:37am UTC](https://discuss.huggingface.co/t/add-faiss-index-with-multiple-columns/51303/1 "2023-08-19T06:37:33Z")

</div>

This article ([Semantic search with FAISS - Hugging Face NLP Course](https://huggingface.co/learn/nlp-course/chapter5/6?fw=tf)) concatenates the title, body and comments together before creating embeddings.  
Later, it uses embeddings\_dataset.add\_faiss\_index(column=“embeddings”), with a single column.

I would like to use multiple columns separately for title, body and comments while indexing faiss, with separate embeddings for each.

I would highly appreciate if anyone could give a solution to resolve this scenario. Thanks!
