mirror of
https://github.com/wassname/openrouter-python-sdk-retry-errors.git
synced 2026-07-31 12:30:30 +08:00
Co-authored-by: speakeasybot <bot@speakeasyapi.dev> Co-authored-by: speakeasy-github[bot] <128539517+speakeasy-github[bot]@users.noreply.github.com>
56 lines
2.9 KiB
Python
56 lines
2.9 KiB
Python
"""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."""
|