nemo_microservices.resources.evaluation.configs#

Module Contents#

Classes#

API#

class nemo_microservices.resources.evaluation.configs.AsyncConfigsResource(
client: nemo_microservices._client.AsyncNeMoMicroservices,
)#

Bases: nemo_microservices._resource.AsyncAPIResource

Initialization

async create(
*,
type: str,
custom_fields: Dict[str, object] | nemo_microservices._types.Omit = omit,
description: str | nemo_microservices._types.Omit = omit,
groups: Dict[str, nemo_microservices.types.group_config_param.GroupConfigParam] | nemo_microservices._types.Omit = omit,
name: str | nemo_microservices._types.Omit = omit,
namespace: str | nemo_microservices._types.Omit = omit,
ownership: nemo_microservices.types.shared_params.ownership.Ownership | nemo_microservices._types.Omit = omit,
params: nemo_microservices.types.evaluation_params_param.EvaluationParamsParam | nemo_microservices._types.Omit = omit,
project: str | nemo_microservices._types.Omit = omit,
tasks: Dict[str, nemo_microservices.types.task_config_param.TaskConfigParam] | nemo_microservices._types.Omit = omit,
extra_headers: nemo_microservices._types.Headers | None = None,
extra_query: nemo_microservices._types.Query | None = None,
extra_body: nemo_microservices._types.Body | None = None,
timeout: float | httpx.Timeout | None | nemo_microservices._types.NotGiven = not_given,
) nemo_microservices.types.evaluation_config.EvaluationConfig#

Create a new evaluation config.

Args: type: The type of the evaluation, e.g., ‘mmlu’, ‘big_code’.For custom evaluations, this is set to custom.

custom_fields: A set of custom fields that the user can define and use for various purposes.

description: The description of the entity.

groups: Evaluation tasks belonging to the evaluation.

name: The name of the entity. Must be unique inside the namespace. If not specified, it will be the same as the automatically generated id.

namespace: The namespace of the entity. This can be missing for namespace entities or in deployments that don’t use namespaces.

ownership: Information about ownership of an entity.

  If the entity is a namespace, the `access_policies` will typically apply to all
  entities inside the namespace.

params: Global parameters for an evaluation.

project: The URN of the project associated with this entity.

tasks: Evaluation tasks belonging to the evaluation.

extra_headers: Send extra headers

extra_query: Add additional query parameters to the request

extra_body: Add additional JSON properties to the request

timeout: Override the client-level default timeout for this request, in seconds

async delete(
config_name: str,
*,
namespace: str,
extra_headers: nemo_microservices._types.Headers | None = None,
extra_query: nemo_microservices._types.Query | None = None,
extra_body: nemo_microservices._types.Body | None = None,
timeout: float | httpx.Timeout | None | nemo_microservices._types.NotGiven = not_given,
) nemo_microservices.types.shared.delete_response.DeleteResponse#

Delete Evaluation Config

Args: extra_headers: Send extra headers

extra_query: Add additional query parameters to the request

extra_body: Add additional JSON properties to the request

timeout: Override the client-level default timeout for this request, in seconds

list(
*,
filter: nemo_microservices.types.evaluation_config_filter_param.EvaluationConfigFilterParam | nemo_microservices._types.Omit = omit,
page: int | nemo_microservices._types.Omit = omit,
page_size: int | nemo_microservices._types.Omit = omit,
search: nemo_microservices.types.evaluation.evaluation_config_search_param.EvaluationConfigSearchParam | nemo_microservices._types.Omit = omit,
sort: nemo_microservices.types.shared.generic_sort_field.GenericSortField | nemo_microservices._types.Omit = omit,
extra_headers: nemo_microservices._types.Headers | None = None,
extra_query: nemo_microservices._types.Query | None = None,
extra_body: nemo_microservices._types.Body | None = None,
timeout: float | httpx.Timeout | None | nemo_microservices._types.NotGiven = not_given,
) nemo_microservices._base_client.AsyncPaginator[nemo_microservices.types.evaluation_config.EvaluationConfig, nemo_microservices.pagination.AsyncDefaultPagination[nemo_microservices.types.evaluation_config.EvaluationConfig]]#

List available evaluation configs.

Args: filter: Filter configs on various criteria.

page: Page number.

page_size: Page size.

