_stats
StatsModelsTimeframe
Bases: StrEnum
Source code in horde_sdk/ai_horde_api/apimodels/_stats.py
ImageStatsModelsResponse
Bases: HordeResponseBaseModel
Represents the data returned from the /v2/stats/img/models endpoint.
v2 API Model: ImgModelStats
Source code in horde_sdk/ai_horde_api/apimodels/_stats.py
validate_timeframe_data
classmethod
Validate the data for a timeframe.
Parameters:
-
v(dict[str, int | None]) –The data for a timeframe.
Raises:
-
ValueError–If the data is invalid.
Returns:
-
dict[str, int]–dict[str, int]: The data for a timeframe.
Source code in horde_sdk/ai_horde_api/apimodels/_stats.py
get_api_model_name
classmethod
get_timeframe
Return the data for the given timeframe.
Parameters:
-
timeframe(StatsModelsTimeframe) –The timeframe to get the data for.
Returns:
-
dict[str, int]–dict[str, int]: The data for the given timeframe.
Source code in horde_sdk/ai_horde_api/apimodels/_stats.py
ImageStatsModelsRequest
Bases: BaseAIHordeRequest
Represents the data needed to make a request to the /v2/stats/img/models endpoint.
Source code in horde_sdk/ai_horde_api/apimodels/_stats.py
model_state
class-attribute
instance-attribute
The state of the models to get stats for. Known models are models that are known to the system.
get_api_model_name
classmethod
get_http_method
classmethod
get_api_endpoint_subpath
classmethod
get_default_success_response_type
classmethod
SinglePeriodImgStat
Bases: HordeAPIObjectBaseModel
Represents the stats for a single period of image generation.
v2 API Model: SinglePeriodImgStat
Source code in horde_sdk/ai_horde_api/apimodels/_stats.py
images
class-attribute
instance-attribute
The amount of images generated during this period.
ps
class-attribute
instance-attribute
The amount of pixelsteps generated during this period.
ImageStatsModelsTotalResponse
Bases: HordeResponseBaseModel
Represents the data returned from the /v2/stats/img/totals endpoint.
Source code in horde_sdk/ai_horde_api/apimodels/_stats.py
day
class-attribute
instance-attribute
The total stats for the past day.
hour
class-attribute
instance-attribute
The total stats for the past hour.
minute
class-attribute
instance-attribute
The total stats for the past minute.
month
class-attribute
instance-attribute
The total stats for the past month.
total
class-attribute
instance-attribute
The total stats for all time.
ImageStatsModelsTotalRequest
Bases: BaseAIHordeRequest
Represents the data needed to make a request to the /v2/stats/img/totals endpoint.
Source code in horde_sdk/ai_horde_api/apimodels/_stats.py
get_api_model_name
classmethod
get_http_method
classmethod
get_api_endpoint_subpath
classmethod
get_default_success_response_type
classmethod
TextStatsModelResponse
Bases: HordeResponseBaseModel
Represents the data returned from the /v2/stats/text/models endpoint.
Source code in horde_sdk/ai_horde_api/apimodels/_stats.py
validate_timeframe_data
classmethod
Validate the data for a timeframe.
Parameters:
-
v(dict[str, int | None]) –The data for a timeframe.
Raises:
-
ValueError–If the data is invalid.
Returns:
-
dict[str, int]–dict[str, int]: The data for a timeframe.
Source code in horde_sdk/ai_horde_api/apimodels/_stats.py
TextStatsModelsRequest
Bases: BaseAIHordeRequest
Represents the data needed to make a request to the /v2/stats/text/models endpoint.
Source code in horde_sdk/ai_horde_api/apimodels/_stats.py
get_api_model_name
classmethod
get_http_method
classmethod
get_api_endpoint_subpath
classmethod
get_default_success_response_type
classmethod
SinglePeriodTxtStat
Bases: HordeAPIObjectBaseModel
Represents the stats for a single period.
v2 API Model: SinglePeriodTxtStat
Source code in horde_sdk/ai_horde_api/apimodels/_stats.py
requests
class-attribute
instance-attribute
The number of requests made during this period.
tokens
class-attribute
instance-attribute
The number of tokens generated during this period.
TextStatsModelsTotalResponse
Bases: HordeResponseBaseModel
Represents the data returned from the /v2/stats/text/totals endpoint.
Source code in horde_sdk/ai_horde_api/apimodels/_stats.py
TextStatsModelsTotalRequest
Bases: BaseAIHordeRequest
Represents the data needed to make a request to the /v2/stats/text/totals endpoint.