SurfSense/surfsense_backend/app/tasks
CREDO23 e9a98ecafb refactor(chat): add streaming/flows/shared/ base helpers
Six small, single-purpose modules shared by the upcoming new_chat and
resume_chat orchestrators:

* llm_bundle: dispatches negative config_id to the YAML loader and
  non-negative config_id to the DB loader, returning (llm, AgentConfig).
* pre_stream_setup: builds the connector service, resolves the
  Firecrawl API key, and returns the chat checkpointer.
* first_frames: iter_initial_frames + iter_final_frames emit the canonical
  message-start / step-start / idle / finish / done SSE envelope.
* finalize_emit: iter_token_usage_frame emits the per-turn usage frame
  from a TokenAccumulator summary.
* finally_cleanup: close_session_and_clear_ai_responding and run_gc_pass
  centralize the finally-block bookkeeping.
* span: open_chat_request_span / set_agent_mode / close_chat_request_span /
  record_outcome_attrs wrap the OpenTelemetry chat_request span.

Add-only; these are not yet wired into stream_new_chat.py.
2026-05-25 21:49:09 +02:00
..
celery_tasks feat(connectors): add retry and auth telemetry events 2026-05-22 17:50:02 +05:30
chat refactor(chat): add streaming/flows/shared/ base helpers 2026-05-25 21:49:09 +02:00
connector_indexers perf(indexers): offload sync embed_text to thread across background workers 2026-05-20 10:09:38 +02:00
document_processors perf(indexers): offload sync embed_text to thread across background workers 2026-05-20 10:09:38 +02:00
__init__.py feat: SurfSense v0.0.6 init 2025-03-14 18:53:14 -07:00
composio_indexer.py chore: ran frontend and backend linting 2026-02-01 22:54:25 +05:30
surfsense_docs_indexer.py chore: ran linting 2026-03-17 04:40:46 +05:30