search: Search evaluation configs using substring matching. You can combine multiple search fields and filters.

  For example:

  - `?search[name]=llama-benchmark`: searches all configs with 'llama-benchmark'
    in the name.
  - `?search[type]=classification`: searches all configs with 'classification' in
    the type.
  - `?search[tasks]=accuracy`: searches all configs with 'accuracy' in the tasks.
  - `?search[name]=llama-benchmark&search[type]=classification`: searches all
    configs with 'llama-benchmark' in the name AND 'classification' in the type.
  - `?search[updated_at][start]=2024-01-01T00:00:00` finds all configs updated on
    or after the start date
  - `?search[created_at][start]=2022-01-01&search[updated_at][end]=2024-01-01`
    finds all configs created from start date up to and including end date

sort: The field to sort by. To sort in decreasing order, use - in front of the field name.

extra_headers: Send extra headers

extra_query: Add additional query parameters to the request

extra_body: Add additional JSON properties to the request

timeout: Override the client-level default timeout for this request, in seconds

async retrieve(
config_name: str,
*,
namespace: str,
extra_headers: nemo_microservices._types.Headers | None = None,
extra_query: nemo_microservices._types.Query | None = None,
extra_body: nemo_microservices._types.Body | None = None,
timeout: float | httpx.Timeout | None | nemo_microservices._types.NotGiven = not_given,
) nemo_microservices.types.evaluation_config.EvaluationConfig#

Get evaluation config info.

Args: extra_headers: Send extra headers

extra_query: Add additional query parameters to the request

extra_body: Add additional JSON properties to the request

timeout: Override the client-level default timeout for this request, in seconds

async update(
config_name: str,
*,
path_namespace: str,
custom_fields: Dict[str, object] | nemo_microservices._types.Omit = omit,
description: str | nemo_microservices._types.Omit = omit,
groups: Dict[str, nemo_microservices.types.group_config_param.GroupConfigParam] | nemo_microservices._types.Omit = omit,
name: str | nemo_microservices._types.Omit = omit,
body_namespace: str | nemo_microservices._types.Omit = omit,
ownership: nemo_microservices.types.shared_params.ownership.Ownership | nemo_microservices._types.Omit = omit,
params: nemo_microservices.types.evaluation_params_param.EvaluationParamsParam | nemo_microservices._types.Omit = omit,
project: str | nemo_microservices._types.Omit = omit,
tasks: Dict[str, nemo_microservices.types.task_config_param.TaskConfigParam] | nemo_microservices._types.Omit = omit,
type: str | nemo_microservices._types.Omit = omit,
extra_headers: nemo_microservices._types.Headers | None = None,
extra_query: nemo_microservices._types.Query | None = None,
extra_body: nemo_microservices._types.Body | None = None,
timeout: float | httpx.Timeout | None | nemo_microservices._types.NotGiven = not_given,
) nemo_microservices.types.evaluation_config.EvaluationConfig#

Update the evaluation config.

Args: custom_fields: A set of custom fields that the user can define and use for various purposes.

description: The description of the entity.

groups: Evaluation tasks belonging to the evaluation.

name: The name of the entity. Must be unique inside the namespace. If not specified, it will be the same as the automatically generated id.

body_namespace: The namespace of the entity. This can be missing for namespace entities or in deployments that don’t use namespaces.

ownership: Information about ownership of an entity.

  If the entity is a namespace, the `access_policies` will typically apply to all
  entities inside the namespace.

params: Global parameters for an evaluation.

project: The URN of the project associated with this entity.

tasks: Evaluation tasks belonging to the evaluation.

type: The type of the evaluation, e.g., ‘mmlu’, ‘big_code’.For custom evaluations, this is set to custom.

extra_headers: Send extra headers

extra_query: Add additional query parameters to the request

extra_body: Add additional JSON properties to the request

timeout: Override the client-level default timeout for this request, in seconds

property with_raw_response: nemo_microservices.resources.evaluation.configs.AsyncConfigsResourceWithRawResponse#

This property can be used as a prefix for any HTTP method call to return the raw response object instead of the parsed content.

For more information, see https://docs.nvidia.com/nemo/microservices/latest/pysdk/index.html#accessing-raw-response-data-e-g-headers

property with_streaming_response: nemo_microservices.resources.evaluation.configs.AsyncConfigsResourceWithStreamingResponse#

An alternative to .with_raw_response that doesn’t eagerly read the response body.

For more information, see https://docs.nvidia.com/nemo/microservices/latest/pysdk/index.html#with_streaming_response

class nemo_microservices.resources.evaluation.configs.AsyncConfigsResourceWithRawResponse(
configs: nemo_microservices.resources.evaluation.configs.AsyncConfigsResource,
)#

Initialization

