Skip to content

v1.2.0

Latest

Choose a tag to compare

@ftsartek ftsartek released this 21 Jul 00:28
aba8a75

Changed

  • Breaking: embed() and batch_embed() now return the full EmbeddingResponse instead of bare vectors, on both clients. Get the vectors via output() (one per input, so output()[0] for embed()), and token usage via usage() - previously usage on embedding calls was unrecoverable.
  • Breaking: rerank() now returns the full RerankResponse instead of a list[RerankResult], on both clients. Get the sorted results via output() (or results), and token usage via usage().
  • Breaking: EmbeddingResponse.output() now returns validated float vectors (list[list[float]]) and raises sthai.ResponseError for non-float encoding formats or when the response carries no embeddings. The raw entries stay available on data.