Package com.hw.langchain.prompts.base
Class StringPromptTemplate
java.lang.Object
com.hw.langchain.prompts.base.BasePromptTemplate
com.hw.langchain.prompts.base.StringPromptTemplate
- Direct Known Subclasses:
FewShotPromptTemplate
,PromptTemplate
String prompt should expose the format method, returning a prompt.
- Author:
- HamaWhite
-
Field Summary
Fields inherited from class com.hw.langchain.prompts.base.BasePromptTemplate
inputVariables, outputParser, partialVariables
-
Constructor Summary
ModifierConstructorDescriptionprotected
StringPromptTemplate
(List<String> inputVariables) protected
StringPromptTemplate
(List<String> inputVariables, BaseOutputParser<?> outputParser) protected
-
Method Summary
Methods inherited from class com.hw.langchain.prompts.base.BasePromptTemplate
format, mergePartialAndUserVariables
-
Constructor Details
-
StringPromptTemplate
-
StringPromptTemplate
-
StringPromptTemplate
-
-
Method Details
-
formatPrompt
Description copied from class:BasePromptTemplate
Create Chat Messages.- Specified by:
formatPrompt
in classBasePromptTemplate
-