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

feat(agents-api): Move blob storage to cozo #947

Closed
wants to merge 1 commit into from
Closed
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
3 changes: 2 additions & 1 deletion agents-api/.gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
# Local database files
cozo.db
cozo*
.cozo*
temporal.db
*.bak
*.dat
Expand Down
4 changes: 1 addition & 3 deletions agents-api/agents_api/activities/demo.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
from typing import Callable

from temporalio import activity

from ..env import testing
Expand All @@ -14,6 +12,6 @@ async def mock_demo_activity(a: int, b: int) -> int:
return a + b


demo_activity: Callable[[int, int], int] = activity.defn(name="demo_activity")(
demo_activity = activity.defn(name="demo_activity")(
demo_activity if not testing else mock_demo_activity
)
9 changes: 5 additions & 4 deletions agents-api/agents_api/activities/truncation.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@
def get_extra_entries(messages: list[Entry], token_count_threshold: int) -> list[UUID]:
raise NotImplementedError()

if not len(messages):
return messages
# if not len(messages):
# return messages

_token_cnt, _offset = 0, 0
# _token_cnt, _offset = 0, 0
# if messages[0].role == Role.system:
# token_cnt, offset = messages[0].token_count, 1

Expand All @@ -36,7 +36,8 @@ def get_extra_entries(messages: list[Entry], token_count_threshold: int) -> list
@activity.defn
@beartype
async def truncation(session_id: str, token_count_threshold: int) -> None:
session_id = UUID(session_id)
raise NotImplementedError()
# session_id = UUID(session_id)

# delete_entries(
# get_extra_entries(
Expand Down
6 changes: 6 additions & 0 deletions agents-api/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ dev = [
"ipywidgets>=8.1.5",
"julep>=1.43.1",
"jupyterlab>=4.3.1",
"pip>=24.3.1",
"poethepoet>=0.31.1",
"pyjwt>=2.10.1",
"pyright>=1.1.389",
Expand All @@ -68,6 +69,11 @@ dev = [
"ward>=0.68.0b0",
]

[tool.setuptools]
py-modules = [
"agents_api"
]

[tool.uv.sources]
litellm = { url = "https://github.com/julep-ai/litellm/archive/fix_anthropic_tool_image_content.zip" }

11 changes: 11 additions & 0 deletions agents-api/uv.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading