Get in Touch
 Duration 14 hours

Course Outline

AI Sovereignty and Local LLM Deployment

  • Risks associated with cloud LLMs: data retention, training on user inputs, and foreign jurisdiction.
  • Ollama architecture: model server, registry, and OpenAI-compatible API.
  • Comparative analysis with vLLM, llama.cpp, and Text Generation Inference.
  • Model licensing terms for Llama, Mistral, Qwen, and Gemma.

Installation and Hardware Configuration

  • Installing Ollama on Linux with support for CUDA and ROCm.
  • CPU-only fallback mechanisms and AVX/AVX2 optimization strategies.
  • Docker-based deployment and persistent volume mapping.
  • Multi-GPU configurations and VRAM allocation tactics.

Model Management

  • Retrieving models from the Ollama registry: ollama pull llama3.
  • Importing GGUF models from HuggingFace and TheBloke.
  • Trade-offs between quantization levels: Q4_K_M, Q5_K_M, and Q8_0.
  • Model switching logic and limits on concurrent model loading.

Custom Modelfiles

  • Syntax for Modelfiles: FROM, PARAMETER, SYSTEM, TEMPLATE.
  • Tuning parameters including temperature, top_p, and repeat_penalty.
  • System prompt engineering for specific role-based 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.
  • Integration with LangChain, LlamaIndex, and bespoke applications.
  • Implementing authentication and rate limiting via reverse proxy.

Performance Optimization

  • Sizing context windows and managing KV caches.
  • Batch inference and parallel request processing.
  • CPU thread allocation and NUMA topology awareness.
  • Monitoring GPU utilization and memory pressure.

Security and Compliance

  • Network isolation for model serving endpoints.
  • Pipelines for input filtering and output moderation.
  • Audit logging for prompts and completions.
  • Model provenance tracking and hash verification.

Requirements

  • Intermediate proficiency in Linux and container administration.
  • A high-level understanding of machine learning and transformer architectures.
  • Practical familiarity with REST APIs and JSON data structures.

Target Audience

  • AI engineers and developers seeking to substitute cloud LLM APIs.
  • Organizations with sensitive data constraints that prohibit cloud model usage.
  • Government and defense units requiring air-gapped language model capabilities.

Number of participants


Price per participant

Upcoming Courses

Related Categories