class nemo_microservices.resources.evaluation.configs.AsyncConfigsResourceWithStreamingResponse(
configs: nemo_microservices.resources.evaluation.configs.AsyncConfigsResource,
)#

Initialization

class nemo_microservices.resources.evaluation.configs.ConfigsResource(client: nemo_microservices._client.NeMoMicroservices)#

Bases: nemo_microservices._resource.SyncAPIResource

Initialization

create(
*,
type: str,
custom_fields: Dict[str, object] | nemo_microservices._types.Omit = omit,
description: str | nemo_microservices._types.Omit = omit,
groups: Dict[str, nemo_microservices.types.group_config_param.GroupConfigParam] | nemo_microservices._types.Omit = omit,
name: str | nemo_microservices._types.Omit = omit,
namespace: str | nemo_microservices._types.Omit = omit,
ownership: nemo_microservices.types.shared_params.ownership.Ownership | nemo_microservices._types.Omit = omit,
params: nemo_microservices.types.evaluation_params_param.EvaluationParamsParam | nemo_microservices._types.Omit = omit,
project: str | nemo_microservices._types.Omit = omit,
tasks: Dict[str, nemo_microservices.types.task_config_param.TaskConfigParam] | nemo_microservices._types.Omit = omit,
extra_headers: nemo_microservices._types.Headers | None = None,
extra_query: nemo_microservices._types.Query | None = None,
extra_body: nemo_microservices._types.Body | None = None,
timeout: float | httpx.Timeout | None | nemo_microservices._types.NotGiven = not_given,
) nemo_microservices.types.evaluation_config.EvaluationConfig#

Create a new evaluation config.

Args: type: The type of the evaluation, e.g., ‘mmlu’, ‘big_code’.For custom evaluations, this is set to custom.

custom_fields: A set of custom fields that the user can define and use for various purposes.

description: The description of the entity.

groups: Evaluation tasks belonging to the evaluation.

name: The name of the entity. Must be unique inside the namespace. If not specified, it will be the same as the automatically generated id.

namespace: The namespace of the entity. This can be missing for namespace entities or in deployments that don’t use namespaces.

ownership: Information about ownership of an entity.

  If the entity is a namespace, the `access_policies` will typically apply to all
  entities inside the namespace.

params: Global parameters for an evaluation.

project: The URN of the project associated with this entity.

tasks: Evaluation tasks belonging to the evaluation.

extra_headers: Send extra headers

extra_query: Add additional query parameters to the request

extra_body: Add additional JSON properties to the request

timeout: Override the client-level default timeout for this request, in seconds

delete(
config_name: str,
*,
namespace: str,
extra_headers: nemo_microservices._types.Headers | None = None,
extra_query: nemo_microservices._types.Query | None = None,
extra_body: nemo_microservices._types.Body | None = None,
timeout: float | httpx.Timeout | None | nemo_microservices._types.NotGiven = not_given,
) nemo_microservices.types.shared.delete_response.DeleteResponse#

Delete Evaluation Config

Args: extra_headers: Send extra headers

extra_query: Add additional query parameters to the request

extra_body: Add additional JSON properties to the request

timeout: Override the client-level default timeout for this request, in seconds

list(
*,
filter: nemo_microservices.types.evaluation_config_filter_param.EvaluationConfigFilterParam | nemo_microservices._types.Omit = omit,
page: int | nemo_microservices._types.Omit = omit,
page_size: int | nemo_microservices._types.Omit = omit,
search: nemo_microservices.types.evaluation.evaluation_config_search_param.EvaluationConfigSearchParam | nemo_microservices._types.Omit = omit,
sort: nemo_microservices.types.shared.generic_sort_field.GenericSortField | nemo_microservices._types.Omit = omit,
extra_headers: nemo_microservices._types.Headers | None = None,
extra_query: nemo_microservices._types.Query | None = None,
extra_body: nemo_microservices._types.Body | None = None,
timeout: float | httpx.Timeout | None | nemo_microservices._types.NotGiven = not_given,
) nemo_microservices.pagination.SyncDefaultPagination[nemo_microservices.types.evaluation_config.EvaluationConfig]#

List available evaluation configs.

Args: filter: Filter configs on various criteria.

page: Page number.

page_size: Page size.

