Skip to content

Commit

Permalink
Merge pull request #1058 from julep-ai/dev
Browse files Browse the repository at this point in the history
dev -> main
  • Loading branch information
HamadaSalhab authored Jan 14, 2025
2 parents 9eb5b17 + cd1004c commit 07ce391
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions agents-api/agents_api/queries/agents/patch_agent.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,14 @@
default_settings = CASE
WHEN $7::jsonb IS NOT NULL THEN $7
ELSE default_settings
END,
instructions = CASE
WHEN $8::text[] IS NOT NULL THEN $8
ELSE instructions
END,
canonical_name = CASE
WHEN $9::citext IS NOT NULL THEN $9
ELSE canonical_name
END
WHERE agent_id = $2 AND developer_id = $1
RETURNING *;
Expand Down Expand Up @@ -72,6 +80,8 @@ async def patch_agent(
data.metadata,
data.model,
data.default_settings.model_dump() if data.default_settings else None,
[data.instructions] if isinstance(data.instructions, str) else data.instructions,
data.canonical_name,
]

return (
Expand Down

0 comments on commit 07ce391

Please sign in to comment.