Prerequisites
Before setting up the repository, ensure you have the following tools installed:Go (Required)
Bifrost requires Go 1.21+ for development.Node.js and npm (Required for UI development)
The UI components require Node.js 18+ and npm.Make (Required)
Required for running development commands via the Makefile.make is not installed, follow our Install make command guide.
Docker (Optional)
Only needed if you plan to build Docker images or test containerized deployments.Air (Auto-installed)
Air provides hot reloading during development. The Makefile will install it automatically when needed.Clone the Repository
core/, framework/, transports/, ui/, plugins/, docs/, etc.
Repository Structure
Bifrost uses a modular architecture with the following structure:core/schemas/ for easy extension to new AI providers.
Learn More About the Architecture:
- Request Flow - Deep dive into how requests are processed from transport to provider
- Plugin System - How plugins extend functionality
- Framework Components - Shared storage and utilities
- MCP Integration - Model Context Protocol implementation
Development Environment Setup
Quick Start (Recommended)
The fastest way to get started is using the complete development environment:- Install UI dependencies automatically
- Install Air for hot reloading
- Set up the Go workspace with local modules
- Start the Next.js development server (port 3000)
- Start the API server with UI proxy (port 8080)
The
make dev command handles all setup automatically. You can skip the manual setup steps below if this works for you.Manual Setup (Alternative)
If you prefer to set up components manually:1. Install UI Dependencies
2. Install Air for Hot Reloading
3. Set Up Go Workspace
go.work file that links all local modules for development.
4. Build the Application
5. Run the Application
Available Make Commands
The Makefile provides numerous commands for development:Development Commands
Testing Commands
Workspace Management
UI Commands
Docker Commands
Documentation
Code Quality
Environment Variables
You can customize the development environment with these variables:Understanding Bifrost Architecture
Before diving into development, it’s helpful to understand how Bifrost works internally. The architecture documentation provides detailed insights into:Core Components
- Request Flow - How requests flow through the system from transport to provider and back
- Concurrency - Worker pools and threading model
- MCP Integration - Model Context Protocol implementation
- Plugin System - How plugins extend core functionality
Framework Layer
- What is Framework - Shared storage and utilities overview
- Config Store - Configuration persistence patterns
- Log Store - Request logging and analytics
- Vector Store - Semantic search and caching
Plugins & Transports
- Plugin Architecture - Plugin development patterns and execution model
- Transport Layer - HTTP and other transport implementations
Reading the architecture documentation will help you understand where to make changes and how different components interact.
Development Workflow
1. Start Development Environment
2. Make Your Changes
- Core changes: Edit files in
core/ - API changes: Edit files in
transports/bifrost-http/ - UI changes: Edit files in
ui/ - Plugin changes: Edit files in
plugins/
3. Test Your Changes
4. Verify Code Quality
5. Build for Production
Troubleshooting
Common Issues
Go workspace issues:Getting Help
- Check logs: Development logs appear in your terminal
- Verify prerequisites: Ensure Go, Node.js, and make are properly installed
- Clean build: Run
make cleanand try again - Discord: Join our Discord community for real-time help
Next Steps
Once your development environment is running:- Explore the UI: Visit http://localhost:8080 to see the web interface
- Make API calls: Test the API endpoints at http://localhost:8080/v1/
- Understand the architecture: Read our request flow documentation to understand how Bifrost works internally
- Read the documentation: Check out our complete documentation
- Review contribution guidelines: See our code conventions and PR guidelines

