A package for defining completion object models.
This helps Spark understand the schema of our completions, regardless of the model provider.
BaseCompletion
Bases: BaseModel
Completion model for defining what model was used and number of tokens.
Source code in spark_instructor/completions/base.py
| class BaseCompletion(BaseModel):
"""Completion model for defining what model was used and number of tokens."""
id: str
model: str
|
is_anthropic_available()
Check if Anthropic-related modules are available.
Source code in spark_instructor/completions/__init__.py
| def is_anthropic_available():
"""Check if Anthropic-related modules are available."""
return ANTHROPIC_AVAILABLE
|