Skip to content

Commit

Permalink
Add missing documentation to completion response.
Browse files Browse the repository at this point in the history
  • Loading branch information
Martin Reinhardt committed Dec 5, 2023
1 parent 5ece809 commit 06ce9f4
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions aleph_alpha_client/completion.py
Original file line number Diff line number Diff line change
Expand Up @@ -247,6 +247,19 @@ def _asdict(self) -> Mapping[str, Any]:

@dataclass(frozen=True)
class CompletionResponse:
"""
Describes a completion response
Parameters:
model_version:
Model name and version (if any) of the used model for inference.
completions:
List of completions; may contain only one entry if no more are requested (see parameter n).
optimized_prompt:
Describes prompt after optimizations. This field is only returned if the flag
`disable_optimizations` flag is not set and the prompt has actually changed.
"""

model_version: str
completions: Sequence[CompletionResult]
optimized_prompt: Optional[Prompt] = None
Expand Down

0 comments on commit 06ce9f4

Please sign in to comment.