← 返回
未分类 Key

食物热量识别(WiseDiag Calories)

Food Calorie Estimator — Identify food items and estimate calories from an image (via local file binary upload or image URL) with AI-powered recognition. Triggered when the user asks to estimate food calories and provides a local image file path or image URL. Can also be invoked explicitly: say 'Use WiseDiag Calories to analyze this'.
食物热量识别:拍一张食物照片,AI 自动识别食物种类并估算每份热量、蛋白质、碳水、脂肪等营养成分。适用于:减肥热量管控、糖尿病饮食追踪、健身营养计算、备孕/孕期饮食记录、外卖饮食热量查询。触发条件:用户上传食物图片并询问"这顿饭多少卡路里"、"这个能吃吗"、"帮我算一下热量"、"这道菜营养成分是什么"——会调用本技能进行AI分析。支持本地文件和图片URL,最多5张图同时分析,30-120秒返回结果。【杭州智诊科技有限公司】
智诊科技 WiseDiag
未分类 community v1.0.5 5 版本 100000 Key: 需要
★ 0
Stars
📥 154
下载
💾 4
安装
5
版本
#latest

概述

When to Use This Skill

Activate this skill when any of the following conditions are met:

  • The user provides local image files of food and asks to estimate calories
  • The user sends an image URL of food and asks to estimate calories
  • The user says things like "how many calories is this", "estimate calories", "analyze this food photo", or similar requests (in any language)

Note: This skill supports both local file uploads (binary stream) and image URLs. The most common usage scenario is uploading local files via binary stream (--file), as users typically have food photos saved on their device rather than hosted at a public URL.

