edit readme and config
This commit is contained in:
parent
a0efd90c14
commit
08d0eef8e5
22
README.md
22
README.md
@ -47,4 +47,26 @@ QDRANT_CLUSTER=''
|
||||
QDRANT_COLLECTION_NAME='titan'
|
||||
TOKENIZER_FOLDER=''
|
||||
MODEL_FOLDER=''
|
||||
```
|
||||
ℹ️ **Note for production/docker container:**
|
||||
`TOKENIZER_FOLDER` and `MODEL_FOLDER` are **only required for local development**.
|
||||
|
||||
When running the application in a **Docker container**, these variables are already set in the `Dockerfile` and do not need to be defined in your `.env` file.
|
||||
|
||||
|
||||
|
||||
## 📥 NLTK Setup for Development
|
||||
|
||||
If you are running the application in development mode for the first time, you need to manually download the NLTK resource required for sentence tokenization.
|
||||
|
||||
### Run the following inside your virtual environment:
|
||||
```ini
|
||||
import nltk
|
||||
nltk.download('punkt_tab')
|
||||
```
|
||||
|
||||
This will download the necessary model and store it on your local machine under:
|
||||
|
||||
```
|
||||
~/nltk_data
|
||||
```
|
||||
@ -1,12 +1,12 @@
|
||||
from dotenv import dotenv_values
|
||||
import os
|
||||
from pathlib import Path
|
||||
|
||||
# load_dotenv("/home/user/recommender-service-flask/src/.env")
|
||||
|
||||
# load_dotenv("/home/charlenewsl/recommender-service-flask/src/.env")
|
||||
|
||||
# config = dotenv_values("/home/charlenewsl/recommender-service-flask/src/.env")
|
||||
|
||||
config = dotenv_values(".env")
|
||||
# config = dotenv_values("/home/user/recommender-service-flask/src/.env")
|
||||
env_path = Path(__file__).resolve().parents[1]/ ".env"
|
||||
config = dotenv_values(env_path)
|
||||
|
||||
|
||||
def env(name, default=None, cast=None):
|
||||
|
||||
Loading…
Reference in New Issue
Block a user