LLM Processing
Claude Integration
The system uses Anthropic's Claude Sonnet 4 model as the primary AI engine.
Configuration
| Setting | Value |
|---|---|
| Model | claude-sonnet-4-20250514 |
| Temperature | 0.1 (for consistent responses) |
| Max Tokens | 4096 |
| Streaming | Enabled |
System Prompts
- Slack - Optimized for Slack communication style
- Teams - Optimized for Microsoft Teams environment
- Default - General-purpose AI assistant
Tool Integration
- MCP tools for external data access
- Web search capabilities
- File processing tools
- Custom business logic tools
Message Processing Flow
- Input Validation - Validates message format and user permissions
- Content Processing - Processes text, files, and audio content
- Context Building - Retrieves conversation history and user context
- AI Processing - Sends to Claude with appropriate system prompts
- Response Generation - Streams response back to user
- Persistence - Saves conversation and usage data
Debug Modes
| Mode | Description |
|---|---|
[debug] |
Full request/response logging with tool call details |
[info] |
Basic tool call notifications |
| Default | Standard processing without debug output |
File Processing
Supported File Types
Text Files:
- PDF: Native Claude processing
- TXT: Direct text processing
- HTML: Structured content extraction
Structured Data:
- CSV: LangChain CSVLoader with column support
- Excel: XLSX/XLS processing with sheet support
- JSON: Structured data processing
Media Files:
- Images: JPG, PNG, GIF, WebP, BMP, TIFF
- Audio: MP3, WAV, M4A, OPUS (with transcription)
Documents:
- DOC/DOCX: Microsoft Word documents
- PPT/PPTX: PowerPoint presentations
File Import Workflow
- Upload - File uploaded via multipart form data
- Validation - File type and size validation
- Storage - Upload to Google Cloud Storage
- Processing - AI-powered format conversion
- Template Application - Structured data extraction
- Output Generation - Convert to requested format
- Storage - Save processed file
- Registration - Register with commercial API
- Response - Return content or download URL
Template System
interface Template {
name: string;
entityType: string;
description: string;
requiredFields: string[];
fields: string[];
}