Skip to content

Commit

Permalink
Pulling in latest fh-llm-client for CommonLLMNames (#810)
Browse files Browse the repository at this point in the history
  • Loading branch information
jamesbraza authored Jan 14, 2025
1 parent e5b6447 commit bdb1a3b
Show file tree
Hide file tree
Showing 13 changed files with 6,423 additions and 5,022 deletions.
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ repos:
- aiohttp>=3.10.6 # Match pyproject.toml
- PyMuPDF>=1.24.12
- anyio
- fh-llm-client>=0.0.3 # Match pyproject.toml
- fh-llm-client>=0.0.9 # Match pyproject.toml
- fhaviary[llm]>=0.14 # Match pyproject.toml
- ldp>=0.17 # Match pyproject.toml
- html2text
Expand Down
13 changes: 9 additions & 4 deletions paperqa/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,12 @@

import anyio
from aviary.core import ToolSelector
from llmclient import EmbeddingModel, LiteLLMModel, embedding_model_factory
from llmclient import (
CommonLLMNames,
EmbeddingModel,
LiteLLMModel,
embedding_model_factory,
)
from pydantic import (
BaseModel,
ConfigDict,
Expand Down Expand Up @@ -438,7 +443,7 @@ class AgentSettings(BaseModel):
model_config = ConfigDict(extra="forbid")

agent_llm: str = Field(
default="gpt-4o-2024-08-06",
default=CommonLLMNames.GPT_4O.value,
description="Model to use for agent.",
)

Expand Down Expand Up @@ -596,7 +601,7 @@ class Settings(BaseSettings):
model_config = SettingsConfigDict(extra="ignore")

llm: str = Field(
default="gpt-4o-2024-08-06",
default=CommonLLMNames.GPT_4O.value,
description=(
"Default LLM for most things, including answers. Should be 'best' LLM."
),
Expand All @@ -612,7 +617,7 @@ class Settings(BaseSettings):
),
)
summary_llm: str = Field(
default="gpt-4o-2024-08-06",
default=CommonLLMNames.GPT_4O.value,
description="Default LLM for summaries and parsing citations.",
)
summary_llm_config: dict | None = Field(
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ dependencies = [
"PyMuPDF>=1.24.12", # For pymupdf.set_messages addition
"aiohttp>=3.10.6", # TODO: remove in favor of httpx, pin for aiohttp.ClientConnectionResetError
"anyio",
"fh-llm-client>=0.0.3", # Pin for EmbeddingModel
"fh-llm-client>=0.0.9", # Pin for CommonLLMNames
"fhaviary[llm]>=0.14", # For MultipleChoiceQuestion
"html2text", # TODO: evaluate moving to an opt-in dependency
"httpx",
Expand Down
247 changes: 138 additions & 109 deletions tests/cassettes/TestTaskDataset.test_tool_failure.yaml

Large diffs are not rendered by default.

2,294 changes: 1,152 additions & 1,142 deletions tests/cassettes/test_docs_lifecycle.yaml

Large diffs are not rendered by default.

1,299 changes: 969 additions & 330 deletions tests/cassettes/test_partitioning_fn_docs[False].yaml

Large diffs are not rendered by default.

Loading

0 comments on commit bdb1a3b

Please sign in to comment.