Introduction
Ollama allows you to run large language models locally on your own hardware. By integrating Ollama with Aikeedo, you can provide AI capabilities without relying on cloud services, ensuring data privacy and reducing costs.Currently, Ollama integration is available only for the Chat tool in Aikeedo.
About Ollama
Ollama is an open-source project that simplifies running and managing large language models locally. It offers:- Easy installation and setup
- Support for various open-source models
- Local execution for enhanced privacy
- Custom model configuration
- REST API for integration
Setting Up Ollama
Step 1: Install Ollama
- macOS
- Linux
- Windows
For detailed installation instructions and troubleshooting, refer to the Ollama Installation Guide.
Step 2: Configure Your Model
- Start the Ollama service
- Pull your desired model. For example:
Step 3: Configure Server Address
By default, Ollama runs on:- Configure your firewall to allow access to port 11434
- Set up proper security measures as Ollama doesn’t include authentication by default
Integrating with Aikeedo
Step 1: Set the server address
- Log in to your Aikeedo admin panel
- Navigate to Settings → Ollama
- Enter your Ollama Server address (e.g.,
http://localhost:11434) - Click Save changes
The server address must include the scheme (http/https), host, and port number. Aikeedo calls the address you set here.
Step 2: Add your models
Ollama models are added on the Models page. Click Manage models on the Ollama settings page, or go to Settings → Models.- Click Add model and choose Ollama as the provider.
- Choose the Model type: Text for chat models, or Embedding.
- Enter the API model id exactly as Ollama names it, such as
llama3.3:70b. - Enter the Name users see and the Developer, such as Meta for Llama models.
- Set its capabilities, such as Vision and Tool calling, and its context window.
- Save, then switch the model on.
Model Configuration
You can customize model behavior using Modelfiles. Example:Hardware Requirements
Minimum requirements vary by model:- 7B models: 8GB RAM
- 13B models: 16GB RAM
- 33B+ models: 32GB+ RAM
- NVIDIA GPUs with CUDA
- AMD GPUs with ROCm
- Apple Silicon (Metal)
Best Practices
-
Model Selection:
- Start with smaller models (7B) and test performance
- Consider your hardware capabilities
- Choose models based on your specific use case
-
Performance:
- Enable GPU acceleration when available
- Monitor system resources
- Adjust model parameters for optimal performance
-
Security:
- Implement proper firewall rules
- Use reverse proxy for additional security
- Regular system updates
Troubleshooting
Common issues and solutions:-
Connection Issues:
- Verify Ollama service is running
- Check server address format
- Confirm firewall settings
-
Model Loading Failures:
- Ensure sufficient system resources
- Verify model is properly pulled
- Check model compatibility
-
Performance Issues:
- Monitor system resources
- Consider using a smaller model
- Adjust model parameters
Additional Resources
Keep Ollama and your models updated for the best performance and security.