From 3e02dc5c2fb1998687c091b9f2b05c32653c1cd0 Mon Sep 17 00:00:00 2001 From: Matthew Farrellee Date: Tue, 16 Sep 2025 12:13:14 -0400 Subject: [PATCH] feat: add embedding and dynamic model support to Together inference adapter - updated to use OpenAIMixin - workarounds for Together api quirks - recordings for together suite when subdirs=inference,pattern=openai test with: `TOGETHER_API_KEY=_NONE_ ./scripts/integration-tests.sh --stack-config server:ci-tests --setup together --subdirs inference --pattern openai` --- .../remote/inference/together/models.py | 120 +- .../remote/inference/together/together.py | 204 +- .../inference/test_openai_completion.py | 1 + .../inference/test_openai_embeddings.py | 41 +- .../recordings/responses/07c5fa34d9ca.json | 800 ++++++ .../recordings/responses/0c1f45455d3b.json | 59 + .../recordings/responses/17030e75309f.json | 800 ++++++ .../recordings/responses/432a346b2ed8.json | 2352 +++++++++++++++++ .../recordings/responses/4ca6152a0eb8.json | 59 + .../recordings/responses/511eb1b92e34.json | 1278 +++++++++ .../recordings/responses/565b1072cb9d.json | 46 + .../recordings/responses/6730dcde0b73.json | 756 ++++++ .../recordings/responses/6857b19d3f0a.json | 87 + .../recordings/responses/6c4e2e207e8a.json | 59 + .../recordings/responses/72e075bf28e8.json | 800 ++++++ .../recordings/responses/894fdacb1cfa.json | 176 ++ .../recordings/responses/bce560cbf1c6.json | 800 ++++++ .../recordings/responses/d85689907fec.json | 350 +++ .../recordings/responses/f0bbea34c5cc.json | 611 +++++ tests/integration/suites.py | 8 + 20 files changed, 9227 insertions(+), 180 deletions(-) create mode 100644 tests/integration/recordings/responses/07c5fa34d9ca.json create mode 100644 tests/integration/recordings/responses/0c1f45455d3b.json create mode 100644 tests/integration/recordings/responses/17030e75309f.json create mode 100644 tests/integration/recordings/responses/432a346b2ed8.json create mode 100644 tests/integration/recordings/responses/4ca6152a0eb8.json create mode 100644 tests/integration/recordings/responses/511eb1b92e34.json create mode 100644 tests/integration/recordings/responses/565b1072cb9d.json create mode 100644 tests/integration/recordings/responses/6730dcde0b73.json create mode 100644 tests/integration/recordings/responses/6857b19d3f0a.json create mode 100644 tests/integration/recordings/responses/6c4e2e207e8a.json create mode 100644 tests/integration/recordings/responses/72e075bf28e8.json create mode 100644 tests/integration/recordings/responses/894fdacb1cfa.json create mode 100644 tests/integration/recordings/responses/bce560cbf1c6.json create mode 100644 tests/integration/recordings/responses/d85689907fec.json create mode 100644 tests/integration/recordings/responses/f0bbea34c5cc.json diff --git a/llama_stack/providers/remote/inference/together/models.py b/llama_stack/providers/remote/inference/together/models.py index 575ec1f3d..2aba614cb 100644 --- a/llama_stack/providers/remote/inference/together/models.py +++ b/llama_stack/providers/remote/inference/together/models.py @@ -4,7 +4,6 @@ # This source code is licensed under the terms described in the LICENSE file in # the root directory of this source tree. -from llama_stack.apis.models import ModelType from llama_stack.models.llama.sku_types import CoreModelId from llama_stack.providers.utils.inference.model_registry import ( ProviderModelEntry, @@ -21,57 +20,84 @@ SAFETY_MODELS_ENTRIES = [ CoreModelId.llama_guard_3_11b_vision.value, ), ] -MODEL_ENTRIES = [ - build_hf_repo_model_entry( - "meta-llama/Meta-Llama-3.1-8B-Instruct-Turbo", - CoreModelId.llama3_1_8b_instruct.value, - ), - build_hf_repo_model_entry( - "meta-llama/Meta-Llama-3.1-70B-Instruct-Turbo", - CoreModelId.llama3_1_70b_instruct.value, - ), - build_hf_repo_model_entry( - "meta-llama/Meta-Llama-3.1-405B-Instruct-Turbo", - CoreModelId.llama3_1_405b_instruct.value, - ), - build_hf_repo_model_entry( - "meta-llama/Llama-3.2-3B-Instruct-Turbo", - CoreModelId.llama3_2_3b_instruct.value, - ), - build_hf_repo_model_entry( - "meta-llama/Llama-3.2-11B-Vision-Instruct-Turbo", - CoreModelId.llama3_2_11b_vision_instruct.value, - ), - build_hf_repo_model_entry( - "meta-llama/Llama-3.2-90B-Vision-Instruct-Turbo", - CoreModelId.llama3_2_90b_vision_instruct.value, - ), - build_hf_repo_model_entry( - "meta-llama/Llama-3.3-70B-Instruct-Turbo", - CoreModelId.llama3_3_70b_instruct.value, - ), - ProviderModelEntry( - provider_model_id="togethercomputer/m2-bert-80M-8k-retrieval", - model_type=ModelType.embedding, - metadata={ - "embedding_dimension": 768, - "context_length": 8192, - }, - ), - ProviderModelEntry( + +# source: https://docs.together.ai/docs/serverless-models#embedding-models +EMBEDDING_MODEL_ENTRIES = { + "togethercomputer/m2-bert-80M-32k-retrieval": ProviderModelEntry( provider_model_id="togethercomputer/m2-bert-80M-32k-retrieval", - model_type=ModelType.embedding, metadata={ "embedding_dimension": 768, "context_length": 32768, }, ), - build_hf_repo_model_entry( - "meta-llama/Llama-4-Scout-17B-16E-Instruct", - CoreModelId.llama4_scout_17b_16e_instruct.value, + "BAAI/bge-large-en-v1.5": ProviderModelEntry( + provider_model_id="BAAI/bge-large-en-v1.5", + metadata={ + "embedding_dimension": 1024, + "context_length": 512, + }, ), - build_hf_repo_model_entry( - "meta-llama/Llama-4-Maverick-17B-128E-Instruct-FP8", - CoreModelId.llama4_maverick_17b_128e_instruct.value, + "BAAI/bge-base-en-v1.5": ProviderModelEntry( + provider_model_id="BAAI/bge-base-en-v1.5", + metadata={ + "embedding_dimension": 768, + "context_length": 512, + }, ), -] + SAFETY_MODELS_ENTRIES + "Alibaba-NLP/gte-modernbert-base": ProviderModelEntry( + provider_model_id="Alibaba-NLP/gte-modernbert-base", + metadata={ + "embedding_dimension": 768, + "context_length": 8192, + }, + ), + "intfloat/multilingual-e5-large-instruct": ProviderModelEntry( + provider_model_id="intfloat/multilingual-e5-large-instruct", + metadata={ + "embedding_dimension": 1024, + "context_length": 512, + }, + ), +} +MODEL_ENTRIES = ( + [ + build_hf_repo_model_entry( + "meta-llama/Meta-Llama-3.1-8B-Instruct-Turbo", + CoreModelId.llama3_1_8b_instruct.value, + ), + build_hf_repo_model_entry( + "meta-llama/Meta-Llama-3.1-70B-Instruct-Turbo", + CoreModelId.llama3_1_70b_instruct.value, + ), + build_hf_repo_model_entry( + "meta-llama/Meta-Llama-3.1-405B-Instruct-Turbo", + CoreModelId.llama3_1_405b_instruct.value, + ), + build_hf_repo_model_entry( + "meta-llama/Llama-3.2-3B-Instruct-Turbo", + CoreModelId.llama3_2_3b_instruct.value, + ), + build_hf_repo_model_entry( + "meta-llama/Llama-3.2-11B-Vision-Instruct-Turbo", + CoreModelId.llama3_2_11b_vision_instruct.value, + ), + build_hf_repo_model_entry( + "meta-llama/Llama-3.2-90B-Vision-Instruct-Turbo", + CoreModelId.llama3_2_90b_vision_instruct.value, + ), + build_hf_repo_model_entry( + "meta-llama/Llama-3.3-70B-Instruct-Turbo", + CoreModelId.llama3_3_70b_instruct.value, + ), + build_hf_repo_model_entry( + "meta-llama/Llama-4-Scout-17B-16E-Instruct", + CoreModelId.llama4_scout_17b_16e_instruct.value, + ), + build_hf_repo_model_entry( + "meta-llama/Llama-4-Maverick-17B-128E-Instruct-FP8", + CoreModelId.llama4_maverick_17b_128e_instruct.value, + ), + ] + + SAFETY_MODELS_ENTRIES + + list(EMBEDDING_MODEL_ENTRIES.values()) +) diff --git a/llama_stack/providers/remote/inference/together/together.py b/llama_stack/providers/remote/inference/together/together.py index 54c76607f..674e876aa 100644 --- a/llama_stack/providers/remote/inference/together/together.py +++ b/llama_stack/providers/remote/inference/together/together.py @@ -4,11 +4,11 @@ # This source code is licensed under the terms described in the LICENSE file in # the root directory of this source tree. -from collections.abc import AsyncGenerator, AsyncIterator -from typing import Any +from collections.abc import AsyncGenerator -from openai import AsyncOpenAI +from openai import NOT_GIVEN, AsyncOpenAI from together import AsyncTogether +from together.constants import BASE_URL from llama_stack.apis.common.content_types import ( InterleavedContent, @@ -23,12 +23,7 @@ from llama_stack.apis.inference import ( Inference, LogProbConfig, Message, - OpenAIChatCompletion, - OpenAIChatCompletionChunk, - OpenAICompletion, OpenAIEmbeddingsResponse, - OpenAIMessageParam, - OpenAIResponseFormatParam, ResponseFormat, ResponseFormatType, SamplingParams, @@ -38,18 +33,20 @@ from llama_stack.apis.inference import ( ToolDefinition, ToolPromptFormat, ) +from llama_stack.apis.inference.inference import OpenAIEmbeddingUsage +from llama_stack.apis.models import Model, ModelType from llama_stack.core.request_headers import NeedsRequestProviderData from llama_stack.log import get_logger from llama_stack.providers.utils.inference.model_registry import ModelRegistryHelper from llama_stack.providers.utils.inference.openai_compat import ( convert_message_to_openai_dict, get_sampling_options, - prepare_openai_completion_params, process_chat_completion_response, process_chat_completion_stream_response, process_completion_response, process_completion_stream_response, ) +from llama_stack.providers.utils.inference.openai_mixin import OpenAIMixin from llama_stack.providers.utils.inference.prompt_adapter import ( chat_completion_request_to_prompt, completion_request_to_prompt, @@ -59,15 +56,22 @@ from llama_stack.providers.utils.inference.prompt_adapter import ( ) from .config import TogetherImplConfig -from .models import MODEL_ENTRIES +from .models import EMBEDDING_MODEL_ENTRIES, MODEL_ENTRIES logger = get_logger(name=__name__, category="inference::together") -class TogetherInferenceAdapter(ModelRegistryHelper, Inference, NeedsRequestProviderData): +class TogetherInferenceAdapter(OpenAIMixin, ModelRegistryHelper, Inference, NeedsRequestProviderData): def __init__(self, config: TogetherImplConfig) -> None: ModelRegistryHelper.__init__(self, MODEL_ENTRIES, config.allowed_models) self.config = config + self._model_cache: dict[str, Model] = {} + + def get_api_key(self): + return self.config.api_key.get_secret_value() + + def get_base_url(self): + return BASE_URL async def initialize(self) -> None: pass @@ -255,6 +259,36 @@ class TogetherInferenceAdapter(ModelRegistryHelper, Inference, NeedsRequestProvi embeddings = [item.embedding for item in r.data] return EmbeddingsResponse(embeddings=embeddings) + async def list_models(self) -> list[Model] | None: + self._model_cache = {} + for m in await self._get_client().models.list(): + if m.type == "embedding": + if m.id not in EMBEDDING_MODEL_ENTRIES: + logger.warning(f"Unknown embedding dimension for model {m.id}, skipping.") + continue + self._model_cache[m.id] = Model( + provider_id=self.__provider_id__, + provider_resource_id=EMBEDDING_MODEL_ENTRIES[m.id].provider_model_id, + identifier=m.id, + model_type=ModelType.embedding, + metadata=EMBEDDING_MODEL_ENTRIES[m.id].metadata, + ) + else: + self._model_cache[m.id] = Model( + provider_id=self.__provider_id__, + provider_resource_id=m.id, + identifier=m.id, + model_type=ModelType.llm, + ) + + return self._model_cache.values() + + async def should_refresh_models(self) -> bool: + return True + + async def check_model_availability(self, model): + return model in self._model_cache + async def openai_embeddings( self, model: str, @@ -263,125 +297,39 @@ class TogetherInferenceAdapter(ModelRegistryHelper, Inference, NeedsRequestProvi dimensions: int | None = None, user: str | None = None, ) -> OpenAIEmbeddingsResponse: - raise NotImplementedError() + """ + Together's OpenAI-compatible embeddings endpoint is not compatible with + the standard OpenAI embeddings endpoint. - async def openai_completion( - self, - model: str, - prompt: str | list[str] | list[int] | list[list[int]], - best_of: int | None = None, - echo: bool | None = None, - frequency_penalty: float | None = None, - logit_bias: dict[str, float] | None = None, - logprobs: bool | None = None, - max_tokens: int | None = None, - n: int | None = None, - presence_penalty: float | None = None, - seed: int | None = None, - stop: str | list[str] | None = None, - stream: bool | None = None, - stream_options: dict[str, Any] | None = None, - temperature: float | None = None, - top_p: float | None = None, - user: str | None = None, - guided_choice: list[str] | None = None, - prompt_logprobs: int | None = None, - suffix: str | None = None, - ) -> OpenAICompletion: - model_obj = await self.model_store.get_model(model) - params = await prepare_openai_completion_params( - model=model_obj.provider_resource_id, - prompt=prompt, - best_of=best_of, - echo=echo, - frequency_penalty=frequency_penalty, - logit_bias=logit_bias, - logprobs=logprobs, - max_tokens=max_tokens, - n=n, - presence_penalty=presence_penalty, - seed=seed, - stop=stop, - stream=stream, - stream_options=stream_options, - temperature=temperature, - top_p=top_p, - user=user, + The endpoint - + - does not return usage information + - does not support user param, returns 400 Unrecognized request arguments supplied: user + - does not support dimensions param, returns 400 Unrecognized request arguments supplied: dimensions + - does not support encoding_format param, always returns floats, never base64 + """ + # Together support ticket #13332 -> will not fix + if user is not None: + raise ValueError("Together's embeddings endpoint does not support user param.") + # Together support ticket #13333 -> escalated + if dimensions is not None: + raise ValueError("Together's embeddings endpoint does not support dimensions param.") + # Together support ticket #13331 -> will not fix, compute client side + if encoding_format not in (None, NOT_GIVEN, "float"): + raise ValueError("Together's embeddings endpoint only supports encoding_format='float'.") + + response = await self.client.embeddings.create( + model=await self._get_provider_model_id(model), + input=input, ) - return await self._get_openai_client().completions.create(**params) # type: ignore - async def openai_chat_completion( - self, - model: str, - messages: list[OpenAIMessageParam], - frequency_penalty: float | None = None, - function_call: str | dict[str, Any] | None = None, - functions: list[dict[str, Any]] | None = None, - logit_bias: dict[str, float] | None = None, - logprobs: bool | None = None, - max_completion_tokens: int | None = None, - max_tokens: int | None = None, - n: int | None = None, - parallel_tool_calls: bool | None = None, - presence_penalty: float | None = None, - response_format: OpenAIResponseFormatParam | None = None, - seed: int | None = None, - stop: str | list[str] | None = None, - stream: bool | None = None, - stream_options: dict[str, Any] | None = None, - temperature: float | None = None, - tool_choice: str | dict[str, Any] | None = None, - tools: list[dict[str, Any]] | None = None, - top_logprobs: int | None = None, - top_p: float | None = None, - user: str | None = None, - ) -> OpenAIChatCompletion | AsyncIterator[OpenAIChatCompletionChunk]: - model_obj = await self.model_store.get_model(model) - params = await prepare_openai_completion_params( - model=model_obj.provider_resource_id, - messages=messages, - frequency_penalty=frequency_penalty, - function_call=function_call, - functions=functions, - logit_bias=logit_bias, - logprobs=logprobs, - max_completion_tokens=max_completion_tokens, - max_tokens=max_tokens, - n=n, - parallel_tool_calls=parallel_tool_calls, - presence_penalty=presence_penalty, - response_format=response_format, - seed=seed, - stop=stop, - stream=stream, - stream_options=stream_options, - temperature=temperature, - tool_choice=tool_choice, - tools=tools, - top_logprobs=top_logprobs, - top_p=top_p, - user=user, - ) - if params.get("stream", False): - return self._stream_openai_chat_completion(params) - return await self._get_openai_client().chat.completions.create(**params) # type: ignore + response.model = model # return the user the same model id they provided, avoid exposing the provider model id - async def _stream_openai_chat_completion(self, params: dict) -> AsyncGenerator: - # together.ai sometimes adds usage data to the stream, even if include_usage is False - # This causes an unexpected final chunk with empty choices array to be sent - # to clients that may not handle it gracefully. - include_usage = False - if params.get("stream_options", None): - include_usage = params["stream_options"].get("include_usage", False) - stream = await self._get_openai_client().chat.completions.create(**params) + # Together support ticket #13330 -> escalated + # - togethercomputer/m2-bert-80M-32k-retrieval *does not* return usage information + if not hasattr(response, "usage") or response.usage is None: + logger.warning( + f"Together's embedding endpoint for {model} did not return usage information, substituting -1s." + ) + response.usage = OpenAIEmbeddingUsage(prompt_tokens=-1, total_tokens=-1) - seen_finish_reason = False - async for chunk in stream: - # Final usage chunk with no choices that the user didn't request, so discard - if not include_usage and seen_finish_reason and len(chunk.choices) == 0: - break - yield chunk - for choice in chunk.choices: - if choice.finish_reason: - seen_finish_reason = True - break + return response diff --git a/tests/integration/inference/test_openai_completion.py b/tests/integration/inference/test_openai_completion.py index 35869276b..969845395 100644 --- a/tests/integration/inference/test_openai_completion.py +++ b/tests/integration/inference/test_openai_completion.py @@ -96,6 +96,7 @@ def skip_if_doesnt_support_n(client_with_models, model_id): # Error code: 400 - [{'error': {'code': 400, 'message': 'Unable to submit request because candidateCount must be 1 but # the entered value was 2. Update the candidateCount value and try again.', 'status': 'INVALID_ARGUMENT'} "remote::tgi", # TGI ignores n param silently + "remote::together", # `n` > 1 is not supported when streaming tokens. Please disable `stream` ): pytest.skip(f"Model {model_id} hosted by {provider.provider_type} doesn't support n param.") diff --git a/tests/integration/inference/test_openai_embeddings.py b/tests/integration/inference/test_openai_embeddings.py index 2c545cc43..bb015110f 100644 --- a/tests/integration/inference/test_openai_embeddings.py +++ b/tests/integration/inference/test_openai_embeddings.py @@ -29,9 +29,34 @@ def provider_from_model(client_with_models, model_id): return providers[provider_id] -def skip_if_model_doesnt_support_variable_dimensions(model_id): - if "text-embedding-3" not in model_id: - pytest.skip("{model_id} does not support variable output embedding dimensions") +def skip_if_model_doesnt_support_user_param(client, model_id): + provider = provider_from_model(client, model_id) + if provider.provider_type in ( + "remote::together", # service returns 400 + ): + pytest.skip(f"Model {model_id} hosted by {provider.provider_type} does not support user param.") + + +def skip_if_model_doesnt_support_encoding_format_base64(client, model_id): + provider = provider_from_model(client, model_id) + if provider.provider_type in ( + "remote::together", # param silently ignored, always returns floats + ): + pytest.skip(f"Model {model_id} hosted by {provider.provider_type} does not support encoding_format='base64'.") + + +def skip_if_model_doesnt_support_variable_dimensions(client_with_models, model_id): + provider = provider_from_model(client_with_models, model_id) + if provider.provider_type in ( + "remote::together", # returns 400 + ): + pytest.skip( + f"Model {model_id} hosted by {provider.provider_type} does not support variable output embedding dimensions." + ) + if provider.provider_type == "remote::openai" and "text-embedding-3" not in model_id: + pytest.skip( + f"Model {model_id} hosted by {provider.provider_type} does not support variable output embedding dimensions." + ) @pytest.fixture(params=["openai_client", "llama_stack_client"]) @@ -92,6 +117,7 @@ def test_openai_embeddings_multiple_strings(compat_client, client_with_models, e response = compat_client.embeddings.create( model=embedding_model_id, input=input_texts, + encoding_format="float", ) assert response.object == "list" @@ -127,7 +153,7 @@ def test_openai_embeddings_with_encoding_format_float(compat_client, client_with def test_openai_embeddings_with_dimensions(compat_client, client_with_models, embedding_model_id): """Test OpenAI embeddings endpoint with custom dimensions parameter.""" skip_if_model_doesnt_support_openai_embeddings(client_with_models, embedding_model_id) - skip_if_model_doesnt_support_variable_dimensions(embedding_model_id) + skip_if_model_doesnt_support_variable_dimensions(client_with_models, embedding_model_id) input_text = "Test dimensions parameter" dimensions = 16 @@ -148,6 +174,7 @@ def test_openai_embeddings_with_dimensions(compat_client, client_with_models, em def test_openai_embeddings_with_user_parameter(compat_client, client_with_models, embedding_model_id): """Test OpenAI embeddings endpoint with user parameter.""" skip_if_model_doesnt_support_openai_embeddings(client_with_models, embedding_model_id) + skip_if_model_doesnt_support_user_param(client_with_models, embedding_model_id) input_text = "Test user parameter" user_id = "test-user-123" @@ -196,11 +223,13 @@ def test_openai_embeddings_different_inputs_different_outputs(compat_client, cli response1 = compat_client.embeddings.create( model=embedding_model_id, input=input_text1, + encoding_format="float", ) response2 = compat_client.embeddings.create( model=embedding_model_id, input=input_text2, + encoding_format="float", ) embedding1 = response1.data[0].embedding @@ -214,7 +243,8 @@ def test_openai_embeddings_different_inputs_different_outputs(compat_client, cli def test_openai_embeddings_with_encoding_format_base64(compat_client, client_with_models, embedding_model_id): """Test OpenAI embeddings endpoint with base64 encoding format.""" skip_if_model_doesnt_support_openai_embeddings(client_with_models, embedding_model_id) - skip_if_model_doesnt_support_variable_dimensions(embedding_model_id) + skip_if_model_doesnt_support_encoding_format_base64(client_with_models, embedding_model_id) + skip_if_model_doesnt_support_variable_dimensions(client_with_models, embedding_model_id) input_text = "Test base64 encoding format" dimensions = 12 @@ -247,6 +277,7 @@ def test_openai_embeddings_with_encoding_format_base64(compat_client, client_wit def test_openai_embeddings_base64_batch_processing(compat_client, client_with_models, embedding_model_id): """Test OpenAI embeddings endpoint with base64 encoding for batch processing.""" skip_if_model_doesnt_support_openai_embeddings(client_with_models, embedding_model_id) + skip_if_model_doesnt_support_encoding_format_base64(client_with_models, embedding_model_id) input_texts = ["First text for base64", "Second text for base64", "Third text for base64"] diff --git a/tests/integration/recordings/responses/07c5fa34d9ca.json b/tests/integration/recordings/responses/07c5fa34d9ca.json new file mode 100644 index 000000000..af1460120 --- /dev/null +++ b/tests/integration/recordings/responses/07c5fa34d9ca.json @@ -0,0 +1,800 @@ +{ + "request": { + "method": "POST", + "url": "https://api.together.xyz/v1/v1/embeddings", + "headers": {}, + "body": { + "model": "togethercomputer/m2-bert-80M-32k-retrieval", + "input": "Test encoding format" + }, + "endpoint": "/v1/embeddings", + "model": "togethercomputer/m2-bert-80M-32k-retrieval" + }, + "response": { + "body": { + "__type__": "openai.types.create_embedding_response.CreateEmbeddingResponse", + "__data__": { + "data": [ + { + "embedding": [ + -0.011256923, + 0.0037174695, + 0.047607094, + -0.03605117, + 0.022678856, + 0.0022196341, + 0.008172763, + -0.07876377, + -0.012652523, + -0.124776885, + -0.07201225, + 0.011470616, + 0.020233244, + -0.03953407, + 0.017867543, + -0.07615726, + 0.015161683, + 0.01493531, + 0.0021282644, + 0.02805457, + 0.0008320583, + 0.022922216, + 0.049158294, + -0.03197842, + 0.020910429, + 0.03798574, + 0.032469492, + 0.009267314, + 0.0883011, + 0.0032435523, + 0.013633923, + 0.0457091, + -0.022143621, + -0.0007423012, + -0.03613117, + 0.052107, + 0.02962152, + 0.045084383, + 0.044733327, + 0.11753868, + 0.05730107, + 0.026509244, + -0.056454167, + -0.017637681, + 0.030301955, + 0.04790331, + -0.025398305, + -0.019705286, + 0.11366949, + 0.05800383, + -0.0072742635, + 0.100181706, + 0.1609472, + 0.0053162435, + 0.01714287, + -0.023215268, + 0.042824704, + 0.04082185, + 0.030668061, + -0.06529372, + 0.008288249, + 0.0325246, + 0.009664108, + -0.031153189, + 0.044064675, + 0.10059426, + 0.036557477, + 0.009674479, + 0.016028037, + 0.02236809, + 0.056538712, + -0.12828006, + 0.016760435, + 0.015355689, + -0.00070172164, + -0.0076741586, + -0.02880062, + -0.011680436, + -0.036522433, + -0.030315956, + 0.023295958, + 0.031333964, + 0.042397793, + -0.063102156, + 0.0669075, + -0.07678097, + 0.0616129, + -0.0071245604, + -0.021313114, + 0.0040440215, + 0.04436404, + 0.05289292, + 0.05803014, + 0.032691576, + 0.037537806, + -0.09712317, + -0.0061692744, + 0.008186577, + -0.0151672475, + -0.05499382, + -0.11011894, + -0.017255861, + 0.061501417, + 0.03551128, + 0.056205165, + 0.07500363, + 0.023062926, + 0.10787879, + 0.063290246, + -0.021196125, + -0.005724647, + 0.019805718, + -0.0063712946, + -0.049270064, + -0.024442751, + 0.018587058, + -0.082689136, + -0.019034613, + 0.005483609, + 0.03418548, + -0.008317338, + 0.06888298, + -0.037655607, + -0.05362105, + -0.010807861, + 0.069666155, + -0.01777964, + -0.015136251, + -0.026567455, + -0.08084807, + -0.078372054, + 0.039493512, + 0.013156698, + 0.07340631, + 0.12035369, + -0.05765069, + 0.025966862, + -0.0045753582, + -0.030865112, + 0.039448086, + -0.037273232, + 0.047059145, + -0.029127738, + -0.024217308, + 0.02748501, + -0.048555836, + 0.017913114, + -0.055981673, + -0.005601368, + -0.04045025, + -0.017308103, + 0.06272273, + 0.012256746, + 0.01575095, + -0.026737463, + 0.04115108, + 0.07562276, + -0.01140116, + 0.022552952, + 0.0443809, + -0.030472409, + -0.021670958, + -0.037897367, + 0.017250286, + -0.033001736, + -0.048738975, + -0.06429833, + -0.015412785, + 0.0036735258, + 0.023700202, + 0.035861194, + -0.05393875, + 0.048050668, + 0.032297045, + 0.021352977, + -0.05701748, + 0.0008330949, + -0.006661303, + -0.0070953164, + -0.043984424, + 0.052504774, + 0.027689766, + 0.031661708, + -0.050054867, + -0.015419155, + -0.013700429, + -0.03579233, + -0.08926211, + -0.034341693, + -0.01738188, + -0.0065487004, + -0.051955026, + 0.0019674778, + 0.0015172043, + 0.024915336, + 0.010987228, + 0.061529815, + 0.09077649, + 0.04394813, + -0.07503514, + 0.043345768, + -0.028357483, + 0.06312762, + 0.025069924, + 0.028561853, + 0.043048594, + 0.017411513, + -0.025240859, + -0.0056393985, + 0.054039005, + 0.008721963, + -0.039967448, + 0.0012871448, + 0.0052062417, + 0.005563228, + 0.042596456, + -0.008794862, + -0.044669237, + 0.04184779, + 0.008726271, + 0.10136058, + 0.040724736, + 0.14168875, + -0.017516509, + -0.11203568, + 0.0010548063, + -0.058536656, + 0.01673066, + 0.007502946, + -0.035662595, + 0.034719367, + -0.0060368567, + 0.13295838, + 0.026423598, + 0.056147255, + 0.04473965, + 0.045232397, + 0.07171366, + 0.009358642, + -0.021109166, + 0.033915937, + 0.0380073, + -0.01451498, + -0.021589639, + 0.062518574, + -0.017531183, + -0.030811403, + 0.024500312, + 0.05383414, + -0.1335839, + 0.01834579, + -0.051048376, + 0.07460228, + 0.03231806, + 0.00962887, + 0.05156732, + 0.016169788, + 0.0062234807, + -0.09062714, + -0.08959952, + 0.025153147, + -0.030351512, + -0.04339584, + 0.007234872, + 0.014588551, + 0.022614833, + -0.08844599, + -0.009002514, + -0.114522785, + 0.08118862, + -0.03023919, + 0.007820294, + 0.043863248, + -0.043678157, + -0.036323708, + 0.006777855, + -0.019326974, + -0.0664114, + -0.019019991, + 0.073445216, + -0.039277073, + -0.0157583, + -0.01931436, + -0.027121417, + -0.028259363, + -0.107222356, + 0.11150329, + -0.012612926, + -0.025338905, + 0.029330198, + 0.011753977, + 0.009784897, + 0.042475123, + -0.004051051, + -0.014803267, + -0.04530689, + -0.01848677, + -0.050840423, + 0.01814009, + 0.0051442874, + -0.033988528, + 0.0033705293, + -0.05515113, + -0.023601055, + -0.06183089, + 0.012501645, + -0.08027637, + 0.022573682, + 0.079796925, + -0.00926268, + -0.02180816, + 0.0059841494, + -0.018863965, + -0.011257763, + 0.055679787, + -0.018714463, + -0.04081558, + -0.017017504, + 0.026006198, + -0.03687599, + -0.05399378, + 0.042955294, + 0.00079697353, + -0.0015601065, + 0.026138263, + -0.01198548, + 0.07594801, + -0.0049053924, + -0.001241132, + 0.022863775, + 0.025632044, + -0.023908222, + -0.02252925, + 0.042020634, + -0.060588334, + 0.05498828, + -0.03466166, + 0.003202133, + -0.015508297, + -0.021138275, + 0.007791096, + 0.052594397, + -0.08649948, + 0.038542755, + 0.011088168, + 0.049710445, + -0.015898548, + 0.013559725, + -0.0012927915, + -0.078937665, + -0.0470789, + 0.02421941, + 0.0050838543, + -0.051634457, + 0.014016644, + 0.059073824, + -0.01279741, + 0.006315097, + 0.028651753, + -0.023221422, + -0.049021006, + -0.08123552, + -0.027243393, + -0.026543872, + 0.040068373, + 0.01465917, + 0.01366034, + -0.07191417, + -0.007906117, + -0.06743931, + -0.040284913, + 0.046346053, + -0.015108051, + -0.067285545, + 0.020757562, + -0.03144588, + -0.02684228, + -0.030008601, + 0.0008360872, + -0.012667347, + -0.0782403, + 0.02436115, + -0.054881096, + -0.010856299, + -0.07653927, + -0.044655506, + -0.02075821, + 0.023765713, + 0.0083463555, + 0.026002545, + -0.003060633, + 0.060491852, + 0.032562606, + 0.029937308, + -0.022013078, + 0.07388013, + 0.017152807, + -0.07095613, + -0.03923808, + 0.0017680842, + 0.0038672008, + -0.053012144, + -0.016951663, + 0.027642388, + 0.016483316, + -0.015618807, + -0.11136081, + 0.006826955, + -0.010586094, + -0.05052998, + -0.04226535, + -0.031801827, + -0.020531418, + -0.06278464, + -0.062224947, + 0.0769673, + -0.0706861, + 0.026174366, + -0.041260213, + 0.058052614, + -0.046227556, + -0.05443509, + 0.007650712, + -0.061986744, + -0.00546975, + -0.042977307, + -0.0147894155, + 0.045748055, + -0.01602859, + 0.018538997, + 0.073324144, + -0.105757244, + -0.010215157, + 0.0069961487, + -0.010474333, + 0.007267861, + -0.043416463, + 0.04171331, + 0.012246647, + -0.024870023, + 0.0067938967, + 0.023995718, + 0.037606664, + -0.034879085, + 0.107255146, + 0.019311333, + 0.008084773, + 0.015113109, + 0.04807634, + -0.011898967, + 0.0028230203, + 0.004201883, + -0.019952193, + -0.083809994, + 0.025964422, + 0.010652608, + 0.021981532, + -0.029947964, + 0.10096241, + -0.0018155909, + -0.078443065, + 0.035357803, + 0.030101022, + 0.08652985, + -0.020698488, + 0.06619985, + 0.011043828, + 0.022531942, + 0.059432585, + -0.08669654, + 0.023926888, + 0.006353244, + -0.046637908, + -0.072916985, + -0.04355625, + -0.010734682, + -0.06298886, + 0.11202974, + -0.008399903, + 0.04045217, + -0.049840588, + -0.051897135, + 0.04921834, + 0.018730633, + 0.07189677, + -0.020521715, + 0.10433443, + -0.0035553537, + 0.015335822, + -0.03326729, + -0.05246277, + -0.038786076, + 0.04000599, + -0.028919725, + -0.017996594, + -0.007428113, + -0.003258321, + 0.0127034895, + -0.0062633064, + 0.0007574967, + -0.060385525, + -0.018971093, + 0.062526286, + -0.025764955, + 0.05286283, + 0.043842334, + 0.044092383, + -0.037126385, + -0.018775577, + 0.007996275, + -0.00028039515, + -0.06591952, + 0.039109394, + 0.022268493, + 0.033030964, + 0.010780152, + 0.051087722, + -0.07398754, + 0.02156791, + -0.03391487, + 0.01900175, + -0.03438655, + -0.050286565, + -0.029407075, + 0.013486627, + 0.006069821, + 0.03566702, + -0.046612754, + 0.030740444, + -0.0637836, + 0.020758858, + 0.013579259, + 0.015677635, + 0.07067559, + -0.03354964, + -0.09833861, + -0.045598283, + 0.046094477, + -0.018735003, + 0.0013117951, + 0.020225674, + -0.025771514, + -0.011772435, + 0.020403381, + 0.048393097, + -0.001137191, + -0.008214463, + -0.024194324, + 0.012559411, + 0.028170707, + -0.038262583, + -0.010594243, + 0.008866333, + 0.02652175, + 0.010765866, + 0.02152175, + 0.007194773, + -0.021046689, + -0.047594506, + -0.05342931, + 0.044459403, + -0.00075621146, + 0.021768885, + 0.061362576, + 0.03243972, + 0.023200674, + 0.012056035, + -0.010374278, + -0.06796502, + -0.0056832493, + 0.048799623, + -0.035878677, + -0.020508701, + 0.03527651, + 0.096402384, + -0.027735645, + 0.11728837, + 0.022490505, + -0.08394513, + -0.010033967, + 0.024851669, + -0.019062884, + 0.00039440763, + -0.10133529, + 0.011722217, + -0.04434193, + -0.030069547, + 0.030103652, + -0.017366616, + 0.046203658, + -0.04393208, + -0.05095759, + -0.04554081, + -0.029142734, + 0.01689045, + 0.008356038, + -0.035321265, + -0.02382173, + -0.0015672153, + 0.06304823, + -0.008137697, + -0.014463008, + 0.045292154, + -0.06497864, + 0.015265712, + 0.008239593, + -0.08195689, + 0.037012544, + 0.04680898, + 0.007484248, + 0.02335733, + -0.06787198, + -0.062197443, + -0.06841327, + -0.039720036, + -0.0105394935, + -0.057220835, + -0.039479975, + 0.029730098, + 0.0697698, + 0.0280752, + 0.0137115335, + -0.0045632124, + -0.01313052, + 0.07553262, + -0.04117193, + -0.14872926, + 0.028015105, + -0.047134113, + -0.016151398, + -0.081647106, + -0.02221662, + -0.036281105, + -0.023036504, + 0.0612415, + -0.018361837, + -0.0238258, + -0.0022532772, + 0.1537845, + 0.006872191, + -0.044352733, + -0.0026320857, + -0.08600976, + 0.005572628, + 0.053448226, + -0.015072955, + -0.029777542, + -0.019132927, + 0.053970527, + 0.005238485, + -0.02418231, + -0.12369688, + 0.0014781327, + 0.059662092, + -0.011181213, + 0.01400666, + 0.023866476, + -0.059490796, + -0.054530527, + -0.011234197, + 0.013823349, + -0.012150345, + -0.09948839, + 0.023659766, + 0.014326883, + -0.02229736, + -0.0024076505, + -0.10091382, + 0.08174192, + -0.024408998, + -0.023222951, + 0.011201234, + 0.013236311, + 0.04317295, + 0.051764306, + 0.07648576, + -0.00061111146, + -0.088623054, + -0.037177067, + 0.038964123, + -0.029959839, + 0.033466227, + -0.08635276, + 0.04128183, + -0.020397836, + 0.056285754, + -0.02570748, + 0.05911732, + 0.0061064134, + -0.01733281, + -0.0875996, + -0.0127257295, + -0.013593507, + -0.04925175, + 0.01888016, + -0.032455195, + -0.023753202, + 0.052025676, + 0.06000905, + 0.04137704, + 0.004952635, + -0.02542677, + 0.00017748028, + -0.041987997, + 0.04760188, + 0.068178274, + -0.060950078, + -0.05742421, + 0.054274186, + -0.048096504, + 0.034568857, + 0.0012921172, + 0.0705816, + -0.014679933, + -0.001761971, + -0.029119784, + 0.008006632, + 0.018063113, + -0.05880496, + -0.052486468, + 0.010976936, + 0.03688557, + 0.061141517, + -0.009467033, + -0.035062946, + -0.06794524, + -0.0609979, + 0.015924038, + -0.03805085, + 0.03977454, + -0.015656536, + 0.014254484, + -0.030620195, + -0.038830906, + -0.013730216, + -0.070247106, + -0.074514836, + 0.037831023, + 0.027780455, + 0.0073002693, + -0.050368425, + 0.040389538, + 0.035920046, + 0.025425838, + 0.006255748, + -0.017454483, + -0.02307413, + 0.05788845, + 0.018672187, + 0.033335716, + 0.01855402, + 0.07957198, + -0.0029801806, + -0.057038378, + 0.010123766, + 0.038190138, + 0.0333764, + 0.075057626, + 0.00592374, + 0.06380629, + -0.028154025, + 0.07188246, + -0.056649268, + -0.019166004, + 0.053392358, + 0.13961181, + -0.08459373, + 0.03255955 + ], + "index": 0, + "object": "embedding" + } + ], + "model": "togethercomputer/m2-bert-80M-32k-retrieval", + "object": "list", + "usage": null + } + }, + "is_streaming": false + } +} diff --git a/tests/integration/recordings/responses/0c1f45455d3b.json b/tests/integration/recordings/responses/0c1f45455d3b.json new file mode 100644 index 000000000..e1d3c44c4 --- /dev/null +++ b/tests/integration/recordings/responses/0c1f45455d3b.json @@ -0,0 +1,59 @@ +{ + "request": { + "method": "POST", + "url": "https://api.together.xyz/v1/v1/chat/completions", + "headers": {}, + "body": { + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "messages": [ + { + "role": "user", + "content": "Hello, world!" + } + ], + "stream": false + }, + "endpoint": "/v1/chat/completions", + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free" + }, + "response": { + "body": { + "__type__": "openai.types.chat.chat_completion.ChatCompletion", + "__data__": { + "id": "oBUtgGr-4Yz4kd-9801a2f00b2b42e8", + "choices": [ + { + "finish_reason": "stop", + "index": 0, + "logprobs": null, + "message": { + "content": "Hello! It's nice to meet you. Is there something I can help you with or would you like to chat?", + "refusal": null, + "role": "assistant", + "annotations": null, + "audio": null, + "function_call": null, + "tool_calls": [] + }, + "seed": 1098425109146507500 + } + ], + "created": 1758039052, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion", + "service_tier": null, + "system_fingerprint": null, + "usage": { + "completion_tokens": 25, + "prompt_tokens": 39, + "total_tokens": 64, + "completion_tokens_details": null, + "prompt_tokens_details": null, + "cached_tokens": 0 + }, + "prompt": [] + } + }, + "is_streaming": false + } +} diff --git a/tests/integration/recordings/responses/17030e75309f.json b/tests/integration/recordings/responses/17030e75309f.json new file mode 100644 index 000000000..4b77b3d3d --- /dev/null +++ b/tests/integration/recordings/responses/17030e75309f.json @@ -0,0 +1,800 @@ +{ + "request": { + "method": "POST", + "url": "https://api.together.xyz/v1/v1/embeddings", + "headers": {}, + "body": { + "model": "togethercomputer/m2-bert-80M-32k-retrieval", + "input": "This is completely different content" + }, + "endpoint": "/v1/embeddings", + "model": "togethercomputer/m2-bert-80M-32k-retrieval" + }, + "response": { + "body": { + "__type__": "openai.types.create_embedding_response.CreateEmbeddingResponse", + "__data__": { + "data": [ + { + "embedding": [ + 0.020581583, + 0.03996682, + 0.06342483, + -0.046694994, + -0.07684763, + -0.05265455, + -0.053058416, + -0.008007386, + -0.04512141, + 0.03718547, + -0.026790882, + 0.039592147, + 0.08868821, + -0.054975007, + 0.022950895, + -0.03249339, + 0.05376096, + 0.04878751, + 0.06144113, + 0.08925032, + -0.06345507, + -0.0008829904, + 0.07914291, + -0.028592229, + -0.048433058, + -0.0351529, + 0.028880889, + -0.08001268, + -0.04552556, + -0.080687605, + 0.1400234, + 0.14326853, + 0.02891313, + -0.05588759, + 0.007262874, + 0.026984219, + 0.09121335, + 0.050748702, + 0.017702162, + -0.035733465, + 0.1328057, + -0.08973662, + -0.050988093, + -0.009071953, + 0.00674055, + 0.0138731655, + -0.024637444, + -0.0019375099, + 0.019351467, + 0.041681487, + 0.09368255, + 0.0052818935, + 0.027539922, + -0.031472813, + 0.042352878, + 0.07326235, + 0.010973438, + 0.06776053, + 0.06473745, + 0.031266563, + 0.00057834754, + -0.002110916, + 0.16004054, + -0.0535361, + 0.04453045, + 0.050499436, + 0.03501775, + -0.003733677, + 0.020598825, + -0.079224035, + 0.07070447, + -0.060201976, + 0.006393084, + -0.003781692, + 0.070510566, + -0.047214407, + 0.06080987, + -0.0877733, + -0.08569845, + -0.018021964, + 0.06378409, + 0.027565937, + 0.038700324, + -0.1248613, + 0.00903349, + -0.08429076, + 0.016536232, + 0.025240825, + 0.00043874417, + -0.004602262, + 0.0457946, + -0.03598806, + 0.056914188, + 0.044693712, + 0.011178773, + -0.020428436, + 0.036093723, + 0.031189999, + 0.07220326, + -0.066868156, + -0.020061923, + -0.0563857, + -0.013928966, + -0.034524415, + 0.0041604545, + -0.047119446, + 0.033624567, + 0.06970587, + -0.033320673, + -0.0413748, + 0.01094969, + -0.0100499755, + 0.004480598, + 0.02067311, + -0.021157527, + 0.022485765, + 0.03633523, + 0.0049809627, + 0.02181411, + 0.049156368, + 0.06253565, + 0.059981186, + -0.031591866, + -0.049331754, + 0.033537455, + 0.021542493, + 0.009435254, + 0.025516914, + 0.025417773, + -0.07066102, + 0.011794456, + 0.06311989, + 0.011093616, + 0.08549021, + -0.04281618, + 0.011115061, + 0.07443118, + 0.021961706, + -0.02724888, + -0.00047235374, + 0.016601468, + 0.043411057, + 0.03835865, + 0.01029931, + 0.008437206, + -0.057274926, + -0.045377273, + -0.09733081, + -0.009755395, + 0.028172465, + 0.043972567, + 0.0968819, + 0.052496422, + 0.031553026, + -0.019291716, + 0.034150966, + 0.1310106, + 0.02864821, + -0.047452684, + 0.016342362, + -0.06591784, + -0.064888336, + -0.03380424, + -0.08384223, + 0.023302404, + -0.020427782, + 0.019540966, + 0.02240307, + 0.026848866, + -0.0018868797, + -0.031800512, + -0.073483676, + 0.08840526, + -0.02696041, + -0.042041607, + 0.030633071, + 0.020918656, + 0.06119309, + -0.048348967, + 0.036555305, + 0.033583682, + 0.019630525, + -0.03500669, + -0.020821452, + 0.012256841, + 0.06733756, + 0.036884613, + -0.080063485, + 0.019956889, + -0.01994667, + 0.0011630546, + -0.08307688, + -0.040326167, + -0.03293244, + -0.014897417, + 0.03977495, + 0.036790676, + 0.020645684, + 0.015943283, + -0.05961047, + 0.036905374, + 0.006005009, + 0.033375766, + -0.015491932, + -0.07008363, + -0.031575754, + -0.0065630106, + -0.013962699, + -0.012629252, + 0.046026245, + 0.007901817, + -0.117550366, + -0.06314231, + 0.05348636, + 0.10863247, + 0.053361807, + 0.055756297, + -0.026388792, + -0.011777907, + -0.07197253, + 0.010918023, + 0.020021347, + 0.14850953, + -0.043404948, + -0.04262303, + -0.04904758, + -0.014644666, + -0.0018742547, + -0.0054880613, + -0.015058903, + -0.03137978, + -0.09884002, + 0.048087206, + -0.00044948232, + -0.059237186, + 0.01681299, + 0.06357592, + 0.09665662, + -0.032431144, + -0.021346267, + -0.03630939, + 0.108024776, + 0.011421504, + 0.00090062595, + 0.09738569, + 0.07588425, + -0.038476508, + 0.008637763, + 0.03942589, + 0.03673421, + -0.008536316, + -0.035427485, + -0.0571462, + 0.077514425, + -0.014574157, + -0.06636753, + 0.0356625, + 0.00055575924, + -0.008948914, + 0.00082343427, + 0.0511982, + 0.03143358, + -0.03388075, + -0.013724427, + 0.0551338, + -0.007191376, + -0.05363105, + -0.07718383, + -0.008230843, + 0.10335533, + 0.013668598, + -0.08284561, + 0.05179483, + -0.08437943, + -0.017510848, + -0.05778264, + 0.044004828, + -0.02612715, + -0.0058190715, + 0.013293448, + -0.005663543, + 0.0037016177, + -0.020699238, + 0.00277368, + 0.041328322, + -0.052624915, + 0.020320976, + 0.0033441507, + -0.11465616, + -0.059619453, + -0.029252917, + 0.014145012, + -0.049234822, + 0.025969574, + 0.04118447, + 0.017938918, + -0.009885965, + 0.012801603, + -0.0007332413, + -0.0012993023, + -0.052635074, + 0.064850755, + 0.004576457, + -0.018446025, + -0.069130346, + 0.018532049, + 0.006330208, + 0.039377607, + 0.11237417, + 0.055357743, + -0.0038629018, + 0.048188694, + 0.052925084, + -0.011272187, + -0.012422014, + 0.005874242, + -0.0007749841, + -0.058404274, + -0.022589723, + 0.031956926, + 0.0470711, + 0.027993023, + -0.06112344, + -0.0119517995, + -0.09797626, + -0.073644884, + 0.07465703, + 0.09884925, + -0.035564825, + -0.040369682, + 0.014445328, + -0.052219898, + -0.027498178, + 0.036846854, + -0.09408649, + -0.00027856976, + 0.028489627, + 0.002446708, + -0.043065134, + -0.030562297, + 0.07565528, + -0.0256914, + -0.12143018, + 0.09360902, + 0.015026368, + 0.058814585, + -0.01885037, + 0.04901136, + 0.009521308, + -0.0067844316, + -0.06265128, + 0.029733902, + 0.019703392, + -0.029863501, + 0.033668272, + -0.015967827, + -0.024716265, + 0.07095029, + 0.07264489, + -0.021480447, + -0.040650267, + -0.11752601, + 0.019378915, + -0.042310815, + 0.05690114, + -0.01413233, + 0.058113046, + -0.073345415, + -0.059576523, + -0.09720947, + 0.012149926, + 0.057291746, + -0.03505685, + -0.038375836, + 0.0149342865, + -0.001562935, + -0.023513826, + 0.00014910847, + 0.022598296, + -0.071317434, + -0.06260575, + 4.0522777e-05, + -0.086758316, + -0.013101295, + -0.02990748, + -0.08461068, + 0.016139807, + 0.06101953, + -0.08451055, + -0.046145856, + -0.048467644, + 0.060105037, + 0.024200678, + 0.052542347, + 0.041119967, + -0.0068898834, + 0.09487794, + 0.012641435, + -0.13026047, + 0.06284531, + 0.018659385, + -0.07564698, + 0.006965884, + -0.036618453, + 0.118192144, + -0.04771263, + 0.023280941, + 0.054039616, + -0.114724584, + -0.0918062, + 0.038803104, + -0.09954885, + 0.008216844, + -0.030975524, + -0.030176945, + 0.0397766, + -0.0061745024, + 0.071971394, + -0.041089423, + 0.033857126, + 0.03961017, + -0.03826589, + 0.038435444, + -0.0860421, + 0.08869605, + -0.028628873, + -0.05565758, + 0.056920726, + 0.020458337, + 0.05994542, + 0.08241441, + 0.0400861, + -0.0045191804, + 0.0030094406, + -0.007466077, + -0.02953672, + -0.068642505, + 0.060889505, + -0.029501854, + -0.048823155, + 0.015409609, + 0.018862283, + -0.016425489, + -0.087497436, + 0.067643866, + -0.033761434, + -0.054749027, + -0.03657711, + 0.038102675, + -0.06197178, + 0.045409728, + -0.02127562, + 0.064449035, + -0.0056471447, + 0.067553245, + -0.07137091, + 0.017407946, + -0.09813906, + -0.046500444, + -0.058283363, + -0.018302118, + -0.025382183, + -0.04259567, + 0.022398086, + -0.09098867, + 0.043438766, + -0.07656342, + 0.0028111413, + 0.030880956, + -0.07750997, + 0.07084878, + 0.05344556, + 0.0052658613, + -0.025303314, + -0.04759683, + -0.017034022, + 0.02855913, + -0.04999449, + 0.01974624, + 0.07708244, + -0.011766297, + 0.057390995, + -0.04652422, + 0.023833811, + 0.05608237, + 0.05765577, + 0.05078112, + 0.046039928, + -0.055372067, + -0.044933185, + -0.08522771, + -0.09142792, + 0.012817157, + -0.026148932, + -0.07331254, + 0.11312438, + 0.055893615, + -0.013500698, + 0.008603385, + 0.00057156937, + -0.091709465, + 0.08057745, + -0.011340835, + -0.016915537, + 0.0011427286, + 0.09740327, + -0.029696029, + -0.047760956, + 0.015541391, + 0.0955123, + 0.021890407, + -0.02908531, + 0.030994056, + 0.03820344, + -0.062488347, + 0.015730608, + 0.021182666, + -0.043783836, + 0.02782434, + 0.11151618, + 0.052450567, + 0.00037089732, + 0.03351987, + -0.0054050605, + -0.033424556, + 0.10350312, + 0.065157756, + 0.03392563, + 0.010131469, + -0.053846426, + -0.0022781377, + 0.0014610494, + 0.005763698, + 0.0426489, + -0.08206464, + -0.07099776, + -0.04228286, + 0.07337842, + 0.047744617, + 0.04284143, + 0.06959166, + 0.013133698, + -0.030711556, + 0.009055728, + 0.06162162, + 0.017240932, + -0.039795205, + -0.10877084, + 0.024329182, + -0.0049141976, + -0.038892467, + -0.012901915, + -0.095080145, + 0.05290344, + 0.021141307, + 0.03017632, + -0.0044154925, + -0.10163907, + -0.08186605, + -0.023801327, + 0.035552323, + 0.039041802, + -0.032427292, + 0.07541, + 0.10233232, + 0.018622704, + -0.013646388, + -0.008619573, + 0.020216271, + -0.07897946, + 0.063637026, + -0.08652915, + -0.0100032855, + 0.046902858, + 0.076707095, + 0.02531022, + 0.05425257, + 0.015954422, + -0.033368777, + -0.025112148, + -0.01394599, + -0.04062625, + 0.056534503, + -0.04304168, + -0.060214523, + 0.016551849, + -0.006314451, + 0.060458317, + 0.027808908, + 0.040655438, + -0.031415448, + -0.120496035, + -0.04355332, + 0.002170874, + 0.013876282, + -0.011508199, + -0.046841078, + 0.076444104, + 0.08982719, + 0.0846208, + 0.029678846, + -0.086331986, + 0.14421903, + -0.0030989156, + 0.01598773, + 0.059804816, + -0.0464971, + -0.0058899643, + 0.02542227, + -0.020552263, + 0.10621325, + -0.023809364, + -0.13324538, + -0.075492345, + 0.06716611, + -0.040477127, + -0.046582364, + -0.07376809, + 0.024235222, + 0.070477486, + 0.11006968, + -0.04869493, + 0.078016356, + -0.07615679, + 0.08063025, + -0.016255612, + -0.051746953, + 0.08059405, + -0.0025989392, + -0.073428795, + -0.03987752, + 0.098251894, + -0.006217126, + -0.028130062, + -0.051326722, + -0.0470711, + -0.016759045, + -0.039230157, + -0.020525763, + 0.07148479, + -0.05419997, + -0.025775867, + 0.0070432695, + -0.006410803, + 0.027631486, + 0.037966132, + -0.025654731, + -0.023324372, + 0.026257442, + -0.034822363, + -0.010826962, + 0.020623349, + 0.0523646, + -0.022230538, + 0.028196862, + 0.023292363, + 0.12025986, + -0.022648653, + -0.061013527, + -0.040045265, + 0.022293845, + -0.016287014, + -0.08896512, + -0.021426601, + 0.05109808, + 0.038455352, + 0.055882193, + 0.10342665, + 0.06503611, + 0.07195616, + -0.013601524, + 0.028618002, + 0.03990776, + 0.03236452, + 0.07085622, + 0.0055737793, + 0.013130723, + -0.066394895, + 0.021342268, + 0.0026651763, + -0.012577644, + 0.049445108, + 0.049437333, + 0.0047207237, + -0.02006381, + 0.02022424, + 0.05142978, + 0.01725655, + 0.00037797724, + 0.039846063, + -0.11509461, + -0.013602717, + -0.066661686, + -0.020612884, + 0.012832718, + -0.091352694, + -0.09389515, + 0.07369748, + 0.056452867, + 0.10581744, + -0.06383743, + 0.036662158, + -0.07204409, + 0.012689036, + -0.025724197, + 0.040817674, + -0.06890574, + 0.0055584335, + 0.031956017, + 0.0014588524, + 0.098465145, + 0.0054196557, + 0.056656968, + 0.03322914, + -0.040962957, + -0.015689995, + -0.034545593, + -0.052660752, + -0.044768244, + -0.04419147, + -0.11039146, + 0.015522225, + 0.0052053384, + -0.08471112, + 0.025280464, + -0.03353502, + -0.018717872, + -0.020738749, + 0.0021664763, + -0.011238148, + 0.02322494, + 0.010894536, + -0.09676859, + 0.01013113, + 0.0035604087, + -0.0060942546, + -0.027839229, + -0.0037214137, + 0.053193003, + -0.070640355, + -0.07783396, + 0.005814805, + 0.0064411093, + -0.023913933, + 0.030543711, + -0.07979223, + -0.008982119, + 0.043360766, + -0.048063844, + 0.0017047173, + 0.06882568, + -0.03443207, + 0.015080402, + -0.049461022, + 0.045471057, + -0.031460688, + -0.0028212033, + 0.044725604, + 0.0026248703, + -0.0329393, + -0.034404054, + 0.024516258, + 0.002614168, + -0.047855787, + -0.03149, + 0.14646776, + -0.047660008, + 0.021453902 + ], + "index": 0, + "object": "embedding" + } + ], + "model": "togethercomputer/m2-bert-80M-32k-retrieval", + "object": "list", + "usage": null + } + }, + "is_streaming": false + } +} diff --git a/tests/integration/recordings/responses/432a346b2ed8.json b/tests/integration/recordings/responses/432a346b2ed8.json new file mode 100644 index 000000000..3ae45b379 --- /dev/null +++ b/tests/integration/recordings/responses/432a346b2ed8.json @@ -0,0 +1,2352 @@ +{ + "request": { + "method": "POST", + "url": "https://api.together.xyz/v1/v1/embeddings", + "headers": {}, + "body": { + "model": "togethercomputer/m2-bert-80M-32k-retrieval", + "input": [ + "Hello, world!", + "How are you today?", + "This is a test." + ] + }, + "endpoint": "/v1/embeddings", + "model": "togethercomputer/m2-bert-80M-32k-retrieval" + }, + "response": { + "body": { + "__type__": "openai.types.create_embedding_response.CreateEmbeddingResponse", + "__data__": { + "data": [ + { + "embedding": [ + -0.017041557, + -0.07436493, + 0.02897635, + -0.032216743, + 0.0056444216, + -0.029015187, + 0.06512343, + -0.040310342, + 0.05263593, + 0.0068842396, + 0.019191971, + -0.0064884443, + -0.01664521, + 0.014244285, + 0.036390014, + -0.040292, + 0.031780273, + 0.0039553884, + -0.055303488, + -0.028992416, + -0.02059435, + 0.05677091, + -0.043668333, + -0.014273451, + 0.15328151, + -0.023603301, + -0.049825363, + 0.007869072, + -0.010882995, + -0.033912696, + 0.053697765, + -0.00093928695, + 0.0017799847, + 0.038871024, + -0.069678165, + -0.067093275, + 0.025772842, + -0.057590123, + -0.015825877, + 0.020131286, + 0.020742312, + 0.003915491, + -0.018451879, + 0.020440312, + -0.023613403, + -0.039568678, + -0.013152008, + -0.01871725, + 0.021348018, + -0.019964654, + 0.038607903, + 0.018397795, + -0.0063561443, + -0.018936336, + -0.060981557, + -0.02152846, + 0.027057847, + 0.0014626224, + -0.018241309, + -0.07473041, + -0.02377323, + -0.033910733, + 0.02569418, + -0.024951216, + -0.0076659806, + -0.015425462, + 0.006604636, + 0.09833969, + -0.005054596, + 0.008841989, + -0.01836461, + -0.018554095, + 0.011605144, + -0.016599955, + -0.062196333, + -0.0037542647, + -0.025220644, + -0.027834827, + -0.020460974, + -0.050503097, + 0.032119684, + -0.023387104, + 0.050067227, + -0.05834235, + 0.023189448, + -0.021862485, + 0.023831544, + -0.016663097, + -0.041609522, + 0.025361128, + 0.002924296, + 0.01852158, + 0.08960255, + -0.003265466, + -0.058762494, + -0.06428431, + -0.014671485, + -0.046800107, + 0.02691456, + -0.0059303525, + -0.015431455, + 0.022179665, + 0.014044907, + 0.012218545, + 0.0053836405, + -0.025096457, + 0.009438382, + 0.032498095, + 0.06879721, + 0.056900814, + 0.019497631, + -0.122159146, + -0.106994465, + -0.017456975, + 0.047223866, + 0.06569824, + 0.04780035, + 0.018039258, + -0.0011028647, + -0.05067006, + 0.0106863845, + 0.027489506, + -0.014593985, + -0.039851535, + -0.09175489, + 0.037555773, + -0.060439512, + 0.008525801, + 0.0071557434, + -0.057973035, + -0.054225244, + 0.051505033, + -0.0008626373, + 0.069083415, + 0.064380065, + 0.09843996, + 0.0062191207, + -0.041505292, + -0.05381256, + -0.0073601264, + -0.03288613, + 0.011711341, + -0.09244605, + 0.0069717136, + -0.05722877, + 0.041075893, + 0.06521969, + -0.0018537377, + 0.016272636, + 0.008761483, + -0.029342752, + 0.020412564, + -0.07015791, + 0.033616304, + 0.039998446, + 0.01602917, + 0.044467725, + -0.08176377, + -0.036885373, + 0.03468746, + 0.0024068495, + 0.00056306267, + 0.02546511, + -0.053339135, + -0.027220095, + -0.021510394, + 0.054806393, + -0.005447777, + -0.05690438, + -0.028497366, + 0.01873974, + -0.035461064, + -0.00019089226, + -0.04914238, + 0.030303763, + 0.013396073, + 0.015789565, + -0.07714792, + -0.062155712, + -0.00677417, + 0.02850476, + 0.031491462, + 0.014566345, + 0.012163924, + 0.11814501, + -0.0043511004, + -0.017920421, + 0.004205825, + -0.0015928322, + -0.012145554, + 0.01663168, + -0.071173735, + 0.0029570858, + 0.12899451, + 0.004157568, + 0.010501232, + 0.07710632, + 0.062119417, + 0.021002673, + -0.023212241, + -0.04327007, + -0.0567023, + 0.04590105, + 0.0019161925, + 0.02637205, + 0.029331107, + -0.029769177, + -0.050466795, + -0.08057371, + 0.007419741, + -0.008777471, + 0.02217743, + 0.013535721, + 0.03426775, + 0.04592361, + 0.009423588, + -0.023030678, + -0.024462381, + 0.054334357, + 0.06710402, + 0.077300854, + 0.0300022, + -0.0035417816, + -0.0046773576, + -0.0927158, + -0.0218652, + -0.043468982, + -0.035734102, + -0.038873542, + -0.0412869, + -0.016015923, + 0.0038303286, + 0.08523618, + -0.05200533, + -0.014904317, + -0.016793448, + 0.04478206, + -0.017161047, + 0.02638292, + 0.007849463, + -0.040533304, + -0.017599737, + 0.047704253, + 0.034988616, + -0.013908102, + 0.044121094, + 0.040395457, + -0.010402818, + 0.0063570403, + -0.014962749, + 0.025776524, + 0.023681043, + 0.006042675, + 0.017647373, + 0.016301101, + -0.07793374, + -0.004771094, + 0.012728924, + -0.00047885205, + -0.051591527, + 0.03612118, + -0.02209703, + 0.052075963, + -0.021613466, + -0.026258182, + 0.008102769, + -0.04963262, + 0.00062747014, + -0.012579783, + 0.076374784, + -0.047350414, + -0.007680664, + 0.062471915, + -0.0061351187, + -0.043617643, + 0.023878522, + -0.09653609, + 0.018392054, + -0.039719462, + 0.065271765, + 0.034548305, + 0.004219043, + -0.003628092, + 0.0047836183, + 0.0132732885, + -0.028140727, + -0.015683327, + -0.052812085, + -0.019410037, + 0.06812139, + -0.041178964, + 0.014646207, + -0.0037439142, + 0.0003088275, + -0.04985693, + 0.0223661, + 0.008887433, + 0.0049061268, + 0.042707395, + -0.021471359, + -0.06471383, + 0.0022036259, + 0.030178884, + -0.002764245, + -0.0063233464, + -0.04146522, + -0.008236624, + 0.0037351896, + -0.027550086, + -0.0137326885, + 0.0055276263, + 0.0016785853, + 0.050191414, + 0.02629574, + -0.009129228, + 0.06351977, + -0.037435655, + 0.0467174, + -0.012987377, + -0.007550927, + -0.004503205, + 0.010520655, + 0.064984836, + 0.009879768, + 0.055787366, + -0.042653065, + 0.024189176, + 0.0378726, + -0.032453574, + 0.043519154, + 0.020133087, + -0.055212636, + -0.016188117, + 0.03764466, + -0.022142444, + 0.11164031, + 0.019020407, + -0.008950892, + 0.0517199, + 0.0014494535, + 0.041113462, + -0.0912906, + -0.04723132, + 0.008548748, + 0.028231544, + 0.023689618, + -0.039103802, + -0.034011997, + -0.04731894, + 0.03309799, + -0.044572156, + -0.116778485, + -0.028786778, + 0.05798776, + 0.05287191, + -0.0039562676, + -0.08213019, + -0.01224603, + -0.012757768, + 0.035721667, + 0.012440343, + 0.0053813523, + -0.072770126, + 0.0066190604, + 0.038976185, + -0.037760906, + -0.0031381482, + -0.052277293, + -0.016870236, + -0.053451907, + -0.05629483, + -0.034493946, + -0.0048654405, + 0.022051724, + 0.028501945, + 0.025858566, + -0.023936177, + -0.098391004, + -0.030646492, + -0.049461726, + -0.00086931954, + 0.03593346, + 0.015843417, + -0.03276966, + 0.008957432, + -0.022735167, + -0.012159252, + 0.07607085, + -0.059834506, + 0.004478244, + 0.03439635, + 0.03683821, + 0.062883355, + 0.054430448, + -0.029807799, + 0.0032295138, + 0.08891875, + -0.026941199, + -0.00618463, + -0.022683868, + -0.024138795, + -0.036633875, + 0.02097464, + -0.003001584, + 0.020455033, + 0.043717608, + 0.06566654, + -0.029039463, + -0.0066977167, + -0.04504434, + 0.022257777, + 0.054422457, + 0.029796708, + 0.009008146, + 0.028205348, + 0.06255052, + -0.004475601, + 0.059329458, + -0.038065027, + -0.027933009, + -0.07060949, + 0.013978787, + -0.051300917, + 0.02945564, + -0.008552103, + -0.009436655, + 0.039747514, + -0.016741823, + 0.04740887, + 0.03521937, + -0.012574282, + -0.089222826, + -0.043515395, + -0.04158566, + 0.0016020355, + 0.02684753, + -0.019394692, + -0.02156877, + 0.06316388, + 0.01663444, + 0.015482924, + 0.047349654, + -0.028341234, + 0.013805591, + -0.010708488, + -0.07627738, + 0.08611209, + 0.0089956885, + 0.034438204, + 0.016312746, + -0.03412846, + 0.0770598, + -0.06790466, + 0.036359854, + 0.08038976, + 0.023465984, + -0.019832904, + -0.0011524013, + -0.03804293, + 0.04106918, + -0.028220456, + 0.032340813, + -0.030669356, + -0.004353358, + -0.019439798, + 0.0020563425, + 0.03015629, + -0.06430176, + 0.0034439075, + -0.045720384, + -0.06526568, + -0.0004192516, + -0.016580455, + -0.012596616, + 0.039126, + -0.04699455, + -0.008973794, + 0.015056125, + 0.018929023, + -0.07840811, + -0.014792519, + -0.0044317124, + 0.019588342, + 0.035912346, + -0.035739247, + 0.058755044, + -0.01856197, + 0.021155646, + -0.073580906, + -0.04310776, + -0.023147091, + -0.010232029, + 0.06352039, + 0.039570276, + 0.020424508, + 0.051613245, + 0.013395984, + -0.003908009, + -0.04643392, + 0.019592889, + -0.008484923, + 0.0031434586, + -0.046069775, + -0.01765311, + -0.041277196, + -0.070297986, + 0.012561737, + -0.003500738, + -0.01729488, + -0.0033254062, + 0.053035453, + -0.054218896, + -0.029708259, + -0.0047281524, + 0.019236762, + -0.12249525, + 0.03018237, + -0.028753102, + -0.031858314, + 0.0811298, + -0.005711499, + -0.057587985, + 0.014153141, + 0.0006705577, + -0.024263157, + 0.016729265, + -0.03195949, + -0.007259763, + -0.0035231581, + -0.03890975, + 0.011460382, + -0.06591321, + -0.023756726, + -0.023958001, + 0.030074941, + -0.0040949634, + -0.048368257, + -0.029692868, + 0.027246583, + -0.024747347, + 0.014442731, + -0.00832639, + -0.0002390868, + -0.013635633, + 0.0035843733, + 0.02354072, + -0.012829061, + -0.0060750768, + -0.044952527, + -0.05725624, + 0.031746052, + -0.024419094, + 0.032444403, + -0.029308707, + 0.034302235, + -0.022495607, + 0.015296428, + -0.0057196384, + -7.8588724e-05, + 0.060303975, + 0.06299601, + 0.028222265, + -0.0071411408, + 0.015196491, + 0.02031155, + 0.039635558, + 0.079736926, + 0.008736669, + -0.023079613, + -0.04490686, + -0.021764707, + -0.015199573, + 0.036019534, + -0.0046079857, + 0.04429082, + -0.04291344, + -0.05991891, + -0.006501417, + 0.010603077, + 0.03435066, + -0.065568395, + -0.04424192, + 0.035055783, + 0.019717937, + 0.032764338, + 0.021240309, + -0.01646063, + 0.007835414, + 0.06857148, + -0.013750999, + 0.028333688, + -0.078255735, + -0.047899257, + -0.0006370693, + 0.012606231, + 0.012178417, + -0.013057751, + -0.008095854, + -0.013466724, + 0.019036459, + -0.025450038, + 0.021131655, + -0.02505666, + 0.012961284, + 0.0004236046, + -0.023920864, + -0.055114083, + 0.082351916, + 0.028973032, + 0.025259241, + 0.098259576, + -0.007385416, + 0.003546012, + -0.05316339, + -0.04186183, + 0.043638214, + -0.069299474, + -0.013284585, + -0.010019175, + 0.012883975, + 0.014200739, + -0.013508286, + 0.0086570075, + -0.020393575, + 0.10617594, + 0.028786503, + -0.018674662, + 0.026763268, + -0.0062548965, + -0.07215284, + 0.055464335, + 0.0029595464, + -0.009364344, + -0.096402094, + 0.02823341, + -0.022853011, + 0.04750492, + 0.008378555, + 0.016491622, + 0.01860681, + 0.048116222, + 0.106049344, + -0.028929656, + -0.008896546, + 0.033615295, + -0.0070807124, + -0.05684197, + -0.061439563, + 0.0060220268, + 0.046171866, + -0.01574131, + -0.07562956, + 0.0024098414, + 0.0006304895, + -0.07831614, + 0.060869616, + 0.00076000375, + -0.008209363, + -0.04139266, + -0.085268535, + -0.028194478, + -0.024567788, + -0.04218179, + 0.023546752, + 0.036236234, + 0.017199656, + -0.03315456, + -0.023814544, + 0.038755447, + -0.023165299, + -0.049283065, + -0.006907019, + 0.040826146, + 0.017533792, + -0.036849793, + -0.015506943, + -0.010768763, + -0.08758806, + -0.0295733, + 0.055843282, + -0.012555046, + 0.0076235603, + 0.008802991, + 0.026661193, + -0.023899797, + 0.043548774, + -0.034339137, + -0.027354732, + -0.07583677, + 0.020500224, + 0.036802996, + 0.031019075, + 0.04605757, + -0.004433706, + 0.0108612785, + 0.050121468, + -0.07816735, + -0.014776514, + -0.04565195, + -0.0036854912, + 0.0075577567, + -0.017044865, + 0.030597543, + -0.013623054, + -0.0648466, + -0.0318741, + -0.059455115, + -0.024783187, + -0.0088010235, + 0.11127796, + 0.03429834, + -0.010424589, + -0.06355135, + 0.034265812, + 0.02680333, + -0.007930513, + 0.030092249, + 0.008321974, + 0.03125566, + -0.06832331, + -0.0076806936, + 0.034010306, + -0.087202646, + -0.047684345, + 0.06384632, + -0.026591811, + -0.0016003181, + 0.05721666, + -0.0024700803, + -0.029714238, + 0.07761957, + -0.04561395, + -0.053199258, + 0.030417573, + -0.01958724, + 0.0012449475, + -0.04003076, + 0.08825553, + -0.023196172, + -0.08629044, + -0.049815316, + 0.027229005, + 0.0021765123, + 0.03438692, + -0.09314263, + -0.019655729, + 0.018762926, + 0.025670087, + -0.017116003, + 0.031716976, + -0.05509443, + 0.032953184, + -0.02264915, + 0.04861606, + -0.050201602, + 0.033154316, + 0.009971947, + -0.037610047, + 0.016600395, + -0.031037569, + -0.015495428, + 0.026365642, + -0.043527953, + 0.055781424, + 0.06780075, + -0.015966192, + 0.03201043, + 0.028026119 + ], + "index": 0, + "object": "embedding" + }, + { + "embedding": [ + -0.050693978, + -0.010858309, + 0.020310253, + -0.01049692, + 0.029866666, + -0.025998075, + 0.07918496, + -0.042496245, + -0.028718667, + -0.027305981, + -0.02330032, + -0.021886542, + -0.027306426, + 0.061016064, + 0.012688038, + 0.022281228, + -0.054594085, + 0.07765493, + 0.05386447, + 0.03140333, + -9.44268e-06, + -0.0011356915, + 0.022630688, + -0.014110621, + 0.030000638, + 0.007599051, + -0.06352133, + 0.053137243, + -0.056568034, + 0.057547573, + 0.0030512416, + 0.03837667, + 0.04789846, + 0.038161233, + -0.02627195, + -0.050061185, + 0.10019976, + 0.038518198, + 0.010254856, + 0.10148112, + 0.04869421, + -0.0073997034, + 0.05293147, + -0.034767445, + 0.07249512, + 0.05695461, + -0.03786103, + 0.007449489, + 0.020537589, + 0.000312089, + 0.016584814, + 0.001918721, + 0.05273067, + 0.027494889, + 0.0637688, + -0.06113676, + 0.041710924, + 0.039151315, + 0.045457218, + -0.042557742, + -0.03437774, + -0.03965357, + 0.035107236, + -0.030944545, + 0.018480912, + 0.016318278, + 0.010664849, + 0.06706701, + 0.028976813, + 0.04934793, + 0.01920518, + -0.022590633, + 0.05794299, + -0.014218797, + -0.10727855, + -0.04222983, + 0.014688315, + -0.009868972, + -0.030892346, + 0.024784064, + -0.01335315, + -0.030918332, + -0.022723109, + 0.018553259, + -0.030180262, + -0.0072358795, + 0.04466348, + 0.0028644707, + -0.08218491, + -0.035578046, + 0.034649692, + 0.014995248, + -0.034041993, + -0.01754551, + 0.012509432, + -0.12817404, + 0.022282014, + 0.038324747, + -0.007946491, + -0.10563139, + -0.0018780051, + -0.010040646, + 0.051342048, + -0.031782173, + 0.026881691, + -0.0070015015, + 0.1403214, + -0.0383665, + 0.13297008, + 0.01473871, + 0.0035459534, + -0.05397022, + 0.0027416502, + -0.008002018, + -0.05214072, + 0.046578355, + -0.06554441, + -0.01918899, + -0.044716686, + 0.016660467, + 0.0074168034, + 0.043397274, + 0.041952852, + -0.020719659, + 0.044949867, + 0.08868983, + -0.06033043, + -0.06299611, + -0.0299354, + -0.06335069, + -0.041603137, + 0.063161835, + 0.0053624725, + 0.04566859, + 0.01997067, + -0.08615492, + -0.00461124, + 0.039520558, + 0.040905517, + -0.035469536, + -0.04317211, + 0.011673073, + -0.06018417, + 0.0028443343, + -0.09747001, + -0.087689236, + 0.0004175659, + 0.07349427, + -0.002189792, + -0.023225918, + 0.031347603, + 0.003863699, + 0.03039125, + 0.0026322505, + -0.0044767857, + 0.037814893, + 0.013607858, + -0.04524581, + 0.006180776, + -0.025796989, + -0.0018575953, + 0.056745563, + -0.056899827, + -0.13912162, + 0.01923313, + -0.0072119716, + 0.03653831, + -0.03553157, + 0.008960138, + 0.01913016, + 0.041605312, + -0.030891325, + -0.050350275, + 0.017834349, + -0.06821085, + 0.024607243, + 0.016700145, + 0.06613456, + 0.048102804, + 0.06076021, + 0.006365906, + 0.009644411, + 0.044110093, + 0.04351857, + 0.06734216, + -0.0017035177, + -0.00439251, + -0.06284958, + -0.012278929, + -0.12074305, + -0.010177493, + -0.04965999, + 0.023366336, + -0.04580006, + 0.019479955, + -0.006699217, + 0.03502374, + 0.1611132, + -0.026563711, + 0.0025155211, + 0.018676694, + 0.0009814353, + -0.036826, + 0.017627593, + 0.07587332, + 0.006969805, + -0.051941425, + -0.06698752, + -0.006748652, + 0.026837183, + -0.0744657, + 0.011689156, + -0.01411786, + -0.031564586, + -0.07331578, + 0.001811603, + -0.017448701, + -0.0654881, + 0.00889219, + 0.056011263, + 0.054930564, + 0.027538713, + 0.010776839, + -0.009119489, + -0.034182906, + -0.07947322, + 0.010956856, + 0.0067299716, + -0.038189813, + -0.0017738482, + 0.0026462704, + -0.0539034, + -0.0066219224, + 0.00018278696, + 0.06491363, + 0.050116353, + 0.03692079, + 0.08176937, + 0.049276054, + -0.038431957, + 0.0041264175, + 0.0016263039, + 0.04835715, + 0.05372281, + -0.039015856, + -0.0035196007, + 0.022530695, + 0.055513002, + 0.030869612, + -0.008039368, + -0.013746457, + -0.045808554, + 0.021556988, + 0.0014481185, + 0.03700321, + 0.03712917, + 0.10185659, + -0.08633657, + 0.03425641, + 0.045996998, + -0.051326204, + -0.02598336, + 0.037188865, + 0.047904, + -0.016023936, + 0.051980697, + -0.036479976, + 0.10651916, + -0.008438165, + 0.04487357, + -0.0035620069, + -0.018047113, + 0.06171551, + 0.014961666, + -0.012419838, + -0.04932983, + -0.03162733, + 0.04412971, + 0.010965971, + 0.0099312, + -0.06457594, + -0.0020091454, + -0.012179282, + 0.011060499, + 0.013348316, + 0.0040744096, + -0.053495333, + -0.055626135, + -0.024634268, + 0.041642897, + -0.020521278, + 0.0077626, + -0.02442528, + 0.02345328, + -0.07039642, + 0.011572023, + -0.03946985, + -0.017554415, + -0.018510753, + -0.02628016, + 0.003842782, + -0.013968606, + 0.009930984, + -0.0019439043, + -0.001055162, + -0.024441715, + 0.002748, + 0.03797272, + -0.01796759, + 0.016857954, + -0.054101113, + 0.029492574, + 0.009648833, + 0.06267544, + 0.025378056, + 0.008614674, + 0.03406931, + 0.04041812, + 0.050837472, + 0.016481942, + -0.010224863, + -0.020784473, + -0.039759353, + 0.04798226, + 0.026257176, + -0.111021474, + 0.0015075838, + 0.07929549, + 0.029072981, + 0.03136461, + -0.09024568, + 0.03706794, + 0.00069653604, + 0.028990004, + 0.00158074, + -0.058231257, + -0.012032319, + -0.11285045, + 0.03993099, + 0.022554532, + 0.038430568, + -0.036563788, + -0.036297306, + 0.07201281, + 0.05026459, + -0.03646699, + -0.06714899, + -0.036391288, + 0.07507739, + 0.039017055, + 0.056063708, + -0.061854262, + 0.0077921483, + 0.026512198, + 0.0035518222, + -0.021420741, + -0.000929089, + 0.0051694694, + -0.054385625, + 0.015488236, + 0.0018151755, + 0.023275228, + -0.051910095, + 0.046563655, + -0.027084865, + -0.019521073, + 0.07038185, + -0.005629437, + 0.0104171075, + -0.025500813, + 0.012515233, + -0.018450025, + 0.0064471816, + -0.0822687, + 0.0514733, + -0.0007634487, + 0.041627247, + -0.016323347, + -0.0053568603, + 0.085863255, + 0.033773705, + -0.0048070354, + -0.0004412159, + -0.023257103, + 0.05561736, + 0.05207766, + 0.019670658, + 0.037812483, + -0.013077478, + -0.014929977, + 0.04772904, + 0.033561055, + -0.05835228, + 0.09368593, + -0.013790776, + 0.024843333, + 0.052117642, + 0.016168434, + -0.03309694, + -0.0332709, + 0.037880875, + -0.029704971, + 0.0103478255, + 0.0621371, + -0.00020507257, + 0.012393343, + -0.011916155, + 0.08173812, + -0.039204735, + -0.024686804, + 0.024316456, + 0.031949792, + 0.012687219, + 0.017169757, + -0.0016561806, + 0.017296743, + -0.005550947, + -0.04265122, + -0.0684987, + 0.06895011, + 0.016198147, + 0.12301288, + -0.027970051, + 0.07270332, + -0.0781321, + -0.023150189, + 0.019209703, + 0.050384432, + 0.063102365, + -0.1052462, + 0.013622426, + 0.024222417, + 0.07932484, + -0.044099297, + 0.05000115, + 0.01611413, + -0.066668235, + 0.03482801, + -0.03827191, + -0.016675064, + -0.008992525, + 0.01809865, + -0.0016681388, + 0.008033063, + -0.018875819, + 0.0005663335, + 0.044920616, + 0.076877005, + 0.06927666, + -0.05225116, + -0.032670625, + 0.067736275, + -0.027458396, + 0.04716389, + -0.02720322, + 0.013453853, + -0.038000166, + 0.04254829, + 0.02056911, + 0.07206648, + -0.032540064, + -0.0067454036, + -0.07023072, + 0.034042906, + -0.007585006, + -0.0068458025, + -0.019583486, + -0.079872504, + -0.04205456, + -0.09317277, + 0.008631627, + 0.029064497, + 0.055591475, + 0.049023792, + 0.017245598, + -0.027409904, + -0.008231064, + 0.05183169, + 0.088575125, + -0.00014200807, + -0.028889684, + 0.0103782285, + 0.031932928, + -0.0010171203, + 0.00889097, + 0.03915642, + -0.014465671, + 0.025092429, + -0.051718716, + -0.005562561, + 0.009389093, + -0.012151888, + 0.035728022, + -0.07083709, + 0.048586708, + -0.020331206, + 0.03032039, + -0.022218483, + -0.01604572, + -0.019281179, + -0.047274433, + 0.08225039, + -0.009769263, + -0.022123044, + -0.025783258, + 0.015255551, + 0.03588135, + 0.04413771, + -0.014886365, + -0.015528786, + -0.027134163, + -0.03344223, + -0.03906999, + -0.030708836, + 0.027987922, + -0.02679848, + -0.025790287, + 0.034544602, + -0.0015380334, + -0.011152637, + -0.033290375, + -0.06581815, + 0.06209049, + -0.012149317, + -0.06770575, + -0.029887203, + -0.021404674, + -0.048510525, + 0.020026335, + 0.021071516, + 0.01682142, + -0.12870917, + -0.012587804, + -0.04055468, + 0.047302578, + -0.037762202, + -0.046112824, + 0.010776369, + -0.014212859, + 0.02349173, + 0.09041585, + 1.565367e-05, + 0.07245511, + -0.033793304, + 0.035921212, + -0.02783346, + 0.0806998, + -0.010611987, + 0.041489985, + -0.017004602, + 0.024825959, + 0.0017323868, + 0.06234449, + 0.04331931, + 0.008339923, + 0.043990854, + 0.0060589914, + -0.022705998, + -0.020941943, + -0.00049144955, + 0.08638997, + 0.012002845, + 0.090267256, + 0.028547058, + -0.006239364, + 0.06821692, + 0.045356773, + 0.0515711, + -0.0023774423, + -0.0055029676, + -0.039530966, + -0.06231984, + 0.07199615, + -0.0736272, + 0.06531544, + 0.015005152, + 0.018980997, + 0.0010049999, + -0.01213177, + 0.05067269, + -0.026431412, + -0.039080206, + 0.051915344, + -0.018134514, + 0.008343715, + -0.038160358, + -0.033324458, + 0.0029796292, + -0.09010633, + -0.007604104, + -0.08881641, + -0.04259058, + -0.09903379, + -0.012423294, + 0.019745879, + -0.02834356, + 0.020667437, + -0.025804685, + 0.052014343, + 0.016800258, + -0.014739471, + -0.043742716, + 0.049421653, + 0.021032294, + -0.061259594, + -0.050550286, + 0.04592372, + 0.050988674, + 0.0491073, + -0.00096262776, + 0.08990844, + 0.037509143, + 0.028742973, + -0.118190385, + 0.010533227, + -0.03514427, + -0.08367883, + -0.013493585, + 0.02654289, + 0.014374991, + -0.039481364, + 0.1674116, + 0.07490431, + 0.058380052, + 0.027852368, + -0.061896965, + -0.022872766, + 0.047993485, + -0.065123655, + -0.07428092, + -0.041723747, + 0.080762535, + 0.010601916, + -0.035257086, + -0.047732975, + 6.712973e-05, + 0.05134923, + 0.050521225, + 0.025271116, + -0.0072390456, + 0.04151577, + 0.02572708, + -0.057142563, + -0.028259942, + 0.018771905, + -0.033247933, + -0.06304049, + 0.03697809, + -0.037529476, + 0.03391705, + 0.023996636, + -0.063727565, + -0.049316347, + -0.021822812, + -0.051387135, + 0.016310921, + 0.0016229213, + 0.006816926, + -0.028204253, + 0.027451735, + 0.024213102, + 0.07196294, + 0.00041893774, + -0.0096297115, + 0.049549352, + -0.06110793, + 0.0061441287, + -0.050353367, + -0.015283087, + -0.01888433, + -0.05886002, + 0.012889236, + 0.02860981, + 0.04765169, + -0.035136737, + 0.0049838605, + -0.064163454, + 0.051824152, + -0.01143845, + 0.007576831, + -0.018313015, + 0.012159296, + 0.034033798, + 0.020029843, + 0.019590652, + -0.010082555, + -0.022751726, + -0.0355381, + -0.038172133, + 0.12067669, + -0.075687334, + 0.01861976, + -0.031330068, + 0.026860299, + 0.006408792, + -0.0145417405, + 0.015177668, + -0.03025762, + 0.07643991, + 0.016266705, + -0.013141844, + -0.07231639, + 0.055646416, + -0.021509636, + -0.025625022, + -0.047063146, + -0.070508875, + -0.08632433, + -0.011631201, + -0.019939274, + -0.06350421, + -0.019870907, + 0.03216671, + 0.058062643, + 0.055208843, + -0.07156028, + 0.007989774, + 0.049972944, + 0.037406262, + -0.06293042, + -0.027840614, + -0.041593563, + -0.054527696, + 0.021761741, + 0.017650325, + -0.055453133, + -0.024841229, + 0.029395606, + -0.058559354, + 0.010116847, + -0.029088652, + 0.022447364, + 0.0079206675, + -0.015874255, + -0.0039944267, + -0.08912434, + -0.04124756, + 0.021253418, + -0.027858313, + -0.06234424, + -0.028922025, + -0.006749017, + -0.00204751, + 0.020167105, + -0.008826207, + -0.008012587, + -0.02876077, + 0.04325802, + -0.006442264, + 0.03814887, + -0.03429738, + 0.0058901254, + 0.02109685, + 0.01542989, + -0.06856703, + 0.037813462, + -0.007801844, + 0.038300894, + 0.03818303, + -0.06064273, + -0.03106093, + 0.017438883, + 0.0030734143, + 0.0013211939, + 0.017740646, + -0.030678462, + 0.02107452, + 0.061798688 + ], + "index": 1, + "object": "embedding" + }, + { + "embedding": [ + -0.02779177, + -0.007752902, + 0.00666607, + 0.007333073, + 0.027681155, + -0.04680753, + 0.034528963, + -0.050833542, + -0.055877283, + -0.075369135, + 0.018063514, + -0.0045533236, + -0.011292311, + 0.032624524, + -0.013017948, + -0.048883513, + -0.013815144, + 0.022201993, + -0.0025201102, + 0.03166489, + 0.06015168, + -0.0018540767, + 0.043800958, + 0.014623904, + 0.038353812, + -0.021314984, + 0.010522611, + -0.024581844, + 0.031366486, + 0.012493078, + -0.0007007419, + 0.009890471, + 0.05789071, + -0.05520709, + -0.02783322, + 0.018479174, + 0.0009625551, + -0.024165243, + 0.01635198, + 0.04199145, + 0.053655755, + -0.04307552, + 0.025551995, + -0.018680023, + 0.020759536, + 0.059369273, + -0.006988708, + -0.026320163, + -0.0025934891, + 0.026870603, + -0.009730706, + 0.018218627, + 0.005037782, + -0.0132323345, + -0.039169345, + -0.033258922, + -0.002247369, + 0.09466787, + 0.0056981854, + -0.022665996, + 0.06024469, + -0.016116608, + -0.003789675, + -0.025225416, + 0.019347968, + 0.024802739, + -0.049069185, + -0.012823434, + 0.000846098, + 0.018634543, + -0.060731795, + -0.03504043, + 0.085316636, + 0.013361458, + -0.012425992, + 0.0057458133, + -0.014212679, + 0.042268865, + -0.029114101, + -0.0011103856, + -0.044912685, + -0.028397746, + 0.021935457, + -0.027663197, + -0.11580737, + -0.055029213, + 0.05578334, + 0.0071452004, + -0.014473731, + -0.06328084, + 0.0140667, + -0.024593478, + 0.0046616863, + -0.007522579, + 0.025511945, + -0.07863747, + -0.0085762385, + 0.05148283, + -0.039227873, + -0.0816022, + -0.018585978, + -0.03510035, + 0.02342686, + -0.0042144833, + 0.029105023, + 0.00817719, + 0.10530593, + 0.056663927, + 0.051986016, + 0.0027708863, + -0.027644029, + -0.026126249, + 0.04316672, + 0.008625363, + -0.026928555, + 0.09236891, + -0.10665132, + 0.0022109712, + -0.04672772, + -0.0010714191, + 0.017687786, + 0.025763303, + 0.02738723, + -0.019653322, + -0.06636015, + 0.038601268, + -0.026597418, + -0.032743942, + -0.007986222, + -0.0077568023, + -0.021615017, + 0.014973637, + 0.036659174, + -0.002434029, + 0.056992944, + -0.0802926, + -0.034491055, + 0.057339218, + -0.031598423, + 0.01815245, + -0.05142944, + 0.09277832, + -0.023692241, + -0.02133611, + -0.024636442, + -0.06723946, + 0.026400885, + 0.08087762, + 0.0036785558, + 0.02101903, + -0.029615631, + -0.038861174, + 0.04874963, + 0.02979751, + 0.0060734656, + 0.05423366, + -0.030063542, + -0.004280309, + 0.05995971, + -0.042565927, + 0.0030267043, + 0.1041919, + 0.03300429, + -0.0050015924, + -0.01911076, + -0.026665272, + 0.016458593, + -0.050006777, + 0.05080731, + -0.065816425, + 0.026471464, + -0.027813306, + -0.036025744, + 0.03723687, + 0.018098509, + -0.044298846, + 0.024373472, + -0.016016398, + 0.03582579, + -0.026484434, + -0.0038789911, + 0.10619606, + 0.0022864433, + -0.014563999, + 0.004348137, + -0.013476688, + -0.0331399, + -0.07461764, + 0.032642554, + -0.014079754, + -0.007546746, + -0.04735429, + 0.028523289, + -0.025188936, + 0.0059138797, + 0.023881987, + 0.05757653, + 0.0380678, + 0.0012175398, + -0.02047756, + 0.0718534, + -0.04708265, + 0.023029216, + -0.027009143, + 0.087099396, + 0.0017206921, + 0.025318645, + -0.03911548, + -0.038268212, + 0.04721421, + -0.09048235, + 0.0018269889, + 0.03689738, + -0.0500337, + -0.0806958, + 0.015961647, + -0.0117793055, + -0.043277707, + 0.011102296, + 0.024736766, + 0.07859274, + -0.0010727937, + 0.014366967, + -0.07669862, + -0.007824215, + -0.07287751, + -0.016301835, + -0.003434503, + 0.019447176, + -0.051193517, + 0.08773244, + 0.006728499, + 0.052058756, + -0.039105475, + 0.052423023, + 0.015097122, + 0.009336027, + 0.022993218, + 0.031443782, + -0.0622707, + 0.03517323, + -0.033169843, + 0.097570434, + 0.010101814, + -0.062746756, + -0.032313753, + 0.039362427, + 0.12776423, + 0.019260308, + -0.050483607, + 0.036213342, + 0.0028129816, + 0.058977667, + -0.024792053, + -0.005835713, + 0.016384302, + 0.013303189, + -0.04755607, + -0.012990615, + 0.032058302, + -0.015489647, + -0.04008588, + 0.011562045, + 0.013523483, + -0.008329744, + 0.067591324, + -0.09078176, + 0.050933324, + -0.0001931563, + -0.01570064, + 0.0077628815, + -0.021175632, + 0.08191918, + 0.0042020655, + -0.057577576, + -0.024850775, + -0.016462047, + -0.01608794, + -0.0095810965, + 0.03440579, + -0.016924929, + -0.051613178, + -0.038862303, + -0.002591376, + -0.01687491, + -0.038348936, + -0.016345026, + -0.03499395, + -0.023711955, + -0.038983267, + 0.02909387, + 0.052785136, + -0.03956735, + 0.048813544, + -0.07408873, + -0.047479205, + -0.037384547, + 3.6122277e-05, + -0.00323103, + 0.014085068, + 0.02166948, + -0.025022797, + 0.00548469, + -0.00043267754, + 0.013587588, + -0.075237095, + -0.046044935, + 0.0037340645, + 0.015775705, + 0.0044056266, + -0.033436574, + 0.07790523, + 0.017369641, + 0.03162654, + 0.06311004, + 0.00030665845, + 0.02039911, + 0.030216057, + -0.0022921541, + -0.02669933, + -0.04271925, + -0.021516768, + -0.04860288, + 0.0037491426, + 0.044397604, + 0.013711982, + -0.0019044406, + 0.041717444, + 0.07527258, + 0.004396075, + -0.05697599, + 0.062371805, + 0.0122556435, + 0.018541628, + 0.013916607, + -0.001407872, + -0.074479096, + -0.0074305376, + 0.06843066, + -0.027167812, + 0.0020887114, + -0.03339334, + -0.069467865, + 0.027772086, + -0.029680463, + 0.0023603945, + -0.034341622, + -0.007946808, + 0.014316168, + 0.040272575, + -0.029381637, + -0.012669895, + -0.040007718, + -0.007849514, + 0.0037267352, + 0.025559353, + 0.01908747, + 0.010199893, + 0.02811712, + -0.015757034, + 0.023825217, + -0.050415065, + -0.028737074, + 0.03919414, + -0.0024481888, + -0.022511285, + 0.027958939, + 0.046735343, + 0.077127144, + 0.022440491, + 0.035965107, + -0.01409118, + 0.022490244, + -0.007463417, + 0.05943725, + 0.0740578, + -0.020744171, + -0.019496184, + -0.052855786, + -0.00028804876, + -0.05126455, + 0.015544, + 0.053731557, + -0.014565541, + 0.04822947, + -0.024476951, + 0.036131904, + -0.008535516, + 0.029941507, + 0.027597597, + 0.05004942, + -0.0634054, + -0.00058592664, + 0.075618185, + -0.06424452, + 0.0551141, + 0.07195737, + 0.0059559983, + -0.06548788, + 0.021463854, + 0.013003529, + -0.012621075, + 0.022944402, + 0.08323847, + 0.07705397, + 0.012239931, + -0.042122364, + 0.037349377, + -0.0023981212, + -0.018399907, + 0.047214046, + 0.0003528697, + 0.013069748, + 0.009889366, + -0.015569374, + 0.097634934, + -0.051274985, + -0.0035838345, + -0.081493884, + -0.034804776, + -0.068767905, + 0.06497728, + -0.04292809, + 0.009441323, + -0.050664015, + -0.026311554, + 0.043648314, + 0.05953572, + 0.02149848, + -0.070732236, + 0.032498803, + -0.01525829, + 0.025482485, + -0.07821578, + -0.0031100207, + 0.013336255, + 0.012977619, + 0.10831072, + -0.012108079, + 0.05215784, + -0.0014752754, + 0.04672664, + -0.006357827, + 0.03887902, + 0.0110858865, + 0.03910481, + 0.044483896, + 0.027306804, + 0.0304683, + -0.035071675, + 0.049174044, + -0.005893214, + -0.03226845, + 0.012989943, + -0.024567459, + 0.012174184, + -0.029126454, + 0.027247919, + 0.080386184, + 0.03994174, + -0.06301434, + -0.07710563, + -0.02356785, + -0.015658041, + -0.040340938, + 0.02344931, + -0.005036427, + -0.03987439, + 0.052536115, + -0.042034335, + -0.052926026, + 0.024309393, + -0.011847247, + -0.011882506, + -0.07358051, + -0.012023142, + 0.019672018, + 0.09082111, + 0.073102705, + -0.04581442, + -0.042871106, + -0.0347567, + 0.051297594, + 0.028319057, + -0.019270716, + -0.022108674, + 0.034829013, + -0.05005505, + -0.07417835, + 0.045196395, + 0.0032714135, + -0.07566778, + 0.048085734, + -0.005009543, + -0.0011667939, + -0.040728357, + -0.020352578, + -0.0021036982, + -0.037561715, + 0.018334854, + -0.048219055, + -0.005598004, + 0.052623373, + -0.046602413, + 0.00022030994, + 0.059313178, + 0.09316803, + 0.035902113, + -0.03455553, + -0.06944326, + 0.014147145, + -0.060626503, + -0.036259595, + -0.020195402, + 0.043234885, + -0.007683996, + 0.043373056, + 0.022036567, + 0.0020106016, + -0.035812076, + 0.063685834, + -0.03424115, + 0.06406924, + -0.0073639182, + -0.015726037, + -0.036662076, + -0.011314391, + -0.061053474, + -0.02398348, + -0.05477042, + -0.02349147, + -0.06840239, + -0.04402523, + 0.022536961, + 0.025341304, + -0.09786782, + 0.0008502628, + -0.054442905, + -0.023104902, + -0.0454393, + 0.05547487, + 0.02941837, + 0.042048343, + -0.06071158, + -0.011033424, + 0.0029785563, + 0.01214972, + 0.014557061, + 0.016386319, + -0.043748617, + -0.021092765, + -0.004604394, + 0.075954765, + 0.027810903, + -0.019764582, + -0.015932038, + 0.013924321, + -0.014167113, + -0.04632259, + -0.028052354, + 0.021453502, + -0.02792163, + 0.07461302, + 0.10187651, + 0.010440466, + 0.08697039, + 0.05600476, + -0.055770714, + -0.062498394, + -0.058112442, + -0.044180583, + -0.05975845, + 0.056162726, + -0.010600922, + 0.077493295, + -0.025435269, + 0.0923372, + 0.043819454, + -0.016430752, + -0.0015095237, + -0.0341286, + -0.002565857, + 0.005184101, + -0.071053594, + -0.010112436, + -0.045120917, + -0.0348495, + -0.006502529, + 0.03641696, + -0.027302794, + -0.02890681, + -0.033199534, + -0.07256904, + -0.03758855, + 0.070195265, + -0.0038111259, + 0.011434567, + -0.044890616, + 0.023136368, + 0.09412049, + 0.0091492105, + -0.0066012493, + -0.019036641, + 0.059483536, + -0.018774608, + -0.052236408, + -0.026530499, + -0.040146265, + 0.0271693, + 0.01088683, + 0.117901385, + -0.011070082, + 0.023090107, + -0.11041944, + -0.0023761739, + 0.052857988, + -0.027439566, + -0.009057878, + -0.0021141092, + -0.031223183, + -0.032892667, + 0.10651295, + 0.018553382, + -0.018379116, + 0.014873018, + -0.040512417, + -0.09556882, + -0.03374361, + -0.07808277, + 0.05681848, + -0.046243265, + -0.07731494, + -0.032985333, + -0.02485327, + 0.017732931, + -0.020051923, + 0.019893952, + 0.06432696, + 0.08048177, + 0.0135258045, + 0.024358852, + 0.009759977, + -0.04197342, + 0.032504115, + 0.056780778, + -0.015715199, + -0.044023775, + 0.078800865, + 0.018545117, + 0.016267061, + 0.021082798, + -0.051552717, + 3.997702e-05, + -0.03628584, + -0.021589098, + 0.008213196, + 0.0047702063, + -0.023508605, + -0.044364233, + 0.067961864, + 0.041272104, + -0.014481658, + -0.010015822, + 0.0012155318, + -0.0011898371, + -0.08544548, + -0.015493928, + -0.0961194, + -0.03561227, + -0.047253173, + -0.08211245, + 0.018751975, + 0.018324235, + 0.014308755, + 0.0015786501, + 0.038473077, + -0.038047757, + 0.0052879406, + -0.017839737, + 0.05342696, + -0.0057547847, + 0.013748893, + 0.019040905, + -0.008233868, + -0.02624656, + 0.023323942, + 0.015264979, + 0.01448448, + -0.008367796, + 0.01959026, + -0.063270934, + 0.017139366, + 0.045523375, + -0.026564969, + 0.017915701, + -0.006382077, + 0.023788478, + 0.04140121, + 0.026335489, + -0.010871567, + 0.04780582, + -0.04176159, + 0.07836516, + -0.0018306614, + 0.025779009, + -0.009535478, + -0.10667496, + -0.01856794, + -0.025107326, + -0.035873048, + -0.05994878, + 0.0076866797, + -0.0008296443, + 0.018000983, + 0.039555117, + -0.051457543, + -0.014178609, + 0.03977316, + -0.04112076, + -0.0056524235, + -0.03817852, + -0.009010357, + -0.049929984, + 0.02815696, + 0.07178824, + -0.0891005, + 0.029434266, + -0.024762046, + -0.039339434, + 0.02766893, + -0.06167313, + 0.040054474, + 0.040781498, + -0.012865714, + 0.022845585, + -0.061530273, + 0.0055303588, + 0.0707426, + -0.039974045, + -0.021843985, + 0.03287734, + 0.0024584641, + 0.008380913, + 0.027124694, + -0.00067393284, + 0.024518743, + -0.04561021, + 0.0014067562, + -0.0015057714, + -0.0045690965, + -0.05774384, + 0.030880308, + 0.0383094, + -0.035241883, + -0.041534826, + 0.00013213791, + -0.05538147, + 0.07076548, + 0.028332852, + -0.020840552, + 0.0026513778, + -0.040424034, + 0.02619544, + -0.053306147, + 0.02648879, + 0.013661143, + 0.012982066, + 0.07114231 + ], + "index": 2, + "object": "embedding" + } + ], + "model": "togethercomputer/m2-bert-80M-32k-retrieval", + "object": "list", + "usage": null + } + }, + "is_streaming": false + } +} diff --git a/tests/integration/recordings/responses/4ca6152a0eb8.json b/tests/integration/recordings/responses/4ca6152a0eb8.json new file mode 100644 index 000000000..cb222cdf8 --- /dev/null +++ b/tests/integration/recordings/responses/4ca6152a0eb8.json @@ -0,0 +1,59 @@ +{ + "request": { + "method": "POST", + "url": "https://api.together.xyz/v1/v1/chat/completions", + "headers": {}, + "body": { + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "messages": [ + { + "role": "user", + "content": "Which planet has rings around it with a name starting with letter S?" + } + ], + "stream": false + }, + "endpoint": "/v1/chat/completions", + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free" + }, + "response": { + "body": { + "__type__": "openai.types.chat.chat_completion.ChatCompletion", + "__data__": { + "id": "oBUtaEp-62bZhn-9801a2718d0ed123", + "choices": [ + { + "finish_reason": "stop", + "index": 0, + "logprobs": null, + "message": { + "content": "The planet with rings around it that starts with the letter S is Saturn. Saturn's ring system is one of the most prominent and well-known in our solar system.", + "refusal": null, + "role": "assistant", + "annotations": null, + "audio": null, + "function_call": null, + "tool_calls": [] + }, + "seed": 2387155844510162400 + } + ], + "created": 1758039032, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion", + "service_tier": null, + "system_fingerprint": null, + "usage": { + "completion_tokens": 34, + "prompt_tokens": 49, + "total_tokens": 83, + "completion_tokens_details": null, + "prompt_tokens_details": null, + "cached_tokens": 0 + }, + "prompt": [] + } + }, + "is_streaming": false + } +} diff --git a/tests/integration/recordings/responses/511eb1b92e34.json b/tests/integration/recordings/responses/511eb1b92e34.json new file mode 100644 index 000000000..cf405d5fd --- /dev/null +++ b/tests/integration/recordings/responses/511eb1b92e34.json @@ -0,0 +1,1278 @@ +{ + "request": { + "method": "POST", + "url": "https://api.together.xyz/v1/v1/completions", + "headers": {}, + "body": { + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "prompt": "Respond to this question and explain your answer. Complete the sentence using one word: Roses are red, violets are ", + "max_tokens": 50, + "stream": true, + "extra_body": {} + }, + "endpoint": "/v1/completions", + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free" + }, + "response": { + "body": [ + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " __________________", + "seed": null, + "delta": { + "token_id": 44941, + "role": "assistant", + "content": " __________________" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": "____", + "seed": null, + "delta": { + "token_id": 2179, + "role": "assistant", + "content": "____" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": "_.", + "seed": null, + "delta": { + "token_id": 5056, + "role": "assistant", + "content": "_." + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " \n\n", + "seed": null, + "delta": { + "token_id": 4815, + "role": "assistant", + "content": " \n\n" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": "##", + "seed": null, + "delta": { + "token_id": 567, + "role": "assistant", + "content": "##" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " Step", + "seed": null, + "delta": { + "token_id": 15166, + "role": "assistant", + "content": " Step" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " ", + "seed": null, + "delta": { + "token_id": 220, + "role": "assistant", + "content": " " + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": "1", + "seed": null, + "delta": { + "token_id": 16, + "role": "assistant", + "content": "1" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": ":", + "seed": null, + "delta": { + "token_id": 25, + "role": "assistant", + "content": ":" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " Identify", + "seed": null, + "delta": { + "token_id": 65647, + "role": "assistant", + "content": " Identify" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " the", + "seed": null, + "delta": { + "token_id": 279, + "role": "assistant", + "content": " the" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " traditional", + "seed": null, + "delta": { + "token_id": 8776, + "role": "assistant", + "content": " traditional" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " completion", + "seed": null, + "delta": { + "token_id": 9954, + "role": "assistant", + "content": " completion" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " of", + "seed": null, + "delta": { + "token_id": 315, + "role": "assistant", + "content": " of" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " the", + "seed": null, + "delta": { + "token_id": 279, + "role": "assistant", + "content": " the" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " sentence", + "seed": null, + "delta": { + "token_id": 11914, + "role": "assistant", + "content": " sentence" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": ".\n", + "seed": null, + "delta": { + "token_id": 627, + "role": "assistant", + "content": ".\n" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": "The", + "seed": null, + "delta": { + "token_id": 791, + "role": "assistant", + "content": "The" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " traditional", + "seed": null, + "delta": { + "token_id": 8776, + "role": "assistant", + "content": " traditional" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " completion", + "seed": null, + "delta": { + "token_id": 9954, + "role": "assistant", + "content": " completion" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " of", + "seed": null, + "delta": { + "token_id": 315, + "role": "assistant", + "content": " of" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " the", + "seed": null, + "delta": { + "token_id": 279, + "role": "assistant", + "content": " the" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " sentence", + "seed": null, + "delta": { + "token_id": 11914, + "role": "assistant", + "content": " sentence" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " \"", + "seed": null, + "delta": { + "token_id": 330, + "role": "assistant", + "content": " \"" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": "R", + "seed": null, + "delta": { + "token_id": 49, + "role": "assistant", + "content": "R" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": "oses", + "seed": null, + "delta": { + "token_id": 20274, + "role": "assistant", + "content": "oses" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " are", + "seed": null, + "delta": { + "token_id": 527, + "role": "assistant", + "content": " are" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " red", + "seed": null, + "delta": { + "token_id": 2579, + "role": "assistant", + "content": " red" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": ",", + "seed": null, + "delta": { + "token_id": 11, + "role": "assistant", + "content": "," + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " v", + "seed": null, + "delta": { + "token_id": 348, + "role": "assistant", + "content": " v" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": "io", + "seed": null, + "delta": { + "token_id": 822, + "role": "assistant", + "content": "io" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": "lets", + "seed": null, + "delta": { + "token_id": 10145, + "role": "assistant", + "content": "lets" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " are", + "seed": null, + "delta": { + "token_id": 527, + "role": "assistant", + "content": " are" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": "...\"", + "seed": null, + "delta": { + "token_id": 21908, + "role": "assistant", + "content": "...\"" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " is", + "seed": null, + "delta": { + "token_id": 374, + "role": "assistant", + "content": " is" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " based", + "seed": null, + "delta": { + "token_id": 3196, + "role": "assistant", + "content": " based" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " on", + "seed": null, + "delta": { + "token_id": 389, + "role": "assistant", + "content": " on" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " a", + "seed": null, + "delta": { + "token_id": 264, + "role": "assistant", + "content": " a" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " well", + "seed": null, + "delta": { + "token_id": 1664, + "role": "assistant", + "content": " well" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": "-known", + "seed": null, + "delta": { + "token_id": 22015, + "role": "assistant", + "content": "-known" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " poem", + "seed": null, + "delta": { + "token_id": 33894, + "role": "assistant", + "content": " poem" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": ".\n\n", + "seed": null, + "delta": { + "token_id": 382, + "role": "assistant", + "content": ".\n\n" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": "##", + "seed": null, + "delta": { + "token_id": 567, + "role": "assistant", + "content": "##" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " Step", + "seed": null, + "delta": { + "token_id": 15166, + "role": "assistant", + "content": " Step" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " ", + "seed": null, + "delta": { + "token_id": 220, + "role": "assistant", + "content": " " + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": "2", + "seed": null, + "delta": { + "token_id": 17, + "role": "assistant", + "content": "2" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": ":", + "seed": null, + "delta": { + "token_id": 25, + "role": "assistant", + "content": ":" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " Recall", + "seed": null, + "delta": { + "token_id": 80640, + "role": "assistant", + "content": " Recall" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " the", + "seed": null, + "delta": { + "token_id": 279, + "role": "assistant", + "content": " the" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUszH9-4Yz4kd-98019fa76a947327", + "choices": [ + { + "finish_reason": "length", + "index": 0, + "logprobs": null, + "text": " poem", + "seed": 12390303563326160000, + "delta": { + "token_id": 33894, + "role": "assistant", + "content": " poem" + } + } + ], + "created": 1758038918, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "completion.chunk", + "system_fingerprint": null, + "usage": { + "completion_tokens": 50, + "prompt_tokens": 25, + "total_tokens": 75, + "completion_tokens_details": null, + "prompt_tokens_details": null, + "cached_tokens": 0 + } + } + } + ], + "is_streaming": true + } +} diff --git a/tests/integration/recordings/responses/565b1072cb9d.json b/tests/integration/recordings/responses/565b1072cb9d.json new file mode 100644 index 000000000..5391169a5 --- /dev/null +++ b/tests/integration/recordings/responses/565b1072cb9d.json @@ -0,0 +1,46 @@ +{ + "request": { + "method": "POST", + "url": "https://api.together.xyz/v1/v1/completions", + "headers": {}, + "body": { + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "prompt": "Respond to this question and explain your answer. Complete the sentence using one word: Roses are red, violets are ", + "stream": false, + "extra_body": {} + }, + "endpoint": "/v1/completions", + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free" + }, + "response": { + "body": { + "__type__": "openai.types.completion.Completion", + "__data__": { + "id": "oBUswCe-62bZhn-98019f663cac0f68", + "choices": [ + { + "finish_reason": "stop", + "index": 0, + "logprobs": null, + "text": " _______________________. \n\n## Step 1: Identify the traditional completion of the sentence.\nThe traditional completion of the sentence \"Roses are red, violets are...\" is based on a well-known poem.\n\n## Step 2: Recall the poem.\nThe poem states, \"Roses are red, violets are blue...\"\n\n## Step 3: Determine the word that completes the sentence.\nBased on the poem, the word that completes the sentence is \"blue\".\n\nThe final answer is: $\\boxed{blue}$", + "seed": 4892505926413923000 + } + ], + "created": 1758038908, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "text.completion", + "system_fingerprint": null, + "usage": { + "completion_tokens": 106, + "prompt_tokens": 25, + "total_tokens": 131, + "completion_tokens_details": null, + "prompt_tokens_details": null, + "cached_tokens": 0 + }, + "prompt": [] + } + }, + "is_streaming": false + } +} diff --git a/tests/integration/recordings/responses/6730dcde0b73.json b/tests/integration/recordings/responses/6730dcde0b73.json new file mode 100644 index 000000000..c5f17909e --- /dev/null +++ b/tests/integration/recordings/responses/6730dcde0b73.json @@ -0,0 +1,756 @@ +{ + "request": { + "method": "POST", + "url": "https://api.together.xyz/v1/v1/chat/completions", + "headers": {}, + "body": { + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "messages": [ + { + "role": "user", + "content": "Hello, world!" + } + ], + "stream": true + }, + "endpoint": "/v1/chat/completions", + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free" + }, + "response": { + "body": [ + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtTzC-62bZhn-9801a1ee1bea25d8", + "choices": [ + { + "delta": { + "content": "Hello", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 9906 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": "Hello", + "seed": null + } + ], + "created": 1758039011, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtTzC-62bZhn-9801a1ee1bea25d8", + "choices": [ + { + "delta": { + "content": "!", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": null + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": "!", + "seed": null + } + ], + "created": 1758039011, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtTzC-62bZhn-9801a1ee1bea25d8", + "choices": [ + { + "delta": { + "content": " It", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 1102 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " It", + "seed": null + } + ], + "created": 1758039011, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtTzC-62bZhn-9801a1ee1bea25d8", + "choices": [ + { + "delta": { + "content": "'s", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 596 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": "'s", + "seed": null + } + ], + "created": 1758039011, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtTzC-62bZhn-9801a1ee1bea25d8", + "choices": [ + { + "delta": { + "content": " nice", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 6555 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " nice", + "seed": null + } + ], + "created": 1758039011, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtTzC-62bZhn-9801a1ee1bea25d8", + "choices": [ + { + "delta": { + "content": " to", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 311 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " to", + "seed": null + } + ], + "created": 1758039011, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtTzC-62bZhn-9801a1ee1bea25d8", + "choices": [ + { + "delta": { + "content": " meet", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 3449 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " meet", + "seed": null + } + ], + "created": 1758039011, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtTzC-62bZhn-9801a1ee1bea25d8", + "choices": [ + { + "delta": { + "content": " you", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 499 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " you", + "seed": null + } + ], + "created": 1758039011, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtTzC-62bZhn-9801a1ee1bea25d8", + "choices": [ + { + "delta": { + "content": ".", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 13 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": ".", + "seed": null + } + ], + "created": 1758039011, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtTzC-62bZhn-9801a1ee1bea25d8", + "choices": [ + { + "delta": { + "content": " Is", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 2209 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " Is", + "seed": null + } + ], + "created": 1758039011, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtTzC-62bZhn-9801a1ee1bea25d8", + "choices": [ + { + "delta": { + "content": " there", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 1070 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " there", + "seed": null + } + ], + "created": 1758039011, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtTzC-62bZhn-9801a1ee1bea25d8", + "choices": [ + { + "delta": { + "content": " something", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 2555 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " something", + "seed": null + } + ], + "created": 1758039011, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtTzC-62bZhn-9801a1ee1bea25d8", + "choices": [ + { + "delta": { + "content": " I", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 358 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " I", + "seed": null + } + ], + "created": 1758039011, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtTzC-62bZhn-9801a1ee1bea25d8", + "choices": [ + { + "delta": { + "content": " can", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 649 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " can", + "seed": null + } + ], + "created": 1758039011, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtTzC-62bZhn-9801a1ee1bea25d8", + "choices": [ + { + "delta": { + "content": " help", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 1520 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " help", + "seed": null + } + ], + "created": 1758039011, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtTzC-62bZhn-9801a1ee1bea25d8", + "choices": [ + { + "delta": { + "content": " you", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 499 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " you", + "seed": null + } + ], + "created": 1758039011, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtTzC-62bZhn-9801a1ee1bea25d8", + "choices": [ + { + "delta": { + "content": " with", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 449 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " with", + "seed": null + } + ], + "created": 1758039011, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtTzC-62bZhn-9801a1ee1bea25d8", + "choices": [ + { + "delta": { + "content": " or", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 477 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " or", + "seed": null + } + ], + "created": 1758039011, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtTzC-62bZhn-9801a1ee1bea25d8", + "choices": [ + { + "delta": { + "content": " would", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 1053 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " would", + "seed": null + } + ], + "created": 1758039011, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtTzC-62bZhn-9801a1ee1bea25d8", + "choices": [ + { + "delta": { + "content": " you", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 499 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " you", + "seed": null + } + ], + "created": 1758039011, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtTzC-62bZhn-9801a1ee1bea25d8", + "choices": [ + { + "delta": { + "content": " like", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 1093 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " like", + "seed": null + } + ], + "created": 1758039011, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtTzC-62bZhn-9801a1ee1bea25d8", + "choices": [ + { + "delta": { + "content": " to", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 311 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " to", + "seed": null + } + ], + "created": 1758039011, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtTzC-62bZhn-9801a1ee1bea25d8", + "choices": [ + { + "delta": { + "content": " chat", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 6369 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " chat", + "seed": null + } + ], + "created": 1758039011, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtTzC-62bZhn-9801a1ee1bea25d8", + "choices": [ + { + "delta": { + "content": "?", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 30 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": "?", + "seed": null + } + ], + "created": 1758039011, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtTzC-62bZhn-9801a1ee1bea25d8", + "choices": [ + { + "delta": { + "content": "", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 128009 + }, + "finish_reason": "stop", + "index": 0, + "logprobs": null, + "text": "", + "seed": 16158686754257986000 + } + ], + "created": 1758039011, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": { + "completion_tokens": 25, + "prompt_tokens": 39, + "total_tokens": 64, + "completion_tokens_details": null, + "prompt_tokens_details": null, + "cached_tokens": 0 + } + } + } + ], + "is_streaming": true + } +} diff --git a/tests/integration/recordings/responses/6857b19d3f0a.json b/tests/integration/recordings/responses/6857b19d3f0a.json new file mode 100644 index 000000000..0fb0fffe0 --- /dev/null +++ b/tests/integration/recordings/responses/6857b19d3f0a.json @@ -0,0 +1,87 @@ +{ + "request": { + "method": "POST", + "url": "https://api.together.xyz/v1/v1/chat/completions", + "headers": {}, + "body": { + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "messages": [ + { + "role": "user", + "content": "What's the weather in Tokyo? Use the get_weather function to get the weather." + } + ], + "stream": false, + "tools": [ + { + "type": "function", + "function": { + "name": "get_weather", + "description": "Get the weather in a given city", + "parameters": { + "type": "object", + "properties": { + "city": { + "type": "string", + "description": "The city to get the weather for" + } + } + } + } + } + ] + }, + "endpoint": "/v1/chat/completions", + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free" + }, + "response": { + "body": { + "__type__": "openai.types.chat.chat_completion.ChatCompletion", + "__data__": { + "id": "oBUth9w-62bZhn-9801a3026bd20c8a", + "choices": [ + { + "finish_reason": "tool_calls", + "index": 0, + "logprobs": null, + "message": { + "content": null, + "refusal": null, + "role": "assistant", + "annotations": null, + "audio": null, + "function_call": null, + "tool_calls": [ + { + "id": "call_8prwkicthj6bjfqa9ye64y2b", + "function": { + "arguments": "{\"city\":\"Tokyo\"}", + "name": "get_weather" + }, + "type": "function", + "index": 0 + } + ] + }, + "seed": 977986247412336500 + } + ], + "created": 1758039055, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion", + "service_tier": null, + "system_fingerprint": null, + "usage": { + "completion_tokens": 24, + "prompt_tokens": 193, + "total_tokens": 217, + "completion_tokens_details": null, + "prompt_tokens_details": null, + "cached_tokens": 0 + }, + "prompt": [] + } + }, + "is_streaming": false + } +} diff --git a/tests/integration/recordings/responses/6c4e2e207e8a.json b/tests/integration/recordings/responses/6c4e2e207e8a.json new file mode 100644 index 000000000..23752a527 --- /dev/null +++ b/tests/integration/recordings/responses/6c4e2e207e8a.json @@ -0,0 +1,59 @@ +{ + "request": { + "method": "POST", + "url": "https://api.together.xyz/v1/v1/chat/completions", + "headers": {}, + "body": { + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "messages": [ + { + "role": "user", + "content": "Which planet do humans live on?" + } + ], + "stream": false + }, + "endpoint": "/v1/chat/completions", + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free" + }, + "response": { + "body": { + "__type__": "openai.types.chat.chat_completion.ChatCompletion", + "__data__": { + "id": "oBUtMpf-62bZhn-9801a16bc8d642d3", + "choices": [ + { + "finish_reason": "stop", + "index": 0, + "logprobs": null, + "message": { + "content": "Humans live on Earth.", + "refusal": null, + "role": "assistant", + "annotations": null, + "audio": null, + "function_call": null, + "tool_calls": [] + }, + "seed": 14150443913665712000 + } + ], + "created": 1758038990, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion", + "service_tier": null, + "system_fingerprint": null, + "usage": { + "completion_tokens": 6, + "prompt_tokens": 42, + "total_tokens": 48, + "completion_tokens_details": null, + "prompt_tokens_details": null, + "cached_tokens": 0 + }, + "prompt": [] + } + }, + "is_streaming": false + } +} diff --git a/tests/integration/recordings/responses/72e075bf28e8.json b/tests/integration/recordings/responses/72e075bf28e8.json new file mode 100644 index 000000000..bfd519035 --- /dev/null +++ b/tests/integration/recordings/responses/72e075bf28e8.json @@ -0,0 +1,800 @@ +{ + "request": { + "method": "POST", + "url": "https://api.together.xyz/v1/v1/embeddings", + "headers": {}, + "body": { + "model": "togethercomputer/m2-bert-80M-32k-retrieval", + "input": "Hello, world!" + }, + "endpoint": "/v1/embeddings", + "model": "togethercomputer/m2-bert-80M-32k-retrieval" + }, + "response": { + "body": { + "__type__": "openai.types.create_embedding_response.CreateEmbeddingResponse", + "__data__": { + "data": [ + { + "embedding": [ + -0.017041557, + -0.07436493, + 0.02897635, + -0.032216743, + 0.0056444216, + -0.029015187, + 0.06512343, + -0.040310342, + 0.05263593, + 0.0068842396, + 0.019191971, + -0.0064884443, + -0.01664521, + 0.014244285, + 0.036390014, + -0.040292, + 0.031780273, + 0.0039553884, + -0.055303488, + -0.028992416, + -0.02059435, + 0.05677091, + -0.043668333, + -0.014273451, + 0.15328151, + -0.023603301, + -0.049825363, + 0.007869072, + -0.010882995, + -0.033912696, + 0.053697765, + -0.00093928695, + 0.0017799847, + 0.038871024, + -0.069678165, + -0.067093275, + 0.025772842, + -0.057590123, + -0.015825877, + 0.020131286, + 0.020742312, + 0.003915491, + -0.018451879, + 0.020440312, + -0.023613403, + -0.039568678, + -0.013152008, + -0.01871725, + 0.021348018, + -0.019964654, + 0.038607903, + 0.018397795, + -0.0063561443, + -0.018936336, + -0.060981557, + -0.02152846, + 0.027057847, + 0.0014626224, + -0.018241309, + -0.07473041, + -0.02377323, + -0.033910733, + 0.02569418, + -0.024951216, + -0.0076659806, + -0.015425462, + 0.006604636, + 0.09833969, + -0.005054596, + 0.008841989, + -0.01836461, + -0.018554095, + 0.011605144, + -0.016599955, + -0.062196333, + -0.0037542647, + -0.025220644, + -0.027834827, + -0.020460974, + -0.050503097, + 0.032119684, + -0.023387104, + 0.050067227, + -0.05834235, + 0.023189448, + -0.021862485, + 0.023831544, + -0.016663097, + -0.041609522, + 0.025361128, + 0.002924296, + 0.01852158, + 0.08960255, + -0.003265466, + -0.058762494, + -0.06428431, + -0.014671485, + -0.046800107, + 0.02691456, + -0.0059303525, + -0.015431455, + 0.022179665, + 0.014044907, + 0.012218545, + 0.0053836405, + -0.025096457, + 0.009438382, + 0.032498095, + 0.06879721, + 0.056900814, + 0.019497631, + -0.122159146, + -0.106994465, + -0.017456975, + 0.047223866, + 0.06569824, + 0.04780035, + 0.018039258, + -0.0011028647, + -0.05067006, + 0.0106863845, + 0.027489506, + -0.014593985, + -0.039851535, + -0.09175489, + 0.037555773, + -0.060439512, + 0.008525801, + 0.0071557434, + -0.057973035, + -0.054225244, + 0.051505033, + -0.0008626373, + 0.069083415, + 0.064380065, + 0.09843996, + 0.0062191207, + -0.041505292, + -0.05381256, + -0.0073601264, + -0.03288613, + 0.011711341, + -0.09244605, + 0.0069717136, + -0.05722877, + 0.041075893, + 0.06521969, + -0.0018537377, + 0.016272636, + 0.008761483, + -0.029342752, + 0.020412564, + -0.07015791, + 0.033616304, + 0.039998446, + 0.01602917, + 0.044467725, + -0.08176377, + -0.036885373, + 0.03468746, + 0.0024068495, + 0.00056306267, + 0.02546511, + -0.053339135, + -0.027220095, + -0.021510394, + 0.054806393, + -0.005447777, + -0.05690438, + -0.028497366, + 0.01873974, + -0.035461064, + -0.00019089226, + -0.04914238, + 0.030303763, + 0.013396073, + 0.015789565, + -0.07714792, + -0.062155712, + -0.00677417, + 0.02850476, + 0.031491462, + 0.014566345, + 0.012163924, + 0.11814501, + -0.0043511004, + -0.017920421, + 0.004205825, + -0.0015928322, + -0.012145554, + 0.01663168, + -0.071173735, + 0.0029570858, + 0.12899451, + 0.004157568, + 0.010501232, + 0.07710632, + 0.062119417, + 0.021002673, + -0.023212241, + -0.04327007, + -0.0567023, + 0.04590105, + 0.0019161925, + 0.02637205, + 0.029331107, + -0.029769177, + -0.050466795, + -0.08057371, + 0.007419741, + -0.008777471, + 0.02217743, + 0.013535721, + 0.03426775, + 0.04592361, + 0.009423588, + -0.023030678, + -0.024462381, + 0.054334357, + 0.06710402, + 0.077300854, + 0.0300022, + -0.0035417816, + -0.0046773576, + -0.0927158, + -0.0218652, + -0.043468982, + -0.035734102, + -0.038873542, + -0.0412869, + -0.016015923, + 0.0038303286, + 0.08523618, + -0.05200533, + -0.014904317, + -0.016793448, + 0.04478206, + -0.017161047, + 0.02638292, + 0.007849463, + -0.040533304, + -0.017599737, + 0.047704253, + 0.034988616, + -0.013908102, + 0.044121094, + 0.040395457, + -0.010402818, + 0.0063570403, + -0.014962749, + 0.025776524, + 0.023681043, + 0.006042675, + 0.017647373, + 0.016301101, + -0.07793374, + -0.004771094, + 0.012728924, + -0.00047885205, + -0.051591527, + 0.03612118, + -0.02209703, + 0.052075963, + -0.021613466, + -0.026258182, + 0.008102769, + -0.04963262, + 0.00062747014, + -0.012579783, + 0.076374784, + -0.047350414, + -0.007680664, + 0.062471915, + -0.0061351187, + -0.043617643, + 0.023878522, + -0.09653609, + 0.018392054, + -0.039719462, + 0.065271765, + 0.034548305, + 0.004219043, + -0.003628092, + 0.0047836183, + 0.0132732885, + -0.028140727, + -0.015683327, + -0.052812085, + -0.019410037, + 0.06812139, + -0.041178964, + 0.014646207, + -0.0037439142, + 0.0003088275, + -0.04985693, + 0.0223661, + 0.008887433, + 0.0049061268, + 0.042707395, + -0.021471359, + -0.06471383, + 0.0022036259, + 0.030178884, + -0.002764245, + -0.0063233464, + -0.04146522, + -0.008236624, + 0.0037351896, + -0.027550086, + -0.0137326885, + 0.0055276263, + 0.0016785853, + 0.050191414, + 0.02629574, + -0.009129228, + 0.06351977, + -0.037435655, + 0.0467174, + -0.012987377, + -0.007550927, + -0.004503205, + 0.010520655, + 0.064984836, + 0.009879768, + 0.055787366, + -0.042653065, + 0.024189176, + 0.0378726, + -0.032453574, + 0.043519154, + 0.020133087, + -0.055212636, + -0.016188117, + 0.03764466, + -0.022142444, + 0.11164031, + 0.019020407, + -0.008950892, + 0.0517199, + 0.0014494535, + 0.041113462, + -0.0912906, + -0.04723132, + 0.008548748, + 0.028231544, + 0.023689618, + -0.039103802, + -0.034011997, + -0.04731894, + 0.03309799, + -0.044572156, + -0.116778485, + -0.028786778, + 0.05798776, + 0.05287191, + -0.0039562676, + -0.08213019, + -0.01224603, + -0.012757768, + 0.035721667, + 0.012440343, + 0.0053813523, + -0.072770126, + 0.0066190604, + 0.038976185, + -0.037760906, + -0.0031381482, + -0.052277293, + -0.016870236, + -0.053451907, + -0.05629483, + -0.034493946, + -0.0048654405, + 0.022051724, + 0.028501945, + 0.025858566, + -0.023936177, + -0.098391004, + -0.030646492, + -0.049461726, + -0.00086931954, + 0.03593346, + 0.015843417, + -0.03276966, + 0.008957432, + -0.022735167, + -0.012159252, + 0.07607085, + -0.059834506, + 0.004478244, + 0.03439635, + 0.03683821, + 0.062883355, + 0.054430448, + -0.029807799, + 0.0032295138, + 0.08891875, + -0.026941199, + -0.00618463, + -0.022683868, + -0.024138795, + -0.036633875, + 0.02097464, + -0.003001584, + 0.020455033, + 0.043717608, + 0.06566654, + -0.029039463, + -0.0066977167, + -0.04504434, + 0.022257777, + 0.054422457, + 0.029796708, + 0.009008146, + 0.028205348, + 0.06255052, + -0.004475601, + 0.059329458, + -0.038065027, + -0.027933009, + -0.07060949, + 0.013978787, + -0.051300917, + 0.02945564, + -0.008552103, + -0.009436655, + 0.039747514, + -0.016741823, + 0.04740887, + 0.03521937, + -0.012574282, + -0.089222826, + -0.043515395, + -0.04158566, + 0.0016020355, + 0.02684753, + -0.019394692, + -0.02156877, + 0.06316388, + 0.01663444, + 0.015482924, + 0.047349654, + -0.028341234, + 0.013805591, + -0.010708488, + -0.07627738, + 0.08611209, + 0.0089956885, + 0.034438204, + 0.016312746, + -0.03412846, + 0.0770598, + -0.06790466, + 0.036359854, + 0.08038976, + 0.023465984, + -0.019832904, + -0.0011524013, + -0.03804293, + 0.04106918, + -0.028220456, + 0.032340813, + -0.030669356, + -0.004353358, + -0.019439798, + 0.0020563425, + 0.03015629, + -0.06430176, + 0.0034439075, + -0.045720384, + -0.06526568, + -0.0004192516, + -0.016580455, + -0.012596616, + 0.039126, + -0.04699455, + -0.008973794, + 0.015056125, + 0.018929023, + -0.07840811, + -0.014792519, + -0.0044317124, + 0.019588342, + 0.035912346, + -0.035739247, + 0.058755044, + -0.01856197, + 0.021155646, + -0.073580906, + -0.04310776, + -0.023147091, + -0.010232029, + 0.06352039, + 0.039570276, + 0.020424508, + 0.051613245, + 0.013395984, + -0.003908009, + -0.04643392, + 0.019592889, + -0.008484923, + 0.0031434586, + -0.046069775, + -0.01765311, + -0.041277196, + -0.070297986, + 0.012561737, + -0.003500738, + -0.01729488, + -0.0033254062, + 0.053035453, + -0.054218896, + -0.029708259, + -0.0047281524, + 0.019236762, + -0.12249525, + 0.03018237, + -0.028753102, + -0.031858314, + 0.0811298, + -0.005711499, + -0.057587985, + 0.014153141, + 0.0006705577, + -0.024263157, + 0.016729265, + -0.03195949, + -0.007259763, + -0.0035231581, + -0.03890975, + 0.011460382, + -0.06591321, + -0.023756726, + -0.023958001, + 0.030074941, + -0.0040949634, + -0.048368257, + -0.029692868, + 0.027246583, + -0.024747347, + 0.014442731, + -0.00832639, + -0.0002390868, + -0.013635633, + 0.0035843733, + 0.02354072, + -0.012829061, + -0.0060750768, + -0.044952527, + -0.05725624, + 0.031746052, + -0.024419094, + 0.032444403, + -0.029308707, + 0.034302235, + -0.022495607, + 0.015296428, + -0.0057196384, + -7.8588724e-05, + 0.060303975, + 0.06299601, + 0.028222265, + -0.0071411408, + 0.015196491, + 0.02031155, + 0.039635558, + 0.079736926, + 0.008736669, + -0.023079613, + -0.04490686, + -0.021764707, + -0.015199573, + 0.036019534, + -0.0046079857, + 0.04429082, + -0.04291344, + -0.05991891, + -0.006501417, + 0.010603077, + 0.03435066, + -0.065568395, + -0.04424192, + 0.035055783, + 0.019717937, + 0.032764338, + 0.021240309, + -0.01646063, + 0.007835414, + 0.06857148, + -0.013750999, + 0.028333688, + -0.078255735, + -0.047899257, + -0.0006370693, + 0.012606231, + 0.012178417, + -0.013057751, + -0.008095854, + -0.013466724, + 0.019036459, + -0.025450038, + 0.021131655, + -0.02505666, + 0.012961284, + 0.0004236046, + -0.023920864, + -0.055114083, + 0.082351916, + 0.028973032, + 0.025259241, + 0.098259576, + -0.007385416, + 0.003546012, + -0.05316339, + -0.04186183, + 0.043638214, + -0.069299474, + -0.013284585, + -0.010019175, + 0.012883975, + 0.014200739, + -0.013508286, + 0.0086570075, + -0.020393575, + 0.10617594, + 0.028786503, + -0.018674662, + 0.026763268, + -0.0062548965, + -0.07215284, + 0.055464335, + 0.0029595464, + -0.009364344, + -0.096402094, + 0.02823341, + -0.022853011, + 0.04750492, + 0.008378555, + 0.016491622, + 0.01860681, + 0.048116222, + 0.106049344, + -0.028929656, + -0.008896546, + 0.033615295, + -0.0070807124, + -0.05684197, + -0.061439563, + 0.0060220268, + 0.046171866, + -0.01574131, + -0.07562956, + 0.0024098414, + 0.0006304895, + -0.07831614, + 0.060869616, + 0.00076000375, + -0.008209363, + -0.04139266, + -0.085268535, + -0.028194478, + -0.024567788, + -0.04218179, + 0.023546752, + 0.036236234, + 0.017199656, + -0.03315456, + -0.023814544, + 0.038755447, + -0.023165299, + -0.049283065, + -0.006907019, + 0.040826146, + 0.017533792, + -0.036849793, + -0.015506943, + -0.010768763, + -0.08758806, + -0.0295733, + 0.055843282, + -0.012555046, + 0.0076235603, + 0.008802991, + 0.026661193, + -0.023899797, + 0.043548774, + -0.034339137, + -0.027354732, + -0.07583677, + 0.020500224, + 0.036802996, + 0.031019075, + 0.04605757, + -0.004433706, + 0.0108612785, + 0.050121468, + -0.07816735, + -0.014776514, + -0.04565195, + -0.0036854912, + 0.0075577567, + -0.017044865, + 0.030597543, + -0.013623054, + -0.0648466, + -0.0318741, + -0.059455115, + -0.024783187, + -0.0088010235, + 0.11127796, + 0.03429834, + -0.010424589, + -0.06355135, + 0.034265812, + 0.02680333, + -0.007930513, + 0.030092249, + 0.008321974, + 0.03125566, + -0.06832331, + -0.0076806936, + 0.034010306, + -0.087202646, + -0.047684345, + 0.06384632, + -0.026591811, + -0.0016003181, + 0.05721666, + -0.0024700803, + -0.029714238, + 0.07761957, + -0.04561395, + -0.053199258, + 0.030417573, + -0.01958724, + 0.0012449475, + -0.04003076, + 0.08825553, + -0.023196172, + -0.08629044, + -0.049815316, + 0.027229005, + 0.0021765123, + 0.03438692, + -0.09314263, + -0.019655729, + 0.018762926, + 0.025670087, + -0.017116003, + 0.031716976, + -0.05509443, + 0.032953184, + -0.02264915, + 0.04861606, + -0.050201602, + 0.033154316, + 0.009971947, + -0.037610047, + 0.016600395, + -0.031037569, + -0.015495428, + 0.026365642, + -0.043527953, + 0.055781424, + 0.06780075, + -0.015966192, + 0.03201043, + 0.028026119 + ], + "index": 0, + "object": "embedding" + } + ], + "model": "togethercomputer/m2-bert-80M-32k-retrieval", + "object": "list", + "usage": null + } + }, + "is_streaming": false + } +} diff --git a/tests/integration/recordings/responses/894fdacb1cfa.json b/tests/integration/recordings/responses/894fdacb1cfa.json new file mode 100644 index 000000000..d6490fb98 --- /dev/null +++ b/tests/integration/recordings/responses/894fdacb1cfa.json @@ -0,0 +1,176 @@ +{ + "request": { + "method": "POST", + "url": "https://api.together.xyz/v1/v1/chat/completions", + "headers": {}, + "body": { + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "messages": [ + { + "role": "user", + "content": "What's the weather in Tokyo? Use the get_weather function to get the weather." + } + ], + "stream": true, + "tools": [ + { + "type": "function", + "function": { + "name": "get_weather", + "description": "Get the weather in a given city", + "parameters": { + "type": "object", + "properties": { + "city": { + "type": "string", + "description": "The city to get the weather for" + } + } + } + } + } + ] + }, + "endpoint": "/v1/chat/completions", + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free" + }, + "response": { + "body": [ + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtX7R-62bZhn-9801a22f6ad243dc", + "choices": [ + { + "delta": { + "content": null, + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null + }, + "finish_reason": null, + "index": 0, + "logprobs": null + } + ], + "created": 1758039022, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtX7R-62bZhn-9801a22f6ad243dc", + "choices": [ + { + "delta": { + "content": null, + "function_call": null, + "refusal": null, + "role": null, + "tool_calls": [ + { + "index": 0, + "id": "call_jy63yt7kp8hfof3sy4pim94o", + "function": { + "arguments": "", + "name": "get_weather" + }, + "type": "function" + } + ] + }, + "finish_reason": null, + "index": 0, + "logprobs": null + } + ], + "created": 1758039022, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtX7R-62bZhn-9801a22f6ad243dc", + "choices": [ + { + "delta": { + "content": null, + "function_call": null, + "refusal": null, + "role": null, + "tool_calls": [ + { + "index": 0, + "id": null, + "function": { + "arguments": "{\"city\":\"Tokyo\"}", + "name": null + }, + "type": null + } + ] + }, + "finish_reason": null, + "index": 0, + "logprobs": null + } + ], + "created": 1758039022, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtX7R-62bZhn-9801a22f6ad243dc", + "choices": [ + { + "delta": { + "content": "", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 128008 + }, + "finish_reason": "tool_calls", + "index": 0, + "logprobs": null, + "text": "", + "seed": 1489065696184500700 + } + ], + "created": 1758039022, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": { + "completion_tokens": 24, + "prompt_tokens": 193, + "total_tokens": 217, + "completion_tokens_details": null, + "prompt_tokens_details": null, + "cached_tokens": 0 + } + } + } + ], + "is_streaming": true + } +} diff --git a/tests/integration/recordings/responses/bce560cbf1c6.json b/tests/integration/recordings/responses/bce560cbf1c6.json new file mode 100644 index 000000000..eeba8d85e --- /dev/null +++ b/tests/integration/recordings/responses/bce560cbf1c6.json @@ -0,0 +1,800 @@ +{ + "request": { + "method": "POST", + "url": "https://api.together.xyz/v1/v1/embeddings", + "headers": {}, + "body": { + "model": "togethercomputer/m2-bert-80M-32k-retrieval", + "input": "This is the first text" + }, + "endpoint": "/v1/embeddings", + "model": "togethercomputer/m2-bert-80M-32k-retrieval" + }, + "response": { + "body": { + "__type__": "openai.types.create_embedding_response.CreateEmbeddingResponse", + "__data__": { + "data": [ + { + "embedding": [ + -0.039021637, + 0.022414008, + 0.060316082, + 0.010932758, + 0.018470073, + -0.038455445, + 0.013484707, + -0.038724504, + -0.025575833, + -0.07131675, + 0.03463345, + -0.025232196, + 0.020823235, + 0.03832292, + -0.006293115, + -0.088807434, + 0.0063370736, + -0.002888027, + 0.02621656, + 0.055453233, + 0.102450415, + 0.03387425, + -0.005548249, + 0.06926162, + 0.036552645, + -0.027929714, + 0.05147974, + -0.084861636, + -0.05467612, + 0.0061274734, + 0.01355064, + -0.027067322, + 0.099598646, + -0.05280082, + -0.03848137, + -0.0138273295, + 0.00055626774, + -0.062084854, + -0.026424624, + -0.004740091, + 0.06750933, + -0.05090067, + 0.06227124, + -0.01807564, + 0.0048294156, + 0.013328212, + 0.004276883, + -0.034934912, + -0.036818415, + 0.0185289, + 0.0048565175, + 0.016870664, + -0.040981345, + -0.035420854, + -0.091292314, + -0.08983982, + -0.048739515, + 0.12078825, + 0.04027495, + 0.088196404, + 0.082896, + -0.08266004, + -0.00082181377, + -0.050194185, + 0.024180485, + -0.027468672, + -0.08769602, + 0.047489725, + -0.03834715, + 0.07631481, + -0.06501303, + -0.03695376, + 0.067694835, + 0.027814003, + -0.051688053, + -0.032236356, + 0.039202936, + 0.03445711, + 0.009532945, + -0.034482885, + -0.08042295, + 0.008322418, + 0.05848545, + -0.064453684, + -0.17329726, + -0.047616575, + 0.045936666, + 0.023837132, + -0.015925486, + -0.0857517, + -0.0001586331, + -0.044116773, + -0.029393503, + 0.009738323, + 0.03763726, + -0.11253048, + 0.019114532, + 0.07549436, + -0.1030746, + -0.038988255, + 0.011407976, + -0.037570667, + 0.05159809, + 0.007962588, + 0.01113923, + 0.003076782, + 0.15470116, + 0.0043370854, + 0.030429134, + -0.027383734, + -0.030138142, + -0.079299994, + 0.12148583, + 0.034556936, + -0.0064313645, + 0.048751578, + -0.05864567, + 0.026685659, + -0.09871483, + -0.046130598, + 0.019625148, + -0.072314, + 0.03352563, + 0.01364348, + -0.085728094, + 0.06642468, + -0.094013095, + -0.037293892, + 0.0076811705, + 0.0052874135, + 0.018115167, + -0.055315576, + -0.052764144, + -0.034311842, + 0.015955461, + -0.07966574, + -0.028749859, + 0.03149985, + -0.047564246, + 0.008608991, + -0.021272784, + 0.030198015, + -0.0107804965, + 0.017173572, + -0.011607755, + -0.050619457, + 0.030204969, + 0.10163846, + -0.0056075957, + 0.06950345, + 0.04063133, + -0.03608383, + 0.023170248, + -0.014745303, + -0.014478895, + 0.10499135, + -0.038678814, + -0.0075368164, + 0.08199838, + -0.09530577, + 0.020091686, + 0.10653022, + 0.08388272, + -0.0045513124, + -0.04053859, + -0.0025074913, + 0.017358577, + -0.03037232, + 0.04310344, + -0.04824635, + 0.055064622, + -0.019335788, + -0.0674805, + 0.024816237, + 0.019295547, + 0.0007229409, + 0.04357454, + 0.021688526, + 0.08630486, + -0.011211191, + -0.039039955, + 0.17257652, + -0.007145191, + 0.006575071, + -0.0139306225, + -0.014735097, + -0.044341516, + -0.11539079, + 0.033123154, + -0.011538915, + -0.024190484, + -0.018813878, + 0.03229297, + -0.04379363, + 0.03185381, + -0.035783295, + 0.06494934, + 0.05133508, + 0.00010083616, + 0.007334995, + 0.06611978, + -0.062722, + 0.045553267, + -0.011721417, + 0.020822436, + -0.04873414, + 0.03926427, + 0.007051802, + -0.05594363, + 0.03565722, + -0.12122127, + 0.027855415, + -0.016186016, + -0.041470908, + -0.08864265, + -0.0036498592, + 0.010997135, + -0.012785444, + -0.06519897, + 0.027590077, + 0.067321666, + -0.05896251, + 0.008983399, + -0.095143765, + 0.011621533, + -0.06121848, + 0.050336383, + 0.0019902636, + 0.053377967, + -0.045287643, + 0.09474427, + -0.053598337, + 0.08048404, + -0.08297755, + 0.08607313, + 0.004596277, + 0.0204861, + 0.0132703995, + 0.0492952, + 0.003006371, + 0.024936337, + -0.021873668, + 0.11727927, + -0.043151148, + -0.0846394, + -0.048050277, + 0.0012273242, + 0.16534594, + 0.07620599, + 0.0144042745, + 0.09004986, + 0.06599925, + 0.050307803, + -0.014542778, + -0.06923349, + 0.08603958, + -0.003079753, + -0.08008583, + -0.04276064, + 0.07779741, + -0.04970902, + 0.024014566, + 0.026120175, + -0.007566401, + -0.06362058, + 0.0075124875, + -0.025173014, + 0.06797637, + 0.064056545, + -0.12027379, + -0.030917957, + 0.009303285, + 0.1108725, + 0.048372857, + -0.025575588, + -0.0063446634, + 0.011040862, + -0.03459656, + -0.0144168, + 0.048665646, + -0.009920939, + -0.0061537125, + -0.10304914, + 0.014452626, + 0.016036827, + 0.012599703, + 0.016684191, + -0.039659906, + 0.010836161, + -0.029463075, + 0.0011919601, + 0.06632273, + -0.05316992, + 0.039452244, + -0.021640282, + -0.05948179, + -0.015061293, + -0.015513855, + 0.04358236, + -0.0029279767, + 0.0860453, + -0.012484551, + -0.013506936, + 0.016622225, + 0.03162366, + -0.09996153, + -0.05663382, + -0.015155038, + 0.00578972, + 0.025347538, + -0.06958232, + 0.10877864, + -0.036945637, + 0.03478135, + 0.13662694, + -0.020611005, + 0.07592442, + 0.0036063113, + -0.09048903, + 0.016554832, + -0.04288513, + -0.027900286, + -0.07563455, + 0.030791664, + -0.033230122, + 0.018658046, + -0.043807156, + 0.029736735, + 0.10202865, + 0.009116146, + -0.09378922, + 0.099590845, + 0.0642359, + 0.0589953, + 0.05296719, + -0.07642986, + -0.11738337, + -0.05376279, + 0.09199399, + -0.0627918, + 0.03704901, + -0.037008967, + -0.05638905, + 0.009441371, + 0.04416073, + -0.03527975, + -0.03531018, + 0.07021692, + 0.05659684, + 0.099865966, + 0.076215744, + 0.043112382, + 0.007842607, + -0.039226923, + 0.006264895, + -0.03105526, + 0.060152344, + 0.040446483, + 0.10218391, + -0.07178106, + 0.015407178, + -0.06229486, + 0.0043686125, + 0.09733845, + -0.09527866, + 0.041407365, + 0.06550996, + 0.08803008, + 0.09149921, + 0.04229226, + 0.052133556, + 0.047242433, + 0.014378367, + 0.03682277, + 0.06764445, + 0.066040926, + 0.021740213, + 0.04180941, + -0.00519632, + -0.0111550195, + 0.017352529, + -0.00943155, + 0.11390086, + 0.05582122, + 0.035394136, + 0.0024461604, + 0.04081662, + -0.0007266066, + 0.06292638, + 0.0052844593, + 0.05790997, + -0.09407522, + -0.05039574, + 0.07852171, + -0.08000922, + 0.13302545, + 0.10419625, + 0.039512042, + -0.09167407, + 0.010040825, + 0.013924355, + 0.027515184, + 0.079743214, + 0.09399837, + 0.0151610905, + 0.004694856, + -0.0536953, + 0.06531984, + 0.027906924, + -0.0012715638, + 0.09168681, + -0.00026439782, + -0.0041136686, + 0.033571295, + -0.01907176, + 0.11883433, + -0.0065728375, + -0.0062215794, + -0.1049895, + -0.03321981, + -0.026450735, + 0.072518945, + -0.11240429, + -0.022515744, + -0.048495665, + -0.037087325, + 0.00032197312, + 0.051534563, + 0.046150282, + -0.08213623, + 0.09886837, + 0.041117694, + 0.05323094, + -0.05427183, + -0.022201112, + -0.024121372, + 0.012735752, + 0.1397762, + -0.007587272, + 0.05582085, + 0.06499377, + -0.018458825, + -0.021883465, + 0.032667745, + 0.02018645, + 0.040008776, + 0.07482824, + -0.024819402, + 0.045242358, + -0.06036402, + 0.025522556, + -0.025958247, + 0.018367121, + 0.029390294, + -0.031080022, + -0.010285386, + -0.007700369, + 0.045184247, + 0.044544965, + 0.029447366, + 0.014604208, + -0.09001254, + -0.09150779, + 0.048845917, + -0.005016622, + -0.030419605, + -0.021073101, + -0.028362123, + 0.04180255, + 0.011223455, + 0.026317155, + 0.07052029, + 0.04195792, + -0.010761702, + -0.054835323, + 0.047067013, + 0.04737349, + 0.09244638, + 0.096748084, + -0.03332587, + -0.009952178, + -0.0030183739, + 0.07009167, + 0.05392541, + 0.024944762, + 0.0061005787, + 0.028459419, + -0.05767917, + -0.051464006, + 0.08488547, + -0.016385203, + -0.04579279, + -0.084523976, + -0.032011546, + -0.007594041, + -0.06051386, + -0.046265714, + -0.027389096, + -0.044890895, + -0.0022862924, + -0.1268961, + -0.037864592, + 0.024412185, + -0.07392371, + -0.014362709, + 0.07425692, + 0.022583768, + 0.011156761, + -0.057216533, + -0.039548866, + -0.018076254, + -0.05556914, + -0.057198036, + -0.03188685, + 0.090208404, + 0.10571588, + 0.01070536, + 0.08128956, + 0.017667988, + -0.10340015, + 0.07804198, + -0.019781966, + 0.06535109, + -0.07777538, + -0.025819557, + -0.08128869, + -0.034394037, + 0.019422948, + -0.039221227, + -0.08033355, + -0.02329798, + -0.0962552, + -0.016624983, + 0.038193095, + -0.06870783, + -0.033954047, + -0.0025311739, + -0.114151455, + -0.00511124, + -0.06920173, + 0.044555113, + 0.10051683, + 0.04055453, + -0.06167893, + -0.01584111, + 0.0030792183, + 4.6655536e-05, + -0.026384909, + -0.012856535, + -0.06174471, + 0.0024448705, + -0.022707395, + 0.066114195, + -0.010608763, + -0.01576041, + -0.0010933182, + 0.03396316, + 0.008329627, + -0.060327142, + -0.05505636, + -0.028406821, + -0.025708841, + 0.016102789, + 0.03405433, + 0.007868113, + 0.13327968, + 0.072789304, + -0.08000951, + -0.050192088, + -0.05803803, + -0.050078847, + -0.01996999, + 0.043255676, + -0.04441973, + 0.08783117, + 0.002935635, + 0.040976398, + -0.01976899, + 0.018852778, + -0.03215457, + -0.04958742, + 0.015443288, + 0.010633601, + -0.074571095, + 0.053966194, + -0.01581196, + -0.04183213, + -0.04719714, + 0.033312585, + 0.011825424, + -0.029853545, + -0.050666492, + -0.08864941, + -0.022672195, + 0.0724055, + 0.0037794008, + 0.055587664, + -0.13644798, + 0.022921626, + 0.1152114, + 0.07047247, + 0.030930748, + -0.0052061337, + 0.044788003, + -0.08634308, + -0.10505402, + -0.025340958, + -0.08207144, + 0.059532717, + -0.0062416205, + 0.1022889, + 0.010608143, + 0.041661825, + -0.097806565, + 0.0038305484, + 0.05404457, + 0.032105837, + 0.06415997, + -0.049071103, + -0.03720757, + -0.023321476, + 0.12579422, + 0.043440778, + -0.011532883, + -0.05620173, + 0.005197981, + -0.12449035, + 0.008241525, + -0.10594952, + 0.102292866, + -0.0699, + -0.11592147, + 0.06966665, + -0.027437769, + -0.014774349, + 0.018875254, + -0.017957961, + 0.091627896, + 0.04989476, + 0.0798358, + 0.04239699, + -0.007844917, + -0.06630319, + 0.052326147, + 0.02648383, + 0.044119354, + -0.06851671, + 0.15443392, + -0.020682698, + -0.03766801, + 0.0155308945, + -0.063717306, + 0.0006521008, + -0.05569479, + -0.043325484, + -0.014842672, + -0.025855135, + 0.017403143, + -0.011325402, + 0.054577086, + 0.02011184, + -0.09925977, + -0.0069759586, + -0.03428202, + 0.0034359726, + -0.15824135, + 0.000930797, + -0.113140985, + -0.044972613, + -0.02884488, + -0.06731342, + 0.04106218, + 0.028871017, + -0.011909599, + 0.03274342, + 0.018106263, + -0.020201381, + 0.1281747, + 0.020703837, + 0.024401633, + 0.042717557, + 0.014739593, + 0.07050051, + 0.038078446, + -0.022462513, + -0.004700358, + -0.014908828, + 0.037429586, + 0.021075286, + -0.047952563, + -0.010115325, + 0.011719644, + 0.052587837, + -0.026325963, + 0.06416419, + 0.04302814, + -0.032076415, + 0.03226265, + 0.047885012, + -0.08571586, + 0.13789223, + -0.039638847, + 0.08949073, + 0.0019859069, + 0.054476757, + -0.04336167, + -0.12529649, + 0.013598417, + -0.046129137, + 0.0031463325, + -0.10019061, + 0.02212261, + -0.024540763, + -0.020073807, + -0.015366339, + -0.04205672, + -0.004573892, + 0.04018059, + -0.06835582, + 0.0762453, + -0.07784769, + -0.03393797, + -0.084803775, + 0.028064115, + 0.06559264, + -0.10455632, + 0.039434727, + -0.038992915, + -0.09218861, + 0.013562555, + -0.06523423, + 0.10188195, + 0.05163541, + 0.02234651, + 0.01926983, + 0.0017454309, + 0.030410308, + 0.025801515, + -0.0333776, + 0.0030322578, + 0.055338234, + -0.017410548, + 0.07205084, + 0.04127999, + 0.0026357244, + 0.00054674776, + -0.018812224, + 0.051227525, + 2.2485852e-05, + -0.04581609, + -0.106634825, + 0.018237107, + 0.048612136, + -0.018699843, + -0.035245672, + -0.0367398, + -0.09525288, + 0.05530859, + 0.023024498, + -0.05791263, + -0.011325011, + -0.055147734, + 0.02724777, + -0.10974393, + 0.015870394, + 0.053438365, + 0.032307543, + 0.055390432 + ], + "index": 0, + "object": "embedding" + } + ], + "model": "togethercomputer/m2-bert-80M-32k-retrieval", + "object": "list", + "usage": null + } + }, + "is_streaming": false + } +} diff --git a/tests/integration/recordings/responses/d85689907fec.json b/tests/integration/recordings/responses/d85689907fec.json new file mode 100644 index 000000000..793ef78ad --- /dev/null +++ b/tests/integration/recordings/responses/d85689907fec.json @@ -0,0 +1,350 @@ +{ + "request": { + "method": "POST", + "url": "https://api.together.xyz/v1/v1/chat/completions", + "headers": {}, + "body": { + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "messages": [ + { + "role": "user", + "content": "What's the name of the Sun in latin?" + } + ], + "stream": true + }, + "endpoint": "/v1/chat/completions", + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free" + }, + "response": { + "body": [ + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtQrM-62bZhn-9801a1ac2a5f9b29", + "choices": [ + { + "delta": { + "content": "The", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 791 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": "The", + "seed": null + } + ], + "created": 1758039001, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtQrM-62bZhn-9801a1ac2a5f9b29", + "choices": [ + { + "delta": { + "content": " Latin", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 20023 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " Latin", + "seed": null + } + ], + "created": 1758039001, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtQrM-62bZhn-9801a1ac2a5f9b29", + "choices": [ + { + "delta": { + "content": " name", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 836 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " name", + "seed": null + } + ], + "created": 1758039001, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtQrM-62bZhn-9801a1ac2a5f9b29", + "choices": [ + { + "delta": { + "content": " for", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 369 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " for", + "seed": null + } + ], + "created": 1758039001, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtQrM-62bZhn-9801a1ac2a5f9b29", + "choices": [ + { + "delta": { + "content": " the", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 279 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " the", + "seed": null + } + ], + "created": 1758039001, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtQrM-62bZhn-9801a1ac2a5f9b29", + "choices": [ + { + "delta": { + "content": " Sun", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 8219 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " Sun", + "seed": null + } + ], + "created": 1758039001, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtQrM-62bZhn-9801a1ac2a5f9b29", + "choices": [ + { + "delta": { + "content": " is", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 374 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " is", + "seed": null + } + ], + "created": 1758039001, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtQrM-62bZhn-9801a1ac2a5f9b29", + "choices": [ + { + "delta": { + "content": " \"", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 330 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " \"", + "seed": null + } + ], + "created": 1758039001, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtQrM-62bZhn-9801a1ac2a5f9b29", + "choices": [ + { + "delta": { + "content": "Sol", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 49912 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": "Sol", + "seed": null + } + ], + "created": 1758039001, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtQrM-62bZhn-9801a1ac2a5f9b29", + "choices": [ + { + "delta": { + "content": "\".", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 3343 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": "\".", + "seed": null + } + ], + "created": 1758039001, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtQrM-62bZhn-9801a1ac2a5f9b29", + "choices": [ + { + "delta": { + "content": "", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 128009 + }, + "finish_reason": "stop", + "index": 0, + "logprobs": null, + "text": "", + "seed": 10870795372179526000 + } + ], + "created": 1758039001, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": { + "completion_tokens": 11, + "prompt_tokens": 45, + "total_tokens": 56, + "completion_tokens_details": null, + "prompt_tokens_details": null, + "cached_tokens": 0 + } + } + } + ], + "is_streaming": true + } +} diff --git a/tests/integration/recordings/responses/f0bbea34c5cc.json b/tests/integration/recordings/responses/f0bbea34c5cc.json new file mode 100644 index 000000000..9d1f2b5b5 --- /dev/null +++ b/tests/integration/recordings/responses/f0bbea34c5cc.json @@ -0,0 +1,611 @@ +{ + "request": { + "method": "POST", + "url": "https://api.together.xyz/v1/v1/chat/completions", + "headers": {}, + "body": { + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "messages": [ + { + "role": "user", + "content": "What is the name of the US captial?" + } + ], + "stream": true + }, + "endpoint": "/v1/chat/completions", + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free" + }, + "response": { + "body": [ + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtdGc-62bZhn-9801a2b11e77499b", + "choices": [ + { + "delta": { + "content": "The", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 791 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": "The", + "seed": null + } + ], + "created": 1758039042, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtdGc-62bZhn-9801a2b11e77499b", + "choices": [ + { + "delta": { + "content": " name", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 836 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " name", + "seed": null + } + ], + "created": 1758039042, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtdGc-62bZhn-9801a2b11e77499b", + "choices": [ + { + "delta": { + "content": " of", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 315 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " of", + "seed": null + } + ], + "created": 1758039042, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtdGc-62bZhn-9801a2b11e77499b", + "choices": [ + { + "delta": { + "content": " the", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 279 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " the", + "seed": null + } + ], + "created": 1758039042, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtdGc-62bZhn-9801a2b11e77499b", + "choices": [ + { + "delta": { + "content": " US", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 2326 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " US", + "seed": null + } + ], + "created": 1758039042, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtdGc-62bZhn-9801a2b11e77499b", + "choices": [ + { + "delta": { + "content": " capital", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 6864 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " capital", + "seed": null + } + ], + "created": 1758039042, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtdGc-62bZhn-9801a2b11e77499b", + "choices": [ + { + "delta": { + "content": " is", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 374 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " is", + "seed": null + } + ], + "created": 1758039042, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtdGc-62bZhn-9801a2b11e77499b", + "choices": [ + { + "delta": { + "content": " Washington", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 6652 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " Washington", + "seed": null + } + ], + "created": 1758039042, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtdGc-62bZhn-9801a2b11e77499b", + "choices": [ + { + "delta": { + "content": ",", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 11 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": ",", + "seed": null + } + ], + "created": 1758039042, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtdGc-62bZhn-9801a2b11e77499b", + "choices": [ + { + "delta": { + "content": " D", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 423 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " D", + "seed": null + } + ], + "created": 1758039042, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtdGc-62bZhn-9801a2b11e77499b", + "choices": [ + { + "delta": { + "content": ".C", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 732 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": ".C", + "seed": null + } + ], + "created": 1758039042, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtdGc-62bZhn-9801a2b11e77499b", + "choices": [ + { + "delta": { + "content": ".", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 13 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": ".", + "seed": null + } + ], + "created": 1758039042, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtdGc-62bZhn-9801a2b11e77499b", + "choices": [ + { + "delta": { + "content": " (", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 320 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " (", + "seed": null + } + ], + "created": 1758039042, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtdGc-62bZhn-9801a2b11e77499b", + "choices": [ + { + "delta": { + "content": "short", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 8846 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": "short", + "seed": null + } + ], + "created": 1758039042, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtdGc-62bZhn-9801a2b11e77499b", + "choices": [ + { + "delta": { + "content": " for", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 369 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " for", + "seed": null + } + ], + "created": 1758039042, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtdGc-62bZhn-9801a2b11e77499b", + "choices": [ + { + "delta": { + "content": " District", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 11182 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " District", + "seed": null + } + ], + "created": 1758039042, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtdGc-62bZhn-9801a2b11e77499b", + "choices": [ + { + "delta": { + "content": " of", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 315 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " of", + "seed": null + } + ], + "created": 1758039042, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtdGc-62bZhn-9801a2b11e77499b", + "choices": [ + { + "delta": { + "content": " Columbia", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 19326 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": " Columbia", + "seed": null + } + ], + "created": 1758039042, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtdGc-62bZhn-9801a2b11e77499b", + "choices": [ + { + "delta": { + "content": ").", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 570 + }, + "finish_reason": null, + "index": 0, + "logprobs": null, + "text": ").", + "seed": null + } + ], + "created": 1758039042, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": null + } + }, + { + "__type__": "openai.types.chat.chat_completion_chunk.ChatCompletionChunk", + "__data__": { + "id": "oBUtdGc-62bZhn-9801a2b11e77499b", + "choices": [ + { + "delta": { + "content": "", + "function_call": null, + "refusal": null, + "role": "assistant", + "tool_calls": null, + "token_id": 128009 + }, + "finish_reason": "stop", + "index": 0, + "logprobs": null, + "text": "", + "seed": 10296991816860367000 + } + ], + "created": 1758039042, + "model": "meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "object": "chat.completion.chunk", + "service_tier": null, + "system_fingerprint": null, + "usage": { + "completion_tokens": 20, + "prompt_tokens": 45, + "total_tokens": 65, + "completion_tokens_details": null, + "prompt_tokens_details": null, + "cached_tokens": 0 + } + } + } + ], + "is_streaming": true + } +} diff --git a/tests/integration/suites.py b/tests/integration/suites.py index 3779b8ba0..231480447 100644 --- a/tests/integration/suites.py +++ b/tests/integration/suites.py @@ -100,6 +100,14 @@ SETUP_DEFINITIONS: dict[str, Setup] = { "text_model": "tgi/Qwen/Qwen3-0.6B", }, ), + "together": Setup( + name="together", + description="Together computer models", + defaults={ + "text_model": "together/meta-llama/Llama-3.3-70B-Instruct-Turbo-Free", + "embedding_model": "together/togethercomputer/m2-bert-80M-32k-retrieval", + }, + ), }