From 4332e247407d433c162e2225d7ae20a786e4b005 Mon Sep 17 00:00:00 2001 From: oobabooga <112222186+oobabooga@users.noreply.github.com> Date: Tue, 9 Jan 2024 19:06:11 -0800 Subject: [PATCH] API: Make user_name/bot_name the official and name1/name2 the alias --- extensions/openai/typing.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/extensions/openai/typing.py b/extensions/openai/typing.py index 5725ece8..cd997106 100644 --- a/extensions/openai/typing.py +++ b/extensions/openai/typing.py @@ -99,10 +99,10 @@ class ChatCompletionRequestParams(BaseModel): instruction_template_str: str | None = Field(default=None, description="A Jinja2 instruction template. If set, will take precedence over everything else.") character: str | None = Field(default=None, description="A character defined under text-generation-webui/characters. If not set, the default \"Assistant\" character will be used.") - name1: str | None = Field(default=None, description="Your name (the user). By default, it's \"You\".", alias=['user_name']) - name2: str | None = Field(default=None, description="Overwrites the value set by character.", alias=['bot_name']) - context: str | None = Field(default=None, description="Overwrites the value set by character.") - greeting: str | None = Field(default=None, description="Overwrites the value set by character.") + user_name: str | None = Field(default=None, description="Your name (the user). By default, it's \"You\".", alias=['name1']) + bot_name: str | None = Field(default=None, description="Overwrites the value set by character field.", alias=['name2']) + context: str | None = Field(default=None, description="Overwrites the value set by character field.") + greeting: str | None = Field(default=None, description="Overwrites the value set by character field.") chat_template_str: str | None = Field(default=None, description="Jinja2 template for chat.") chat_instruct_command: str | None = None