# BRAINIAC Recipe Yield Normalizer

> BRAINIAC Recipe Yield Normalizer is a paid API for AI agents from www.brainiac.software, paid per call via x402, $0.04/call, status unknown (last checked 2026-11-11).

Normalizes recipe ingredient quantities and units across a set of recipes, computing per-portion breakdowns, costs, allergen matrix validation, and waste tracking without inventing missing data.

## Facts

- Endpoint: POST https://www.brainiac.software/api/v1/restaurant-operations/recipe-yield-normalize?utm_source=zero.xyz
- Price: $0.04/call
- Payment: x402
- Status: unknown
- Last checked: 2026-11-11
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/brainiac-recipe-yield-normalizer-f01f6443
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_bPmR1YnH0h2lPIyT5iAGe

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability brainiac-recipe-yield-normalizer-f01f6443 -d '<json body>'
```

Example prompt: Normalize the yield and ingredient units for my Latte Syrup Base recipe — it makes 4 portions from 1 batch, using 1 kg milk and 200 g sugar — and calculate the per-portion quantities using my supplier prices of $1.20/l for milk and $0.80/kg for sugar.

## When to prefer this

Use this endpoint when you need to programmatically normalize and standardize recipe ingredient data — converting mixed units, computing per-portion costs, and validating allergen claims — especially in a restaurant, catering, or food-service context where data integrity matters and you do not want values invented. Prefer this over generic LLM-based recipe parsing when you need deterministic unit conversion, traceable cost computation from real supplier prices, and explicit flags distinguishing supplied vs. inferred values.

## Known failure modes

- Missing required recipe fields cause those recipes to be skipped or flagged in findings
- Unrecognized or non-convertible units (e.g. 'pinch', count-to-volume) are left unconverted with convertible=false
- Missing supplier prices result in cost fields being omitted rather than invented
- Allergen validation only covers explicitly supplied flags — undeclared ingredients produce no findings
- Input CSV/JSON exceeding size limits returns a validation error
- Malformed base64 file content causes a parsing error

## How this service works

Pay-per-call APIs for AI agents: OFAC sanctions screening, compliance checks, token security, and Base chain data via x402. No account. Fixed USDC price. MCP-ready.

## Output

A JSON object containing normalized recipe items, each with standardized ingredient lines (converted units, normalized quantities, per-portion breakdowns), yield info, portion counts, computed costs where prices are supplied, allergen findings, normalization status, a checkedAt timestamp, and a limitations list clarifying what was and was not computed or invented.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "csv": {
   "type": "string",
   "maxLength": 200000
  },
  "asOf": {
   "type": "string",
   "maxLength": 40
  },
  "file": {
   "type": "object",
   "required": [
    "mediaType",
    "fileBase64"
   ],
   "properties": {
    "filename": {
     "type": "string",
     "maxLength": 180,
     "minLength": 1
    },
    "mediaType": {
     "enum": [
      "text/plain",
      "text/csv",
      "application/json"
     ],
     "type": "string"
    },
    "fileBase64": {
     "type": "string",
     "maxLength": 12000000,
     "minLength": 1
    }
   },
   "additionalProperties": false
  },
  "json": {
   "type": "string",
   "maxLength": 200000
  },
  "text": {
   "type": "string",
   "maxLength": 200000
  },
  "sales": {
   "type": "array",
   "items": {
    "type": "object",
    "properties": {
     "date": {
      "type": "string",
      "maxLength": 40
     },
     "units": {
      "type": "number",
      "maximum": 1000000000,
      "minimum": 0
     },
     "revenue": {
      "type": "number",
      "maximum": 1000000000,
      "minimum": 0
     },
     "recipeId": {
      "type": "string",
      "maxLength": 80
     }
    },
    "additionalProperties": false
   },
   "maxItems": 400
  },
  "waste": {
   "type": "array",
   "items": {
    "type": "object",
    "properties": {
     "unit": {
      "type": "string",
      "maxLength": 40
     },
     "reason": {
      "type": "string",
      "maxLength": 160
     },
     "quantity": {
      "type": "number",
      "maximum": 1000000000,
      "minimum": 0
     },
     "ingredientId": {
      "type": "string",
      "maxLength": 80
     }
    },
    "additionalProperties": false
   },
   "maxItems": 200
  },
  "matrix": {
   "type": "array",
   "items": {
    "type": "object",
    "properties": {
     "claimed": {
      "type": "boolean"
     },
     "allergen": {
      "type": "string",
      "maxLength": 80
     },
     "recipeId": {
      "type": "string",
      "maxLength": 80
     }
    },
    "additionalProperties": false
   },
   "maxItems": 400
  },
  "prices": {
   "type": "array",
   "items": {
    "type": "object",
    "properties": {
     "asOf": {
      "type": "string",
      "maxLength": 40
     },
     "unit": {
      "type": "string",
      "maxLength": 40
     },
     "packSize": {
      "type": "number",
      "maximum": 1000000000,
      "minimum": 0
     },
     "packPrice": {
      "type": "number",
      "maximum": 1000000000,
      "minimum": 0
  
… (truncated)
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "items": [
   {
    "name": "Latte syrup base",
    "lines": [
     {
      "unit": "l",
      "quantity": 1,
      "converted": true,
      "convertible": true,
      "ingredientId": "milk",
      "normalizedUnit": "ml",
      "normalizedQuantity": 1000
     },
     {
      "unit": "kg",
      "quantity": 0.2,
      "converted": true,
      "convertible": true,
      "ingredientId": "sugar",
      "normalizedUnit": "g",
      "normalizedQuantity": 200
     }
    ],
    "portions": 4,
    "recipeId": "R-1",
    "yieldQty": 1,
    "yieldUnit": "batch",
    "perPortion": [
     {
      "unit": "ml",
      "ingredientId": "milk",
      "quantityPerPortion": 250,
      "quantityPerPortionSupplied": true
     },
     {
      "unit": "g",
      "ingredientId": "sugar",
      "quantityPerPortion": 50,
      "quantityPerPortionSupplied": true
     }
    ],
    "portionsSupplied": true,
    "yieldQtySupplied": true,
    "nutritionInvented": false
   }
  ],
  "status": "normalized",
  "findings": [],
  "checkedAt": "2026-11-04T21:00:00.000Z",
  "limitations": [
   "Recipes, supplier prices, sales, waste, and allergen rows are copied only from labeled fields supplied by the caller.",
   "Recipe cost uses supplied quantities and prices after unit conversion. Missing prices are not invented.",
   "Unit conversion covers common mass and volume units. Count units convert only to the same count family.",
   "Allergen validation uses only explicitly supplied ingredient allergen flags and menu claims.",
   "Nutritional values are never invented. No legal food-safety compliance is claimed."
  ],
  "priceInvented": false,
  "allergenInvented": false,
  "nutritionInvented": false,
  "foodSafetyComplianceClaimed": false
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/brainiac-recipe-yield-normalizer-f01f6443/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from www.brainiac.software](https://www.zero.xyz/host/www.brainiac.software/llms.txt)
