AI for IT Professionals
— Complete Notes
All 12 modules. Plain language — no math, no research papers. What AI actually is, how to run it locally, how to use it daily as a DevOps or IT professional. Free to read — no signup needed.
What is AI? (Plain Language)
Not sci-fi — what AI actually is and how it got here.
What is Artificial Intelligence?
AI is software that learns patterns from data instead of following rules someone wrote. Traditional software: if X happens, do Y. AI software: here are a million examples of X and Y — figure out the pattern yourself. The result is a system that can do things no programmer explicitly programmed.
AI is not robots taking over the world. In 2026 it's autocomplete that got very good — predicting the most likely next word, pixel, or action based on billions of examples it was trained on.
| Feature | Traditional Software | AI |
|---|---|---|
| Rules | Programmer writes every rule | System learns rules from data |
| Flexibility | Only does what it was programmed for | Can handle inputs it never saw before |
| How it improves | Programmer updates the code | Train on more/better data |
| Example | if temperature > 100: send_alert() | Look at 1M server logs → predict failures |
| Good for | Defined, repeatable tasks | Pattern recognition, language, images |
Brief History — How We Got Here
1950s: Alan Turing asks "Can machines think?" — the question that started AI. 1980s–90s: Rule-based expert systems — smart but brittle, couldn't handle the real world. 2012: Deep learning breakthrough — neural networks trained on GPUs finally beat humans at image recognition. 2017: Transformers invented — the architecture behind every modern LLM. 2022: ChatGPT released — AI became something ordinary people used daily.
- AI
- Software that learns patterns from data. Umbrella term covering everything from spam filters to ChatGPT.
- LLM
- Large Language Model. An AI trained on huge amounts of text to predict and generate language. ChatGPT, Claude, Gemini are LLMs.
- Training
- The process of feeding data to an AI model so it learns patterns. Done once by the model creator — expensive, needs lots of GPUs.
- Inference
- Running an already-trained model to get answers. What you do when you use ChatGPT — much cheaper than training.
- Parameters
- The "weights" inside a neural network that encode what the model learned. GPT-4 has ~1.8 trillion parameters.
- Token
- A chunk of text — roughly 3/4 of a word. LLMs process and generate tokens, not letters or words. Costs are priced per token.
ML vs Deep Learning vs GenAI
Three terms everyone uses interchangeably — they're not the same thing.
The Three Layers — Each Builds on the Previous
AI is the broad term. Machine Learning is a type of AI. Deep Learning is a type of Machine Learning. Generative AI is a category of Deep Learning applications. Think of it as nested circles — each one is more specific than the last.
| Type | What it Does | Real Example |
|---|---|---|
| Machine Learning | Learns patterns from structured data — numbers and tables | Predict if a server will fail based on CPU/disk trends |
| Deep Learning | Uses neural networks to learn from unstructured data — images, audio, text | Detect anomalies in server logs automatically |
| Generative AI | Creates new content — text, code, images, audio | ChatGPT writing a Dockerfile for you |
| LLMs specifically | GenAI trained on text — predicts and generates language | Claude, ChatGPT, Gemini, Llama |
For IT professionals: You'll mostly work with GenAI (LLMs) for daily tasks. ML is relevant when you're deploying ML models to production — monitoring them, serving them with Docker/K8s, managing their infrastructure.
AI Tools Landscape
ChatGPT, Claude, Gemini, Grok — what each is best at and when to use which.
| Tool | Best For | Free Tier |
|---|---|---|
| ChatGPT (OpenAI) | General tasks, coding, DALL-E images, plugins | GPT-4o mini free · GPT-4o limited |
| Claude (Anthropic) | Long documents, coding, reasoning, safety-focused | Claude 3.5 Sonnet free with limits |
| Gemini (Google) | Google Workspace integration, search-connected | Gemini 1.5 Flash free |
| Grok (xAI) | Real-time X/Twitter data, less filtered responses | Free on X with limits |
| Perplexity | Search with citations — replaces Google for research | Free · Pro plan for GPT-4/Claude |
| GitHub Copilot | Code completion inside VS Code — inline suggestions | Free for students · $10/mo otherwise |
| Ollama | Run LLMs locally — private, offline, free | Completely free |
For DevOps work: Claude and ChatGPT are best for writing scripts, explaining errors, and generating configs. GitHub Copilot is best for in-editor code completion. Perplexity is best when you need an answer with a source you can verify.
Running AI Locally — Ollama
Run LLMs on your own machine — private, offline, no API cost.
What is Ollama?
Ollama is a tool that lets you download and run open-source LLMs on your own computer. No internet connection required after download. No data sent to any server. No API cost. It works from the terminal or through a browser UI. Think of it as Docker for AI models — pull a model, run it, use it.
| Feature | Ollama (Local) | ChatGPT / Claude API |
|---|---|---|
| Cost | Free — runs on your hardware | Pay per token — adds up fast |
| Privacy | Nothing leaves your machine | Your prompts go to their servers |
| Internet needed | No — works fully offline | Yes — always |
| Speed | Depends on your GPU/CPU | Fast — their servers are powerful |
| Model quality | Good — Llama3, Mistral, Phi3 | Best — GPT-4o, Claude 3.5 |
| Best for | Private data, learning, offline dev | Production apps, best quality needed |
# Install on Linux curl -fsSL https://ollama.com/install.sh | sh # Install on macOS # Download from: https://ollama.com/download/mac # Pull and run a model (downloads automatically) ollama run llama3.2 # Meta's Llama 3.2 — great general model ollama run mistral # Mistral 7B — fast, efficient ollama run phi3 # Microsoft Phi-3 — small but smart ollama run codellama # Optimised for code generation # List downloaded models ollama list # Run in API mode (works like OpenAI API) ollama serve # starts on localhost:11434 # Call it with curl curl http://localhost:11434/api/generate -d '{ "model": "llama3.2", "prompt": "Explain what a Docker container is in 2 sentences", "stream": false }' # Install Open WebUI — browser interface for Ollama docker run -d -p 3000:8080 \ -v open-webui:/app/backend/data \ --add-host=host.docker.internal:host-gateway \ ghcr.io/open-webui/open-webui:main # Then open: http://localhost:3000
Open Source Models
Llama, Mistral, Phi, Gemma — who makes them and how to pick the right one.
| Model | Made By | Best For | RAM Needed |
|---|---|---|---|
| Llama 3.2 | Meta | General purpose — best all-rounder for local use | 8GB+ |
| Mistral 7B | Mistral AI | Fast, efficient — good on weaker hardware | 6GB+ |
| Phi-3 Mini | Microsoft | Surprisingly smart for its size — low resource | 4GB+ |
| Gemma 2 | Well-rounded, Google-quality open source | 8GB+ | |
| CodeLlama | Meta | Code generation and completion | 8GB+ |
| DeepSeek Coder | DeepSeek | Strong at coding — rivals GPT-4 for code | 8GB+ |
What is HuggingFace?
HuggingFace is the GitHub of AI — a platform where anyone can publish, download, and run AI models. Over 500,000 models are available. When you see a new AI model announced, it's almost always on HuggingFace within days. You can browse, filter by task (text generation, image classification, code), and run models directly in the browser or download them.
Which to use for learning: Start with ollama run llama3.2 — it's the best balance of quality and speed for general IT tasks. For code specifically, use ollama run codellama. Both run fine on a laptop with 8GB RAM.
Alternative Platforms & Self-Hosted AI
Open WebUI, AnythingLLM, HuggingFace Spaces — beyond the terminal.
| Tool | What it Does | Install |
|---|---|---|
| Open WebUI | Browser UI for Ollama — looks like ChatGPT, works locally | Docker one-liner |
| AnythingLLM | Chat with your own documents — PDFs, Word files, notes | Desktop app download |
| LM Studio | Desktop app to download and run models with a nice GUI | Desktop app |
| LocalAI | OpenAI API-compatible local server — drop-in replacement | Docker |
| HuggingFace Spaces | Run models in the cloud free — no install needed | Browser only |
# docker-compose.yml — Ollama + Open WebUI services: ollama: image: ollama/ollama ports: - "11434:11434" volumes: - ollama:/root/.ollama # Add GPU support if you have NVIDIA: # deploy: # resources: # reservations: # devices: # - driver: nvidia # count: all open-webui: image: ghcr.io/open-webui/open-webui:main ports: - "3000:8080" environment: - OLLAMA_BASE_URL=http://ollama:11434 volumes: - open-webui:/app/backend/data depends_on: - ollama volumes: ollama: open-webui: # Run it: docker compose up -d # Open: http://localhost:3000 # Pull a model: docker exec -it ollama ollama pull llama3.2
Prompt Engineering
How to talk to AI so it gives you useful answers — not generic ones.
Why Prompt Engineering Matters
The same AI model gives completely different quality answers depending on how you ask. "Fix my code" gets a generic answer. "You are a senior Linux engineer. This bash script is supposed to monitor disk usage and send an alert if any partition exceeds 80%. It runs without error but never sends alerts. Debug it step by step and explain what's wrong." — that gets a useful answer. Prompt engineering is the skill of asking well.
── Pattern 1: Role + Task + Context ── "You are a senior DevOps engineer with 10 years of Linux experience. I have a bash script that backs up /var/www to S3 using aws-cli. It works manually but fails silently when run via cron. Diagnose the most likely causes and give me fixes for each." ── Pattern 2: Step by Step ── "Explain how Docker networking works. Do it step by step. Start with the simplest concept and build up. Use an analogy before any technical terms." ── Pattern 3: Specific Output Format ── "Write an Ansible playbook that installs nginx on RHEL 9. Requirements: - Enable nginx on boot - Open port 80 in firewalld - Deploy an index.html with content 'Hello from Ansible' - Fix SELinux context on /var/www/html Output: only the YAML, no explanation." ── Pattern 4: Debug with Error ── "I'm getting this error when running terraform apply: Error: Error creating VPC: InvalidVpcCidr.MalformedInput My main.tf has cidr_block = '10.0.0.0/8' What's wrong and how do I fix it?" ── Pattern 5: Explain in Simple Terms ── "Explain Kubernetes namespaces as if I know Linux but have never touched Kubernetes. Use a real-world analogy."
- Prompt
- The text you send to an AI. Quality of prompt = quality of answer.
- System prompt
- Instructions given to the AI before the conversation. Sets its role and behaviour.
- Context window
- How much text the AI can "see" at once. Longer = more expensive. Claude has a very large context window.
- Temperature
- Randomness setting — 0 = deterministic/focused, 1 = creative/varied. Use low for code, higher for creative writing.
- Few-shot prompting
- Give the AI 2-3 examples of what you want before asking it to do the task. Dramatically improves quality.
- Chain of thought
- Ask AI to "think step by step" — it produces better reasoning when it explains its process.
AI in DevOps Workflows
GitHub Copilot, AI-assisted debugging, writing configs and scripts with AI.
How AI Fits into Daily DevOps Work
AI doesn't replace a DevOps engineer — it removes the slow parts. Writing boilerplate Dockerfiles, researching the right Terraform resource syntax, understanding an error message you've never seen before, writing documentation nobody wants to write. AI does all of that in seconds. You focus on architecture, judgment, and the work that actually requires experience.
| Task | Before AI | With AI |
|---|---|---|
| Write a Dockerfile | Copy from docs, trial and error | Describe your app → AI writes it → you review |
| Debug an error | Google the message, read Stack Overflow | Paste error + context → AI explains + suggests fix |
| Write Ansible playbook | Check module docs, write from scratch | Describe what you need → AI writes YAML → you test |
| Understand a log | Read line by line, search each code | Paste log → AI explains what happened in plain language |
| Write bash script | Lookup syntax, test in terminal | Describe logic → AI writes → you adjust |
| Write documentation | Nobody does it | Paste your code/config → AI writes the docs |
# Install GitHub Copilot extension in VS Code # Extensions → search "GitHub Copilot" → Install # Sign in with GitHub account # Free for students → apply at: education.github.com # $10/month for individuals otherwise # How it works — as you type, Copilot suggests completions # Accept suggestion: Tab # Reject: Esc # See alternatives: Alt + ] # Copilot Chat (in VS Code sidebar) # /explain → explains selected code # /fix → suggests fix for selected code # /tests → generates unit tests # /doc → writes documentation
AI APIs — OpenAI, Claude, Gemini
Call AI from your own Python scripts — build tools that use AI.
What is an AI API?
Instead of typing into a chat interface, an API lets your code send a message to an AI and receive the response — programmatically. You build an application that uses AI as a brain. Your Python script sends a server log to the API and receives an explanation. Your CI/CD pipeline sends failing test output and receives a diagnosis. The AI becomes a component of your automation, not just a chat window.
# pip install openai from openai import OpenAI client = OpenAI(api_key="sk-your-api-key-here") # get from platform.openai.com response = client.chat.completions.create( model="gpt-4o-mini", # cheapest good model — ~$0.15 per 1M tokens messages=[ {"role": "system", "content": "You are a senior Linux sysadmin. Be concise and practical."}, {"role": "user", "content": "Explain this error: ENOSPC: no space left on device"} ] ) print(response.choices[0].message.content)
# No API key needed — runs on localhost import requests, json def ask_ollama(prompt, model="llama3.2"): response = requests.post( "http://localhost:11434/api/generate", json={"model": model, "prompt": prompt, "stream": False} ) return response.json()["response"] # Use it answer = ask_ollama("What does chmod 755 do in Linux?") print(answer)
Building Simple AI Tools
Log analyser, doc generator, simple chatbot — tools you'll actually use.
The Approach
Every useful AI tool follows the same pattern: get some input (a log file, a config, an error message), send it to an AI with a good prompt, return the result. You don't need machine learning knowledge to build these. You need Python, an API key, and a clear prompt.
#!/usr/bin/env python3 # log-analyser.py — paste a log, get a plain-language explanation import sys from openai import OpenAI client = OpenAI(api_key="your-key") # or use Ollama for free def analyse_log(log_content): prompt = f"""You are a senior Linux/DevOps engineer. Analyse this server log and provide: 1. What happened (plain language, 2 sentences max) 2. Root cause (if identifiable) 3. Recommended fix (specific commands if applicable) Log: {log_content}""" response = client.chat.completions.create( model="gpt-4o-mini", messages=[{"role":"user","content":prompt}] ) return response.choices[0].message.content # Read from file or stdin if len(sys.argv) > 1: log = open(sys.argv[1]).read() else: log = sys.stdin.read() print(analyse_log(log))
# Simple RAG (Retrieval-Augmented Generation) # Load your own docs → AI answers questions about them def chat_with_docs(docs_folder, question): # Read all markdown/text files context = "" import os for fname in os.listdir(docs_folder): if fname.endswith(('.md', '.txt')): context += open(f"{docs_folder}/{fname}").read() + "\n\n" prompt = f"""Answer this question using ONLY the documentation below. If the answer isn't in the docs, say so. Documentation: {context[:8000]} # limit to context window Question: {question}""" response = client.chat.completions.create( model="gpt-4o-mini", messages=[{"role":"user","content":prompt}] ) return response.choices[0].message.content print(chat_with_docs("./docs", "How do I configure nginx for HTTPS?"))
AI Infrastructure on Cloud
GPU instances, costs, running Ollama on EC2 — when you need cloud AI.
| Option | Cost | Speed | Use When |
|---|---|---|---|
| Laptop CPU (Ollama) | Free | Slow — 5–15 tokens/sec | Learning, private data, small models |
| AWS g4dn.xlarge (GPU) | ~$0.53/hr | Fast — 50–100 tokens/sec | Team sharing, larger models, production |
| OpenAI/Claude API | Per token | Very fast | Production apps, best model quality needed |
| HuggingFace Inference | Free tier + paid | Variable | Hosted models without managing infra |
# Launch g4dn.xlarge on AWS (NVIDIA T4 GPU) # AMI: Deep Learning AMI (Ubuntu) — GPU drivers pre-installed # SSH into your EC2, then: curl -fsSL https://ollama.com/install.sh | sh # Pull models ollama pull llama3.2 ollama pull codellama # Start Ollama listening on all interfaces (for team access) OLLAMA_HOST=0.0.0.0:11434 ollama serve & # Open EC2 Security Group: port 11434 from your team's IPs only # Deploy Open WebUI for browser access docker run -d -p 80:8080 \ -e OLLAMA_BASE_URL=http://localhost:11434 \ -v open-webui:/app/backend/data \ ghcr.io/open-webui/open-webui:main # Team accesses via: http://your-ec2-ip # Everyone gets a private AI — no data leaves your AWS account # Cost control: Stop instance when not in use # Use Lambda to auto-stop at night (see Cloud course Module 13)
Ethics, Limits & What AI Can't Do
Hallucinations, data privacy, job reality — what you need to know before relying on AI.
Hallucinations — AI's Biggest Lie
AI models sometimes produce confident, well-written, completely wrong answers. This is called hallucination. The model doesn't "know" it's wrong — it's predicting the most plausible-sounding text based on patterns. It will invent package names, fake documentation URLs, wrong command syntax, and fictional CVEs — all with the same confident tone as correct answers.
Rule: Never run an AI-generated command on a production server without verifying it. Never paste AI-generated config directly. Always test in a safe environment first.
| Task | Trust Level | Why |
|---|---|---|
| Explain a concept | High — verify major claims | Good at explaining known concepts |
| Write boilerplate code | Medium — test before use | Good at patterns, may miss your specific context |
| Specific version syntax | Low — always check docs | Training data may be outdated |
| Security recommendations | Low — consult a human expert | Stakes too high for AI errors |
| Diagnose an error | Medium — use as a starting point | Good at common errors, may miss edge cases |
| Generate passwords or keys | Never | Use proper random generators only |
Never paste into public AI tools: Client data, database credentials, API keys, private IP addresses, internal hostnames, proprietary code, or anything under NDA. Use Ollama locally for anything sensitive.
AI and Jobs — Realistic View
AI removes the slow parts of IT work — writing boilerplate, looking up syntax, drafting documentation. It does not replace judgment, architecture decisions, client communication, troubleshooting novel problems, or security expertise. The engineers who learn to use AI as a tool will outpace those who ignore it. The engineers who trust AI blindly will cause production incidents. The right position is in the middle: use it, verify it, own the result.
Ready to go beyond reading?
The live course includes hands-on labs, building real AI tools in Python, running your own AI server on EC2, and a final project you'll actually use in your DevOps workflow.
💬 Enroll via WhatsApp →Batch info & fee on request