Skip to content

Commit

Permalink
Grazie LLM fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
waleko committed Jul 10, 2024
1 parent e81db58 commit 44a11aa
Show file tree
Hide file tree
Showing 4 changed files with 594 additions and 682 deletions.
4 changes: 2 additions & 2 deletions code_editing/configs/agents/llm_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ class LLMProfileConfig:
grazie_jwt_token: str = os.environ.get("GRAZIE_JWT_TOKEN", MISSING)
auth_type: str = AuthType.USER
client_url: str = GrazieApiGatewayUrls.STAGING
profile: LLMProfileConfig = field(default_factory=LLMProfileConfig)
profile: str = "openai-chat-gpt"


cs = ConfigStore.instance()
Expand All @@ -42,6 +42,6 @@ def create_agent_method(llm_config: ChatLLMConfig):
if target == "langchain_openai.ChatOpenAI":
return "langchain.agents.create_openai_tools_agent"
elif target == "grazie_langchain_utils.language_models.grazie.ChatGrazie":
return "grazie_langchain_utils.agents.create_grazie_tools_agent"
return "grazie_langchain_utils.agents.create_tool_calling_agent"
else:
raise ValueError(f"Unknown target: {target}")
5 changes: 5 additions & 0 deletions code_editing/scripts/conf/llm/claude-3-sonnet.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
defaults:
- grazie
- _self_

profile: anthropic-claude-3-sonnet
Loading

0 comments on commit 44a11aa

Please sign in to comment.