{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "One household-measure portion from USDA FoodData Central that is a cup, a tablespoon or a teaspoon",
  "type": "object",
  "additionalProperties": false,
  "required": [
    "release",
    "fdc_id",
    "data_type",
    "description",
    "unit",
    "amount",
    "gram_weight",
    "grams_per_unit",
    "url"
  ],
  "properties": {
    "release": {
      "type": "string",
      "description": "Which release the row is from: sr_legacy (April 2018 data, final) or foundation (2025-04-24 release).",
      "x-origin": "built",
      "x-source": "artwaste-land",
      "enum": [
        "sr_legacy",
        "foundation"
      ]
    },
    "fdc_id": {
      "type": "integer",
      "description": "USDA's FoodData Central id for the food. Foundation Foods rows from the same release carry their own ids; the two releases are cited separately in sources.json.",
      "x-origin": "redistributed",
      "x-source": "usda-fdc-sr-legacy"
    },
    "data_type": {
      "type": "string",
      "description": "sr_legacy_food; or foundation_food (the summary record) or market_acquisition (one purchased sample of that food).",
      "x-origin": "redistributed",
      "x-source": "usda-fdc-sr-legacy",
      "enum": [
        "sr_legacy_food",
        "foundation_food",
        "market_acquisition"
      ]
    },
    "ndb_number": {
      "type": [
        "string",
        "null"
      ],
      "description": "The legacy Nutrient Database number, where the release carries one.",
      "x-origin": "redistributed",
      "x-source": "usda-fdc-sr-legacy"
    },
    "description": {
      "type": "string",
      "description": "The food, as USDA describes it.",
      "x-origin": "redistributed",
      "x-source": "usda-fdc-sr-legacy"
    },
    "category": {
      "type": [
        "string",
        "null"
      ],
      "description": "USDA's food category.",
      "x-origin": "redistributed",
      "x-source": "usda-fdc-sr-legacy"
    },
    "unit": {
      "type": "string",
      "description": "cup, tbsp or tsp, read out of SR Legacy's free-text modifier (which must BEGIN with the unit word) or Foundation Foods' measure_unit id.",
      "x-origin": "built",
      "x-source": "artwaste-land",
      "enum": [
        "cup",
        "tbsp",
        "tsp"
      ]
    },
    "amount": {
      "type": "number",
      "description": "How many of the unit the gram weight is for, as USDA lists it.",
      "x-origin": "redistributed",
      "x-source": "usda-fdc-sr-legacy",
      "exclusiveMinimum": 0
    },
    "modifier": {
      "type": [
        "string",
        "null"
      ],
      "description": "USDA's own modifier text: \"cup\", \"cup, chopped\", \"cup packed\", \"cup (8 fl oz)\". Where it says packed, sifted or dipped, that is the only method information in the release.",
      "x-origin": "redistributed",
      "x-source": "usda-fdc-sr-legacy"
    },
    "portion_description": {
      "type": [
        "string",
        "null"
      ],
      "description": "USDA's portion description, where the row has one.",
      "x-origin": "redistributed",
      "x-source": "usda-fdc-sr-legacy"
    },
    "gram_weight": {
      "type": "number",
      "description": "The gram weight USDA lists for that amount of that unit.",
      "x-origin": "redistributed",
      "x-source": "usda-fdc-sr-legacy",
      "exclusiveMinimum": 0
    },
    "grams_per_unit": {
      "type": "number",
      "description": "gram_weight divided by amount, rounded to three decimals: the figure per one cup, tablespoon or teaspoon. The one derived column.",
      "x-origin": "built",
      "x-source": "artwaste-land",
      "exclusiveMinimum": 0
    },
    "data_points": {
      "type": [
        "integer",
        "null"
      ],
      "description": "USDA's count of data points behind the weight, where the release records one. Blank for most SR Legacy rows.",
      "x-origin": "redistributed",
      "x-source": "usda-fdc-sr-legacy"
    },
    "min_year_acquired": {
      "type": [
        "integer",
        "null"
      ],
      "description": "USDA's earliest acquisition year, where recorded.",
      "x-origin": "redistributed",
      "x-source": "usda-fdc-sr-legacy"
    },
    "footnote": {
      "type": [
        "string",
        "null"
      ],
      "description": "USDA's footnote, where there is one.",
      "x-origin": "redistributed",
      "x-source": "usda-fdc-sr-legacy"
    },
    "acquisition_date": {
      "type": [
        "string",
        "null"
      ],
      "description": "For a Foundation Foods market acquisition, the date the sample was bought.",
      "x-origin": "redistributed",
      "x-source": "usda-fdc-sr-legacy"
    },
    "store_state": {
      "type": [
        "string",
        "null"
      ],
      "description": "For a market acquisition, the US state it was bought in.",
      "x-origin": "redistributed",
      "x-source": "usda-fdc-sr-legacy"
    },
    "url": {
      "type": "string",
      "description": "The FoodData Central page for the food, where the portion can be read.",
      "x-origin": "built",
      "x-source": "artwaste-land"
    }
  }
}
