Metadata-Version: 2.1
Name: retriever_search
Version: 0.5.0
Summary: Local retriever search for your use
Home-page: https://github.com/GovML/retriever.git
Author: Sidharth Kathpal
Author-email: kathpal.sid@gmail.com
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: haystack-ai ==2.0.0
Requires-Dist: pymupdf ==1.22.5
Requires-Dist: sentence-transformers ==2.5.1
Requires-Dist: umap ==0.1.1
Requires-Dist: umap-learn ==0.5.5
Requires-Dist: qdrant-haystack ==3.0.0
Requires-Dist: Flask
Requires-Dist: pandas ==2.2.1
Requires-Dist: torch ==2.2.1
Requires-Dist: accelerate ==0.27.2
Requires-Dist: gradio ==4.37.2
Requires-Dist: dash ==2.15.0
Requires-Dist: plotly ==5.10.0
Requires-Dist: wordcloud
Requires-Dist: pyLDAvis ==3.4.1
Requires-Dist: nltk ==3.7
Requires-Dist: geopy
Requires-Dist: pycountry

<div align="center">

# Retriever

### To setup your own local search you can now use this repo.

<p>
<img alt="GitHub Contributors" src="https://img.shields.io/github/contributors/GovML/retriever" />
<img alt="GitHub Last Commit" src="https://img.shields.io/github/last-commit/GovML/retriever" />
<img alt="GitHub Repo Size" src="https://img.shields.io/github/repo-size/GovML/retriever" />
<img alt="GitHub Issues" src="https://img.shields.io/github/issues/GovML/retriever" />
<img alt="GitHub Pull Requests" src="https://img.shields.io/github/issues-pr/GovML/retriever" />
<img alt="Github License" src="https://img.shields.io/badge/License-Apache-yellow.svg" />
</p>

</div>

-----
## Install 

Recommended to use a virtual environment using venv - 

```bash
$ python -m venv new_env
$ source new_env/bin/activate
```
For installing from the github repo - 
```bash
$ pip install -e .
```
For installing from the pip - 
```bash
$ pip install retriever-search
```

## Search server

```bash
>>> from retriever_search import search_server
>>> search_server.run_search_server('input_directory', 'input_json', 'json_save_path', device='cpu')
```

## Search parameter meanings

- input_directory -- The directory holding your files
- input_json -- pre saved json file from earlier runs can be used for faster loading
- save_json_path -- pass for saving the embeddings to a json can be used later as input_json

## Frontend and Vizualisation run

```bash
>>> from retriever_search import frontend_app as fp
>>> fp.run_frontend()
```


## Where to access the frontend 

Access via the following URL - http://127.0.0.1:7860 
This URL would work for your local setup only


## Tickets

1.0.0
- [ ] Add lightweight embedding model support as flag in launcher
- [ ] Remove HTML requirement for plotly visualization
- [ ] Make LDA visualization update
- [ ] Add model quantized

