Type Alias: ChatWrapperSettings
type ChatWrapperSettings = {
supportsSystemMessages: boolean;
functions: {
call: {
optionalPrefixSpace: boolean;
prefix: string | LlamaText;
paramsPrefix: string | LlamaText;
suffix: string | LlamaText;
};
result: {
prefix: string | LlamaText;
suffix: string | LlamaText;
};
parallelism: {
call: {
sectionPrefix: string | LlamaText;
betweenCalls: string | LlamaText;
sectionSuffix: string | LlamaText;
};
result: {
sectionPrefix: string | LlamaText;
betweenResults: string | LlamaText;
sectionSuffix: string | LlamaText;
};
};
};
segments: {
closeAllSegments: string | LlamaText;
reiterateStackAfterFunctionCalls: boolean;
thought: ChatWrapperSettingsSegment & {
reopenAfterFunctionCalls: boolean;
};
};
};
Defined in: types.ts:22
Type declaration
supportsSystemMessages
readonly supportsSystemMessages: boolean;
functions
readonly functions: {
call: {
optionalPrefixSpace: boolean;
prefix: string | LlamaText;
paramsPrefix: string | LlamaText;
suffix: string | LlamaText;
};
result: {
prefix: string | LlamaText;
suffix: string | LlamaText;
};
parallelism: {
call: {
sectionPrefix: string | LlamaText;
betweenCalls: string | LlamaText;
sectionSuffix: string | LlamaText;
};
result: {
sectionPrefix: string | LlamaText;
betweenResults: string | LlamaText;
sectionSuffix: string | LlamaText;
};
};
};
functions.call
readonly call: {
optionalPrefixSpace: boolean;
prefix: string | LlamaText;
paramsPrefix: string | LlamaText;
suffix: string | LlamaText;
};
functions.call.optionalPrefixSpace
readonly optionalPrefixSpace: boolean;
functions.call.prefix
readonly prefix: string | LlamaText;
functions.call.paramsPrefix
readonly paramsPrefix: string | LlamaText;
functions.call.suffix
readonly suffix: string | LlamaText;
functions.result
readonly result: {
prefix: string | LlamaText;
suffix: string | LlamaText;
};
functions.result.prefix
readonly prefix: string | LlamaText;
Supported template parameters:
{{functionName}}
{{functionParams}}
Template parameters can only appear in a string or a string in a LlamaText
.
Template parameters inside a SpecialTokensText
inside a LlamaText
won't be replaced.
Example of supported values:
"texttext"
LlamaText(["texttext"])
Example of unsupported values:
LlamaText([new SpecialTokensText("texttext")])
functions.result.suffix
readonly suffix: string | LlamaText;
Supported template parameters:
{{functionName}}
{{functionParams}}
Template parameters can only appear in a string or a string in a LlamaText
.
Template parameters inside a SpecialTokensText
inside a LlamaText
won't be replaced.
Example of supported values:
"texttext"
LlamaText(["texttext"])
Example of unsupported values:
LlamaText([new SpecialTokensText("texttext")])
functions.parallelism?
readonly optional parallelism: {
call: {
sectionPrefix: string | LlamaText;
betweenCalls: string | LlamaText;
sectionSuffix: string | LlamaText;
};
result: {
sectionPrefix: string | LlamaText;
betweenResults: string | LlamaText;
sectionSuffix: string | LlamaText;
};
};
If this field is present, parallel function calling is supported
functions.parallelism.call
readonly call: {
sectionPrefix: string | LlamaText;
betweenCalls: string | LlamaText;
sectionSuffix: string | LlamaText;
};
functions.parallelism.call.sectionPrefix
readonly sectionPrefix: string | LlamaText;
functions.parallelism.call.betweenCalls?
readonly optional betweenCalls: string | LlamaText;
functions.parallelism.call.sectionSuffix?
readonly optional sectionSuffix: string | LlamaText;
functions.parallelism.result?
readonly optional result: {
sectionPrefix: string | LlamaText;
betweenResults: string | LlamaText;
sectionSuffix: string | LlamaText;
};
functions.parallelism.result.sectionPrefix?
readonly optional sectionPrefix: string | LlamaText;
functions.parallelism.result.betweenResults?
readonly optional betweenResults: string | LlamaText;
functions.parallelism.result.sectionSuffix?
readonly optional sectionSuffix: string | LlamaText;
segments?
readonly optional segments: {
closeAllSegments: string | LlamaText;
reiterateStackAfterFunctionCalls: boolean;
thought: ChatWrapperSettingsSegment & {
reopenAfterFunctionCalls: boolean;
};
};
segments.closeAllSegments?
readonly optional closeAllSegments: string | LlamaText;
Consider all active segments to be closed when this text is detected
segments.reiterateStackAfterFunctionCalls?
readonly optional reiterateStackAfterFunctionCalls: boolean;
After function calls, reiterate the stack of the active segments to remind the model of the context.
Defaults to false
.
segments.thought?
readonly optional thought: ChatWrapperSettingsSegment & {
reopenAfterFunctionCalls: boolean;
};
Chain of Thought text segment
Type declaration
reopenAfterFunctionCalls?
optional reopenAfterFunctionCalls: boolean;