Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dev -> main #1049

Merged
merged 7 commits into from
Jan 13, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,10 @@
from ...common.utils.db_exceptions import common_db_exceptions
from ..utils import pg_query, rewrap_exceptions, wrap_in_class

# FIXME: We should use latest_transitions instead of transitions
# Query to get a paused execution token
get_paused_execution_token_query = """
SELECT * FROM latest_transitions
SELECT * FROM transitions
WHERE
execution_id = $1
AND type = 'wait'
Expand Down
14 changes: 5 additions & 9 deletions agents-api/agents_api/routers/agents/__init__.py
Original file line number Diff line number Diff line change
@@ -1,19 +1,15 @@
# ruff: noqa: F401

from .create_agent import create_agent

# from .create_agent_tool import create_agent_tool
from .create_agent_tool import create_agent_tool
from .create_or_update_agent import create_or_update_agent
from .delete_agent import delete_agent

# from .delete_agent_tool import delete_agent_tool
from .delete_agent_tool import delete_agent_tool
from .get_agent_details import get_agent_details

# from .list_agent_tools import list_agent_tools
from .list_agent_tools import list_agent_tools
from .list_agents import list_agents
from .patch_agent import patch_agent

# from .patch_agent_tool import patch_agent_tool
from .patch_agent_tool import patch_agent_tool
from .router import router
from .update_agent import update_agent
# from .update_agent_tool import update_agent_tool
from .update_agent_tool import update_agent_tool
6 changes: 4 additions & 2 deletions agents-api/agents_api/routers/agents/create_agent_tool.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,12 @@ async def create_agent_tool(
x_developer_id: Annotated[UUID, Depends(get_developer_id)],
data: CreateToolRequest,
) -> ResourceCreatedResponse:
tool = await create_tools_query(
tools = await create_tools_query(
developer_id=x_developer_id,
agent_id=agent_id,
data=[data],
)[0]
)

tool = tools[0]

return ResourceCreatedResponse(id=tool.id, created_at=tool.created_at, jobs=[])
Loading