Skip to content

Commit

Permalink
Fix missing completion types
Browse files Browse the repository at this point in the history
  • Loading branch information
cpsievert committed Dec 3, 2024
1 parent ad96e6c commit 78f7eb9
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 4 deletions.
3 changes: 2 additions & 1 deletion chatlas/_github.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
from ._utils import MISSING, MISSING_TYPE, inform_model_default

if TYPE_CHECKING:
from ._openai import ChatCompletion
from .types.openai import ChatClientArgs, SubmitInputArgs


Expand All @@ -21,7 +22,7 @@ def ChatGithub(
base_url: str = "https://models.inference.ai.azure.com/",
seed: Optional[int] | MISSING_TYPE = MISSING,
kwargs: Optional["ChatClientArgs"] = None,
) -> Chat["SubmitInputArgs"]:
) -> Chat["SubmitInputArgs", ChatCompletion]:
"""
Chat with a model hosted on the GitHub model marketplace.
Expand Down
3 changes: 2 additions & 1 deletion chatlas/_groq.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
from ._utils import MISSING, MISSING_TYPE, inform_model_default

if TYPE_CHECKING:
from ._openai import ChatCompletion
from .types.openai import ChatClientArgs, SubmitInputArgs


Expand All @@ -21,7 +22,7 @@ def ChatGroq(
base_url: str = "https://api.groq.com/openai/v1",
seed: Optional[int] | MISSING_TYPE = MISSING,
kwargs: Optional["ChatClientArgs"] = None,
) -> Chat["SubmitInputArgs"]:
) -> Chat["SubmitInputArgs", ChatCompletion]:
"""
Chat with a model hosted on Groq.
Expand Down
3 changes: 2 additions & 1 deletion chatlas/_ollama.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
from ._turn import Turn

if TYPE_CHECKING:
from ._openai import ChatCompletion
from .types.openai import ChatClientArgs, SubmitInputArgs


Expand All @@ -21,7 +22,7 @@ def ChatOllama(
base_url: str = "http://localhost:11434/v1",
seed: Optional[int] = None,
kwargs: Optional["ChatClientArgs"] = None,
) -> Chat["SubmitInputArgs"]:
) -> Chat["SubmitInputArgs", ChatCompletion]:
"""
Chat with a local Ollama model.
Expand Down
3 changes: 2 additions & 1 deletion chatlas/_perplexity.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
from ._utils import MISSING, MISSING_TYPE, inform_model_default

if TYPE_CHECKING:
from ._openai import ChatCompletion
from .types.openai import ChatClientArgs, SubmitInputArgs


Expand All @@ -21,7 +22,7 @@ def ChatPerplexity(
base_url: str = "https://api.perplexity.ai/",
seed: Optional[int] | MISSING_TYPE = MISSING,
kwargs: Optional["ChatClientArgs"] = None,
) -> Chat["SubmitInputArgs"]:
) -> Chat["SubmitInputArgs", ChatCompletion]:
"""
Chat with a model hosted on perplexity.ai.
Expand Down

0 comments on commit 78f7eb9

Please sign in to comment.