Skip to content

Commit

Permalink
Fix Default LLMs (#23)
Browse files Browse the repository at this point in the history
* Fix Default LLMs

* Code Cleanup
  • Loading branch information
david-oplatka authored Oct 21, 2024
1 parent 8fe7bbb commit 7a22e14
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions vectara_agentic/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,23 +31,23 @@ def _get_llm_params_for_role(role: LLMRole) -> Tuple[ModelProvider, str]:
"""Get the model provider and model name for the specified role."""
if role == LLMRole.TOOL:
model_provider = ModelProvider(
os.getenv("VECTARA_AGENTIC_TOOL_LLM_PROVIDER", str(DEFAULT_MODEL_PROVIDER))
os.getenv("VECTARA_AGENTIC_TOOL_LLM_PROVIDER", DEFAULT_MODEL_PROVIDER.value)
)
model_name = os.getenv(
"VECTARA_AGENTIC_TOOL_MODEL_NAME",
provider_to_default_model_name.get(model_provider),
)
else:
model_provider = ModelProvider(
os.getenv("VECTARA_AGENTIC_MAIN_LLM_PROVIDER", str(DEFAULT_MODEL_PROVIDER))
os.getenv("VECTARA_AGENTIC_MAIN_LLM_PROVIDER", DEFAULT_MODEL_PROVIDER.value)
)
model_name = os.getenv(
"VECTARA_AGENTIC_MAIN_MODEL_NAME",
provider_to_default_model_name.get(model_provider),
)

agent_type = AgentType(
os.getenv("VECTARA_AGENTIC_AGENT_TYPE", str(AgentType.OPENAI))
os.getenv("VECTARA_AGENTIC_AGENT_TYPE", AgentType.OPENAI.value)
)
if (
role == LLMRole.MAIN
Expand Down

0 comments on commit 7a22e14

Please sign in to comment.