Skip to content

Commit 6d6155e

Browse files
szymondudyczberkecanrizai
authored andcommitted
Documentation for prompts in llm-app (#8122)
Co-authored-by: berkecanrizai <[email protected]> GitOrigin-RevId: ab7fbe4630186340c8900a6b248028fbd0c5eedc
1 parent 590d853 commit 6d6155e

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

examples/pipelines/demo-question-answering/app.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,10 @@ question_answerer: !pw.xpacks.llm.question_answering.BaseRAGQuestionAnswerer
5959
indexer: $document_store
6060
# You can set the number of documents to be included as the context of the query
6161
# search_topk: 6
62+
# You can use your own prompt for querying.
63+
# For that set prompt_template to string with `{query}` used as a placeholder for the question,
64+
# and `{context}` as a placeholder for context documents.
65+
# prompt_template: "Given these documents: {context}, please answer the question: {query}"
6266

6367
# Change host and port by uncommenting these lines
6468
# host: "0.0.0.0"

examples/pipelines/gpt_4o_multimodal_rag/app.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,10 @@ question_answerer: !pw.xpacks.llm.question_answering.BaseRAGQuestionAnswerer
6565
indexer: $document_store
6666
# You can set the number of documents to be included as the context of the query
6767
# search_topk: 6
68+
# You can use your own prompt for querying.
69+
# For that set prompt_template to string with `{query}` used as a placeholder for the question,
70+
# and `{context}` as a placeholder for context documents.
71+
# prompt_template: "Given these documents: {context}, please answer the question: {query}"
6872

6973
# Change host and port by uncommenting these lines
7074
# host: "0.0.0.0"

0 commit comments

Comments
 (0)