Complete

class textsynthpy.Complete(text: str, reached_end: Optional[bool] = None, truncated_prompt: Optional[bool] = None, input_tokens: Optional[int] = None, output_tokens: Optional[int] = None)[source]

Object handles response form TextSynth.text_complete().

Parameters
  • text (str) – It is the completed text

  • reached_end (bool) – If true, indicate that it is the last answer. It is only useful in case of streaming output (stream = true in the request).

  • truncated_prompt (bool) – If true, indicate that the prompt was truncated because it was too large compared to the model’s maximum context length. Only the end of the prompt is used to generate the completion.

  • input_tokens (int) – Indicate the number of input tokens. It is useful to estimate the number of compute resources used by the request.

  • output_tokens (int) – Indicate the total number of generated tokens. It is useful to estimate the number of compute resources used by the request.