Skip to content

Commit 9a261c6

Browse files
stainless-app[bot]stainless-bot
authored andcommitted
feat(api): OpenAPI spec update via Stainless API (#210)
1 parent da14f38 commit 9a261c6

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

src/openlayer/types/inference_pipelines/data_stream_params.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
from __future__ import annotations
44

5-
from typing import Dict, List, Union, Iterable
5+
from typing import Dict, List, Union, Iterable, Optional
66
from typing_extensions import Required, Annotated, TypedDict
77

88
from ..._utils import PropertyInfo
@@ -69,6 +69,9 @@ class ConfigLlmData(TypedDict, total=False):
6969
metadata: object
7070
"""Object with metadata."""
7171

72+
num_of_token_column_name: Annotated[Optional[str], PropertyInfo(alias="numOfTokenColumnName")]
73+
"""Name of the column with the total number of tokens."""
74+
7275
prompt: Iterable[ConfigLlmDataPrompt]
7376
"""Prompt for the LLM."""
7477

tests/api_resources/inference_pipelines/test_data.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ def test_method_stream_with_all_params(self, client: Openlayer) -> None:
3939
data = client.inference_pipelines.data.stream(
4040
"182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
4141
config={
42+
"num_of_token_column_name": "tokens",
4243
"context_column_name": "context",
4344
"cost_column_name": "cost",
4445
"ground_truth_column_name": "ground_truth",
@@ -155,6 +156,7 @@ async def test_method_stream_with_all_params(self, async_client: AsyncOpenlayer)
155156
data = await async_client.inference_pipelines.data.stream(
156157
"182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
157158
config={
159+
"num_of_token_column_name": "tokens",
158160
"context_column_name": "context",
159161
"cost_column_name": "cost",
160162
"ground_truth_column_name": "ground_truth",

0 commit comments

Comments
 (0)