File size: 903 Bytes
ab0437a
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
### Gradio app to run QA on a given website

What does the app do :
- Get input prompt (text or transcribed audio)
- Similarity search in a vector DB, returns top k chunks
- Run llm based on context (using basic prompt - langchain not used yet)
- Return response and metadata (url, scores, text chunks...)

Setup process:
- vector store (FAISS) a given website (sitemap) using langchain
- download a llm
- containarise stt (faster-whisper) due to os incompatibility
- build Gradio app

To build Faster-whisper docker image name "fasterwhisper"

`docker build -t . fasterwhisper`

Create python env 'llama'
```
conda create --name="llama" python=3.10
conda activate llama
pip install -r requirements.txt
```

To run the app:

`bash run.sh`

To push to hugging face (including large files) use this command: 

`git lfs migrate import --everything`

`git add .; git commit -m "message"; git push -f origin`