File size: 464 Bytes
ed4d993
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
from langchain_core.prompts.prompt import PromptTemplate

sentence_template = """Given the following fields, create a sentence about them. 
Make the sentence detailed and interesting. Use every given field.
If any additional preferences are given, use them during sentence construction as well.
Fields:
{fields}
Preferences:
{preferences}
Sentence:
"""

SENTENCE_PROMPT = PromptTemplate(
    template=sentence_template, input_variables=["fields", "preferences"]
)