Skip to content

Commit

Permalink
Merge pull request #750 from maysunfaisal/update-rag-2
Browse files Browse the repository at this point in the history
Configure model for the rag recipe
  • Loading branch information
rhatdan authored Aug 12, 2024
2 parents 5671010 + 3a25158 commit 6c088a0
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions recipes/natural_language_processing/rag/app/rag_app.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@

model_service = os.getenv("MODEL_ENDPOINT","http://0.0.0.0:8001")
model_service = f"{model_service}/v1"
model_name = os.getenv("MODEL_NAME", "")
chunk_size = os.getenv("CHUNK_SIZE", 150)
embedding_model = os.getenv("EMBEDDING_MODEL","BAAI/bge-base-en-v1.5")
vdb_vendor = os.getenv("VECTORDB_VENDOR", "chromadb")
Expand Down Expand Up @@ -75,6 +76,7 @@ def read_file(file):

llm = ChatOpenAI(base_url=model_service,
api_key="EMPTY",
model=model_name,
streaming=True,
callbacks=[StreamlitCallbackHandler(st.container(),
collapse_completed_thoughts=True)])
Expand Down

0 comments on commit 6c088a0

Please sign in to comment.