Repository navigation
KAI-Flow v0.1 Alpha
KAI-Fusion v0.1 Alpha - First Release
Release Date: December 26, 2025
Version: 0.1.0-alpha
🎉 Welcome to KAI-Fusion!
We're thrilled to announce the first alpha release of KAI-Fusion, an enterprise-grade AI workflow orchestration platform built on LangGraph and LangChain. KAI-Fusion empowers developers and organizations to build sophisticated, visual AI workflows with a powerful drag-and-drop interface while maintaining complete control over their AI infrastructure.
🏗️ Platform Architecture
LangGraph-Based Workflow Engine
KAI-Fusion is built on LangGraph StateGraph, leveraging cutting-edge stateful workflow orchestration:
- State Management: Uses
FlowStatefor conversation and execution context management - Graph Compilation:
GraphBuildercompiles visual workflows into executable LangGraph pipelines - Node Execution:
NodeExecutorhandles node-level execution within the graph - Control Flow: Advanced control flow management with conditional branching and parallel execution
- Memory Persistence: PostgreSQL-backed memory storage with LangGraph checkpointing
Node Architecture
KAI-Fusion implements a sophisticated node classification system based on BaseNode:
- Provider Nodes - Create LangChain objects (LLMs, Tools, Embeddings)
- Processor Nodes - Orchestrate multiple inputs (Agents, Chains)
- Terminator Nodes - Transform and finalize outputs (Parsers, Formatters)
- Memory Nodes - Manage conversation state and persistence
📦 Available Nodes
🤖 LLM Nodes
OpenAI Language Model (OpenAINode)
- Description: Advanced OpenAI GPT integration with streaming support
- Supported Models: GPT-4, GPT-4-Turbo, GPT-3.5-Turbo, GPT-4o, GPT-4o-mini
- Features:
- Streaming responses with real-time output
- Temperature and token limit control
- System prompt customization
- Response format configuration (JSON, text)
- LangSmith tracing integration
- Configuration:
- API Key (credential-based authentication)
- Model selection
- Temperature (0.0 - 2.0)
- Max tokens (1 - 32000)
- Top P sampling
- Frequency/Presence penalties
OpenAI Compatible (OpenAICompatibleNode)
- Description: Universal connector for any OpenAI-compatible API endpoint
- Supported Providers:
- Commercial: OpenRouter, Groq, DeepSeek, Together AI, Perplexity
- Local: LocalAI, vLLM, Ollama (compatibility mode), LM Studio
- Self-hosted: Any OpenAI API-compatible server
- Features:
- Custom base URL configuration
- Flexible model name input
- Automatic provider-specific headers (e.g., OpenRouter)
- Streaming support
- Standard OpenAI parameters
- Optional API key (for local servers)
- Configuration:
- Base URL (e.g.,
https://openrouter.ai/api/v1,http://localhost:8080/v1) - Model name (e.g.,
anthropic/claude-3.5-sonnet,llama3-70b-8192) - API Key (credential-based, optional for local)
- Temperature (0.0 - 2.0)
- Max tokens (1 - 200000)
- Top P, Frequency/Presence penalties
- Timeout configuration
- OpenRouter-specific: Site URL and Site Name
- Base URL (e.g.,
- Use Cases:
- Access hundreds of models via OpenRouter
- Connect to local LLM inference servers
- Use alternative AI providers
- Cost optimization with cheaper providers
- Multi-provider fallback strategies
🔧 Tool Nodes
HTTP Client (HttpRequestNode)
- Description: Universal HTTP client for external API integration
- Supported Methods: GET, POST, PUT, PATCH, DELETE
- Features:
- Custom headers and authentication
- Request/response body handling
- Timeout configuration
- SSL verification control
- Jinja2 templating for dynamic requests
- Retry logic with exponential backoff
- Use Cases:
- REST API integration
- Web scraping
- External service orchestration
- Data retrieval and submission
Vector Retriever (VectorRetrieverNode)
- Description: Semantic search and document retrieval from vector databases
- Supported Backends: PGVector, Chroma, FAISS
- Features:
- Similarity search with configurable K
- MMR (Maximal Marginal Relevance) retrieval
- Metadata filtering
- Hybrid search capabilities
- Reranking with Cohere
- Configuration:
- Search type (similarity, MMR, threshold)
- Top K results (1-100)
- Score threshold (0.0-1.0)
- Fetch K for MMR
- Lambda diversity
Tavily Search (TavilySearchNode)
- Description: Web search integration powered by Tavily API
- Features:
- Real-time web search
- News and general search modes
- Configurable result count
- Domain filtering
- Search depth control
- Use Cases:
- Real-time information retrieval
- Research and fact-checking
- News aggregation
- Market intelligence
Cohere Reranker (CohereRerankerNode)
- Description: Advanced reranking for search results using Cohere's models
- Features:
- Semantic reranking
- Relevance scoring
- Top N selection
- Multi-language support
- Integration: Works seamlessly with Vector Retriever
🧠 Agent Nodes
React Agent (ReactAgentNode)
- Description: Reasoning and Acting (ReAct) agent with LangGraph integration
- Architecture: Built on LangGraph's
create_react_agent - Features:
- Multi-tool orchestration
- Step-by-step reasoning
- Memory integration
- LangSmith tracing
- Streaming support
- Error handling and recovery
- Capabilities:
- Dynamic tool selection
- Context-aware decision making
- Multi-turn conversations
- Task decomposition
- Configuration:
- LLM provider connection
- Tool connections (multiple)
- Memory connection
- Max iterations (1-50)
- Verbose logging toggle
🧮 Memory Nodes
Buffer Memory (BufferMemoryNode)
- Description: Complete conversation history storage with PostgreSQL persistence
- Features:
- Unlimited history retention
- Database persistence across sessions
- Session-aware storage
- LangSmith tracing
- Multi-tenancy support
- Use Cases:
- Long-form conversations
- Complex problem solving
- Research workflows
- Training scenarios
Conversation Memory (ConversationMemoryNode)
- Description: Sliding window memory for recent conversation context
- Features:
- Configurable window size (1-50 messages)
- Session isolation
- Memory optimization
- Lazy loading
- Auto cleanup
- Configuration:
- Window size (K messages)
- Memory key
- Compression options
- Encryption support
- Use Cases:
- Real-time chat
- Token-constrained scenarios
- Performance-critical workflows
📄 Document Loaders
Document Loader (DocumentLoaderNode)
- Description: Load and process documents from various sources
- Supported Formats: PDF, TXT, CSV, JSON, DOCX, HTML
- Features:
- Batch processing
- Metadata extraction
- Encoding detection
- Error handling
Web Scraper (WebScraperNode)
- Description: Extract content from web pages
- Features:
- HTML parsing
- Content extraction
- Link following
- Rate limiting
- User agent customization
✂️ Text Processing
Chunk Splitter (ChunkSplitterNode)
- Description: Split documents into manageable chunks for processing
- Strategies:
- Character-based splitting
- Token-based splitting
- Recursive splitting
- Semantic splitting
- Configuration:
- Chunk size
- Chunk overlap
- Separators
- Keep metadata
String Input (StringInputNode)
- Description: Manual text input for workflows
- Features:
- Multi-line text support
- Template variables
- Dynamic input injection
🔗 Vector Stores
Vector Store Orchestrator (VectorStoreOrchestratorNode)
- Description: Unified interface for vector database operations
- Supported Backends:
- PGVector (PostgreSQL)
- Chroma
- FAISS
- Pinecone
- Operations:
- Document ingestion
- Similarity search
- Metadata filtering
- Collection management
🎯 Embeddings
OpenAI Embeddings (OpenAIEmbeddingsNode)
- Description: Generate vector embeddings using OpenAI's models
- Supported Models:
- text-embedding-ada-002
- text-embedding-3-small
- text-embedding-3-large
- Features:
- Batch processing
- Dimension configuration
- Cost optimization
⚙️ Workflow Control
Start Node (StartNode)
- Description: Entry point for workflow execution
- Features:
- Initial input handling
- Variable initialization
- State setup
End Node (EndNode)
- Description: Workflow termination and output formatting
- Features:
- Output formatting (JSON, text, structured)
- Result validation
- State finalization
🎬 Trigger Nodes
Webhook Trigger (WebhookTriggerNode)
- Description: HTTP webhook for external workflow triggering
- Supported Methods: GET, POST, PUT, PATCH, DELETE, HEAD
- Features:
- Automatic endpoint generation
- Bearer token authentication
- Event type filtering
- Payload validation
- CORS support
- Rate limiting (0-1000 req/min)
- Real-time event streaming
- Configuration:
- Authentication toggle
- Allowed event types
- Max payload size (1KB-10MB)
- Timeout settings
- Endpoints:
/api/v1/webhooks/{webhook_id}- Trigger endpoint/api/v1/webhooks/{webhook_id}/stream- Event stream/api/v1/webhooks/{webhook_id}/stats- Statistics
Timer Start (TimerStartNode)
- Description: Schedule-based workflow execution
- Schedule Types:
- Interval (60s - 24h)
- Cron expression
- One-time execution
- Manual trigger
- Features:
- Automatic workflow triggering
- Timezone support (UTC, EST, PST, etc.)
- Max execution limits
- Retry on failure
- Background execution
- Configuration:
- Schedule type
- Trigger data payload
- Timeout settings
- Auto-trigger toggle
💻 Processing Nodes
Code Node (CodeNode)
- Description: Execute custom Python code within workflows
- Features:
- Sandboxed execution
- Input/output variable mapping
- Error handling
- Dependency management
🔄 Working Principles
LangGraph-Based Execution
- Workflow Definition: Users create visual workflows using drag-and-drop interface
- Graph Compilation:
GraphBuilderconverts visual workflow into LangGraph StateGraph - State Initialization:
FlowStateinitialized with user inputs and session context - Node Execution: Each node executes sequentially based on graph topology
- State Updates: Node outputs update the shared
FlowState - Memory Persistence: Conversation history saved to PostgreSQL via
BufferMemoryNode - Result Streaming: Real-time output streamed to client via WebSocket
State Management Flow
User Input
↓
FlowState Initialization
↓
GraphBuilder.compile()
↓
StateGraph Creation
↓
Node 1 Execution → State Update
↓
Node 2 Execution → State Update
↓
...
↓
Node N Execution → State Update
↓
Final State → End Node
↓
Result Output
Memory Architecture
- Session-Based: Each conversation has unique session ID
- Persistent Storage: PostgreSQL stores complete history
- Lazy Loading: Memory loaded on-demand
- Windowed Access: Configurable window for recent context
- Cross-Workflow: Memory shared across workflow rebuilds
🎨 Key Features
Visual Workflow Builder
- Drag-and-drop node interface
- Real-time validation
- Connection auto-mapping
- Visual debugging
- Workflow templates
Enterprise Security
- Authentication: JWT-based user authentication
- Authorization: Role-based access control (RBAC)
- Encryption: AES-256 encryption for sensitive data
- API Keys: Secure credential management
- Multi-tenancy: Organization-level isolation
Real-Time Processing
- WebSocket Support: Live workflow execution updates
- Streaming Responses: Real-time LLM output
- Event Broadcasting: Webhook event streaming
- Connection Pooling: Efficient resource management
Monitoring & Observability
- LangSmith Integration: Full tracing support
- Enhanced Logging: Structured JSON logging
- Performance Monitoring: Execution time tracking
- Error Tracking: Comprehensive error handling
- Analytics: Workflow execution statistics
Scalability
- Async Processing: Full async/await support
- Connection Pooling: Database connection management
- Execution Queue: Concurrent workflow handling
- Resource Limits: Configurable memory and CPU limits
- Horizontal Scaling: Stateless API design
🛠️ Technical Stack
Backend
- Framework: FastAPI 0.104+
- Language: Python 3.11+
- AI Framework: LangChain 0.1.0+, LangGraph 0.0.20+
- Database: PostgreSQL 14+ with PGVector
- ORM: SQLAlchemy 2.0+
- Message Queue: Redis (optional)
Frontend
- Framework: React 18+
- State Management: Zustand
- UI Library: Tailwind CSS
- Workflow Editor: React Flow
- HTTP Client: Axios
Infrastructure
- Container: Docker, Docker Compose
- Web Server: Uvicorn (ASGI)
- Reverse Proxy: Nginx (optional)
- Monitoring: LangSmith, Prometheus (optional)
📋 Installation
Prerequisites
- Python 3.11 or higher
- PostgreSQL 14+ with PGVector extension
- Node.js 18+ (for frontend)
- Docker & Docker Compose (optional)
Quick Start with Docker
# Clone the repository
git clone https://github.com/your-org/KAI-Fusion.git
cd KAI-Fusion
# Copy environment files
cp .env.example .env
cp backend/.env.example backend/.env
cp client/.env.example client/.env
# Configure your environment variables
# Edit .env files with your API keys and database credentials
# Start with Docker Compose
docker-compose up -d
# Access the application
# Backend API: http://localhost:8000
# Frontend: http://localhost:3000
# API Docs: http://localhost:8000/docsManual Installation
# Backend setup
cd backend
python -m venv venv
source venv/bin/activate # Windows: venv\Scripts\activate
pip install -r requirements.txt
# Database setup
# Create PostgreSQL database and install PGVector extension
psql -U postgres
CREATE DATABASE kaifusion;
\c kaifusion
CREATE EXTENSION vector;
# Run migrations
alembic upgrade head
# Start backend
uvicorn main:app --reload --host 0.0.0.0 --port 8000
# Frontend setup (in new terminal)
cd client
npm install
npm run dev📚 Getting Started
Create Your First Workflow
- Access the Platform: Navigate to
http://localhost:3000 - Login/Register: Create an account or login
- Create Workflow: Click "New Workflow"
- Add Nodes:
- Drag
StartNodeto canvas - Add
OpenAINode(configure API key) - Add
EndNode
- Drag
- Connect Nodes: Draw connections between nodes
- Configure: Set node parameters
- Execute: Click "Run" to test workflow
- Deploy: Save and deploy workflow
Example: Simple Chat Workflow
[Start] → [OpenAI LLM] → [End]
Example: RAG (Retrieval Augmented Generation)
[Start] → [Vector Retriever] → [React Agent] → [End]
↓ ↓
[OpenAI Embeddings] [OpenAI LLM]
↓
[Conversation Memory]
Example: Web Research Agent
[Timer/Webhook] → [Tavily Search] → [React Agent] → [HTTP Client] → [End]
↓ ↓
[OpenAI LLM] [Cohere Reranker]
🔧 Configuration
Environment Variables
Backend Configuration (.env)
# Database
DATABASE_URL=postgresql://user:password@localhost:5432/kaifusion
POSTGRES_PASSWORD=your_secure_password
# Security
SECRET_KEY=your-secret-key-here
ENCRYPTION_KEY=your-encryption-key-here
# AI Providers (Optional - can be set per-workflow)
OPENAI_API_KEY=sk-...
TAVILY_API_KEY=tvly-...
COHERE_API_KEY=...
# LangSmith Tracing (Optional)
LANGCHAIN_TRACING_V2=true
LANGCHAIN_API_KEY=ls__...
LANGCHAIN_PROJECT=kaifusion
# Application
APP_ENV=development
DEBUG=true
CORS_ORIGINS=http://localhost:3000Frontend Configuration (client/.env)
REACT_APP_API_URL=http://localhost:8000
REACT_APP_WS_URL=ws://localhost:8000🔐 API Documentation
REST API
- Swagger UI:
http://localhost:8000/docs - ReDoc:
http://localhost:8000/redoc - OpenAPI JSON:
http://localhost:8000/openapi.json
Key Endpoints
Workflows
POST /api/v1/workflows- Create workflowGET /api/v1/workflows- List workflowsGET /api/v1/workflows/{id}- Get workflowPUT /api/v1/workflows/{id}- Update workflowDELETE /api/v1/workflows/{id}- Delete workflowPOST /api/v1/workflows/execute- Execute workflow
Nodes
GET /api/v1/nodes- List available nodesGET /api/v1/nodes/{type}- Get node metadata
Credentials
POST /api/v1/credentials- Create credentialGET /api/v1/credentials- List credentialsPUT /api/v1/credentials/{id}- Update credentialDELETE /api/v1/credentials/{id}- Delete credential
Webhooks
POST /api/v1/webhooks/{webhook_id}- Trigger webhookGET /api/v1/webhooks/{webhook_id}/stream- Stream eventsGET /api/v1/webhooks/{webhook_id}/stats- Get statistics
🐛 Known Issues & Limitations (Alpha Release)
Current Limitations
- Node Library: Limited to core nodes (more coming in beta)
- UI Polish: Some UI elements need refinement
- Documentation: API docs are minimal (expanding in beta)
- Testing: Unit test coverage at ~60% (target: 90%)
- Performance: Not optimized for large-scale deployments yet
Known Issues
- Memory Management: High memory usage with large conversation histories
- Error Handling: Some edge cases not handled gracefully
- Workflow Export: Export feature is experimental
- Mobile Support: Limited mobile responsiveness
- Browser Compatibility: Best on Chrome/Firefox (Safari has issues)
🗺️ Roadmap
v0.2 Beta (Q1 2025)
- Additional LLM providers (Anthropic, Google, Mistral)
- Advanced vector store nodes (Pinecone, Weaviate)
- Workflow templates library
- Enhanced error handling
- Performance optimizations
- Comprehensive documentation
v1.0 Stable (Q2 2025)
- Production-ready stability
- Multi-language support
- Advanced workflow analytics
- Enterprise SSO integration
- API versioning
- Mobile app
Future Releases
- Visual workflow debugger
- A/B testing framework
- Cost optimization tools
- Custom node marketplace
- Workflow version control
- Team collaboration features
🤝 Contributing
We welcome contributions from the community! Please see CONTRIBUTING.md for guidelines.
Development Setup
# Fork the repository
git clone https://github.com/your-username/KAI-Fusion.git
cd KAI-Fusion
# Create feature branch
git checkout -b feature/your-feature-name
# Make changes and test
# ...
# Submit pull requestCode of Conduct
Please read our CODE_OF_CONDUCT.md before contributing.
📄 License
This project is open source. See LICENSE for details.
📞 Support
- Documentation: [Coming Soon]
- Issues: GitHub Issues
- Discussions: GitHub Discussions
- Email: mmetehan.aydemir@kafein.com.tr
🙏 Acknowledgments
KAI-Fusion is built on the shoulders of giants:
- LangChain Team - For the incredible LangChain framework
- LangGraph Team - For the powerful state management system
- OpenAI - For GPT models and embeddings
- FastAPI - For the amazing web framework
- React Flow - For the visual workflow editor
- PostgreSQL & PGVector - For robust vector storage
📊 Release Statistics
- Total Nodes: 25+
- Node Categories: 9
- Lines of Code: ~50,000+
- Dependencies: 40+ packages
- Documentation Pages: 15+
- Contributors: 5+
🎯 What's Next?
- Try it out: Install KAI-Fusion and create your first workflow
- Report bugs: Help us improve by reporting issues
- Request features: Tell us what you need
- Contribute: Join our community of developers
- Star the repo: Show your support on GitHub
Thank you for trying KAI-Fusion v0.1 Alpha!
We're excited to have you on this journey as we build the future of AI workflow orchestration. Your feedback and contributions are invaluable in shaping the platform.
Happy building! 🚀
Last Updated: December 26, 2025
Release: v0.1.0-alpha
Build: #1