From 594a6a7c225e5b0c8a7346d7f2dae2fa8673cd04 Mon Sep 17 00:00:00 2001 From: drbh Date: Mon, 25 Nov 2024 08:33:58 -0500 Subject: [PATCH] fix: adjust continuation tests expected text --- .../test_llama_completion_single_prompt.json | 8 ++++---- .../test_llama_completion_single_prompt_continue.json | 8 ++++---- integration-tests/models/test_continue_final_message.py | 4 ++-- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/integration-tests/models/__snapshots__/test_continue_final_message/test_llama_completion_single_prompt.json b/integration-tests/models/__snapshots__/test_continue_final_message/test_llama_completion_single_prompt.json index caa00f99..0bea487c 100644 --- a/integration-tests/models/__snapshots__/test_continue_final_message/test_llama_completion_single_prompt.json +++ b/integration-tests/models/__snapshots__/test_continue_final_message/test_llama_completion_single_prompt.json @@ -5,19 +5,19 @@ "index": 0, "logprobs": null, "message": { - "content": "\nGenerate according to: It is an elephant's one year old baby or a mouse's one year old baby. It is", + "content": "Both an elephant and a mouse are mammals. However, the differences between elephants and mice are:\n\n1", "role": "assistant" } } ], - "created": 1732050325, + "created": 1732541189, "id": "", "model": "TinyLlama/TinyLlama-1.1B-Chat-v1.0", "object": "chat.completion", "system_fingerprint": "2.4.1-dev0-native", "usage": { "completion_tokens": 30, - "prompt_tokens": 37, - "total_tokens": 67 + "prompt_tokens": 49, + "total_tokens": 79 } } diff --git a/integration-tests/models/__snapshots__/test_continue_final_message/test_llama_completion_single_prompt_continue.json b/integration-tests/models/__snapshots__/test_continue_final_message/test_llama_completion_single_prompt_continue.json index 8f782694..bd5cdd7c 100644 --- a/integration-tests/models/__snapshots__/test_continue_final_message/test_llama_completion_single_prompt_continue.json +++ b/integration-tests/models/__snapshots__/test_continue_final_message/test_llama_completion_single_prompt_continue.json @@ -5,19 +5,19 @@ "index": 0, "logprobs": null, "message": { - "content": " the royal mouse? It is a little more slender and only weighs around 1.5 pounds for males and 1.3 pounds", + "content": "the mouse is much smaller than an elephant. The average elephant weight is around 6,500 lbs (3,", "role": "assistant" } } ], - "created": 1732050326, + "created": 1732541190, "id": "", "model": "TinyLlama/TinyLlama-1.1B-Chat-v1.0", "object": "chat.completion", "system_fingerprint": "2.4.1-dev0-native", "usage": { "completion_tokens": 30, - "prompt_tokens": 61, - "total_tokens": 91 + "prompt_tokens": 73, + "total_tokens": 103 } } diff --git a/integration-tests/models/test_continue_final_message.py b/integration-tests/models/test_continue_final_message.py index 2fb99273..24ae720f 100644 --- a/integration-tests/models/test_continue_final_message.py +++ b/integration-tests/models/test_continue_final_message.py @@ -38,7 +38,7 @@ def test_llama_completion_single_prompt( content = response["choices"][0]["message"]["content"] assert ( content - == "\nGenerate according to: It is an elephant's one year old baby or a mouse's one year old baby. It is" + == "Both an elephant and a mouse are mammals. However, the differences between elephants and mice are:\n\n1" ) assert response == response_snapshot @@ -71,6 +71,6 @@ def test_llama_completion_single_prompt_continue( content = response["choices"][0]["message"]["content"] assert ( content - == " the royal mouse? It is a little more slender and only weighs around 1.5 pounds for males and 1.3 pounds" + == "the mouse is much smaller than an elephant. The average elephant weight is around 6,500 lbs (3," ) assert response == response_snapshot