freecals
All topics

Saved foods

Foods the user eats again and again, kept once for every app the user connects.

Save or log

  • save_food keeps a food for reuse. It does not log that the user ate it.
  • "Save this yogurt" is save_food only. "Save it and log it" is save_food, then log_food.
  • Never keep foods in your own app's memory, such as ChatGPT Memory. Other apps cannot read it.

Usual foods

  • "My usual kombucha" names a saved food. Find it with find_saved_foods and its query, then log an item with kind: "saved" and its saved_… id. servings defaults to 1.
  • Do not create a new inline item or a new saved food for a usual food.
  • "That cream cheese i logged yesterday" names an earlier entry, not a saved food. Find it with read_food_journal and its query, and copy its item.
  • A dish the user eats almost daily with different grams is a good saved food. Offer to save it; do not save it without asking.

Changes

  • Passing id to save_food replaces that saved food with the full state you send. Omitted optional fields are cleared.
  • Entries that already used the saved food keep the nutrition they were logged with.