Food tracker skill

Track daily food intake with automatic macro calculation. Log meals via photo or text, get protein/fat/carbs/calories breakdown.

Author self.md
Namespace @self.md/health
Category health
Version 1.0.0
Stars 0
Downloads 0
self.md verified
Table of content

A skill for tracking meals and macros. Send a photo or text description of your food, get instant nutritional breakdown, and track progress toward daily goals.

Save to .claude/skills/food-tracker/index.md to activate.

View skill definition
---
name: food-tracker
description: Track daily food intake with automatic macro calculation. Log meals via photo or text description, get protein/fat/carbs/calories breakdown, track progress toward daily goals. Use when asked to log food, count macros, track nutrition, or show daily food summary.
---

# Food Tracker

Track meals and macros in a JSON file. Calculate nutritional values from ingredients, show progress toward daily goals.

## Data File

`data/food-tracker.json` โ€” stores targets, meals, and daily totals.

## Structure

    {
      "daily_targets": {
        "calories": 1800,
        "protein_g": 150,
        "fat_g": 70,
        "carbs_g": 140,
        "goal": "cut",
        "weight_kg": 75
      },
      "meals": [...],
      "daily_totals": {...}
    }

## Workflow

1. User sends food photo or description
2. Parse ingredients and estimate weights
3. Calculate macros per ingredient using standard values
4. Add to `meals[]` array with timestamp
5. Update `daily_totals` for the date
6. Show summary with % of daily targets

## Common Foods Reference (per 100g)

| Food | P | F | C | kcal |
|------|---|---|---|------|
| Chicken breast | 31 | 3.6 | 0 | 165 |
| Beef (lean) | 26 | 15 | 0 | 250 |
| Salmon | 20 | 13 | 0 | 208 |
| Eggs (1 large ~50g) | 6 | 5 | 0.4 | 72 |
| Rice (cooked) | 2.7 | 0.3 | 28 | 130 |
| Oatmeal (dry) | 13 | 7 | 68 | 389 |
| Banana | 1.1 | 0.3 | 23 | 89 |
| Milk 2% | 3.4 | 2 | 5 | 50 |
| Ricotta | 11 | 13 | 3 | 174 |
| Cottage cheese | 11 | 4 | 3.4 | 98 |
| Greek yogurt | 10 | 0.7 | 3.6 | 59 |
| Whey protein (scoop 30g) | 24 | 1 | 2 | 120 |
| Bread | 9 | 3 | 49 | 265 |
| Pasta (cooked) | 5 | 1 | 31 | 157 |
| Flour | 10 | 1 | 76 | 364 |
| Sugar | 0 | 0 | 100 | 400 |
| Olive oil | 0 | 100 | 0 | 884 |
| Butter | 0.9 | 81 | 0.1 | 717 |
| Avocado | 2 | 15 | 9 | 160 |
| Almonds | 21 | 49 | 22 | 579 |

## Goal Presets

**Cutting (deficit):**
- Protein: 2g/kg bodyweight
- Fat: ~1g/kg
- Calories: TDEE - 400
- Carbs: remaining calories

**Maintenance:**
- Protein: 1.6g/kg
- Balanced macros

**Bulking (surplus):**
- Protein: 1.8g/kg
- Calories: TDEE + 300

## Tips

- Estimate portions if weights unknown (palm = ~100g meat, fist = ~150g rice)
- Round to nearest 5g for simplicity
- Update weight_kg weekly for accurate targets

Usage

"Log: chicken breast 200g, rice 150g"
"Track this meal" + photo
"Show today's macros"
"How much protein left today?"

Example Output

๐Ÿ“Š Food Tracker โ€” 2026-02-03
========================================
Goal: CUT | Weight: 75kg
----------------------------------------

Macro           Eaten   Target      %
----------------------------------------
Calories         942    1800    52% โ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–‘โ–‘โ–‘โ–‘โ–‘
Protein           55g     150g    36% โ–ˆโ–ˆโ–ˆโ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘
Fat               28g      70g    40% โ–ˆโ–ˆโ–ˆโ–ˆโ–‘โ–‘โ–‘โ–‘โ–‘โ–‘
Carbs            111g     140g    79% โ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–‘โ–‘โ–‘
----------------------------------------
Meals today: 2

โณ Remaining: 858 kcal | 95g protein
Tags: health foodnutritionmacroscaloriesproteindiethealthfitnessmeal-tracking