Thank you for sending your enquiry! One of our team members will contact you shortly.
Thank you for sending your booking! One of our team members will contact you shortly.
Duration 14 hours
Course Outline
AI Sovereignty and Local LLM Deployment
- Assessing the risks associated with cloud LLMs, including data retention, training on user inputs, and foreign jurisdiction issues.
- Exploring Ollama’s architecture, covering the model server, registry, and OpenAI-compatible API.
- Comparing Ollama with alternative tools such as vLLM, llama.cpp, and Text Generation Inference.
- Reviewing model licensing terms for Llama, Mistral, Qwen, and Gemma.
Installation and Hardware Configuration
- Installing Ollama on Linux with support for CUDA and ROCm.
- Implementing CPU-only fallbacks and leveraging AVX/AVX2 optimizations.
- Deploying via Docker and configuring persistent volume mapping.
- Setting up multi-GPU environments and defining VRAM allocation strategies.
Model Management
- Pulling models from the Ollama registry using commands like ollama pull llama3.
- Importing GGUF models from HuggingFace and TheBloke.
- Evaluating the trade-offs between quantization levels such as Q4_K_M, Q5_K_M, and Q8_0.
- Managing model switching and understanding concurrent model loading limits.
Custom Modelfiles
- Writing Modelfile syntax, including FROM, PARAMETER, SYSTEM, and TEMPLATE directives.
- Tuning parameters such as temperature, top_p, and repeat_penalty.
- Engineering system prompts to achieve role-specific behaviors.
- Creating and publishing custom models to a local registry.
API Integration
- Utilizing the OpenAI-compatible /v1/chat/completions endpoint.
- Handling streaming responses and JSON mode outputs.
- Integrating with frameworks like LangChain, LlamaIndex, and custom applications.
- Implementing authentication and rate limiting using a reverse proxy.
Performance Optimization
- Managing context window sizing and KV cache efficiency.
- Optimizing batch inference and parallel request handling.
- Allocating CPU threads with NUMA awareness.
- Monitoring GPU utilization and memory pressure.
Security and Compliance
- Implementing network isolation for model serving endpoints.
- Establishing input filtering and output moderation pipelines.
- Configuring audit logging for prompts and completions.
- Ensuring model provenance and hash verification.
Requirements
- Intermediate proficiency in Linux and container administration.
- A high-level understanding of machine learning concepts and transformer models.
- Familiarity with REST APIs and JSON structures.
Target Audience
- AI engineers and developers seeking to replace cloud LLM APIs with local alternatives.
- Organizations with data sensitivity concerns that preclude the use of cloud-based models.
- Government and defense teams requiring air-gapped language model capabilities.