The flow
Starts it 6Model 8Logic 15Service 9
The steps in the order they run, from what starts it.
- 1Postgres Chat MemoryMemory Postgres ChatModel
- 2Agent LLMLm Chat Open AiModel
- 3Embeddings OpenAIEmbeddings Open AiModel
- 4When chat message receivedWebhookStarts it
- 5GDrive: Watch Knowledge Base FolderGoogle Drive triggerStarts it
- 6OpenAI: Generate EmbeddingsEmbeddings Open AiModel
- 7oader: Format Document + MetadataDocument Default Data LoaderModel
- 8AI AgentAgentModel
- 9Supabase Vector StoreVector Store SupabaseModel
- 10Sanitize QueryCodeLogic
- 11DB: Check File Already IngestedPostgresService
- 12Vector DB: Upsert Embeddings (Supabase)Vector Store SupabaseModel
- 13Check Existing SignupPostgresService
- 14Input Valid?IfLogic
- 15IF: File Exists in Ingestion LogIfLogic
- 16IF: Embedding Pipeline SuccessIfLogic
- 17Signup Already Saved?IfLogic
- 18Build Error ResponseSetLogic
- 19Skip already ingested fileNo OpLogic
- 20Code: Classify Document TypeCodeLogic
- 21Code: Aggregate Chunk CountCodeLogic
- 22DB: Log Failed IngestionPostgresService
- 23Reply to User (Skip Signup Extraction)SetLogic
- 24Fetch Full HistoryPostgresService
- 25Respond, Invalid InputRespond To WebhookStarts it
- 26GDrive: Download FileGoogle DriveService
- 27DB: Log Successful IngestionPostgresService
- 28Respond, Already RegisteredRespond To WebhookStarts it
- 29Extract Signup DataCodeLogic
- 30Extract: PDF/Text ContentExtract From FileService
- 31Signup Complete?IfLogic
- 32Code: Clean + Chunk Text (400 chars strategy)CodeLogic
- 33Save Signup to SupabasePostgresService
- 34Save Partial + FlagPostgresService
- 35Reply to User (Complete)SetLogic
- 36Reply to User (Partial)SetLogic
- 37Respond, Signup CompleteRespond To WebhookStarts it
- 38Respond, Signup PartialRespond To WebhookStarts it