h2oGPTe icon

h2oGPTe

h2oGPTe is an AI-powered search assistant for your internal teams to answer questions gleaned from large volumes of documents, websites and workplace content.

Actions198

Overview

This node operation, "Returns Usage Statistics Grouped by Models," fetches usage statistics data aggregated by different AI models over a specified time interval. It is useful for monitoring and analyzing how various models are being utilized within your system or application. For example, you can track the usage of language models over the last 24 hours to understand demand patterns or resource consumption.

Practical scenarios include:

  • Monitoring model usage to optimize costs.
  • Generating reports on model performance and popularity.
  • Auditing usage for compliance or billing purposes.

Properties

Name Meaning
Interval The length of the time interval for which usage statistics will be obtained. The interval ends at the current time. Example values: "24 hours", "7 days".

Output

The output JSON contains usage statistics grouped by models for the specified interval. This typically includes metrics such as the number of requests, tokens processed, or other usage-related data per model. The exact structure depends on the API response but generally provides aggregated usage data keyed by model identifiers.

No binary data output is indicated for this operation.

Dependencies

  • Requires an API key credential for authentication with the external service.
  • The base URL for API requests is configured from credentials.
  • The node sends a GET request to the endpoint /stats/usage_by_model with the interval query parameter.

Troubleshooting

  • Missing or invalid interval: The interval property is required. Ensure it is provided in a valid format (e.g., "24 hours").
  • Authentication errors: Verify that the API key credential is correctly configured and has necessary permissions.
  • Network issues: Check connectivity to the API endpoint.
  • Unexpected API responses: Confirm that the API version and endpoint have not changed.

Links and References

  • Refer to the external API documentation for /stats/usage_by_model for detailed information on response fields and supported intervals.
  • Consult your platform's credential setup guide to configure the required API key.

Discussion