Skip to content

Commit 47e185f

Browse files
author
omerh
committed
minor fix, default question
1 parent fe05280 commit 47e185f

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

ask-titan-with-rag.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,11 @@ def main():
7878
opensearch_vector_search_client = create_opensearch_vector_search_client(index_name, opensearch_password, bedrock_embeddings_client, opensearch_endpoint)
7979

8080
# LangChain prompt template
81-
question = "what is the meaning of <3?"
81+
if len(args.ask) > 0:
82+
question = args.ask
83+
else:
84+
question = "what is the meaning of <3?"
85+
logging.info(f"No question provided, using default question {question}")
8286

8387
prompt_template = """Use the following pieces of context to answer the question at the end. If you don't know the answer, just say that you don't know, don't try to make up an answer. don't include harmful content
8488

0 commit comments

Comments
 (0)