update gemini user_msg doc

This commit is contained in:
better629 2023-12-14 16:54:56 +08:00
parent bef8d64193
commit 9fb6e7c459

View file

@ -36,6 +36,8 @@ class GeminiGPTAPI(BaseGPTAPI):
genai.configure(api_key=config.gemini_api_key)
def _user_msg(self, msg: str) -> dict[str, str]:
# Not to change BaseGPTAPI default functions but update with Gemini's conversation format.
# You should follow the format.
return {"role": "user", "parts": [msg]}
def _assistant_msg(self, msg: str) -> dict[str, str]: