Overview
Gene-NutritionIntelligence is designed to work immediately after deployment. The three OpenFoodFacts tools require no API key, no configuration, and no sign-up. You can start scanning barcodes and looking up food products right away.
This guide covers:
- Immediate start — Using the gene with no configuration
- Finding barcodes — Where to find product barcodes
- Optional setup — Adding USDA nutrition data
- Testing — Verifying everything works
Start Immediately (No Configuration Needed)
The following tools work immediately after deployment with no API keys or configuration:
| Tool | What It Does |
|---|---|
barcodeLookup |
Look up a product by barcode (most reliable) |
productSearch |
Search for food products by name |
foodLabel |
Get detailed food label information |
To start using the gene:
- Deploy Gene-NutritionIntelligence to Feluda
- Find a product barcode on a food item
- Run
barcodeLookupwith your barcode - Run
productSearchto find foods by name - Use the AI prompts for guided nutrition analysis
Finding Product Barcodes
Barcodes are the most reliable way to look up products in OpenFoodFacts. Here's where to find them:
On Packaging:
- Look on the back or bottom of the product
- Usually a 13-digit number (EAN/UPC format)
- Often found near the nutrition facts panel
Common Barcode Formats:
- EAN-13: 13 digits (most common in Europe)
- UPC-A: 12 digits (common in North America)
- Example: 3017620422003 (Nutella 400g)
Without a Barcode:
- Use
productSearchto search by product name - Example:
productSearchwithquery=cereal
Optional: Add USDA Nutrition Data
If you want reliable nutrition data from the official U.S. government database, you can add the USDA FoodData Central API:
Step 1: Sign Up for USDA FoodData Central
- Go to https://fdc.nal.usda.gov/api-key-signup.html
- Fill out the registration form
- You'll receive an API key via email
- Copy the key for use in Feluda Vault
Step 2: Configure the Secret in Feluda Vault
- Open the Feluda Desktop Application
- Navigate to the Vault section
- Click "Add Secret"
- Add the following key-value pair:
| Secret Name | Value |
|---|---|
USDA_API_KEY |
Your USDA FoodData Central API key |
- Save the secret
Step 3: Test USDA Tools
Run: tool:foodNutritionUSDA with food=apple
Expected: USDA nutrition data for apple
Test Your Setup
Test Without API Keys (Immediate)
-
barcodeLookup
- Run:
tool:barcodeLookupwithbarcode=3017620422003 - Expected: Product data for Nutella
- Run:
-
productSearch
- Run:
tool:productSearchwithquery=bread - Expected: List of bread products
- Run:
-
nutritionAdvisor (Prompt)
- Run:
prompt:nutritionAdvisorwithfood=apple,depth=standard - Expected: Guided nutrition analysis
- Run:
Test With API Keys (Optional)
foodNutritionUSDA
- Run:
tool:foodNutritionUSDAwithfood=apple - Expected: USDA nutrition data for apple
mealNutrition
- Run:
tool:mealNutritionwithfood=apple - Expected: USDA meal nutrition data
Troubleshooting
Tool Returns "Error: 'barcode' parameter is required"
This means you need to provide a barcode parameter.
- Example:
barcode=3017620422003
Tool Returns HTTP 503 (Service Unavailable)
OpenFoodFacts may be experiencing high traffic.
- Try again later
- Use
barcodeLookupinstead ofproductSearch - The barcode endpoint is more reliable
Tool Returns "Secret Not Configured"
This only applies to USDA tools:
- Check that you've added
USDA_API_KEYto Vault - Verify the secret name matches exactly
- Restart Feluda after adding secrets
Tool Returns "Error: 'food' parameter is required"
This means you need to provide a food name.
- Example:
food=apple
Next Steps
- Deploy Gene-NutritionIntelligence to Feluda
- Test
barcodeLookupwith a product you have at home - Test
productSearchto find foods by name - Use the AI prompts for guided analysis
- (Optional) Add USDA API key for reliable nutrition data
You can start using the gene immediately without any API keys. No configuration is required.
Frequently Asked Questions
- Do I need any API keys to use Gene-NutritionIntelligence?
- No. The three OpenFoodFacts tools (productSearch, barcodeLookup, and foodLabel) use the free OpenFoodFacts API and require no API key. You can start using the gene immediately after deployment. Only the USDA tools (mealNutrition and foodNutritionUSDA) require an optional USDA_API_KEY.
- How long does it take to configure Gene-NutritionIntelligence?
- Zero configuration is required to start using the gene. Just deploy it and you can immediately use the barcode lookup and product search tools. If you want to add USDA nutrition data, it takes about 5 minutes to sign up for a free USDA FoodData Central API key.
- What are the rate limits for the OpenFoodFacts API?
- OpenFoodFacts has generous rate limits for non-commercial use. The search endpoint may occasionally return 503 errors during high traffic, but the barcode lookup endpoint is more reliable. There are no hard caps on daily requests for the product API.
- Can I use this gene for commercial purposes?
- Yes. OpenFoodFacts data is available under the Open Database License (ODbL) which allows commercial use with attribution. USDA FoodData Central data is in the public domain. Always check each provider's terms of service for the latest details.
- How do I find product barcodes?
- Product barcodes are found on packaging labels, usually on the back or bottom of food products. They are 13-digit numbers (EAN/UPC format). You can also search for products by name using the productSearch tool if you don't have a barcode.