ClawKit Logo
ClawKitReliability Toolkit
Back to Registry
Official Verified

food-channel

Handle messages in a food-tracking channel by routing food intake events through a deterministic food tracker. Use when working in a dedicated food channel, especially for barcode lookups, photo estimates, and daily summaries.

skill-install — Terminal

Install via CLI (Recommended)

clawhub install openclaw/skills/skills/cdmichaelb/food-channel
Or

Food Channel Skill

Handle messages in a food-tracking channel by logging food intake events.

Configuration

Set the following environment variables or replace placeholders before use:

  • FOOD_CHANNEL_ID — Channel ID for food tracking (env var)
  • FOOD_PROFILE_PATH — Path to user profile JSON (default: $WORKSPACE/data/food_profile.json)
  • Tracker script is at scripts/tracker.py (included in bundle)

Message Types

1. Barcode Lookup

User sends a barcode (numeric string, 8-14 digits). Optional servings specified as "2x", "2 servings", "x2", etc. Defaults to 1.

Flow:

  1. Parse the barcode and optional servings from the message
  2. Run: python3 scripts/tracker.py lookup <barcode> [servings]
  3. If successful, reply with a formatted summary of the food item and nutrition logged
  4. If failed, reply with the error

2. Photo Estimate

User sends an image attachment.

Flow:

  1. Copy the image to the workspace data dir
  2. Resize it to max 1024px on longest side: convert src.jpg -resize '1024x1024>' -quality 80 dst.jpg (or use python3 -c "from PIL import Image; ..." if imagemagick unavailable)
  3. Use the image tool on the resized image with a prompt asking to estimate: food items, portion sizes, and approximate nutrition per serving
  4. Parse the vision response into structured nutrition data
  5. Run: echo '<json>' | python3 scripts/tracker.py estimate
  6. Reply with formatted summary noting it's an estimate (≈)

3. Summary Request

User asks for today's summary or a daily summary.

Flow:

  1. Run: python3 scripts/tracker.py summary [YYYY-MM-DD]
  2. Reply with formatted daily totals

4. Post-Log Check (after every barcode or estimate log)

After logging an entry, check running daily totals against limits:

  1. Run: python3 scripts/tracker.py summary
  2. Load profile from FOOD_PROFILE_PATH (default: data/food_profile.json)
  3. Compare totals against daily_limits. Flag any that are over (or under for fiber_g_min):
    • calories > limit → ⚠️ Over calorie budget ({total}/{limit} kcal)
    • sodium_mg > limit → ⚠️ High sodium ({total}/{limit} mg)
    • sugar_g > limit → ⚠️ Over sugar limit ({total}/{limit} g)
    • fiber_g < limit → ℹ️ Low fiber ({total}/{limit} g)
  4. Append any warnings to the log reply. If nothing is over, skip the check section entirely.

Reply Format

For logged items, use this format:

📝 **Item Name** (Brand)
Source: barcode | Servings: 2
Per serving: 150g
---
🔥 300 kcal | 🥩 12g protein | 🍞 45g carbs | 🧈 8g fat
🥬 3g fiber | 🍬 18g sugar | 🧂 420mg sodium
[Vitamins/minerals if present]

For photo estimates, prefix with: 📸 Estimate —

Parsing Servings

From message text, look for patterns like:

  • 2x, x2, ×2
  • 2 servings, 2 serving
  • two, three (common number words)
  • If none found, default to 1

Data Access

Metadata

Stars4017
Views1
Updated2026-04-11
View Author Profile
AI Skill Finder

Not sure this is the right skill?

Describe what you want to build — we'll match you to the best skill from 16,000+ options.

Find the right skill
Add to Configuration

Paste this into your clawhub.json to enable this plugin.

{
  "plugins": {
    "official-cdmichaelb-food-channel": {
      "enabled": true,
      "auto_update": true
    }
  }
}
Safety NoteClawKit audits metadata but not runtime behavior. Use with caution.

Related Skills

sleep-channel

Handle messages in a Discord sleep-tracking channel by grounding all sleep logging and summaries on the real sleep tracker and source Discord metadata. Use when working in a dedicated sleep channel, especially for adding sleep entries, correcting the latest entry, deleting the latest entry, or rendering the current sleep log without hallucinating timestamps, dates, or entries.

cdmichaelb 4017

publish-skill

Prepare and publish an OpenClaw skill to ClawHub. Handles PII/secret auditing, generalization, env var extraction, directory scaffolding, git init, and the clawhub publish command. Use when publishing a new skill or updating an existing one on ClawHub.

cdmichaelb 4017

snippets-sync

Sync code snippets and notes between machines via file sync. Organized by language, rendered in any Markdown viewer (Obsidian, VS Code, etc.).

cdmichaelb 4017

vitamin-tracker-channel

Manage vitamin/supplement reminders across configurable daily time slots via cron jobs. Use when adjusting supplement schedules, adding/removing supplements, or handling vitamin-related channel interactions. Triggers on "vitamin", "supplement", "vitamin reminder", "vitamin schedule".

cdmichaelb 4017

medication-channel

Handle messages in a medication-tracking channel by routing medication events through a deterministic medication tracker instead of freehand model judgment. Use when working in a dedicated medication channel, especially for logging taken/missed/extra medication events, morning/evening completion, timestamp-grounded confirmations, and avoiding hallucinated reminders or fake times.

cdmichaelb 4017