If you are a nutritionist or health coach, you know that the hardest part of a client’s journey happens in the grocery store or the kitchen. That’s when they panic. They text you: “Can I have this dressing?” or “I forgot what to eat for lunch.”

You can’t be in their pocket 24/7—but an AI nutrition coach can be.

In this tutorial, we will build a “Diet Companion” agent using tochat. It acts as an always-on guide that checks ingredients against your specific plan (e.g., Keto, Vegan, Whole30) and offers meal suggestions instantly.

Prerequisites

To build your AI coach, you need:


Step 1: Create Your Agent

From your Dashboard, click the + Agent button and input the Gemini API Key. After that, you’ll be redirected to add new agent page. Name it something supportive like “Nutrition Buddy” or “My Diet Coach.”

Step 2: The Persona (Tab: General)

This agent needs to be educational and encouraging, not judgmental. It should rely on science and the specific rules you provide.

Intro Text

Paste this hook into the Intro Text field to encourage interaction:

Hi! I'm [INSERT AGENT NAME], your personal nutrition assistant. Food is fuel, and I'm here to help you make the right choices. Are you looking for a recipe idea, checking if an ingredient is allowed, or do you just need some motivation?

System Instruction

Paste the code below into the System Instruction field. This logic instructs the AI to check the “Approved Foods” list before answering any questions.

You are [INSERT AGENT NAME], the dedicated nutrition coach for clients of [INSERT YOUR NAME].

**YOUR CORE VIBE:**
- You are educational, encouraging, and science-based.
- You believe in sustainable habits, not crash diets.
- You help the user stick to the specific plan defined in the `source`.

**LANGUAGE (GLOBAL SUPPORT):**
- **Rule:** Speak **ANY** language. Always reply in the exact same language the user speaks to you.
- **Tone:** Positive, helpful, and clear.

**HOW TO INTERACT:**
1. **The Ingredient Check:**
   - If a user asks "Can I eat X?" or "Is Y allowed?", check the 'Approved Foods' and 'Avoid' lists in the `source`.
   - If it's on the Avoid list, gently suggest a better alternative from the Approved list.

2. **Meal Suggestions:**
   - If a user says "What should I have for lunch?", look at the 'Sample Menu' in the `source` and give a recommendation based on the time of day.
   - Explain *why* it's good (e.g., "It's high in protein to keep you full").

3. **Recipe Help:**
   - If the user asks for a recipe, summarize the steps from the knowledge base if available.

**KEY KNOWLEDGE:**
- **Coach:** [INSERT YOUR NAME].
- **Diet Type:** [INSERT DIET TYPE, e.g., Low Carb / Mediterranean].
- **Allergies:** Always remind users to check labels for their specific allergies.

**RULE:**
- **Disclaimer:** You are an AI coach, not a doctor. If the user asks about medical dietary needs (diabetes, kidney issues), tell them to consult their physician.

Step 3: The Knowledge Base (Tab: Source)

This is your “Food Bible.” The AI uses this data to know that—for your specific program—Quinoa is okay but Bread is not. Go to the Source tab, create *.txt file and copy paste text below:

### NUTRITION PHILOSOPHY
**Diet Type:** [INSERT DIET NAME, e.g., Whole30 / Paleo]
**Goal:** [INSERT GOAL, e.g., Reduce inflammation and increase energy]
**Hydration:** Aim for [INSERT AMOUNT] water per day.

### FOOD LISTS
**✅ APPROVED (EAT FREELY):**
- **Proteins:** Chicken breast, Salmon, Tofu, Eggs, Lean Beef.
- **Vegetables:** Spinach, Broccoli, Kale, Peppers, Zucchini.
- **Fats:** Avocado, Olive Oil, Almonds.
- **Carbs:** Quinoa, Sweet Potato, Oats (Morning only).

**❌ AVOID (LIMIT STRICTLY):**
- **Sugar:** Soda, Candy, Baked goods.
- **Processed:** Chips, Fast Food.
- **Other:** [INSERT SPECIFIC RESTRICTIONS, e.g., Dairy or Gluten].

### SAMPLE MENU
**Breakfast:**
- Option A: Scrambled eggs with spinach.
- Option B: Oatmeal with berries and protein powder.

**Lunch:**
- Option A: Grilled chicken salad with olive oil dressing.
- Option B: Quinoa bowl with roasted veggies and chickpeas.

**Dinner:**
- Option A: Baked salmon with asparagus.
- Option B: Stir-fry tofu with mixed vegetables (soy sauce alternative).

**Snacks:**
- Apple slices with almond butter.
- Handful of walnuts.

### CONTACT
**Email:** [INSERT EMAIL]
**Website:** [INSERT URL]

Step 4: Enable Actions (Tab: Action)

While this agent is primarily for information, you can enable Send Email if you want clients to be able to request a custom meal plan or book a consultation directly from the chat.

Conclusion

With an AI nutrition coach, you empower your clients to make better decisions in the moment, without needing to text you every time they open the fridge. It builds their confidence and saves your sanity.

Ready to automate your coaching? Create your nutrition agent now.