diff --git a/python/dataset.mdx b/python/dataset.mdx index 31a42270b..32b0ac6c0 100644 --- a/python/dataset.mdx +++ b/python/dataset.mdx @@ -17,9 +17,8 @@ class Dataset() ### \_\_init\_\_ ```python -def __init__(queries: List[Union[str, ChatCompletion]] = None, - extra_fields: Dict[str, List[Any]] = None, - data: List[Dict[str, Union[ChatCompletion, Any]]] = None, +def __init__(data: Union[str, List[str, Query, DatasetEntry]], + *, name: str = None, auto_sync: bool = False, api_key: Optional[str] = None) @@ -29,15 +28,9 @@ Initialize a local dataset of LLM queries. **Arguments**: -- `queries` - List of LLM queries to initialize the dataset with. - -- `extra_fields` - Dictionary of lists for arbitrary extra fields contained - within the dataset. - -- `data` - If neither `queries` nor `extra_fields` are specified, then this can - be specified instead, which is simply a list of dicts with each first key as - "query" and all other keys otherwise coming from the `extra_fields`. This is - the internal representation used by the class. +- `data` - The data for populating the dataset. This can either can a string + specifying an upstream dataset, a list of user prompts, a list of full + queries, or a list of dicts of queries alongside any extra fields. - `name` - The name of the dataset. diff --git a/python/evaluation.mdx b/python/evaluation.mdx index d6ad52daf..3ce27c5f7 100644 --- a/python/evaluation.mdx +++ b/python/evaluation.mdx @@ -265,4 +265,4 @@ from the other subtracted dataset. - `other` - The other dataset being added to this one. - + diff --git a/python/exceptions.mdx b/python/exceptions.mdx index e66cd3c8b..0848eee34 100644 --- a/python/exceptions.mdx +++ b/python/exceptions.mdx @@ -92,4 +92,4 @@ class InternalServerError(UnifyError) Exception raised for HTTP 500 Internal Server Error errors. - + diff --git a/python/queries/chat.mdx b/python/queries/chat.mdx index f3aa4c372..8249c3bc7 100644 --- a/python/queries/chat.mdx +++ b/python/queries/chat.mdx @@ -207,3 +207,4 @@ Starts the chat interaction loop. - `show_credits` - Whether to show credit consumption. Defaults to False. - `show_provider` - Whether to show the provider used. Defaults to False. + diff --git a/python/queries/clients.mdx b/python/queries/clients.mdx index ec937ac43..c22e639f3 100644 --- a/python/queries/clients.mdx +++ b/python/queries/clients.mdx @@ -1250,4 +1250,4 @@ class AsyncUnify(Client) Class for interacting with the Unify chat completions endpoint in a synchronous manner. - + diff --git a/python/queries/multi_llm.mdx b/python/queries/multi_llm.mdx index 292fc1c2f..955f957fc 100644 --- a/python/queries/multi_llm.mdx +++ b/python/queries/multi_llm.mdx @@ -195,4 +195,3 @@ Generate content using the Unify API. - `UnifyError` - If an error occurs during content generation. - diff --git a/python/utils/credits.mdx b/python/utils/credits.mdx index 9cceab6a6..650d4c899 100644 --- a/python/utils/credits.mdx +++ b/python/utils/credits.mdx @@ -28,4 +28,4 @@ Returns the credits remaining in the user account, in USD. - `ValueError` - If there was an HTTP error. - + diff --git a/python/utils/custom_api_keys.mdx b/python/utils/custom_api_keys.mdx index 3e268b5b8..daa9d10c8 100644 --- a/python/utils/custom_api_keys.mdx +++ b/python/utils/custom_api_keys.mdx @@ -143,4 +143,4 @@ Get a list of custom API keys associated with the user's account. A list of dictionaries containing custom API key information. Each dictionary has 'name' and 'value' keys. - + diff --git a/python/utils/custom_endpoints.mdx b/python/utils/custom_endpoints.mdx index 06ddfd0ba..58b89938a 100644 --- a/python/utils/custom_endpoints.mdx +++ b/python/utils/custom_endpoints.mdx @@ -129,4 +129,4 @@ Get a list of custom endpoints for the authenticated user. - `requests.exceptions.RequestException` - If the API request fails. - + diff --git a/python/utils/datasets.mdx b/python/utils/datasets.mdx index a783040cd..b123f2bca 100644 --- a/python/utils/datasets.mdx +++ b/python/utils/datasets.mdx @@ -147,4 +147,4 @@ Fetches a list of all uploaded datasets. - `ValueError` - If there was an HTTP error. - + diff --git a/python/utils/evaluations.mdx b/python/utils/evaluations.mdx index 6ff845661..1ea658e15 100644 --- a/python/utils/evaluations.mdx +++ b/python/utils/evaluations.mdx @@ -161,4 +161,4 @@ Get the evaluation status for a specific dataset, endpoint, and evaluator. A dictionary containing the evaluation status information. - + diff --git a/python/utils/evaluators.mdx b/python/utils/evaluators.mdx index d27989866..590425ed9 100644 --- a/python/utils/evaluators.mdx +++ b/python/utils/evaluators.mdx @@ -136,4 +136,4 @@ Get a list of available evaluators. A list of available evaluator names if successful, otherwise an empty list. - + diff --git a/python/utils/logging.mdx b/python/utils/logging.mdx index 59fcc5627..e29ecfa65 100644 --- a/python/utils/logging.mdx +++ b/python/utils/logging.mdx @@ -86,4 +86,4 @@ Get query metrics for specified parameters. A dictionary containing the query metrics. - + diff --git a/python/utils/supported_endpoints.mdx b/python/utils/supported_endpoints.mdx index da435a8f0..b66ea13a7 100644 --- a/python/utils/supported_endpoints.mdx +++ b/python/utils/supported_endpoints.mdx @@ -94,4 +94,4 @@ provider. - `BadRequestError` - If there was an HTTP error. - `ValueError` - If there was an error parsing the JSON response. - +