Skip to content

Commit

Permalink
fix(agents-api): fix fn calling and local deployment (#378)
Browse files Browse the repository at this point in the history
* fix(agents-api): fix fn calling and local deployment

* adding model_dump_json()
  • Loading branch information
alt-glitch authored May 31, 2024
1 parent a6631be commit bbb4544
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion agents-api/agents_api/routers/sessions/session.py
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ async def run(
# Ref: https://github.com/openai/openai-cookbook/blob/main/examples/How_to_call_functions_with_chat_models.ipynb
if not message.content and message.tool_calls:
role = "function_call"
content = message.tool_calls[0].function.model_dump()
content = message.tool_calls[0].function.model_dump_json()

elif not message.content:
raise ValueError("No content in response")
Expand Down
5 changes: 5 additions & 0 deletions deploy/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ services:
- cozo_data:/data
env_file:
- .env
ports:
- "9070:9070"

agents-api:
image: julepai/agents-api:dev
Expand Down Expand Up @@ -77,6 +79,9 @@ services:
container_name: julep-temporal
ports:
- 7233:7233
build:
context: .
dockerfile: Dockerfile.temporal
volumes:
- temporal_data:/home/temporal
env_file:
Expand Down

0 comments on commit bbb4544

Please sign in to comment.