develop #2

Merged
roberto merged 160 commits from develop into main 2026-06-12 15:27:23 +00:00
2 changed files with 14 additions and 10 deletions
Showing only changes of commit 297e20ce8d - Show all commits

View File

@@ -49,12 +49,19 @@ def _dt_ms_opt(dt: datetime | None) -> int | None:
def _to_data_types(values: list[str]) -> list[str]: def _to_data_types(values: list[str]) -> list[str]:
normalize = { normalize = {
"task": "tasks", "task": "tasks", "tasks": "tasks",
"note": "notes", "note": "notes", "notes": "notes",
"timeline": "timelines", "timeline": "timelines", "timelines": "timelines", "timelineEvents": "timelines",
"project": "projects", "project": "projects", "projects": "projects",
} }
return [normalize[v] for v in values if v in normalize] seen: set[str] = set()
result: list[str] = []
for v in values:
mapped = normalize.get(v)
if mapped and mapped not in seen:
seen.add(mapped)
result.append(mapped)
return result
def _to_run_log_response(log: AgentRunLog) -> AgentRunLogResponse: def _to_run_log_response(log: AgentRunLog) -> AgentRunLogResponse:

View File

@@ -295,11 +295,8 @@ class AgentCreationCheckResponse(BaseModel):
class AgentTriggerRequest(BaseModel): class AgentTriggerRequest(BaseModel):
directory: str = Field(min_length=1) directory: str = Field(min_length=1)
device_id: str = Field(default="") device_id: str = Field(default="")
what_to_extract: list[Literal["task", "note", "timeline", "project"]] = Field(min_length=1) what_to_extract: list[str] = Field(min_length=1)
actions_by_type: dict[ actions_by_type: dict[str, list[str]] | None = None
Literal["task", "note", "timeline", "project"],
list[Literal["add", "update"]],
] | None = None
batch_interval: str = Field(min_length=1) batch_interval: str = Field(min_length=1)
custom_agent_prompt: str = Field(min_length=1) custom_agent_prompt: str = Field(min_length=1)
active_agents: int = Field(ge=0, default=0) active_agents: int = Field(ge=0, default=0)