cd /news/artificial-intelligence/a-meal-planner-grocery-shopping-agen… · home topics artificial-intelligence article
[ARTICLE · art-26317] src=dev.to ↗ pub= topic=artificial-intelligence verified=true sentiment=↑ positive

A Meal Planner & Grocery Shopping Agent in Typescript with HazelJS

A developer built a meal planning and grocery shopping agent using HazelJS, a TypeScript framework for AI-native applications. The agent uses multi-agent orchestration, retrieval-augmented generation (RAG) for recipe search, and supervisor routing to handle dietary intake, meal planning, and shopping list generation. The project demonstrates production-ready patterns including retries, circuit breakers, and observability via the HazelJS Inspector.

read2 min publishedJun 13, 2026

In this post, we'll build a practical AI-powered meal planning agent using HazelJS. This agent helps users create personalized meal plans, discover recipes, and generate shopping lists—all while demonstrating HazelJS's powerful agent orchestration, RAG capabilities, and production-ready patterns.

#

What We're Building

Our meal planning agent handles the complete meal planning workflow:

Dietary Intake: Extracts dietary restrictions, budget, cooking time, and preferences #

Recipe Search: Finds recipes using RAG over a recipe database #

Meal Planning: Creates day-by-day meal plans with balanced nutrition #

Shopping Lists: Generates organized grocery lists with cost estimates #

Nutrition Coaching: Orchestrates the entire workflow via supervisor routing

#

Why HazelJS?

HazelJS provides a production-ready framework for building AI-native applications. For this project, we leverage:

Multi-agent orchestration with @Agent

, @Tool

, and @Delegate

decorators #

Supervisor routing to delegate tasks to specialized agents #

Production resilience with retries, circuit breakers, and rate limiting #

Built-in observability via the HazelJS Inspector #

Guardrails for safer AI recommendations

#

Project Architecture

#

Agent Implementation

Dietary Intake Agent

The [DietaryIntakeAgent] extracts structured information from natural language:

Recipe Search Agent with RAG

The [RecipeSearchAgent] uses RAG to find recipes semantically:

Nutrition Coach with Supervisor

The [NutritionCoachAgent] orchestrates the workflow using delegation:

#

RAG Implementation

We use MemoryVectorStore

and RAGPipeline

for semantic recipe search:

#

Production Configuration

The AgentModule

is configured with production-ready features:

#

Running the Project

#

Testing the API

#

HazelJS Inspector

Access the built-in inspector at http://localhost:3000/__hazel

for:

  • Real-time agent execution traces
  • Tool call logs
  • Performance metrics
  • Circuit breaker status
  • Rate limiter status

#

Key Takeaways

Multi-agent architecture: Each agent has a focused responsibility, making the system maintainable and testable #

RAG for knowledge retrieval: Semantic search over recipe database provides accurate, context-aware results #

Supervisor routing: The orchestrator agent delegates tasks to specialists, enabling complex workflows #

Production resilience: Built-in retries, circuit breakers, and rate limiting ensure reliability #

Observability: The inspector provides deep insights into agent behavior and performance #

Guardrails: PII redaction and content safety protect users from inappropriate recommendations

#

What's Next?

For a production deployment, you would:

  • Replace the local LLM provider with OpenAI, Anthropic, or Google Generative AI
  • Add persistent storage with @hazeljs/memory for user preferences and meal history
  • Implement @hazeljs/flow for advanced workflow orchestration
  • Add @hazeljs/pubsub for async meal planning notifications
  • Connect to real recipe APIs for dynamic content

#

Conclusion

This meal planning agent demonstrates how HazelJS enables building sophisticated AI applications with production-ready patterns. The combination of multi-agent orchestration, RAG, and resilience features makes it easy to create reliable, observable, and scalable AI-native applications.

Complete project is available here: Meal Planning Agent See you next time!

── more in #artificial-intelligence 4 stories · sorted by recency
sponsored brought to you by zahid.host 4,200+ EU-deployed projects
reading about agents? ship yours in a single git push.

Run your AI side-project on zahid.host

EU-based hosting, git-push deploys, automatic HTTPS, no cold starts. Free tier with a custom domain — perfect for shipping the agent you just read about.

$git push zahid main
Live at https://your-agent.zahid.host
Get free account → Pricing
from €0/mo · no card required
LIVE [news/a-meal-planner-groce…] indexed:0 read:2min 2026-06-13 ·