search: Search evaluation configs using substring matching. You can combine multiple search fields and filters.

  For example:

  - `?search[name]=llama-benchmark`: searches all configs with 'llama-benchmark'
    in the name.
  - `?search[type]=classification`: searches all configs with 'classification' in
    the type.
  - `?search[tasks]=accuracy`: searches all configs with 'accuracy' in the tasks.
  - `?search[name]=llama-benchmark&search[type]=classification`: searches all
    configs with 'llama-benchmark' in the name AND 'classification' in the type.
  - `?search[updated_at][start]=2024-01-01T00:00:00` finds all configs updated on
    or after the start date
  - `?search[created_at][start]=2022-01-01&search[updated_at][end]=2024-01-01`
    finds all configs created from start date up to and including end date

sort: The field to sort by. To sort in decreasing order, use - in front of the field name.

extra_headers: Send extra headers

extra_query: Add additional query parameters to the request

extra_body: Add additional JSON properties to the request

timeout: Override the client-level default timeout for this request, in seconds

retrieve(
config_name: str,
*,
namespace: str,
extra_headers: nemo_microservices._types.Headers | None = None,
extra_query: nemo_microservices._types.Query | None = None,
extra_body: nemo_microservices._types.Body | None = None,
timeout: float | httpx.Timeout | None | nemo_microservices._types.NotGiven = not_given,
) nemo_microservices.types.evaluation_config.EvaluationConfig#

Get evaluation config info.

Args: extra_headers: Send extra headers

extra_query: Add additional query parameters to the request

extra_body: Add additional JSON properties to the request

timeout: Override the client-level default timeout for this request, in seconds

update(
config_name: str,
*,
path_namespace: str,
custom_fields: Dict[str, object] | nemo_microservices._types.Omit = omit,
description: str | nemo_microservices._types.Omit = omit,
groups: Dict[str, nemo_microservices.types.group_config_param.GroupConfigParam] | nemo_microservices._types.Omit = omit,
name: str | nemo_microservices._types.Omit = omit,
body_namespace: str | nemo_microservices._types.Omit = omit,
ownership: nemo_microservices.types.shared_params.ownership.Ownership | nemo_microservices._types.Omit = omit,
params: nemo_microservices.types.evaluation_params_param.EvaluationParamsParam | nemo_microservices._types.Omit = omit,
project: str | nemo_microservices._types.Omit = omit,
tasks: Dict[str, nemo_microservices.types.task_config_param.TaskConfigParam] | nemo_microservices._types.Omit = omit,
type: str | nemo_microservices._types.Omit = omit,
extra_headers: nemo_microservices._types.Headers | None = None,
extra_query: nemo_microservices._types.Query | None = None,
extra_body: nemo_microservices._types.Body | None = None,
timeout: float | httpx.Timeout | None | nemo_microservices._types.NotGiven = not_given,
) nemo_microservices.types.evaluation_config.EvaluationConfig#

Update the evaluation config.

Args: custom_fields: A set of custom fields that the user can define and use for various purposes.

description: The description of the entity.

groups: Evaluation tasks belonging to the evaluation.

name: The name of the entity. Must be unique inside the namespace. If not specified, it will be the same as the automatically generated id.

body_namespace: The namespace of the entity. This can be missing for namespace entities or in deployments that don’t use namespaces.

ownership: Information about ownership of an entity.

  If the entity is a namespace, the `access_policies` will typically apply to all
  entities inside the namespace.

params: Global parameters for an evaluation.

project: The URN of the project associated with this entity.

tasks: Evaluation tasks belonging to the evaluation.

type: The type of the evaluation, e.g., ‘mmlu’, ‘big_code’.For custom evaluations, this is set to custom.

extra_headers: Send extra headers

extra_query: Add additional query parameters to the request

extra_body: Add additional JSON properties to the request

timeout: Override the client-level default timeout for this request, in seconds

property with_raw_response: nemo_microservices.resources.evaluation.configs.ConfigsResourceWithRawResponse#

This property can be used as a prefix for any HTTP method call to return the raw response object instead of the parsed content.

For more information, see https://docs.nvidia.com/nemo/microservices/latest/pysdk/index.html#accessing-raw-response-data-e-g-headers

property with_streaming_response: nemo_microservices.resources.evaluation.configs.ConfigsResourceWithStreamingResponse#

An alternative to .with_raw_response that doesn’t eagerly read the response body.

For more information, see https://docs.nvidia.com/nemo/microservices/latest/pysdk/index.html#with_streaming_response

class nemo_microservices.resources.evaluation.configs.ConfigsResourceWithRawResponse(
configs: nemo_microservices.resources.evaluation.configs.ConfigsResource,
)#

Initialization

class nemo_microservices.resources.evaluation.configs.ConfigsResourceWithStreamingResponse(
configs: nemo_microservices.resources.evaluation.configs.ConfigsResource,
)#

Initialization