From e3e7b4dc33b0ba7fe3e59998b63ad1fee8dc88cc Mon Sep 17 00:00:00 2001 From: hoshi-hiyouga Date: Mon, 5 Feb 2024 22:50:43 +0800 Subject: [PATCH] Update test_toolcall.py Former-commit-id: d4994235f01fccf1498c7cc973cc535247611aa6 --- tests/test_toolcall.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/test_toolcall.py b/tests/test_toolcall.py index 8c706429..74946d40 100644 --- a/tests/test_toolcall.py +++ b/tests/test_toolcall.py @@ -3,10 +3,11 @@ import os from typing import Sequence from openai import OpenAI -# pip install openai >= 1.3.0 +from transformers.utils.versions import require_version os.environ["OPENAI_BASE_URL"] = "http://192.168.0.1:8000/v1" os.environ["OPENAI_API_KEY"] = "0" +require_version("openai>=1.5.0", "To fix: pip install openai>=1.5.0") def calculate_gpa(grades: Sequence[str], hours: Sequence[int]) -> float: