LLM Processing
Model Configuration
The assistant uses Anthropic's Claude, selected per purpose. The customer chat
path (AGENT_CHAT) runs a single agent loop.
| Setting | Value |
|---|---|
| Model | claude-sonnet-4-5 |
| Max output tokens | 4096 |
| Temperature | 0.1 (for consistent responses) |
| Streaming | Enabled |
| Framework | LangChain createAgent (single agent — no supervisor) |
"Max output tokens" is the Anthropic
max_tokenscap — the ceiling on the length of a single generated reply, not a context-window or input budget. The model and this cap are not hardcoded in the chat path: they come from the active provider's entry inLLM_PROVIDER_CONFIG(ACTIVE_LLM_PROVIDER, currentlyanthropic→claude-sonnet-4-5/ 4096). Switching the active provider changes both, and either can be overridden per call. Other purposes pin their own values (e.g. memory/summarization onclaude-haiku-4-5) — seellm-client.service.ts(PURPOSE_DEFAULTS) andllm-provider.config.ts.
Message Processing Flow
One agent handles the whole turn — it plans, calls tools, and answers in a single flat loop. There is no routing supervisor and no subagent handoffs.
sequenceDiagram
participant User
participant MessagesService
participant Agent as Single Agent
participant CLI as cred-platform CLI
participant MCP as Residual MCP tools
User->>MessagesService: Send message
MessagesService->>MessagesService: Build context (history, memory)
MessagesService->>Agent: Discover tools, select visible set, compose skills
Agent->>CLI: e.g. lists create / company resolve / query
CLI-->>Agent: Result
Agent->>MCP: e.g. analytics / workflows / data-science
MCP-->>Agent: Tool results
Agent-->>User: Stream response text
MessagesService->>MessagesService: Save conversation, token usage
Multi-step Queries
For a request like "Find SaaS companies and create a list", the single agent does it in one loop: it calls the CLI to search, then calls the CLI again to build the list from those results, then composes the reply — no cross-agent handoff, because there is only one agent.
Tool Surface & Selection
Each turn the connector assembles the visible tool set (selectVisibleTools):
cred_platform_cli— the primary data edge (lists, company/person resolve- read, filtering/screening, chart authoring, view/report assembly, schema introspection, raw GraphQL). Always included.
- Residual MCP tools — analytics, workflows, reports, data-science, and customer-connected servers the CLI does not cover. Loaded every turn, then gated by the per-request source + vendor filters.
export_document— always included.- Built-in web search — appended by the caller.
The CLI-superseded MCP tools (entity search, list build, chart/view authoring) are dropped so the loop has one data path. See Architecture → Tool surface for the full supersede/exclude lists.
Streaming Architecture
Because there is no supervisor node, the stream is flat: every tool_use /
tool_result is top-level, which lets the deterministic rollup fire off a tool
result directly.
| Mode | What it captures | When it fires |
|---|---|---|
messages |
LLM token-by-token text output | Real-time as the LLM generates |
tools |
Tool lifecycle events (on_tool_start, on_tool_end) |
Real-time as tools execute |
updates |
Node-level state updates (token counts, conversation tracking) | After each graph node completes |
Handoff-tool filtering (
transfer_to_*/transfer_back_to_*) is a supervisor-only concern and does not apply to the single-agent path — there are no handoff tools in the stream.
System Prompt & Skills
The system prompt is assembled per turn by buildAssistantSystemPrompt:
- A single, simplified base prompt (no supervisor routing prompt, no per-domain subagent prompts).
- A CLI help snapshot so the agent knows the CLI's command surface.
- Composed skill instructions — the skill registry resolves the skills
matching the turn and folds their instructions in. Today the only skill is
reports(build mechanics + a per-turn report template). See Architecture → skill system. - On the web surface, an optional persona block (workspace/user memory + instructions).
Debug Modes
| Mode | Description |
|---|---|
[debug] |
Full MCP Request/Response debug with tool call details |
[info] |
Basic tool call notifications |
| Default | Standard processing without debug output |
File Processing
Supported File Types
Text: PDF, TXT, HTML Structured Data: CSV, Excel (XLSX/XLS), JSON Media: Images (JPG, PNG, GIF, WebP), Audio (MP3, WAV, M4A, OPUS with transcription) Documents: DOC/DOCX, PPT/PPTX
Document Export
The export_document tool generates downloadable PDF or DOCX files from text
content. It is one of the tools available to the single agent.