AI Engineering: Putting It All Together
What you will learn
How to set up your own AI development environment, choose the right model, and build a daily workflow for crafting and improving prompts.
Your setup
You already have everything you need:
- This Code Tutor runs on your machine at localhost:8000 — connected to your OpenCode Go
deepseek-v4-flashkey in.env - The AI Tutor panel on every lesson page is a real API-powered assistant using the same patterns this course teaches
- You can use it right now to ask any question about AI engineering
Choosing a model
| If you need... | Pick... | Notes |
|---|---|---|
| Speed + good quality | DeepSeek V4 Flash, GPT-4o Mini, Claude Haiku | Fast, cheap, good for most tasks |
| Maximum reasoning | GPT-4o, Claude Sonnet, DeepSeek R1 | Slower but better at complex tasks |
| Long documents (>100K tokens) | Gemini 1.5 Pro, Claude Sonnet | Huge context windows |
| Code generation | Claude Sonnet, GPT-4o, DeepSeek Coder | Best at code |
| Deterministic output | Any model, temperature=0 | Use for structured data extraction |
Daily workflow
- Write the prompt — use the anatomy from Lesson 2: role, task, context, format
- Test with 3–5 examples — does it work for the simplest cases?
- Find edge cases — what breaks it? Add those to your test set
- Iterate — change one thing at a time, run your test set, compare
- Lock in — when it's good enough, commit the prompt to version control
- Monitor — track latency, error rate, user feedback in production
Practical checklist before deploying
[ ] API key in .env (not in source code)
[ ] .env is in .gitignore
[ ] Rate-limit handling with retry
[ ] Fallback model configured
[ ] Logging (tokens, latency, errors — NOT raw PII)
[ ] Test set with at least 10 examples
[ ] System prompt has guardrails against hallucination
[ ] Output validation (check response format before showing to user)
[ ] Monitoring dashboard or alerts
[ ] Human-in-the-loop for high-stakes decisions
[ ] Data retention / deletion policy
[ ] This course taught you how to evaluate and iterate
The AI tutor on this site
The tutor panel next to every lesson is itself an AI system. You can practice what you've learned:
- Try crafting specific prompts — compare how the tutor responds to vague vs precise questions
- Notice when the tutor hallucinates or misses context — that's the "lost in the middle" effect
- The tutor has a 15-question limit (configurable in
.envasTUTOR_QUESTION_LIMIT) — that's rate limiting in action - Fallback: if the API key is missing or the provider is down, the tutor returns a clear error — handled with try/except
Where to go next
- OpenAI API Documentation — reference for the API format
- LangChain — framework for building LLM applications
- OpenCode Go — your current API provider (generate new keys, explore models)
- Anthropic Prompt Guide — excellent prompt engineering advice
Quick check below!