"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" from __future__ import annotations from .taskclassificationmodel import ( TaskClassificationModel, TaskClassificationModelTypedDict, ) from openrouter.types import BaseModel from typing import List from typing_extensions import TypedDict class TaskClassificationItemTypedDict(TypedDict): category_token_share: float r"""Fraction of this classification's token volume within its macro-category (0–1). Sums to 1 across all classifications sharing the same `macro_category`.""" category_usage_share: float r"""Fraction of this classification's usage within its macro-category (0–1). Sums to 1 across all classifications sharing the same `macro_category`.""" display_name: str r"""Human-readable label for the classification.""" macro_category: str r"""Coarse grouping derived from the tag prefix: `code`, `data`, `agent`, or `general`.""" models: List[TaskClassificationModelTypedDict] r"""Top models for this classification by request volume, sorted descending. Each entry reports the model's share of this classification's requests and tokens.""" tag: str r"""Classification tag identifier (e.g. `code:general_impl`, `agent:web_search`).""" token_share: float r"""Fraction of classified sampled token volume (prompt + completion) attributed to this classification (0–1). The unclassified `other` bucket is excluded from the denominator.""" usage_share: float r"""Fraction of classified sampled requests attributed to this classification (0–1). The unclassified `other` bucket is excluded from the denominator.""" class TaskClassificationItem(BaseModel): category_token_share: float r"""Fraction of this classification's token volume within its macro-category (0–1). Sums to 1 across all classifications sharing the same `macro_category`.""" category_usage_share: float r"""Fraction of this classification's usage within its macro-category (0–1). Sums to 1 across all classifications sharing the same `macro_category`.""" display_name: str r"""Human-readable label for the classification.""" macro_category: str r"""Coarse grouping derived from the tag prefix: `code`, `data`, `agent`, or `general`.""" models: List[TaskClassificationModel] r"""Top models for this classification by request volume, sorted descending. Each entry reports the model's share of this classification's requests and tokens.""" tag: str r"""Classification tag identifier (e.g. `code:general_impl`, `agent:web_search`).""" token_share: float r"""Fraction of classified sampled token volume (prompt + completion) attributed to this classification (0–1). The unclassified `other` bucket is excluded from the denominator.""" usage_share: float r"""Fraction of classified sampled requests attributed to this classification (0–1). The unclassified `other` bucket is excluded from the denominator."""