How to choose (mutually exclusive — pick one):

  • If the user provides a local file path (e.g. /home/user/food.jpg, C:\Users\...\meal.png) → use --file (binary upload). This is the primary and most common usage.
  • If the user provides a URL (starts with http:// or https://) → use --image
  • Do NOT use --file and --image together in one command

⚠️ Privacy Notice

Please read before installing:

This tool transmits your food image files to WiseDiag cloud servers (via direct binary upload or image URL) for AI analysis.

Do not upload images containing sensitive or private content unless:

  • You trust WiseDiag's data handling policy
  • You accept that the file content will be transmitted to and processed remotely

The output of this tool is for reference only and does not constitute professional nutritional or dietary advice. Please consult a qualified nutritionist for specific dietary needs.


WiseDiag Food Calorie Estimator (OpenClaw Skill)

Upload photos of food (meals, snacks, beverages, etc.) and let WiseDiag AI automatically identify food items, estimate calories and nutritional content per serving.

Installation

pip install -r requirements.txt

🔑 API Key Configuration (Required)

Get your API Key: 👉 https://console.wisediag.com/apiKeyManage

The API key MUST be set as an environment variable. The script reads it automatically.

export WISEDIAG_API_KEY=your_api_key

Usage (Step-by-Step)

Do not call any API or HTTP endpoints directly — use only the script below.

⚠️ IMPORTANT: The script makes HTTP requests to an external API and may take 30-120 seconds to complete (especially for large images). Do NOT kill or interrupt a running command — wait for it to finish. The script prints streaming output so you can see it is working.

There are two ways to analyze food — pick one (mutually exclusive):


Option A: Upload local files (recommended) — when user provides local file paths

cd scripts

# Single food image
python3 calories.py -f "/path/to/food.jpg"

# Multiple images (e.g. multiple dishes, max 5)
python3 calories.py -f "/path/to/dish1.jpg" -f "/path/to/dish2.jpg"

# Ask a specific question
python3 calories.py -f "/path/to/food.jpg" --question "这顿饭大概多少卡路里?"

# Specify output filename
python3 calories.py -f "/path/to/food.jpg" -n "lunch_20260324"

Option B: Submit via image URL — when user provides a public HTTP/HTTPS link

cd scripts

# Single image URL
python3 calories.py --image "https://example.com/food.jpg"

# Multiple images
python3 calories.py --image "https://example.com/dish1.jpg" --image "https://example.com/dish2.jpg"

# Ask a specific question
python3 calories.py --image "https://example.com/food.jpg" --question "How many calories is this meal?"

How to choose (mutually exclusive — pick one):

  • User gives a local file path (e.g. /home/user/food.jpg, C:\Users\...\meal.png) → use -f
  • User gives a URL (starts with http:// or https://) → use --image
  • Do NOT use -f and --image together in one command

Results are automatically saved to ~/.openclaw/workspace/WiseDiag-Calories/{name}.md — no manual saving needed.

Parameters

ParameterDescription
------------------------
-f, --fileLocal file path to upload as binary stream — image, repeatable up to 5 times (mutually exclusive with --image)
--imagePublic URL of the food image, repeatable up to 5 times (mutually exclusive with --file)
--questionQuestion to ask (default: estimate calories of the food in the image)
-n, --nameOutput filename (without extension)
-o, --outputOutput directory (default: ~/.openclaw/workspace/WiseDiag-Calories)

FAQ

"WISEDIAG_API_KEY is not set" error:

Verify the environment variable is set correctly by running echo $WISEDIAG_API_KEY.

"Authentication failed" error:

Your API Key may be invalid or expired. Visit console.wisediag.com to check or regenerate it.

"File not found" error:

The local file path provided via -f does not exist. Check the path and try again.

Image not recognized:

Ensure the image is in JPG, JPEG, or PNG format. Photos should be clear and well-lit for best results.

Data Privacy

  • File upload mode (-f): Local files are uploaded as binary streams via multipart/form-data to WiseDiag's server for processing.
  • URL mode (--image): Image URLs are transmitted to WiseDiag cloud servers; their server downloads and processes them.

Image content is not permanently stored. Results are returned directly to you.

⚠️ Disclaimer

The output of this tool is for reference only and does not constitute professional nutritional or dietary advice. Always consult a qualified nutritionist for specific dietary needs.

License

MIT

版本历史

共 5 个版本

  • v1.0.5 Initial release 当前
    2026-05-22 18:37 安全 安全
  • v1.0.4 Initial release
    2026-05-22 18:20 安全 安全
  • v1.0.2 Initial release
    2026-05-21 15:23 安全 安全
  • v1.0.1 Initial release
    2026-05-21 14:51 安全 安全
  • v1.0.0 Initial release
    2026-04-17 14:34 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

报告单解读(WiseDiag Report)

user_a457224d
医疗报告单解读 — 拍照上传医疗报告,AI 秒速解读异常指标并给出健康建议。支持血常规、尿常规、生化全套、甲功、激素六项、B超报告、CT影像报告、基因检测报告等各类单张或多页报告(最多5张图同时上传)。触发条件:用户上传报告图片/PDF并询
★ 0 📥 175

AI问诊·专业健康问答(WiseDiag医疗大模型)

user_a457224d
医疗大模型 — 专为医疗健康领域设计的专业 AI,覆盖疾病诊断、症状分析、用药指导、慢病管理、中医西医、营养健身、术后康复等全科医学知识。当用户询问:我得了什么病、这个症状是什么、药能一起吃吗、血糖偏高怎么办、怀孕期间能吃什么、医生说的XX
★ 0 📥 316

皮肤问题识别(WiseDiag Skin)

user_a457224d
皮肤问题识别:拍一张皮肤照片,AI 帮你分析可能是什么皮肤问题。支持识别湿疹、痤疮/痘痘、荨麻疹、银屑病/牛皮癣、玫瑰糠疹、脂溢性皮炎、特应性皮炎、白癜风、疱疹、皮肤癣、色素痣/黑痣、皮肤肿物等常见皮肤疾病。触发条件:用户上传皮肤照片并询问
★ 0 📥 152