Skip to main content
apps/agent is a queue-driven TypeScript process. It does not expose customer APIs; it consumes work from Redis, calls AI and data services, publishes ordered results, and exposes a small health server on port 4010 by default.

Started workers

Internal layers

Provider architecture

LLM and embedding implementations conform to base interfaces and are selected by ProviderFactory. The current source includes AWS Bedrock, Hugging Face, Ollama, and OpenAI providers. A registry describes capabilities such as streaming and tool support, while routing code tracks health and can apply an ordered fallback chain.
The model and embedding dimensions must agree with the Qdrant collection. Changing embedding models without rebuilding vectors can cause dimension errors or poor retrieval quality.

Reliability behavior

  • Conversation gates prevent stale jobs from replying after closure, assignment, or escalation.
  • URL ingestion uses a distributed lock to prevent duplicate crawls.
  • Streaming chunks are sequence-numbered so the gateway can preserve order.
  • Provider failure returns a safe message and can auto-escalate when human fallback is enabled.
  • Agent runs record steps, duration, usage, status, and error information through the internal gateway API.
  • Graceful shutdown flushes observability data and closes every worker plus the health server.

Agent pipeline

Follow gates, context, retrieval, model execution, and output.

Tool calling

Review the built-in action surface and security context.

Knowledge ingestion

See how sources become tenant-filtered vectors.

Observability

Track latency, tokens, cost estimates, steps, and errors.
Last modified on July 17, 2026