listModelReadmeDriftsWithHttpInfo method

Future<Response> listModelReadmeDriftsWithHttpInfo(
  1. String id, {
  2. int? sinceTs,
  3. int? limit,
  4. int? offset,
  5. Future<void>? abortTrigger,
})

README drift stream for one model

Cost: 5 credits, flat. Every commit that changed the model's README on HF, with size_delta between commits so a consumer spots growth spurts and hard prunes without fetching each version. Poll with since_ts=<max commit_ts of your previous run> for an incremental drift feed.

Note: This method returns the HTTP Response.

Parameters:

  • String id (required):

  • int sinceTs: Unix epoch seconds. Rows with commit_ts >= it only.

  • int limit: Rows to return, 1 to 1000. Values outside the range are clamped, not rejected.

  • int offset: Rows to skip. Negative and non-numeric values are treated as 0.

Implementation

Future<Response> listModelReadmeDriftsWithHttpInfo(String id, { int? sinceTs, int? limit, int? offset, Future<void>? abortTrigger, }) async {
  // ignore: prefer_const_declarations
  final path = r'/api/v1/models/{id}/drifts'
    .replaceAll('{id}', id);

  // ignore: prefer_final_locals
  Object? postBody;

  final queryParams = <QueryParam>[];
  final headerParams = <String, String>{};
  final formParams = <String, String>{};

  if (sinceTs != null) {
    queryParams.addAll(_queryParams('', 'since_ts', sinceTs));
  }
  if (limit != null) {
    queryParams.addAll(_queryParams('', 'limit', limit));
  }
  if (offset != null) {
    queryParams.addAll(_queryParams('', 'offset', offset));
  }

  const contentTypes = <String>[];


  return apiClient.invokeAPI(
    path,
    'GET',
    queryParams,
    postBody,
    headerParams,
    formParams,
    contentTypes.isEmpty ? null : contentTypes.first,
    abortTrigger: abortTrigger,
  );
}