Core Framework Overview
The Ragfish Core Framework provides the foundation for building AI-powered applications using Retrieval-Augmented Generation (RAG).
It defines the core architecture, APIs, and execution pipeline used by every Ragfish application. Whether you're building a document chatbot, an enterprise knowledge assistant, or a multi-source AI platform, every application is built on the same core framework.
The framework is designed to be modular, extensible, and TypeScript-first, allowing developers to build production-ready AI applications with a consistent programming model.
What is the Core Framework?
The Core Framework is the heart of Ragfish.
It provides the essential components responsible for:
Managing AI assistants
Handling conversations
Ingesting knowledge
Processing documents
Retrieving relevant information
Coordinating AI providers
Managing framework configuration
Defining common interfaces and types
These components work together to transform raw knowledge into intelligent, context-aware responses.
Core Framework Architecture
Every Ragfish application follows the same high-level architecture.
Knowledge Sources
│
▼
Ingestion
│
▼
Chunking
│
▼
Embeddings
│
▼
Vector Store
│
▼
Retrieval
│
▼
Chat
│
▼
AI Assistant
Each stage performs a specific responsibility and can be configured or extended independently.
Each component is covered in detail throughout this section.
Framework Design Principles
Ragfish is built around several core principles.
Modular
Each framework component has a single responsibility.
For example, switching from one vector database to another does not require changes to your chat logic or assistant implementation.
Extensible
Every major component can be extended or replaced.
Developers can create custom:
Connectors
AI providers
Vector stores
Retrievers
Chunking strategies
without modifying the framework itself.
TypeScript First
Ragfish is designed specifically for TypeScript developers.
Benefits include:
Strong typing
IntelliSense support
Compile-time validation
Consistent APIs
Improved maintainability
Enterprise Ready
The framework is designed for production workloads.
It supports:
Multiple AI providers
Multiple vector databases
Modular connectors
Streaming responses
Scalable deployments
Enterprise integrations
Request Lifecycle
Every question submitted to a Ragfish application follows the same execution pipeline.
User Question
│
▼
Generate Embedding
│
▼
Retrieve Relevant Knowledge
│
▼
Build Prompt
│
▼
Large Language Model
│
▼
Generate Response
This entire process is orchestrated by the framework, allowing developers to focus on building applications rather than managing the underlying workflow.
Package Structure
The Ragfish ecosystem is organized into modular packages.
@ragfish/core @ragfish/openai @ragfish/qdrant @ragfish/spreadsheet
The @ragfish/core package provides the framework APIs, while additional packages extend the framework with AI providers, vector stores, and connectors.
This modular architecture keeps applications lightweight and allows developers to install only the packages they need.
What You'll Learn
In the following pages, you'll explore each core component in detail.
Architecture – Understand how Ragfish works internally.
Settings – Configure the framework.
Assistant – Create and manage AI assistants.
Chat – Build conversational experiences.
Ingestion – Import knowledge into Ragfish.
Chunking – Prepare documents for semantic search.
Retrieval – Retrieve relevant information efficiently.
Interfaces – Learn the shared framework contracts.
Types – Explore the TypeScript models.
Error Handling – Handle framework and runtime errors.
Each topic builds on the previous one, giving you a complete understanding of how the Ragfish Framework operates.
Next Steps
Now that you understand the purpose and structure of the Ragfish Core Framework, continue to Architecture to explore how the framework components interact, how data flows through the system, and how a user request is processed from start to finis