diff --git a/aidial_adapter_vertexai/chat_completion.py b/aidial_adapter_vertexai/chat_completion.py index f79d8d9..a935b54 100644 --- a/aidial_adapter_vertexai/chat_completion.py +++ b/aidial_adapter_vertexai/chat_completion.py @@ -84,4 +84,4 @@ async def generate_response(usage: TokenUsage, choice_idx: int) -> None: response.set_usage(usage.prompt_tokens, usage.completion_tokens) if params.max_prompt_tokens is not None: - response.set_discarded_messages([]) + response.set_discarded_messages(discarded_messages_count) diff --git a/poetry.lock b/poetry.lock index 1cbf7de..1d4438a 100644 --- a/poetry.lock +++ b/poetry.lock @@ -2,13 +2,13 @@ [[package]] name = "aidial-sdk" -version = "0.7.0" +version = "0.6.2" description = "Framework to create applications and model adapters for AI DIAL" optional = false python-versions = ">=3.8.1,<4.0" files = [ - {file = "aidial_sdk-0.7.0-py3-none-any.whl", hash = "sha256:e22a948011f6ed55d7f7eef4c0f589f26d6e2412a6b55072be5fd37e8adc5752"}, - {file = "aidial_sdk-0.7.0.tar.gz", hash = "sha256:a239af55a29742c18446df8a8a29ced8fedd2deebc8cf351d565fcbf8299c295"}, + {file = "aidial_sdk-0.6.2-py3-none-any.whl", hash = "sha256:fa1cc43f1f8f70047e81adc5fae9914ddf6c94e4d7f55b83ba7ecca3cea5d122"}, + {file = "aidial_sdk-0.6.2.tar.gz", hash = "sha256:46dafb6360cad6cea08531d3cea7600d87cda06cd8c86a560330b61d0a492cab"}, ] [package.dependencies] @@ -2973,4 +2973,4 @@ testing = ["big-O", "jaraco.functools", "jaraco.itertools", "more-itertools", "p [metadata] lock-version = "2.0" python-versions = "~3.11" -content-hash = "3a7a1eba7057c3385c31e422504490b6d2ecd6acd898e113cbbedaf19ec662b1" +content-hash = "4edc35ee316c98f6e54b28a9819f7cc4e556dd99f49132ae5698fc18d2f2bd9d" diff --git a/pyproject.toml b/pyproject.toml index 7256f3c..caf8112 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -15,7 +15,7 @@ repository = "https://github.com/epam/ai-dial-adapter-vertexai/" [tool.poetry.dependencies] python = "~3.11" -aidial-sdk = {version = "0.7.0", extras = ["telemetry"]} +aidial-sdk = {version = "0.6.2", extras = ["telemetry"]} fastapi = "0.109.2" google-cloud-aiplatform = "1.38.1" google-auth = "2.21.0"