support clickup in reseacher agents

This commit is contained in:
CREDO23 2025-07-30 21:30:56 +02:00
parent ede3dce9af
commit 0348aff483
2 changed files with 27 additions and 0 deletions

View file

@ -945,6 +945,32 @@ async def fetch_relevant_documents(
)
}
)
elif connector == "CLICKUP_CONNECTOR":
(
source_object,
clickup_chunks,
) = await connector_service.search_clickup(
user_query=reformulated_query,
user_id=user_id,
search_space_id=search_space_id,
top_k=top_k,
search_mode=search_mode,
)
# Add to sources and raw documents
if source_object:
all_sources.append(source_object)
all_raw_documents.extend(clickup_chunks)
# Stream found document count
if streaming_service and writer:
writer(
{
"yield_value": streaming_service.format_terminal_info_delta(
f"📋 Found {len(clickup_chunks)} ClickUp tasks related to your query"
)
}
)
except Exception as e:
error_message = f"Error searching connector {connector}: {e!s}"