npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

nomnomnumbers

v2.4.1

Published

Nutrition tracking CLI for AI agents — food search, barcode lookup, meal logging with JSON output

Downloads

319

Readme

🍩 NomNom Numbers

"Even donuts deserve to be counted."

Tell your AI what you ate. It remembers, tracks, and coaches — powered by real data, not vibes.

NomNom is a headless nutrition backend that plugs into Claude, OpenClaw, or any AI agent that can run a command. It searches 2M+ foods from the USDA, logs every meal to a local SQLite database, tracks your macros, builds streaks, and spots trends over time. Your AI handles the conversation. NomNom handles the truth.

You:    "I just had two scrambled eggs and toast for breakfast"

Claude: searches "scrambled eggs" → 140 cal, 12g protein
        logs "Scrambled Eggs" × 2 as breakfast
        checks today's progress

        "Logged! 🍩 You're at 850 / 2000 cal today with 65g protein.
         You've got room for a solid lunch — maybe that chicken bowl
         you liked on Thursday?"

Installation

# Run directly (recommended for AI agents)
bunx nomnomnumbers --help

# Or install globally
bun install -g nomnomnumbers
nomnom --help

Core Commands

Search & Log Meals

# Search 2M+ USDA foods
nomnom search "chicken breast" --limit 5

# Log by name (AI can search then log)
nomnom log "Chicken Breast" --qty 1 --calories 165 --protein 31

# Log by barcode
nomnom lookup 00000000924665
nomnom log "Quest Bar" --calories 200 --protein 21

# Save and reuse a repeatable meal
nomnom recipe create "Chicken Bowl" --calories 500 --protein 35 --carbs 42 --fat 18 --fiber 9
nomnom recipe log <recipe-id> --multiplier 2

Track Progress

# Today's summary
nomnom today --human

# Set goals
nomnom goals --calories 2000 --protein 150

# Progress vs goals (includes streaks!)
nomnom progress --human

History & Trends

# Recent meals
nomnom history --limit 10 --human

# Weekly trends (AI uses this for insights)
nomnom trends --days 7

# Find repeated meal combos worth saving as recipes
nomnom trends suggest-recipes --days 30 --min-occurrences 3

# Convert a suggestion into a saved recipe in one step
nomnom trends apply-suggestion <suggestion-id> --days 30 --min-occurrences 3

AI Integration

MCP (Claude Desktop, etc.)

Add to claude_desktop_config.json:

{
  "mcpServers": {
    "nomnom": {
      "command": "bunx",
      "args": ["nomnomnumbers", "mcp"]
    }
  }
}

Then Claude can:

  • Log meals you mention in conversation
  • Track your progress over time
  • Give insights based on your actual data

Example Claude prompt:

"Track my nutrition using the nomnom MCP tool. When I tell you what I ate, log it. When I ask how I'm doing, check my progress. Be proactive about keeping me on track."

CLI (Any AI Agent)

AI agents that can run shell commands can use NomNom directly:

# All output is JSON for easy parsing
result=$(nomnom today)

# Exit code 0 = success, 1 = error
# stdout = JSON result
# stderr = errors/progress (never mixed)

Output Format

| Stream | Content | |--------|---------| | stdout | JSON result (add --human for readable) | | stderr | Errors, progress, initialization | | Exit 0 | Success | | Exit 1 | Error (stderr has { "error": "..." }) |

All Commands

| Command | Description | |---------|-------------| | init | Initialize database (auto-runs) | | search <query> | Search USDA foods | | lookup <barcode> | Look up by barcode | | log <food> [options] | Log a meal | | delete <id> | Delete a meal | | edit <id> [options] | Edit a meal | | today | Today's summary | | history | Meal history | | trends | Nutrition trends, recipe suggestions, and suggestion application | | goals | Set/view goals | | progress | Progress vs goals | | foods add/list/delete | Manage custom foods | | recipe create/list/log/delete | Manage reusable recipe templates | | config | View/modify config | | mcp | Start MCP server |

Run nomnom help for full details.

Data Storage

| Platform | Data | |----------|------| | Linux/Mac | ~/.local/share/nomnom/ | | Windows | %LOCALAPPDATA%\nomnom\ |

Override with NOMNOM_DATA_DIR environment variable.

Example: Agentic Weight Loss Workflow

Day 1 - Setup:

You: "I want to lose weight. My goal is 1800 calories, 140g protein."
Claude: nomnom goals --calories 1800 --protein 140
        "Goals set! I'll track your meals and keep you accountable."

Day 5 - Tracking:

You: "Had a turkey sandwich for lunch"
Claude: nomnom search "turkey sandwich"
        nomnom log "Turkey Sandwich" --calories 350 --protein 25
        "Logged! You're at 1200/1800 cal, 95/140g protein. 600 cal to go!"

Day 12 - Check-in:

You: "How am I doing?"
Claude: nomnom trends --days 7
        nomnom progress
        "Great week! Avg 1750 cal/day, hitting protein 6/7 days. 
         7-day streak on calories! Keep it up."

Day 30 - Insights:

You: "What patterns do you see?"
Claude: [Analyzes 30 days of data via nomnom history/trends]
        "You hit protein goals 85% of days you ate breakfast.
         On days you missed breakfast, avg calories were 2100 (over goal).
         Recommendation: Don't skip breakfast."

License

MIT