How to Build Human-in-the-Loop for AI Agents (Practical Guide)

From the creator

Want to start freelancing? Let me help: https://go.datalumina.com/7DnHzBg Want to learn real AI Engineering? Go here: https://go.datalumina.com/bnyLApI 💼 Need help with a project? Work with me: https://go.datalumina.com/TMGbUvO 🔗 GitHub Repository https://github.com/daveebbelaar/ai-cookbook/tree/main/models/openai/10-human-in-the-loop ⏱️ Timestamps 00:00 Human-in-the-Loop in AI 02:17 Python-Based Approaches 04:13 Tool Calling vs. Routing 07:50 Implementing Approval Steps 10:15 Production Patterns Overview 12:33 SSE Streaming for Real-Time Apps 19:14 Async Process for Backend Workflows 22:59 Key Concepts Recap 📌 Description Learn how to implement human-in-the-loop for your AI agents with two Python approaches: LLM routing with structured output and tool call interception. I cover two production patterns; SSE streaming for real-time chat apps and async workflows with notifications, showing how to manage state, deferred execution, and stateless resume. Perfect for AI engineers building reliable agentic systems that require human approval before executing sensitive actions. 👋🏻 About Me Hi! I'm Dave, AI Engineer and founder of Datalumina®. On this channel, I share practical tutorials that teach developers how to build production-ready AI systems that actually work in the real world. Beyond these tutorials, I also help people start successful freelancing careers. Check out the links above to learn more!

Choose to Build with AI
Matched to Python

AI Maker Residence 3

The third AI workshop taught by our legendary teacher, Nick Sarafa. This is a full-day hands-on training workshop for purposeful co-creation with AI using Claude Code. Imagine having access to hundreds of billions of dollars of computing power and knowing exactly how to make it work for you through the power of super intelligence.

◆ Fri 09 Oct 2026 ◆ KOKO Cafe, London ◆ With Nick Sarafa
AI Maker Residence 3
Live event
AI Maker Residence 3
Fri 09 Oct 2026

More like this

Running one yourself?

List your AI event,
wherever it is.

A meetup, a workshop, a hackathon, a conference. Any city, or online. Tell us about it and it lands in front of people already learning this stuff.