Feature Proposal: Integrate OceanBase seekdb as AI-Native Database
Summary
I propose integrating OceanBase seekdb as the primary database for LemonAI to enhance knowledge retrieval, semantic search, and AI-native capabilities.
Motivation
Currently, LemonAI uses SQLite for data storage and implements basic text-based search for knowledge retrieval. While this works for basic use cases, the project could significantly benefit from an AI-native database that provides:
-
Semantic Search: Currently, knowledge retrieval uses simple text matching (includes()). seekdb enables semantic search to find relevant knowledge even when exact keywords don't match.
-
Vector Search: The codebase has commented-out vector functionality (syncQuestionVectorData), indicating interest in vector capabilities. seekdb provides built-in vector search.
-
Hybrid Search: Combine vector search, full-text search, and relational queries in a single statement for more accurate results.
-
In-Database AI: Run embedding generation, reranking, and LLM inference inside the database, reducing external API calls.
-
Better Knowledge Retrieval: The current resolveUsedKnowledgeForCategory only filters by category and agent_id. With seekdb, we can find semantically similar knowledge across categories.
Why seekdb?
Key Advantages
| Feature |
Current (SQLite) |
seekdb |
| Vector Search |
❌ |
✅ |
| Semantic Search |
❌ |
✅ |
| Hybrid Search |
❌ |
✅ |
| Full-Text Search |
⚠️ Limited |
✅ |
| Embedded Mode |
✅ |
✅ |
| MySQL Compatible |
❌ |
✅ |
| In-Database AI |
❌ |
✅ |
| OLTP Support |
✅ |
✅ |
Perfect Fit for LemonAI
- Embedded Mode: seekdb supports embedded mode (like SQLite), perfect for local deployment
- MySQL Compatible: Easy migration path, minimal code changes
- Unified Engine: Handles relational, vector, text, JSON in one database
- RAG Workflow: Built-in support for document-in/data-out RAG workflows
- Apache 2.0 License: Open source and compatible
Feature Proposal: Integrate OceanBase seekdb as AI-Native Database
Summary
I propose integrating OceanBase seekdb as the primary database for LemonAI to enhance knowledge retrieval, semantic search, and AI-native capabilities.
Motivation
Currently, LemonAI uses SQLite for data storage and implements basic text-based search for knowledge retrieval. While this works for basic use cases, the project could significantly benefit from an AI-native database that provides:
Semantic Search: Currently, knowledge retrieval uses simple text matching (
includes()). seekdb enables semantic search to find relevant knowledge even when exact keywords don't match.Vector Search: The codebase has commented-out vector functionality (
syncQuestionVectorData), indicating interest in vector capabilities. seekdb provides built-in vector search.Hybrid Search: Combine vector search, full-text search, and relational queries in a single statement for more accurate results.
In-Database AI: Run embedding generation, reranking, and LLM inference inside the database, reducing external API calls.
Better Knowledge Retrieval: The current
resolveUsedKnowledgeForCategoryonly filters by category and agent_id. With seekdb, we can find semantically similar knowledge across categories.Why seekdb?
Key Advantages
Perfect Fit for LemonAI