{
  "notice": "bxzxxr MCP archive: a record of what public MCP servers declared when we listed them (we never call their tools). It is data, not a rating: nothing here says a server is safe, secure, verified or trustworthy, and a server can change after we looked. Secrets we detected are redacted; redacted tool lists are withheld and only their hash is shown.",
  "infrastructure": {
    "host": "restaurantdoctorai.com",
    "site": "restaurantdoctorai.com",
    "addresses": [
      {
        "address": "216.150.1.1",
        "endpoints": 948,
        "shared_infrastructure": true,
        "network": {
          "asn": 16509,
          "name": "AMAZON-02 - Amazon.com, Inc.",
          "prefix": "216.150.1.0/24",
          "country": "US"
        }
      }
    ],
    "addresses_recorded": true,
    "address_history": [
      {
        "addresses": [
          "216.150.1.1"
        ],
        "first_seen": "2026-11-22T16:11:15.781Z",
        "last_seen": "2026-11-23T16:12:13.459Z",
        "checks": 2
      }
    ],
    "hosting": [
      {
        "value": "Vercel",
        "evidence": "Server header \"Vercel\""
      }
    ],
    "software": [],
    "server_info": {
      "name": "restaurantdoctorai-profit-check",
      "version": "1.14.0",
      "protocol_version": "2025-06-18"
    },
    "headers": {
      "server": "Vercel",
      "strict-transport-security": "max-age=63072000",
      "access-control-allow-origin": "*"
    },
    "auth": null
  },
  "related": {
    "same_address": {
      "total": 947,
      "sample": [
        {
          "id": "225",
          "url": "https://amigurumi.ai/mcp",
          "server_name": "ai.amigurumi/patterns",
          "last_state": "listed",
          "last_checked_at": "2026-11-24T04:37:01.042Z"
        },
        {
          "id": "378",
          "url": "https://bidbetter.ai/api/mcp",
          "server_name": "ai.bidbetter/collector-car-values",
          "last_state": "listed",
          "last_checked_at": "2026-11-24T04:40:16.298Z"
        },
        {
          "id": "379",
          "url": "https://bidclub.ai/api/mcp",
          "server_name": "ai.bidclub/bidclub",
          "last_state": "listed",
          "last_checked_at": "2026-11-24T04:40:16.575Z"
        },
        {
          "id": "413",
          "url": "https://booqer.ai/mcp",
          "server_name": "ai.booqer/booqer",
          "last_state": "listed",
          "last_checked_at": "2026-11-24T04:41:03.368Z"
        },
        {
          "id": "458",
          "url": "https://calaf.ai/api/mcp",
          "server_name": "ai.calaf/seeds",
          "last_state": "listed",
          "last_checked_at": "2026-11-24T04:43:02.424Z"
        },
        {
          "id": "461",
          "url": "https://callmcp.ai/mcp",
          "server_name": "ai.callmcp/server",
          "last_state": "listed",
          "last_checked_at": "2026-11-24T04:43:02.588Z"
        },
        {
          "id": "465",
          "url": "https://www.canaryusers.ai/api/mcp",
          "server_name": "ai.canaryusers/canaryusers",
          "last_state": "listed",
          "last_checked_at": "2026-11-24T04:43:02.707Z"
        },
        {
          "id": "523",
          "url": "https://agentmart.ciphyr.ai/mcp",
          "server_name": "ai.ciphyr.agentmart/agentmart",
          "last_state": "listed",
          "last_checked_at": "2026-11-24T04:44:03.257Z"
        },
        {
          "id": "524",
          "url": "https://agentmart.ciphyr.ai/mcp/core",
          "server_name": "ai.ciphyr.agentmart/core",
          "last_state": "listed",
          "last_checked_at": "2026-11-24T04:45:05.472Z"
        },
        {
          "id": "670",
          "url": "https://www.decisionlog.ai/api/mcp",
          "server_name": "ai.decisionlog/mcp",
          "last_state": "listed",
          "last_checked_at": "2026-11-24T04:47:02.624Z"
        },
        {
          "id": "754",
          "url": "https://www.edgechat.ai/mcp",
          "server_name": "ai.edgechat/edgepedia",
          "last_state": "listed",
          "last_checked_at": "2026-11-24T04:49:03.533Z"
        },
        {
          "id": "906",
          "url": "https://www.frontierdesk.ai/mcp",
          "server_name": "ai.frontierdesk/desk",
          "last_state": "listed",
          "last_checked_at": "2026-11-24T04:53:03.940Z"
        },
        {
          "id": "1083",
          "url": "https://govrelations.ai/mcp",
          "server_name": "ai.govrelations/govrelations",
          "last_state": "listed",
          "last_checked_at": "2026-11-24T04:55:06.808Z"
        },
        {
          "id": "1353",
          "url": "https://kwekuanansi.ai/mcp/africa-contacts",
          "server_name": "ai.kwekuanansi/africa-contacts",
          "last_state": "listed",
          "last_checked_at": "2026-11-24T05:02:01.039Z"
        },
        {
          "id": "1354",
          "url": "https://kwekuanansi.ai/mcp/africa-pay",
          "server_name": "ai.kwekuanansi/africa-pay",
          "last_state": "listed",
          "last_checked_at": "2026-11-24T05:03:02.433Z"
        },
        {
          "id": "1355",
          "url": "https://kwekuanansi.ai/mcp/africa-scam-check",
          "server_name": "ai.kwekuanansi/africa-scam-check",
          "last_state": "listed",
          "last_checked_at": "2026-11-24T05:04:00.724Z"
        },
        {
          "id": "1356",
          "url": "https://kwekuanansi.ai/mcp/akan-proverbs",
          "server_name": "ai.kwekuanansi/akan-proverbs",
          "last_state": "listed",
          "last_checked_at": "2026-11-24T05:05:02.260Z"
        },
        {
          "id": "1357",
          "url": "https://kwekuanansi.ai/mcp/day-names",
          "server_name": "ai.kwekuanansi/day-names",
          "last_state": "listed",
          "last_checked_at": "2026-11-24T06:44:01.088Z"
        },
        {
          "id": "1358",
          "url": "https://kwekuanansi.ai/mcp/exam-grades",
          "server_name": "ai.kwekuanansi/exam-grades",
          "last_state": "listed",
          "last_checked_at": "2026-11-24T06:46:01.972Z"
        },
        {
          "id": "1359",
          "url": "https://kwekuanansi.ai/mcp/ghana-contacts",
          "server_name": "ai.kwekuanansi/ghana-contacts",
          "last_state": "listed",
          "last_checked_at": "2026-11-24T06:47:02.970Z"
        }
      ]
    },
    "same_site": {
      "total": 0,
      "sample": []
    },
    "same_tool_list": {
      "total": 0,
      "sample": []
    },
    "same_publisher": {
      "publisher": "com.restaurantdoctorai",
      "total": 0,
      "sample": []
    },
    "same_repository": {
      "repository_url": "https://github.com/FelixNovaNexus/restaurantdoctorai-mcp",
      "total": 0,
      "sample": []
    },
    "note": "Shared addresses on big platforms (Cloudflare, Vercel and the like) put unrelated servers together; those are marked shared_infrastructure. A match is a pivot, not a link between operators."
  },
  "endpoint": {
    "id": "15099",
    "server_name": "com.restaurantdoctorai/profit-check",
    "url": "https://restaurantdoctorai.com/api/mcp",
    "host": "restaurantdoctorai.com",
    "transport": "streamable-http",
    "last_checked_at": "2026-11-23T16:12:13.459Z",
    "last_state": "listed",
    "last_detail": null,
    "consecutive_failures": 0,
    "current_sha": "91e1907a2b5995e08c62ac541916c1d86b01fbfc3a9afeff196ad1c412105480",
    "first_listed_at": "2026-11-21T10:39:01.976Z",
    "created_at": "2026-11-21T06:40:08.285Z",
    "resolved_addresses": [
      "216.150.1.1"
    ]
  },
  "server": {
    "name": "com.restaurantdoctorai/profit-check",
    "title": "RestaurantDoctorAI",
    "description": "Free restaurant profit check, recipe costing, calculators, website check, deadlines, guides, blog.",
    "version": "1.14.0",
    "registry_status": "active",
    "repository_url": "https://github.com/FelixNovaNexus/restaurantdoctorai-mcp",
    "website_url": "https://restaurantdoctorai.com/ai-assistants",
    "published_at": "2026-11-04T10:07:10.350Z",
    "updated_at": "2026-11-04T10:07:10.350Z",
    "first_seen": "2026-11-21T06:40:07.656Z"
  },
  "other_endpoints": [],
  "intel": {
    "capabilities": [
      "vector-search"
    ],
    "evm_addresses": [],
    "chains": [],
    "tokens": [],
    "computed_at": "2026-11-22T15:17:11.835Z"
  },
  "operator": {
    "key": "restaurantdoctorai.com",
    "name": "restaurantdoctorai.com",
    "platform": false,
    "marketplace": false
  },
  "needs_sign_in": false,
  "reachability": {
    "window_days": 30,
    "checks": 3,
    "answered": 3,
    "answered_percent": 100,
    "avg_listing_latency_ms": 380,
    "first_check_in_window": "2026-11-21T10:39:01.976Z",
    "consecutive_failures_now": 0,
    "days": [
      {
        "day": "2026-11-21",
        "checks": 1,
        "answered": 1,
        "last_state": "listed"
      },
      {
        "day": "2026-11-22",
        "checks": 1,
        "answered": 1,
        "last_state": "listed"
      },
      {
        "day": "2026-11-23",
        "checks": 1,
        "answered": 1,
        "last_state": "listed"
      }
    ]
  },
  "tool_list": {
    "sha256": "91e1907a2b5995e08c62ac541916c1d86b01fbfc3a9afeff196ad1c412105480",
    "tools": 22,
    "resources": 0,
    "prompts": 0,
    "first_seen": "2026-11-21T10:39:02.385Z",
    "tool_names": [
      "restaurantdoctor_get_questions",
      "restaurantdoctor_run_free_check",
      "restaurantdoctor_cost_recipe",
      "restaurantdoctor_check_website",
      "restaurantdoctor_deadlines",
      "restaurantdoctor_search_knowledge",
      "restaurantdoctor_list_knowledge",
      "restaurantdoctor_read_knowledge",
      "restaurantdoctor_prime_cost",
      "restaurantdoctor_labor_cost",
      "restaurantdoctor_break_even",
      "restaurantdoctor_restaurant_budget",
      "restaurantdoctor_plate_cost",
      "restaurantdoctor_delivery_price",
      "restaurantdoctor_menu_calories",
      "restaurantdoctor_fica_tip_credit",
      "restaurantdoctor_card_fees",
      "restaurantdoctor_booking_fees",
      "restaurantdoctor_cash_out",
      "restaurantdoctor_tip_out",
      "restaurantdoctor_par_levels",
      "restaurantdoctor_prime_cost_consult"
    ],
    "declared": {
      "tools": [
        {
          "name": "restaurantdoctor_get_questions",
          "title": "Profit check questions",
          "description": "Lists the 12 multiple-choice questions of the free restaurant profit check, with the answer values each one accepts. Money ranges, delivery apps and review sites follow the restaurant's country (default US).",
          "inputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "properties": {
              "country": {
                "type": "string",
                "default": "US",
                "pattern": "^[A-Za-z]{2}$",
                "description": "Where the restaurant is: a two-letter ISO 3166-1 code such as US, CA, AU or DE (GB for the United Kingdom). Sets the currency and local wording. Defaults to US."
              }
            },
            "additionalProperties": false
          },
          "outputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "country",
              "countryName",
              "currency",
              "questions",
              "countries"
            ],
            "properties": {
              "country": {
                "type": "string"
              },
              "currency": {
                "type": "string",
                "description": "Of the money ranges (ISO 4217)."
              },
              "countries": {
                "type": "object",
                "required": [
                  "note"
                ],
                "properties": {
                  "note": {
                    "type": "string"
                  }
                },
                "additionalProperties": false
              },
              "questions": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "key",
                    "section",
                    "question",
                    "options"
                  ],
                  "properties": {
                    "key": {
                      "type": "string",
                      "description": "The answer's name, as the free check takes it."
                    },
                    "options": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "required": [
                          "value",
                          "label"
                        ],
                        "properties": {
                          "label": {
                            "type": "string"
                          },
                          "value": {
                            "type": "string"
                          }
                        },
                        "additionalProperties": false
                      }
                    },
                    "section": {
                      "type": "string"
                    },
                    "question": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                }
              },
              "countryName": {
                "type": "string"
              }
            },
            "additionalProperties": false
          },
          "annotations": {
            "title": "Profit check questions",
            "readOnlyHint": true,
            "openWorldHint": false,
            "idempotentHint": true,
            "destructiveHint": false
          }
        },
        {
          "name": "restaurantdoctor_run_free_check",
          "title": "Run the free profit check",
          "description": "Scores a restaurant's 12 answers against RestaurantDoctorAI's targets for its type of restaurant and returns the free result the website shows: an overall grade, grades by area, the estimated money lost to avoidable costs, all of them together, a month and a year, the costliest issue or biggest opportunity with its estimated money a month, what one point of prime cost is worth, and the first fix. Includes a link that opens the same result on restaurantdoctorai.com. Takes only the 12 answers and the country, each answer one of the values its question accepts. The answers aren't stored; only an anonymous daily count of checks is kept.",
          "inputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "serviceModel",
              "monthlyRevenue",
              "primeCostAwareness",
              "plateCostingFrequency",
              "wasteTrackingMethod",
              "beverageMonitoring",
              "laborFlexing",
              "occupancyCostRatio",
              "deliveryDependency",
              "seatingDynamics",
              "contactCapture",
              "reputationHealth"
            ],
            "properties": {
              "country": {
                "type": "string",
                "default": "US",
                "pattern": "^[A-Za-z]{2}$",
                "description": "Where the restaurant is: a two-letter ISO 3166-1 code such as US, CA, AU or DE (GB for the United Kingdom). Sets the currency and local wording. Defaults to US."
              },
              "laborFlexing": {
                "enum": [
                  "realtime_cuts_splh",
                  "fixed_shifts_regardless",
                  "overtime_above_8_percent",
                  "chronic_understaffing_owner_covers"
                ],
                "type": "string",
                "description": "When a shift gets slow, what happens to staffing? realtime_cuts_splh = We cut staff based on sales per labor hour; fixed_shifts_regardless = Everyone works their scheduled shift anyway; overtime_above_8_percent = Overtime is common (More than 8% of hours); chronic_understaffing_owner_covers = We're short-staffed (The owner or GM works the line)."
              },
              "serviceModel": {
                "enum": [
                  "quick_service",
                  "fast_casual",
                  "full_service",
                  "fine_dining",
                  "bar_lounge",
                  "cafe"
                ],
                "type": "string",
                "description": "What kind of restaurant do you run? quick_service = Quick service (Counter or kiosk, fast turnover); fast_casual = Fast casual (Order at the counter, served at the table); full_service = Full service / casual dining (Servers, moderate check); fine_dining = Fine dining (Chef-driven, higher check); bar_lounge = Bar, taproom or lounge (Drinks are about half of sales or more); cafe = Café or coffee shop (Drinks lead, with pastries and light food)."
              },
              "contactCapture": {
                "enum": [
                  "automated_pos_loyalty_50plus",
                  "occasional_checkout_emails",
                  "no_database_social_only",
                  "paid_ads_no_list"
                ],
                "type": "string",
                "description": "How do you bring guests back? automated_pos_loyalty_50plus = Loyalty or email list with automatic campaigns (50+ new contacts a week); occasional_checkout_emails = We collect some emails but rarely use them; no_database_social_only = Social media and walk-ins only; paid_ads_no_list = Paid ads, but no guest list of our own."
              },
              "monthlyRevenue": {
                "enum": [
                  "under_25k",
                  "25k_60k",
                  "60k_120k",
                  "120k_200k",
                  "over_200k"
                ],
                "type": "string",
                "description": "About how much do you sell in a typical month? Amounts are in US dollars, or in the local currency where that's the euro, pound sterling, Swiss franc, or Canadian, Australian or New Zealand dollar. under_25k = Under $25,000 (Under $300K a year); 25k_60k = $25,000 – $60,000 ($300K – $720K a year); 60k_120k = $60,000 – $120,000 ($720K – $1.44M a year); 120k_200k = $120,000 – $200,000 ($1.44M – $2.4M a year); over_200k = Over $200,000 (Over $2.4M a year)."
              },
              "seatingDynamics": {
                "enum": [
                  "consistent_weekround",
                  "packed_weekends_dead_midweek",
                  "strong_lunch_weak_dinner",
                  "erratic_unpredictable"
                ],
                "type": "string",
                "description": "How full is your dining room across the week? consistent_weekround = Steady all week; packed_weekends_dead_midweek = Packed on weekends, quiet midweek; strong_lunch_weak_dinner = Busy lunches, slow dinners; erratic_unpredictable = Hard to predict week to week."
              },
              "reputationHealth": {
                "enum": [
                  "4_5_to_5_0",
                  "4_0_to_4_4",
                  "3_5_to_3_9",
                  "under_3_5"
                ],
                "type": "string",
                "description": "What's your average rating on Google and Yelp? 4_5_to_5_0 = 4.5 – 5.0 stars; 4_0_to_4_4 = 4.0 – 4.4 stars; 3_5_to_3_9 = 3.5 – 3.9 stars; under_3_5 = Below 3.5 stars."
              },
              "beverageMonitoring": {
                "enum": [
                  "no_alcohol",
                  "measured_pour_keg_audits",
                  "occasional_spot_checks",
                  "free_pour_no_audit"
                ],
                "type": "string",
                "description": "How do you control drink pours? no_alcohol = We don't serve alcohol; measured_pour_keg_audits = Measured pours, plus weekly pour-cost checks; occasional_spot_checks = Spot checks when bottles run out early; free_pour_no_audit = Free pours, no pour-cost checks."
              },
              "deliveryDependency": {
                "enum": [
                  "zero_direct_only",
                  "under_15_with_markup",
                  "15_to_35_standard_cut",
                  "over_35_heavy_drag"
                ],
                "type": "string",
                "description": "How much of your sales come through DoorDash, Uber Eats or similar apps? zero_direct_only = None (Dine-in and our own ordering only); under_15_with_markup = Under 15% (With higher app prices to cover fees); 15_to_35_standard_cut = 15% – 35% (At regular menu prices); over_35_heavy_drag = More than 35%."
              },
              "occupancyCostRatio": {
                "enum": [
                  "under_8_percent",
                  "8_to_12_percent",
                  "over_12_percent",
                  "unsure_ratio"
                ],
                "type": "string",
                "description": "What share of sales goes to rent, property costs and utilities? under_8_percent = Under 8%; 8_to_12_percent = 8% – 12%; over_12_percent = More than 12%; unsure_ratio = I'm not sure."
              },
              "primeCostAwareness": {
                "enum": [
                  "under_58",
                  "58_to_64",
                  "over_65",
                  "not_tracked_weekly"
                ],
                "type": "string",
                "description": "What's your prime cost: food, drink and labor costs as a share of sales? under_58 = Under 58%; 58_to_64 = 58% – 64%; over_65 = 65% or more; not_tracked_weekly = I don't track it regularly."
              },
              "wasteTrackingMethod": {
                "enum": [
                  "daily_signed_log",
                  "weekly_visual_estimate",
                  "bulk_loss_only",
                  "no_formal_logging"
                ],
                "type": "string",
                "description": "How do you track kitchen waste and spoilage? daily_signed_log = A daily log the chef signs off; weekly_visual_estimate = A rough estimate during weekly inventory; bulk_loss_only = Only when a big batch or case goes bad; no_formal_logging = We don't track it."
              },
              "plateCostingFrequency": {
                "enum": [
                  "live_monthly_software",
                  "6_to_12m_manual",
                  "new_menu_only",
                  "rarely_gut_feeling"
                ],
                "type": "string",
                "description": "How often do you update recipe costs with current supplier prices? live_monthly_software = Monthly or live, with software (Synced to supplier invoices); 6_to_12m_manual = Once or twice a year (In a spreadsheet); new_menu_only = Only when the menu changes; rarely_gut_feeling = Rarely (Prices are set by feel or by competitors)."
              }
            },
            "additionalProperties": false
          },
          "outputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "country",
              "countryName",
              "grade",
              "risk",
              "needsAttention",
              "needsAttentionText",
              "areas",
              "areasNote",
              "monthlyLeak",
              "yearlyLeak",
              "leakText",
              "biggest",
              "primePoint",
              "notes",
              "dayOneFix",
              "link",
              "disclaimer"
            ],
            "properties": {
              "link": {
                "type": "string",
                "description": "Opens this result on the website."
              },
              "risk": {
                "type": "string"
              },
              "areas": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "area",
                    "grade"
                  ],
                  "properties": {
                    "area": {
                      "type": "string"
                    },
                    "grade": {
                      "enum": [
                        "A",
                        "B",
                        "C",
                        "D",
                        "F"
                      ],
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                }
              },
              "grade": {
                "enum": [
                  "A",
                  "B",
                  "C",
                  "D",
                  "F"
                ],
                "type": "string",
                "description": "A (best) to F."
              },
              "notes": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "What the result assumes."
              },
              "biggest": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "kind",
                      "title",
                      "monthly"
                    ],
                    "properties": {
                      "kind": {
                        "enum": [
                          "leak",
                          "opportunity"
                        ],
                        "type": "string"
                      },
                      "title": {
                        "type": "string"
                      },
                      "monthly": {
                        "type": "object",
                        "required": [
                          "low",
                          "high",
                          "currency",
                          "text"
                        ],
                        "properties": {
                          "low": {
                            "type": "number"
                          },
                          "high": {
                            "type": "number"
                          },
                          "text": {
                            "type": "string"
                          },
                          "currency": {
                            "type": "string"
                          }
                        },
                        "description": "Its estimated money a month, as the website shows it big: lost for an avoidable cost, added sales for an opportunity.",
                        "additionalProperties": false
                      }
                    },
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ],
                "description": "The costliest issue, or the biggest sales opportunity when nothing costs money."
              },
              "country": {
                "type": "string"
              },
              "leakText": {
                "type": "string"
              },
              "alsoCheck": {
                "type": "string"
              },
              "areasNote": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "Why the overall grade differs from the area letters."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "dayOneFix": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "Day 1 of the plan."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "disclaimer": {
                "type": "string"
              },
              "primePoint": {
                "type": "string",
                "description": "What one point of prime cost (1% of sales) is worth a month, at the working figure for the sales range."
              },
              "yearlyLeak": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "low",
                      "high",
                      "currency",
                      "text"
                    ],
                    "properties": {
                      "low": {
                        "type": "number"
                      },
                      "high": {
                        "type": "number"
                      },
                      "text": {
                        "type": "string"
                      },
                      "currency": {
                        "type": "string"
                      }
                    },
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ],
                "description": "The same total a year. null when no major avoidable cost was found."
              },
              "countryName": {
                "type": "string"
              },
              "monthlyLeak": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "low",
                      "high",
                      "currency",
                      "text"
                    ],
                    "properties": {
                      "low": {
                        "type": "number"
                      },
                      "high": {
                        "type": "number"
                      },
                      "text": {
                        "type": "string"
                      },
                      "currency": {
                        "type": "string"
                      }
                    },
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ],
                "description": "The total lost to avoidable costs a month, as the website leads with it. null when no major avoidable cost was found."
              },
              "needsAttention": {
                "type": "integer",
                "maximum": 12,
                "minimum": 0
              },
              "needsAttentionText": {
                "type": "string"
              }
            },
            "additionalProperties": false
          },
          "annotations": {
            "title": "Run the free profit check",
            "readOnlyHint": true,
            "openWorldHint": false,
            "idempotentHint": true,
            "destructiveHint": false
          }
        },
        {
          "name": "restaurantdoctor_cost_recipe",
          "title": "Cost a recipe (draft)",
          "description": "Reads a recipe's ingredient lines as written, weighs each one with USDA FoodData Central and USDA yields, and prices it with the owner's own prices when given, else dated US public prices (BLS and USDA ERS store averages, USDA wholesale prices, and USDA weekly store-ad sale prices, which run low). Returns a draft in US dollars: each line's grams, cost and price source, what each line still needs, the cost per plate as a range, and a link that opens the draft on restaurantdoctorai.com, where the owner checks each line and adds prices for one plate cost and a menu price. The draft never gives one plate cost or a menu price, and says nothing about allergens or nutrition. The recipe isn't stored; only an anonymous daily count of drafts is kept.",
          "inputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "recipe"
            ],
            "properties": {
              "prices": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "ingredient",
                    "paid",
                    "packSize",
                    "packUnit"
                  ],
                  "properties": {
                    "paid": {
                      "type": "number",
                      "maximum": 1000000,
                      "minimum": 0,
                      "description": "What the owner pays for one pack, in US dollars."
                    },
                    "countOf": {
                      "enum": [
                        "each",
                        "clove",
                        "slice",
                        "stick",
                        "bunch",
                        "sprig",
                        "leaf",
                        "can",
                        "package"
                      ],
                      "type": "string",
                      "description": "With packUnit each: what one item is, when it isn't a whole one, such as clove or bunch."
                    },
                    "packSize": {
                      "type": "number",
                      "maximum": 1000000,
                      "description": "How much one pack holds: 10 for a 10 lb case.",
                      "exclusiveMinimum": 0
                    },
                    "packUnit": {
                      "enum": [
                        "g",
                        "kg",
                        "oz",
                        "lb",
                        "ml",
                        "l",
                        "floz",
                        "gal",
                        "each"
                      ],
                      "type": "string",
                      "description": "The pack's unit: g, kg, oz, lb, ml, l, floz (US fluid ounces), gal (US gallons) or each."
                    },
                    "ingredient": {
                      "type": "string",
                      "maxLength": 100,
                      "minLength": 1,
                      "description": "The ingredient as the recipe names it, such as \"ground beef\"."
                    }
                  },
                  "additionalProperties": false
                },
                "maxItems": 60,
                "description": "The owner's own prices, when they give them. Lines without one use US public prices: store averages (BLS, USDA ERS), wholesale prices (USDA) and, for items those don't cover, USDA weekly store-ad sale prices, which run low. None is the owner's cost. Tap water is costed at 0."
              },
              "recipe": {
                "type": "string",
                "maxLength": 8000,
                "minLength": 1,
                "description": "The recipe as written: its name, its servings line (\"Serves 6\") and its ingredient lines, one a line, each amount and unit exactly as the recipe or the photo gives it. Method steps may follow under a heading such as \"Instructions\"; only ingredient lines are costed. The lines are read as sent, not converted, rounded or corrected: the owner checks them on the website. At most 8000 characters and 60 ingredient lines."
              },
              "source": {
                "enum": [
                  "text",
                  "typed-photo",
                  "handwriting",
                  "pdf"
                ],
                "type": "string",
                "default": "text",
                "description": "Where the recipe came from: text the owner typed or pasted (text), a photo or scan of a printed or typed page (typed-photo), a handwritten card (handwriting), or a PDF (pdf). It sets how many lines the owner confirms on the website: handwriting, every line."
              },
              "servings": {
                "type": "number",
                "maximum": 100000,
                "description": "How many plates the recipe makes, when its text doesn't say.",
                "exclusiveMinimum": 0
              }
            },
            "additionalProperties": false
          },
          "outputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "recipe",
              "servings",
              "currency",
              "cost",
              "lines",
              "priceFirst",
              "checks",
              "notes",
              "unusedPrices",
              "link",
              "nextStep",
              "sources",
              "disclaimer"
            ],
            "properties": {
              "cost": {
                "type": "object",
                "required": [
                  "state",
                  "plate",
                  "batch",
                  "ownerShare",
                  "text"
                ],
                "properties": {
                  "text": {
                    "type": "string"
                  },
                  "batch": {
                    "anyOf": [
                      {
                        "type": "object",
                        "required": [
                          "low",
                          "high"
                        ],
                        "properties": {
                          "low": {
                            "type": "number"
                          },
                          "high": {
                            "type": "number"
                          }
                        },
                        "description": "The whole recipe's cost, low to high. Null while incomplete.",
                        "additionalProperties": false
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "plate": {
                    "anyOf": [
                      {
                        "type": "object",
                        "required": [
                          "low",
                          "high"
                        ],
                        "properties": {
                          "low": {
                            "type": "number"
                          },
                          "high": {
                            "type": "number"
                          }
                        },
                        "description": "A plate's cost, low to high. Null until the cost and the plates are known.",
                        "additionalProperties": false
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "state": {
                    "enum": [
                      "range",
                      "incomplete"
                    ],
                    "type": "string",
                    "description": "range: every line is priced. incomplete: some lines need an amount, an ingredient or a price first, so there's no total."
                  },
                  "ownerShare": {
                    "type": "number",
                    "maximum": 1,
                    "minimum": 0,
                    "description": "The share of the priced cost that's on the owner's own prices."
                  }
                },
                "additionalProperties": false
              },
              "link": {
                "type": "string",
                "description": "Opens this draft on the website, where the owner checks each line."
              },
              "lines": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "line",
                    "amount",
                    "ingredient",
                    "match",
                    "status",
                    "grams",
                    "cost",
                    "price",
                    "needs",
                    "size",
                    "check",
                    "notes"
                  ],
                  "properties": {
                    "cost": {
                      "anyOf": [
                        {
                          "type": "object",
                          "required": [
                            "low",
                            "high"
                          ],
                          "properties": {
                            "low": {
                              "type": "number"
                            },
                            "high": {
                              "type": "number"
                            }
                          },
                          "description": "The line's cost for the whole recipe, low to high.",
                          "additionalProperties": false
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "line": {
                      "type": "string",
                      "description": "As written."
                    },
                    "size": {
                      "anyOf": [
                        {
                          "type": "string",
                          "description": "For a can, jar or package line whose recipe gives no size: that its cost waits for the size, which the owner picks on the website. Null otherwise."
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "check": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "What the owner should look at on this line."
                    },
                    "grams": {
                      "anyOf": [
                        {
                          "type": "number",
                          "description": "The weight used, after trimming."
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "match": {
                      "enum": [
                        "exact",
                        "close",
                        "guess",
                        "none"
                      ],
                      "type": "string",
                      "description": "How sure the match is."
                    },
                    "needs": {
                      "anyOf": [
                        {
                          "type": "string",
                          "description": "What the line needs before it can be costed."
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "notes": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "What was assumed to weigh and price it."
                    },
                    "price": {
                      "anyOf": [
                        {
                          "type": "string",
                          "description": "Where its price comes from: \"Your price\", \"Store average, Aug 2026 (BLS)\", \"Store average, 2023 (USDA ERS)\", \"Wholesale, Oct 2026 (USDA)\", \"Store ad price, week of Sep 28, 2026 (USDA AMS); sale prices run low\" or \"Tap water, costed at 0\"."
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "amount": {
                      "type": "string",
                      "description": "As read: \"2 lb\", \"1 can (14.5 oz)\", \"To taste\", \"No amount\"."
                    },
                    "status": {
                      "enum": [
                        "costed",
                        "left-out",
                        "needs"
                      ],
                      "type": "string"
                    },
                    "ingredient": {
                      "anyOf": [
                        {
                          "type": "string",
                          "description": "The USDA FoodData Central food it was matched to."
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "additionalProperties": false
                }
              },
              "notes": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "What the draft assumed about the whole recipe."
              },
              "checks": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "Amounts that look like slips, such as a lot of salt for the plates."
              },
              "recipe": {
                "type": "string"
              },
              "sources": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The public prices used."
              },
              "currency": {
                "type": "string",
                "const": "USD"
              },
              "nextStep": {
                "type": "string"
              },
              "servings": {
                "anyOf": [
                  {
                    "type": "number",
                    "description": "Plates the recipe makes: null when neither the recipe nor the call says."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "disclaimer": {
                "type": "string"
              },
              "priceFirst": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The dearest lines not on the owner's prices yet: their prices move the cost the most."
              },
              "unusedPrices": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "Prices sent that matched no line."
              }
            },
            "additionalProperties": false
          },
          "annotations": {
            "title": "Cost a recipe (draft)",
            "readOnlyHint": true,
            "openWorldHint": false,
            "idempotentHint": true,
            "destructiveHint": false
          }
        },
        {
          "name": "restaurantdoctor_check_website",
          "title": "Check a restaurant's website",
          "description": "Checks a restaurant's own website as the online check on restaurantdoctorai.com does: secure (https) and on its own address, made for phones, a menu written as text that phones and Google can read, online orders on its own terms or only through delivery apps, the address, hours and phone written on the page, tap to call, a way to get in touch, email sign-up and gift cards, what Google reads (a headline, title and description, not hidden from search, restaurant structured data), the preview a shared link shows, the page's text, story, questions, reviews, photo descriptions and social links, and Google's phone speed test with its measures one by one and real visitors' speed when Google has it (15 to 40 seconds; phoneSpeed: false skips it). Returns the score and grade, each area's score, the three checks to fix first with what to do about each, what a basic AI reader can tell about each question in a word, and a link to the full online check, which adds the Google listing, every check with what to fix, the reasons and places nearby on the website. A check it couldn't make (a page drawn by scripts, a security screen instead of the page) is left out of the score, never failed; every check, its points and where its facts come from are listed at https://restaurantdoctorai.com/online-check/checks. Takes only the website address. The website isn't stored; only an anonymous daily count of checks is kept.",
          "inputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "website"
            ],
            "properties": {
              "website": {
                "type": "string",
                "maxLength": 300,
                "minLength": 4,
                "description": "The restaurant's own website address, such as joesdiner.com or https://www.joesdiner.com. Not a DoorDash, Uber Eats or Google Maps page."
              },
              "phoneSpeed": {
                "type": "boolean",
                "default": true,
                "description": "Whether to run Google's phone speed test too (the default). It takes 15 to 40 seconds; false skips it."
              }
            },
            "additionalProperties": false
          },
          "outputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "website",
              "score",
              "grade",
              "meaning",
              "needWork",
              "checked",
              "areas",
              "fixFirst",
              "phoneSpeedSkipped",
              "aiAnswers",
              "fullCheckUrl"
            ],
            "properties": {
              "areas": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "title",
                    "score",
                    "toFix"
                  ],
                  "properties": {
                    "score": {
                      "anyOf": [
                        {
                          "type": "number",
                          "description": "0 to 100."
                        },
                        {
                          "type": "null",
                          "description": "Nothing could be checked here, or the phone speed test was skipped."
                        }
                      ]
                    },
                    "title": {
                      "type": "string"
                    },
                    "toFix": {
                      "type": "number",
                      "description": "How many checks in this area need work."
                    }
                  },
                  "additionalProperties": false
                },
                "description": "The score for the website and for its speed on a phone."
              },
              "grade": {
                "enum": [
                  "A",
                  "B",
                  "C",
                  "D",
                  "F"
                ],
                "type": "string"
              },
              "score": {
                "type": "number",
                "description": "0 to 100, from the website and phone-speed checks only (the full check adds the Google listing)."
              },
              "checked": {
                "type": "number",
                "description": "How many checks could be made. One that couldn't (a page drawn by scripts, a security screen) is left out of the score, never failed."
              },
              "meaning": {
                "type": "string",
                "description": "What the grade means, in a line for the owner."
              },
              "website": {
                "type": "string",
                "description": "Where the site answered after redirects: its scheme and host only, such as https://www.joesdiner.com."
              },
              "fixFirst": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "title",
                    "found",
                    "fix"
                  ],
                  "properties": {
                    "fix": {
                      "type": "string",
                      "description": "What to do."
                    },
                    "found": {
                      "type": "string",
                      "description": "What the check found."
                    },
                    "title": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                },
                "description": "Up to three checks to fix first, most important first."
              },
              "needWork": {
                "type": "number",
                "description": "How many of the checks need work. The full online check names each one."
              },
              "aiAnswers": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "question",
                    "state",
                    "word"
                  ],
                  "properties": {
                    "word": {
                      "type": "string",
                      "description": "The state in words, as the owner reads it: Found, Not found, Can't tell, Not blocked by your rules, Linked."
                    },
                    "state": {
                      "enum": [
                        "found",
                        "missing",
                        "unknown"
                      ],
                      "type": "string",
                      "description": "found (written on the page, which doesn't mean every assistant gets it), missing (not found) or unknown (can't tell). For whether AI can get in, found means no block in the site's robots.txt or tags (a firewall we can't see could still turn crawlers away) and missing means the site's own rules block or limit it."
                    },
                    "question": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                },
                "description": "What a basic AI reader can tell from the home page and at most one menu page: whether AI can get in, what the restaurant sells, its prices, hours, phone and address, and how guests can order or book. Not part of the score. Assistants differ, and some run scripts. No score, and no promise of being recommended."
              },
              "fullCheckUrl": {
                "type": "string",
                "description": "The full online check on restaurantdoctorai.com: adds the Google listing, every check with what to fix, the reasons behind each answer and the places nearby."
              },
              "phoneSpeedSkipped": {
                "type": "boolean",
                "description": "Google's phone speed test wasn't run, because phoneSpeed was false. It isn't in the score."
              }
            },
            "additionalProperties": false
          },
          "annotations": {
            "title": "Check a restaurant's website",
            "readOnlyHint": true,
            "openWorldHint": true,
            "idempotentHint": false,
            "destructiveHint": false
          }
        },
        {
          "name": "restaurantdoctor_deadlines",
          "title": "List a restaurant's deadlines",
          "description": "Lists a US restaurant's coming tax, payroll, license and permit deadlines, as the deadline calendar on restaurantdoctorai.com does: federal dates (payroll forms, tip reports, W-2s, 1099s, returns, estimated tax) and the state's (sales tax, unemployment reports, yearly reports, franchise taxes, minimum wage changes, liquor and health permit dates where one date applies to everyone), each moved for weekends and holidays by the agency's rule, with the rule, what a miss costs and the official source. A state date is given only where the state's own page confirms it; the rest come as what to check with the agency. Also the rules for each hire, and a link that opens the same calendar on the website, where the owner adds their own license and permit dates and gets free email reminders. Takes the state and yes/no answers, no names or emails; scope (federal or state) and withinDays (the next so many days) cut the list. Reminders, not legal or tax advice. The answers aren't stored; only an anonymous daily count of calendars is kept.",
          "inputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "state",
              "staff",
              "alcohol"
            ],
            "properties": {
              "city": {
                "type": "string",
                "pattern": "^[a-z0-9-]{1,40}$",
                "description": "A city with its own minimum wage, as an id like los-angeles or chicago; left out, the state's rate applies."
              },
              "tips": {
                "type": "boolean",
                "default": false,
                "description": "Customers usually tip the staff."
              },
              "scope": {
                "enum": [
                  "all",
                  "federal",
                  "state"
                ],
                "type": "string",
                "description": "Optional, to cut the list: federal (the IRS's and other federal dates only), state (the state's and the city's only) or all (the default). The rules for each hire are listed either way."
              },
              "staff": {
                "type": "boolean",
                "description": "Has anyone on payroll."
              },
              "state": {
                "enum": [
                  "AL",
                  "AK",
                  "AZ",
                  "AR",
                  "CA",
                  "CO",
                  "CT",
                  "DE",
                  "DC",
                  "FL",
                  "GA",
                  "HI",
                  "ID",
                  "IL",
                  "IN",
                  "IA",
                  "KS",
                  "KY",
                  "LA",
                  "ME",
                  "MD",
                  "MA",
                  "MI",
                  "MN",
                  "MS",
                  "MO",
                  "MT",
                  "NE",
                  "NV",
                  "NH",
                  "NJ",
                  "NM",
                  "NY",
                  "NC",
                  "ND",
                  "OH",
                  "OK",
                  "OR",
                  "PA",
                  "RI",
                  "SC",
                  "SD",
                  "TN",
                  "TX",
                  "UT",
                  "VT",
                  "VA",
                  "WA",
                  "WV",
                  "WI",
                  "WY"
                ],
                "type": "string",
                "description": "The restaurant's US state, two letters (DC for Washington DC)."
              },
              "formed": {
                "type": "string",
                "pattern": "^\\d{4}-(0[1-9]|1[0-2])$",
                "description": "The month the LLC or corporation was formed with the state, YYYY-MM. Some states set the yearly report by it."
              },
              "months": {
                "type": "integer",
                "default": 3,
                "maximum": 15,
                "minimum": 1,
                "description": "How many months ahead to list, 1 to 15 (default 3). The calendar runs to the end of 2027. withinDays, when sent, sets the window instead."
              },
              "alcohol": {
                "type": "boolean",
                "description": "Sells alcohol."
              },
              "caterer": {
                "type": "boolean",
                "description": "Mainly catering or a food truck, not a restaurant or bar (OSHA's injury log)."
              },
              "business": {
                "enum": [
                  "sole",
                  "llc_single",
                  "llc_multi",
                  "partnership",
                  "s_corp",
                  "c_corp"
                ],
                "type": "string",
                "description": "How the business is set up: sole (sole owner, no LLC), llc_single, llc_multi, partnership (no LLC), s_corp or c_corp. Decides the tax return and the state's yearly report. Left out, both return dates come with an \"If\"."
              },
              "deposits": {
                "enum": [
                  "provider",
                  "monthly",
                  "semiweekly"
                ],
                "type": "string",
                "description": "Who pays the payroll taxes to the IRS: provider (a payroll company), monthly (the owner, by the 15th), semiweekly (the owner, after each payday)."
              },
              "salesTax": {
                "enum": [
                  "monthly",
                  "quarterly",
                  "yearly"
                ],
                "type": "string",
                "description": "How often the state has the restaurant file sales tax (on its permit letter or state account)."
              },
              "bigTipped": {
                "type": "boolean",
                "description": "Tipped, and staff worked more than 80 hours in total on a typical day last year, all locations together (Form 8027)."
              },
              "estimated": {
                "type": "boolean",
                "description": "The owner pays quarterly estimated tax on the business's profit."
              },
              "fullTime50": {
                "type": "boolean",
                "description": "50 or more full-time staff on average, counting part-timers' hours, related businesses together (ACA forms)."
              },
              "withinDays": {
                "type": "integer",
                "maximum": 460,
                "minimum": 1,
                "description": "Optional: only the dates in the next so many days, 1 to 460, from today in the state (7 for the coming week). Sent, it replaces months."
              },
              "contractors": {
                "type": "boolean",
                "description": "Pays a contractor, or rent to a landlord that isn't a corporation, $2,000 or more a year (1099 forms)."
              }
            },
            "additionalProperties": false
          },
          "outputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "state",
              "from",
              "through",
              "deadlines",
              "checkWith",
              "eachHire",
              "calendarUrl",
              "note"
            ],
            "properties": {
              "from": {
                "type": "string",
                "description": "The first day listed (today in the state), YYYY-MM-DD."
              },
              "note": {
                "type": "string"
              },
              "state": {
                "type": "string"
              },
              "through": {
                "type": "string",
                "description": "The last day listed, YYYY-MM-DD."
              },
              "eachHire": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "title",
                    "detail"
                  ],
                  "properties": {
                    "title": {
                      "type": "string"
                    },
                    "detail": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                },
                "description": "Rules that run each time the restaurant hires (or something happens), not on a date."
              },
              "checkWith": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "title",
                    "detail",
                    "link"
                  ],
                  "properties": {
                    "link": {
                      "type": "string"
                    },
                    "title": {
                      "type": "string"
                    },
                    "detail": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                },
                "description": "What we can't date for this owner: their own schedule or papers, or a state page not yet confirmed. No date here is guessed."
              },
              "deadlines": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "date",
                    "title",
                    "what",
                    "appliesIf",
                    "rule",
                    "movedFrom",
                    "missCost",
                    "level",
                    "source"
                  ],
                  "properties": {
                    "date": {
                      "type": "string",
                      "description": "YYYY-MM-DD, after any weekend or holiday move."
                    },
                    "rule": {
                      "type": "string",
                      "description": "Why it's this date."
                    },
                    "what": {
                      "type": "string",
                      "description": "What to do."
                    },
                    "level": {
                      "enum": [
                        "federal",
                        "state",
                        "city"
                      ],
                      "type": "string"
                    },
                    "title": {
                      "type": "string"
                    },
                    "source": {
                      "type": "object",
                      "required": [
                        "name",
                        "url",
                        "checked"
                      ],
                      "properties": {
                        "url": {
                          "type": "string"
                        },
                        "name": {
                          "type": "string"
                        },
                        "checked": {
                          "type": "string"
                        }
                      },
                      "additionalProperties": false
                    },
                    "missCost": {
                      "anyOf": [
                        {
                          "type": "string",
                          "description": "What missing it costs, from its source, when the source says."
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "appliesIf": {
                      "anyOf": [
                        {
                          "type": "string",
                          "description": "When an answer that decides it wasn't given: the condition it depends on."
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "movedFrom": {
                      "anyOf": [
                        {
                          "type": "string",
                          "description": "The date before a weekend or holiday moved it, and why."
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "additionalProperties": false
                }
              },
              "calendarUrl": {
                "type": "string",
                "description": "The same calendar on restaurantdoctorai.com, where the owner can add the dates printed on their own licenses and permits and get email reminders or a calendar link, free."
              }
            },
            "additionalProperties": false
          },
          "annotations": {
            "title": "List a restaurant's deadlines",
            "readOnlyHint": true,
            "openWorldHint": false,
            "idempotentHint": true,
            "destructiveHint": false
          }
        },
        {
          "name": "restaurantdoctor_search_knowledge",
          "title": "Search RestaurantDoctorAI's library",
          "description": "Searches RestaurantDoctorAI's sourced library: the website's guides and blog posts, RestaurantDoctorAI's step-by-step fixes, RestaurantDoctorAI's targets by type of restaurant, sourced industry facts, and an expert knowledge base of sourced how-tos, rules and checklists (costs, labor, money, growth, compliance, operations). Keyword search: \"break-even\", \"breakeven\" and \"break even\" are one term, and plurals match. Returns the best passages, each with its id, kind, title, link and source; kind narrows the search to one kind of entry. RestaurantDoctorAI's targets are its own, not industry benchmarks. The query isn't stored; only an anonymous daily count of searches and reads is kept.",
          "inputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "query"
            ],
            "properties": {
              "kind": {
                "enum": [
                  "guide",
                  "post",
                  "play",
                  "targets",
                  "fact",
                  "knowledge"
                ],
                "type": "string",
                "description": "Only this kind of entry: guide (the website's guides), post (blog posts), play (RestaurantDoctorAI's step-by-step fixes), targets (RestaurantDoctorAI's targets by type of restaurant), fact (sourced industry facts) or knowledge (sourced how-tos, rules and checklists). Left out, every kind."
              },
              "limit": {
                "type": "integer",
                "default": 5,
                "maximum": 8,
                "minimum": 1,
                "description": "The most passages to return, 1 to 8 (default 5). Up to 5, a passage far weaker than the best match is left out."
              },
              "query": {
                "type": "string",
                "maxLength": 300,
                "minLength": 1,
                "description": "What to look up, in plain words, e.g. 'how to lower food cost', 'tip pool rules' or 'delivery app commission'."
              }
            },
            "additionalProperties": false
          },
          "outputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "hits",
              "note"
            ],
            "properties": {
              "hits": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "id",
                    "kind",
                    "title",
                    "url",
                    "source",
                    "passage"
                  ],
                  "properties": {
                    "id": {
                      "type": "string",
                      "description": "The entry's id, which reading the entry in full takes."
                    },
                    "url": {
                      "type": "string",
                      "description": "Where a reader can check it: the page on restaurantdoctorai.com, or the fact's own source."
                    },
                    "kind": {
                      "enum": [
                        "guide",
                        "post",
                        "play",
                        "targets",
                        "fact",
                        "knowledge"
                      ],
                      "type": "string"
                    },
                    "title": {
                      "type": "string"
                    },
                    "source": {
                      "type": "string",
                      "description": "Who says so, with the date it was checked or updated where there is one."
                    },
                    "passage": {
                      "type": "string",
                      "description": "The part of the entry that matched best."
                    }
                  },
                  "additionalProperties": false
                },
                "description": "Best match first. Empty when nothing matches."
              },
              "note": {
                "type": "string"
              }
            },
            "additionalProperties": false
          },
          "annotations": {
            "title": "Search RestaurantDoctorAI's library",
            "readOnlyHint": true,
            "openWorldHint": false,
            "idempotentHint": true,
            "destructiveHint": false
          }
        },
        {
          "name": "restaurantdoctor_list_knowledge",
          "title": "List RestaurantDoctorAI's library",
          "description": "Lists the entries of RestaurantDoctorAI's sourced library, all or one kind (guide, post, play, targets, fact or knowledge), up to 50 at a time: each with its id, kind, title, link and source, and for guides and blog posts the day it was published and last updated. It shows what the library has, such as every blog post and its date. Pages with offset and limit; nextOffset gives the next page. Nothing about the request is stored; only an anonymous daily count of searches (a list counts as one) is kept.",
          "inputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "properties": {
              "kind": {
                "enum": [
                  "guide",
                  "post",
                  "play",
                  "targets",
                  "fact",
                  "knowledge",
                  "all"
                ],
                "type": "string",
                "default": "all",
                "description": "Which kind of entry to list: guide (the website's guides), post (blog posts), play (RestaurantDoctorAI's step-by-step fixes), targets (RestaurantDoctorAI's targets by type of restaurant), fact (sourced industry facts) or knowledge (sourced how-tos, rules and checklists); or all (the default)."
              },
              "limit": {
                "type": "integer",
                "default": 20,
                "maximum": 50,
                "minimum": 1,
                "description": "How many entries to return, 1 to 50 (default 20)."
              },
              "offset": {
                "type": "integer",
                "default": 0,
                "maximum": 9007199254740991,
                "minimum": 0,
                "description": "How many entries to skip (default 0). The next page starts at the nextOffset the previous list returned."
              }
            },
            "additionalProperties": false
          },
          "outputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "kind",
              "total",
              "offset",
              "nextOffset",
              "entries",
              "note"
            ],
            "properties": {
              "kind": {
                "enum": [
                  "guide",
                  "post",
                  "play",
                  "targets",
                  "fact",
                  "knowledge",
                  "all"
                ],
                "type": "string"
              },
              "note": {
                "type": "string"
              },
              "total": {
                "type": "number",
                "description": "How many entries of this kind there are."
              },
              "offset": {
                "type": "number"
              },
              "entries": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "id",
                    "kind",
                    "title",
                    "url",
                    "source",
                    "published",
                    "updated"
                  ],
                  "properties": {
                    "id": {
                      "type": "string",
                      "description": "The entry's id, which reading the entry in full takes."
                    },
                    "url": {
                      "type": "string",
                      "description": "Where a reader can check it: the page on restaurantdoctorai.com, or the fact's own source."
                    },
                    "kind": {
                      "enum": [
                        "guide",
                        "post",
                        "play",
                        "targets",
                        "fact",
                        "knowledge"
                      ],
                      "type": "string"
                    },
                    "title": {
                      "type": "string"
                    },
                    "source": {
                      "type": "string",
                      "description": "Who says so, with the date it was checked or updated where there is one."
                    },
                    "updated": {
                      "anyOf": [
                        {
                          "type": "string",
                          "description": "Guides and blog posts: the day it was last updated, YYYY-MM-DD. Null for other kinds."
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "published": {
                      "anyOf": [
                        {
                          "type": "string",
                          "description": "Guides and blog posts: the day it was first published, YYYY-MM-DD. Null for other kinds."
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "additionalProperties": false
                },
                "description": "In the library's order: guides, blog posts, playbook fixes, targets, facts, then knowledge entries."
              },
              "nextOffset": {
                "anyOf": [
                  {
                    "type": "number",
                    "description": "Where the next page starts: the offset of the next list."
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false
          },
          "annotations": {
            "title": "List RestaurantDoctorAI's library",
            "readOnlyHint": true,
            "openWorldHint": false,
            "idempotentHint": true,
            "destructiveHint": false
          }
        },
        {
          "name": "restaurantdoctor_read_knowledge",
          "title": "Read a library entry",
          "description": "Reads one entry of RestaurantDoctorAI's library in full (a guide, a blog post, a playbook fix, the targets, a fact or a knowledge entry), by its id (such as 'guide:restaurant-prime-cost'), with its title, link and source. A long entry comes 8,000 characters at a time, with its total length: the next part starts at the nextOffset it returns. The query isn't stored; only an anonymous daily count of searches and reads is kept.",
          "inputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "id"
            ],
            "properties": {
              "id": {
                "type": "string",
                "maxLength": 120,
                "minLength": 3,
                "description": "An entry id, as the library's search and list give it, e.g. 'guide:restaurant-prime-cost' or 'post:restaurant-break-even-point'."
              },
              "offset": {
                "type": "integer",
                "default": 0,
                "maximum": 9007199254740991,
                "minimum": 0,
                "description": "Where to start, in characters (default 0, the start). A long entry comes 8,000 characters at a time: the next part starts at the nextOffset the previous read returned."
              }
            },
            "additionalProperties": false
          },
          "outputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "id",
              "kind",
              "title",
              "url",
              "source",
              "text",
              "offset",
              "totalLength",
              "nextOffset",
              "truncated",
              "note"
            ],
            "properties": {
              "id": {
                "type": "string",
                "description": "The entry's id, which reading the entry in full takes."
              },
              "url": {
                "type": "string",
                "description": "Where a reader can check it: the page on restaurantdoctorai.com, or the fact's own source."
              },
              "kind": {
                "enum": [
                  "guide",
                  "post",
                  "play",
                  "targets",
                  "fact",
                  "knowledge"
                ],
                "type": "string"
              },
              "note": {
                "type": "string"
              },
              "text": {
                "type": "string",
                "description": "The entry's text from offset, up to 8,000 characters."
              },
              "title": {
                "type": "string"
              },
              "offset": {
                "type": "number",
                "description": "Where this part starts, in characters."
              },
              "source": {
                "type": "string",
                "description": "Who says so, with the date it was checked or updated where there is one."
              },
              "truncated": {
                "type": "boolean",
                "description": "More of the entry follows this part (nextOffset says where)."
              },
              "nextOffset": {
                "anyOf": [
                  {
                    "type": "number",
                    "description": "Where the next part starts, in characters: the offset of the next read."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "totalLength": {
                "type": "number",
                "description": "The whole entry's length, in characters."
              }
            },
            "additionalProperties": false
          },
          "annotations": {
            "title": "Read a library entry",
            "readOnlyHint": true,
            "openWorldHint": false,
            "idempotentHint": true,
            "destructiveHint": false
          }
        },
        {
          "name": "restaurantdoctor_prime_cost",
          "title": "Prime cost calculator",
          "description": "Works out a restaurant's prime cost from the owner's own figures for one week or month, as the free prime cost calculator on restaurantdoctorai.com does: food and drink used plus labor, as a share of net sales, against the target for its type of restaurant, with what the points over or under are worth, food and labor each against their own range, and which to look at first. Takes net sales, food and drink purchases and wages, plus optional payroll taxes and benefits, stock counts and the owner's unpaid hours, in any currency; a figure that isn't sent is never counted as 0. Returns the calculator's result, how it was worked out, and a link that opens the calculator with the same figures filled in. The figures aren't stored; only an anonymous daily count of calculator runs is kept.",
          "inputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "format",
              "period"
            ],
            "properties": {
              "sales": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Net sales for the period, in the owner's own currency like every figure here, from the POS sales summary: after discounts and comps, before tax and tips, with any service charge paid out to staff added back. Needed for a result, and more than 0; if missing, the reply asks for it."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "wages": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Every wage and salary for the same dates, from payroll, managers included (a salary counts as a 52nd of a year for a week, a 12th for a month). No tips, but a service charge paid to staff stays in. Needed for a result; if missing, the reply asks for it."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "format": {
                "enum": [
                  "quick_service",
                  "fast_casual",
                  "full_service",
                  "fine_dining",
                  "bar_lounge",
                  "cafe"
                ],
                "type": "string",
                "description": "The type of restaurant, which sets the targets: prime cost, and the ranges for food and drink and for labor: quick_service = Quick service (Counter or kiosk, fast turnover); fast_casual = Fast casual (Order at the counter, served at the table); full_service = Full service / casual dining (Servers, moderate check); fine_dining = Fine dining (Chef-driven, higher check); bar_lounge = Bar, taproom or lounge (Drinks are about half of sales or more); cafe = Café or coffee shop (Drinks lead, with pastries and light food)."
              },
              "period": {
                "enum": [
                  "week",
                  "month"
                ],
                "type": "string",
                "description": "Whether every figure covers one week or one month, the same dates for all of them. Sets how a year is worked out (52 weeks or 12 months)."
              },
              "ownerPay": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional: when the owner works in the restaurant without a salary, what they'd pay someone to do their hours, plus the payroll taxes on it. It's a second figure; the main one stays as the books have it."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "purchases": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Food and drink supplier invoices for the same dates, added up by delivery date, minus credits. No packaging. Needed for a result; if missing, the reply asks for it."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "closingStock": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional: stock at cost at the end of the period, counted on the same items the invoices cover. Used only with openingStock."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "openingStock": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional: stock at cost at the start of the period. Used only with closingStock: food and drink then becomes what was used, opening + purchases - closing."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "payrollCosts": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional: the employer's payroll taxes and benefits for the period, such as health insurance or a pension, when the wages figure leaves them out."
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false
          },
          "outputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "format",
              "period",
              "primeCostPct",
              "target",
              "standing",
              "points",
              "figures",
              "usedStockCounts",
              "overTarget",
              "pointValue",
              "foodAndDrinkShare",
              "laborShare",
              "left",
              "withOwnerPay",
              "result",
              "guide",
              "checks",
              "notes",
              "workedOut",
              "link",
              "freeCheck"
            ],
            "properties": {
              "left": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "pct",
                      "money"
                    ],
                    "properties": {
                      "pct": {
                        "type": "number"
                      },
                      "money": {
                        "type": "number"
                      }
                    },
                    "description": "What's left after prime cost, for rent and everything else.",
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "link": {
                "type": "string",
                "description": "Opens the calculator on the website with these figures filled in."
              },
              "guide": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The guide the result points to."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "notes": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "checks": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "Figures that look like a slip, as the page flags them. They don't block the result."
              },
              "format": {
                "enum": [
                  "quick_service",
                  "fast_casual",
                  "full_service",
                  "fine_dining",
                  "bar_lounge",
                  "cafe"
                ],
                "type": "string"
              },
              "period": {
                "enum": [
                  "week",
                  "month"
                ],
                "type": "string"
              },
              "points": {
                "type": "number",
                "description": "Points over the target, or to spare under it; 0 right at it."
              },
              "result": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The result in the page's words, in its order."
              },
              "target": {
                "type": "number",
                "description": "The prime cost ceiling for this type of restaurant, % of net sales."
              },
              "figures": {
                "type": "object",
                "required": [
                  "sales",
                  "foodAndDrink",
                  "labor",
                  "primeCost"
                ],
                "properties": {
                  "labor": {
                    "type": "number",
                    "description": "Wages plus payroll taxes and benefits."
                  },
                  "sales": {
                    "type": "number"
                  },
                  "primeCost": {
                    "type": "number"
                  },
                  "foodAndDrink": {
                    "type": "number",
                    "description": "Used: opening + purchases - closing with both stock counts, else purchases."
                  }
                },
                "description": "In the currency of the figures sent.",
                "additionalProperties": false
              },
              "standing": {
                "enum": [
                  "over",
                  "at",
                  "within"
                ],
                "type": "string",
                "description": "Against the target, on the share as shown."
              },
              "freeCheck": {
                "type": "string"
              },
              "workedOut": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "label",
                    "value"
                  ],
                  "properties": {
                    "label": {
                      "type": "string"
                    },
                    "value": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                },
                "description": "How it was worked out, with the figures in each step."
              },
              "laborShare": {
                "type": "object",
                "required": [
                  "pct",
                  "range",
                  "band",
                  "pointsOver"
                ],
                "properties": {
                  "pct": {
                    "type": "number",
                    "description": "% of net sales, one decimal."
                  },
                  "band": {
                    "enum": [
                      "under",
                      "inside",
                      "over"
                    ],
                    "type": "string",
                    "description": "Under the range reads as fine, as long as every invoice or pay period is in."
                  },
                  "range": {
                    "type": "object",
                    "required": [
                      "low",
                      "high"
                    ],
                    "properties": {
                      "low": {
                        "type": "number"
                      },
                      "high": {
                        "type": "number"
                      }
                    },
                    "description": "Its range for this type of restaurant, % of net sales.",
                    "additionalProperties": false
                  },
                  "pointsOver": {
                    "type": "number"
                  }
                },
                "additionalProperties": false
              },
              "overTarget": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "perPeriod",
                      "perYear"
                    ],
                    "properties": {
                      "perYear": {
                        "type": "number"
                      },
                      "perPeriod": {
                        "type": "number"
                      }
                    },
                    "description": "The money over the target, a period and a year, rounded as the page shows it.",
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "pointValue": {
                "type": "object",
                "required": [
                  "perPeriod",
                  "perYear"
                ],
                "properties": {
                  "perYear": {
                    "type": "number"
                  },
                  "perPeriod": {
                    "type": "number"
                  }
                },
                "description": "One point of prime cost (1% of net sales), a period and a year, rounded as the page shows it.",
                "additionalProperties": false
              },
              "primeCostPct": {
                "type": "number",
                "description": "Food and drink used plus labor, % of net sales, one decimal."
              },
              "withOwnerPay": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "pct",
                      "standing",
                      "points"
                    ],
                    "properties": {
                      "pct": {
                        "type": "number"
                      },
                      "points": {
                        "type": "number"
                      },
                      "standing": {
                        "enum": [
                          "over",
                          "at",
                          "within"
                        ],
                        "type": "string"
                      }
                    },
                    "description": "Prime cost with the owner's unpaid hours counted.",
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "usedStockCounts": {
                "type": "boolean"
              },
              "foodAndDrinkShare": {
                "type": "object",
                "required": [
                  "pct",
                  "range",
                  "band",
                  "pointsOver"
                ],
                "properties": {
                  "pct": {
                    "type": "number",
                    "description": "% of net sales, one decimal."
                  },
                  "band": {
                    "enum": [
                      "under",
                      "inside",
                      "over"
                    ],
                    "type": "string",
                    "description": "Under the range reads as fine, as long as every invoice or pay period is in."
                  },
                  "range": {
                    "type": "object",
                    "required": [
                      "low",
                      "high"
                    ],
                    "properties": {
                      "low": {
                        "type": "number"
                      },
                      "high": {
                        "type": "number"
                      }
                    },
                    "description": "Its range for this type of restaurant, % of net sales.",
                    "additionalProperties": false
                  },
                  "pointsOver": {
                    "type": "number"
                  }
                },
                "additionalProperties": false
              }
            },
            "additionalProperties": false
          },
          "annotations": {
            "title": "Prime cost calculator",
            "readOnlyHint": true,
            "openWorldHint": false,
            "idempotentHint": true,
            "destructiveHint": false
          }
        },
        {
          "name": "restaurantdoctor_labor_cost",
          "title": "Labor cost calculator",
          "description": "Works out a restaurant's labor cost from the owner's own payroll figures for one week or month, as the free labor cost calculator on restaurantdoctorai.com does, in one of its three modes: share (labor as a % of net sales, against the range for its type of restaurant, with what the points over are worth), hours (next period's labor budget and the hourly staff hours it pays for once salaries are paid) or line (the cut line: the sales per labor hour below which the first person goes home). Takes net sales, hourly pay and hours worked, plus optional salaries, payroll taxes and benefits, expected sales, a target and more, in any currency; a figure that isn't sent is never counted as 0. Returns the calculator's result, how it was worked out, and a link that opens the calculator with the same figures filled in. The figures aren't stored; only an anonymous daily count of calculator runs is kept.",
          "inputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "mode",
              "format",
              "period"
            ],
            "properties": {
              "mode": {
                "enum": [
                  "share",
                  "hours",
                  "line"
                ],
                "type": "string",
                "description": "What to work out, as the page's tabs. share: last period's labor cost, % of net sales, against the range (needs sales, hourlyWages). hours: the labor budget for next period's expected sales and the hourly staff hours it pays for (needs forecast, hourlyWages, hours). line: the cut line, the sales per labor hour below which the first person goes home (needs hourlyWages, hours, and sales or forecast)."
              },
              "hours": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Hours those staff worked last period, from the time clock: overtime in, salaried managers out. Needed for hours and line."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "sales": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Last period's net sales, in the owner's own currency like every amount here, from the POS: after discounts and comps, before tax and tips, plus any service charge paid out to staff. Needed for share, and for line without forecast."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "format": {
                "enum": [
                  "quick_service",
                  "fast_casual",
                  "full_service",
                  "fine_dining",
                  "bar_lounge",
                  "cafe"
                ],
                "type": "string",
                "description": "The type of restaurant, which sets the labor range and the starting target: quick_service = Quick service (Counter or kiosk, fast turnover); fast_casual = Fast casual (Order at the counter, served at the table); full_service = Full service / casual dining (Servers, moderate check); fine_dining = Fine dining (Chef-driven, higher check); bar_lounge = Bar, taproom or lounge (Drinks are about half of sales or more); cafe = Café or coffee shop (Drinks lead, with pastries and light food)."
              },
              "period": {
                "enum": [
                  "week",
                  "month"
                ],
                "type": "string",
                "description": "Whether the figures are a week's or a month's: last period's, all for the same dates, and forecast for the next. Sets how a year is worked out (52 weeks or 12 months)."
              },
              "target": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 99,
                    "minimum": 1,
                    "description": "Optional, for hours and line: the owner's labor target, % of net sales (1 to 99). Left out: the top of the range, where the page starts."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "forecast": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Net sales expected next period, more than 0: the last 4 weeks' (or 3 months') average, adjusted for events and holidays. Needed for hours; for line, the line is then for these sales."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "ownerPay": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional, for share: if the owner works without a salary, what someone doing their hours would cost, payroll taxes in. Shown as a second figure."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "salaries": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional: salaried pay for the period (a yearly salary ÷ 52, or ÷ 12 for a month)."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "hourSales": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional, for line: net sales in the last hour of a shift, for how many hourly staff it pays for."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "hourlyWages": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Last period's gross pay for everyone paid by the hour, from payroll: by the days worked, overtime in, tips out. 0 if all are salaried (share only). Needed in every mode."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "payrollCosts": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional: the employer's payroll taxes and benefits on that pay, such as health insurance. Left out, labor reads lower, unless the pay already includes them."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "overtimeHours": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional, for share: how many of the hours worked were overtime."
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false
          },
          "outputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "mode",
              "format",
              "period",
              "range",
              "target",
              "hourCost",
              "share",
              "nextPeriod",
              "cutLine",
              "result",
              "guide",
              "checks",
              "notes",
              "workedOut",
              "link",
              "freeCheck"
            ],
            "properties": {
              "link": {
                "type": "string",
                "description": "Opens the calculator with these figures."
              },
              "mode": {
                "enum": [
                  "share",
                  "hours",
                  "line"
                ],
                "type": "string"
              },
              "guide": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The guide the result points to."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "notes": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "range": {
                "type": "object",
                "required": [
                  "low",
                  "high"
                ],
                "properties": {
                  "low": {
                    "type": "number"
                  },
                  "high": {
                    "type": "number"
                  }
                },
                "additionalProperties": false
              },
              "share": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "pct",
                      "band",
                      "pointsOver",
                      "overRange",
                      "pointValue",
                      "withOwnerPay"
                    ],
                    "properties": {
                      "pct": {
                        "type": "number",
                        "description": "Pay, salaries, taxes and benefits, % of net sales."
                      },
                      "band": {
                        "enum": [
                          "under",
                          "inside",
                          "over"
                        ],
                        "type": "string"
                      },
                      "overRange": {
                        "anyOf": [
                          {
                            "type": "object",
                            "required": [
                              "perPeriod",
                              "perYear"
                            ],
                            "properties": {
                              "perYear": {
                                "type": "number"
                              },
                              "perPeriod": {
                                "type": "number"
                              }
                            },
                            "description": "The money over the range, a period and a year.",
                            "additionalProperties": false
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "pointValue": {
                        "type": "object",
                        "required": [
                          "perPeriod",
                          "perYear"
                        ],
                        "properties": {
                          "perYear": {
                            "type": "number"
                          },
                          "perPeriod": {
                            "type": "number"
                          }
                        },
                        "description": "One point (1% of net sales), a period and a year.",
                        "additionalProperties": false
                      },
                      "pointsOver": {
                        "type": "number"
                      },
                      "withOwnerPay": {
                        "anyOf": [
                          {
                            "type": "number",
                            "description": "The % with the owner's unpaid hours."
                          },
                          {
                            "type": "null"
                          }
                        ]
                      }
                    },
                    "description": "Mode share.",
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "checks": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "Figures that look like a slip, as the page flags them."
              },
              "format": {
                "enum": [
                  "quick_service",
                  "fast_casual",
                  "full_service",
                  "fine_dining",
                  "bar_lounge",
                  "cafe"
                ],
                "type": "string"
              },
              "period": {
                "enum": [
                  "week",
                  "month"
                ],
                "type": "string"
              },
              "result": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The result in the page's words, in its order."
              },
              "target": {
                "type": "number"
              },
              "cutLine": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "line",
                      "basis",
                      "withoutSalaries",
                      "keepOn",
                      "salesForSalaries"
                    ],
                    "properties": {
                      "line": {
                        "anyOf": [
                          {
                            "type": "number",
                            "description": "Sales per labor hour; null when salaries alone pass the target."
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "basis": {
                        "enum": [
                          "next",
                          "last"
                        ],
                        "type": "string",
                        "description": "For forecast, or last period's sales."
                      },
                      "keepOn": {
                        "anyOf": [
                          {
                            "type": "number",
                            "description": "Staff the hourSales pay for."
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "withoutSalaries": {
                        "anyOf": [
                          {
                            "type": "number",
                            "description": "The line without salaries."
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "salesForSalaries": {
                        "anyOf": [
                          {
                            "type": "number",
                            "description": "When no line works: the sales salaries alone need."
                          },
                          {
                            "type": "null"
                          }
                        ]
                      }
                    },
                    "description": "Mode line.",
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "hourCost": {
                "anyOf": [
                  {
                    "type": "number",
                    "description": "An hour of hourly staff, taxes and benefits in."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "freeCheck": {
                "type": "string"
              },
              "workedOut": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "label",
                    "value"
                  ],
                  "properties": {
                    "label": {
                      "type": "string"
                    },
                    "value": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                },
                "description": "How it was worked out."
              },
              "nextPeriod": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "budget",
                      "salaries",
                      "hourlyBudget",
                      "hours",
                      "change",
                      "salesForSalaries"
                    ],
                    "properties": {
                      "hours": {
                        "anyOf": [
                          {
                            "type": "number",
                            "description": "The hourly staff hours that pays for."
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "budget": {
                        "type": "number",
                        "description": "The most labor can cost at the target."
                      },
                      "change": {
                        "anyOf": [
                          {
                            "type": "number",
                            "description": "Against last period's hours."
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "salaries": {
                        "type": "number",
                        "description": "With their share of taxes and benefits."
                      },
                      "hourlyBudget": {
                        "anyOf": [
                          {
                            "type": "number",
                            "description": "What's left for hourly staff."
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "salesForSalaries": {
                        "anyOf": [
                          {
                            "type": "number",
                            "description": "When salaries alone pass the target: the sales they need."
                          },
                          {
                            "type": "null"
                          }
                        ]
                      }
                    },
                    "description": "Mode hours.",
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false
          },
          "annotations": {
            "title": "Labor cost calculator",
            "readOnlyHint": true,
            "openWorldHint": false,
            "idempotentHint": true,
            "destructiveHint": false
          }
        },
        {
          "name": "restaurantdoctor_break_even",
          "title": "Break-even calculator",
          "description": "Works out a restaurant's break-even sales from the owner's figures for one typical month, as the free break-even calculator on restaurantdoctorai.com does: the sales a month needs to pay every bill, also a week, a day open and guests a day; how far the month was above or short of it; what was left over after every bill; what a point of cost moves it by; with and without the owner's own pay; and if prices were 10% lower or higher (an illustration). Hourly pay can rise with sales or stay fixed, or both ways as a range. Takes the month's figures in any currency; a figure not sent is never counted as 0. Returns the result, the working and a link that opens the calculator with the figures in. The figures aren't stored; only an anonymous daily count of calculator runs is kept.",
          "inputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "properties": {
              "goal": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional: what the owner would like left over a month after every bill, before income tax. Adds the sales for it."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "sales": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Net sales for one typical month, in the owner's own currency: the POS sales summary, before tax and tips, app orders at menu price. Not a holiday rush: every figure is for that month. Needed, more than 0; if missing, the reply asks for it."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "hourly": {
                "anyOf": [
                  {
                    "enum": [
                      "yes",
                      "no",
                      "unsure"
                    ],
                    "type": "string",
                    "description": "Whether hourly staff time goes up and down with sales: yes, shifts are added and cut as it gets busy or quiet; no, about the same team every shift (a bill that stays the same); unsure (the default): both ways, as a range."
                  },
                  {
                    "type": "null"
                  }
                ],
                "default": "unsure"
              },
              "ownerPay": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional: the owner's own pay a month, if not on payroll. Counted as a bill; break-even is also given without it."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "hourlyPay": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "That month's hourly wages from payroll, plus the employer's payroll taxes and benefits; no tips. Paid every two weeks: one pay run × 26 ÷ 12. Needed (0 with no hourly staff); if missing, the reply asks for it."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "purchases": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "That month's food and drink supplier invoices, by delivery date. Needed; if missing, the reply asks for it."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "fixedBills": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "A month of the bills that stay the same: rent and utilities, salaries with their payroll taxes and benefits, insurance, software, marketing, loan and lease payments in full. No depreciation. Yearly bills ÷ 12. Not the owner's pay. Needed; if missing, the reply asks for it."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "daysPerWeek": {
                "anyOf": [
                  {
                    "type": "integer",
                    "maximum": 7,
                    "minimum": 1,
                    "description": "Optional: days open a week, a whole number from 1 to 7. Turns the month into a day open (and guests a day, with averageSpend)."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "averageSpend": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional: average spend per guest, the POS average check or net sales ÷ guests. Turns sales into guests."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "closingStock": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional: stock at cost at the end of the month. Used only with openingStock."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "openingStock": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional: stock at cost at the start of the month. Used only with closingStock: food and drink is then opening + purchases - closing. Skip both if stock stayed steady."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "otherVariable": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "That month's other costs that rise with every sale: card fees, app commissions (app sales minus payouts, without tax and tips), packaging, percentage rent, royalties, ad fund fees; nothing in the food and drink invoices. Needed (0 if none); if missing, the reply asks for it."
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false
          },
          "outputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "hourly",
              "standing",
              "figures",
              "usedStockCounts",
              "daysAMonth",
              "scenarios",
              "leftOver",
              "pointValue",
              "result",
              "checks",
              "whatIf",
              "notes",
              "workedOut",
              "link",
              "freeCheck"
            ],
            "properties": {
              "link": {
                "type": "string",
                "description": "Opens the calculator with these figures."
              },
              "notes": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "checks": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "Figures that look like a slip."
              },
              "hourly": {
                "enum": [
                  "yes",
                  "no",
                  "unsure"
                ],
                "type": "string"
              },
              "result": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The page's result, line by line."
              },
              "whatIf": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "figures": {
                "type": "object",
                "required": [
                  "sales",
                  "foodAndDrink",
                  "hourlyPay",
                  "otherVariable",
                  "fixedBills",
                  "ownerPay"
                ],
                "properties": {
                  "sales": {
                    "type": "number"
                  },
                  "ownerPay": {
                    "anyOf": [
                      {
                        "type": "number",
                        "description": "Null: not sent."
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "hourlyPay": {
                    "type": "number"
                  },
                  "fixedBills": {
                    "type": "number"
                  },
                  "foodAndDrink": {
                    "type": "number",
                    "description": "Opening + purchases - closing with both stock counts, else purchases."
                  },
                  "otherVariable": {
                    "type": "number"
                  }
                },
                "description": "A month, in the currency of the figures sent.",
                "additionalProperties": false
              },
              "leftOver": {
                "type": "number",
                "description": "Left over after every bill and ownerPay at these sales, before income tax: below 0 when short. Not profit."
              },
              "standing": {
                "enum": [
                  "above",
                  "at",
                  "short",
                  "never"
                ],
                "type": "string",
                "description": "Net sales against break-even (at: almost exactly; never: no break-even either way)."
              },
              "freeCheck": {
                "type": "string"
              },
              "scenarios": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "hourlyPay",
                    "costsThatRisePct",
                    "breakEven",
                    "prices"
                  ],
                  "properties": {
                    "prices": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "required": [
                          "changePct",
                          "monthly",
                          "guestsADay"
                        ],
                        "properties": {
                          "monthly": {
                            "anyOf": [
                              {
                                "type": "number",
                                "description": "Null: never."
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "changePct": {
                            "type": "number"
                          },
                          "guestsADay": {
                            "anyOf": [
                              {
                                "type": "number",
                                "description": "Needs daysPerWeek, averageSpend."
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "additionalProperties": false
                      },
                      "description": "Prices -10%, as now, +10%: same guests, plates, hourly pay, bills. An illustration."
                    },
                    "breakEven": {
                      "anyOf": [
                        {
                          "type": "object",
                          "required": [
                            "monthly",
                            "weekly",
                            "dayOpen",
                            "guestsADay",
                            "guestsAMonth",
                            "withoutPay",
                            "guestsADayWithoutPay",
                            "cushion",
                            "cushionPct",
                            "shortADayOpen",
                            "moreGuestsADay",
                            "goalSales",
                            "pointOffRising",
                            "pointOffFixed",
                            "perThousandOffBills"
                          ],
                          "properties": {
                            "weekly": {
                              "type": "number"
                            },
                            "cushion": {
                              "type": "number",
                              "description": "Net sales minus break-even."
                            },
                            "dayOpen": {
                              "anyOf": [
                                {
                                  "type": "number",
                                  "description": "Needs daysPerWeek."
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "monthly": {
                              "type": "number"
                            },
                            "goalSales": {
                              "anyOf": [
                                {
                                  "type": "number",
                                  "description": "Sales a month for the goal. Needs goal."
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "cushionPct": {
                              "type": "number",
                              "description": "The cushion, % of net sales."
                            },
                            "guestsADay": {
                              "anyOf": [
                                {
                                  "type": "number",
                                  "description": "Needs daysPerWeek and averageSpend."
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "withoutPay": {
                              "anyOf": [
                                {
                                  "type": "number",
                                  "description": "Without ownerPay. Needs it."
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "guestsAMonth": {
                              "anyOf": [
                                {
                                  "type": "number",
                                  "description": "Needs averageSpend."
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "pointOffFixed": {
                              "type": "number",
                              "description": "The same, a point off a fixed bill."
                            },
                            "shortADayOpen": {
                              "anyOf": [
                                {
                                  "type": "number",
                                  "description": "When short, with daysPerWeek: the gap a day open."
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "moreGuestsADay": {
                              "anyOf": [
                                {
                                  "type": "number",
                                  "description": "When short, with daysPerWeek and averageSpend: guests a day to close it."
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "pointOffRising": {
                              "type": "number",
                              "description": "Fall in break-even for a point of sales off a rising cost."
                            },
                            "perThousandOffBills": {
                              "type": "number",
                              "description": "The same, 1,000 a month off the bills."
                            },
                            "guestsADayWithoutPay": {
                              "anyOf": [
                                {
                                  "type": "number",
                                  "description": "Needs ownerPay, daysPerWeek, averageSpend."
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            }
                          },
                          "description": "Sales and guests rounded up, the rest to the nearest unit. Null: never breaks even this way.",
                          "additionalProperties": false
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "hourlyPay": {
                      "enum": [
                        "rises",
                        "fixed"
                      ],
                      "type": "string",
                      "description": "Rising with sales, or a fixed bill."
                    },
                    "costsThatRisePct": {
                      "type": "number",
                      "description": "% of net sales. At 100 or more, it never breaks even."
                    }
                  },
                  "additionalProperties": false
                },
                "description": "Hourly pay one way, or both (rising first)."
              },
              "workedOut": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "label",
                    "value"
                  ],
                  "properties": {
                    "label": {
                      "type": "string"
                    },
                    "value": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                },
                "description": "How it was worked out."
              },
              "daysAMonth": {
                "anyOf": [
                  {
                    "type": "number",
                    "description": "Days open a week × 52 ÷ 12, one decimal."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "pointValue": {
                "type": "number",
                "description": "1% of sales: what a point of cost saved leaves a month."
              },
              "usedStockCounts": {
                "type": "boolean"
              }
            },
            "additionalProperties": false
          },
          "annotations": {
            "title": "Break-even calculator",
            "readOnlyHint": true,
            "openWorldHint": false,
            "idempotentHint": true,
            "destructiveHint": false
          }
        },
        {
          "name": "restaurantdoctor_restaurant_budget",
          "title": "Restaurant budget calculator",
          "description": "Works out a restaurant's monthly budget from the owner's expected sales and type of restaurant, as the free restaurant budget calculator on restaurantdoctorai.com does: food and drink, labor, prime cost and rent with utilities as money ranges by RestaurantDoctorAI's targets for that type, other operating costs at the owner's share or a 20% working assumption, what's left after every bill, and break-even sales with labor counted both ways. Takes expected net sales and the type, plus optional rent, the owner's own pay and the other costs share, in any currency; a figure that isn't sent is never counted as 0. Returns the calculator's result, how it was worked out, and a link that opens the calculator with the same figures filled in. The figures aren't stored; only an anonymous daily count of calculator runs is kept.",
          "inputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "format"
            ],
            "properties": {
              "rent": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional: the owner's own rent, property charges and utilities for a month, together, as the occupancy targets count them. Replaces the occupancy range."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "sales": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Expected net sales for one month, in the owner's own currency like every figure here: before tax and tips. Needed for a result, and more than 0; if missing, the reply asks for it."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "format": {
                "enum": [
                  "quick_service",
                  "fast_casual",
                  "full_service",
                  "fine_dining",
                  "bar_lounge",
                  "cafe"
                ],
                "type": "string",
                "description": "The type of restaurant, which sets RestaurantDoctorAI's targets the budget is split by: quick_service = Quick service (Counter or kiosk, fast turnover); fast_casual = Fast casual (Order at the counter, served at the table); full_service = Full service / casual dining (Servers, moderate check); fine_dining = Fine dining (Chef-driven, higher check); bar_lounge = Bar, taproom or lounge (Drinks are about half of sales or more); cafe = Café or coffee shop (Drinks lead, with pastries and light food)."
              },
              "otherPct": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 60,
                    "minimum": 0,
                    "description": "Optional: other operating costs as a % of sales (card fees, packaging, cleaning, repairs, marketing, insurance, software, accounting, loan payments). Left out, 20% is used: a working assumption, not a target or a published figure."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "ownerPay": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional: the owner's own pay for a month, when it isn't on payroll. Comes off what's left, and counts as a bill that stays the same."
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false
          },
          "outputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "format",
              "sales",
              "lines",
              "rent",
              "otherCostsAssumed",
              "left",
              "breakEven",
              "result",
              "checks",
              "notes",
              "workedOut",
              "link",
              "freeCheck"
            ],
            "properties": {
              "left": {
                "type": "object",
                "required": [
                  "low",
                  "high",
                  "lowPct",
                  "highPct"
                ],
                "properties": {
                  "low": {
                    "type": "number"
                  },
                  "high": {
                    "type": "number"
                  },
                  "lowPct": {
                    "type": "number"
                  },
                  "highPct": {
                    "type": "number"
                  }
                },
                "description": "Left over after every bill, before income tax, not profit; low is the budget at the top of the targets.",
                "additionalProperties": false
              },
              "link": {
                "type": "string",
                "description": "Opens the calculator with these figures."
              },
              "rent": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "pct",
                      "band"
                    ],
                    "properties": {
                      "pct": {
                        "type": "number"
                      },
                      "band": {
                        "enum": [
                          "within",
                          "over"
                        ],
                        "type": "string"
                      }
                    },
                    "description": "The owner's rent against the occupancy ceiling, the top of the range: within it or over it.",
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "lines": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "key",
                    "label",
                    "lowPct",
                    "highPct",
                    "low",
                    "high",
                    "basis"
                  ],
                  "properties": {
                    "key": {
                      "enum": [
                        "foodAndDrink",
                        "labor",
                        "primeCost",
                        "occupancy",
                        "otherCosts",
                        "ownerPay"
                      ],
                      "type": "string"
                    },
                    "low": {
                      "type": "number"
                    },
                    "high": {
                      "type": "number"
                    },
                    "basis": {
                      "enum": [
                        "target",
                        "yours",
                        "assumption"
                      ],
                      "type": "string",
                      "description": "target: RestaurantDoctorAI's targets; yours: the owner's figure; assumption: the working assumption."
                    },
                    "label": {
                      "type": "string"
                    },
                    "lowPct": {
                      "type": "number"
                    },
                    "highPct": {
                      "type": "number"
                    }
                  },
                  "additionalProperties": false
                },
                "description": "A month, low to high, money to the unit. primeCost is food and drink plus labor, a subtotal."
              },
              "notes": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "sales": {
                "type": "number"
              },
              "checks": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "Figures that look like a slip."
              },
              "format": {
                "enum": [
                  "quick_service",
                  "fast_casual",
                  "full_service",
                  "fine_dining",
                  "bar_lounge",
                  "cafe"
                ],
                "type": "string"
              },
              "result": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The result in the page's words, in its order."
              },
              "breakEven": {
                "type": "object",
                "required": [
                  "laborRises",
                  "laborFixed",
                  "standing"
                ],
                "properties": {
                  "standing": {
                    "enum": [
                      "above",
                      "at",
                      "short"
                    ],
                    "type": "string",
                    "description": "The expected sales against it."
                  },
                  "laborFixed": {
                    "anyOf": [
                      {
                        "type": "number",
                        "description": "The same, with labor as a bill that stays the same."
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "laborRises": {
                    "anyOf": [
                      {
                        "type": "number",
                        "description": "Sales a month to break even with labor rising with sales."
                      },
                      {
                        "type": "null"
                      }
                    ]
                  }
                },
                "description": "With the budget at the top of the targets, rounded up to the unit.",
                "additionalProperties": false
              },
              "freeCheck": {
                "type": "string"
              },
              "workedOut": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "label",
                    "value"
                  ],
                  "properties": {
                    "label": {
                      "type": "string"
                    },
                    "value": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                },
                "description": "How it was worked out."
              },
              "otherCostsAssumed": {
                "type": "boolean",
                "description": "True when the other operating costs share is the working assumption."
              }
            },
            "additionalProperties": false
          },
          "annotations": {
            "title": "Restaurant budget calculator",
            "readOnlyHint": true,
            "openWorldHint": false,
            "idempotentHint": true,
            "destructiveHint": false
          }
        },
        {
          "name": "restaurantdoctor_plate_cost",
          "title": "Plate cost and menu price calculator",
          "description": "Works out what one plate of a dish costs and what to charge for it, as the free plate cost calculator on restaurantdoctorai.com does: from each ingredient's pack price and the amount used (with a usable % for trim), or from a plate cost the owner already knows; then the food cost at the menu price, what's left per plate, the price for their target food cost and the prices inside the range for their type of restaurant, with the tax taken out of a tax-inclusive menu. It works from the owner's own prices and amounts, in any currency; a figure that isn't sent is never counted as 0. Returns the calculator's result, how it was worked out, and a link that opens the calculator with the same figures filled in. The figures aren't stored; only an anonymous daily count of calculator runs is kept.",
          "inputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "mode",
              "format"
            ],
            "properties": {
              "mode": {
                "enum": [
                  "ingredients",
                  "known"
                ],
                "type": "string",
                "description": "ingredients: from each ingredient's pack price and the amount used. known: from a plate cost the owner already has."
              },
              "sold": {
                "anyOf": [
                  {
                    "type": "integer",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional: how many of this dish sold last month (POS item sales), for the figures a month."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "extras": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 100,
                    "minimum": 0,
                    "description": "Optional, mode ingredients: small extras without a line of their own (salt, oil, garnish), % of the ingredients; often 5 to 10."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "format": {
                "enum": [
                  "quick_service",
                  "fast_casual",
                  "full_service",
                  "fine_dining",
                  "bar_lounge",
                  "cafe"
                ],
                "type": "string",
                "description": "The type of restaurant, which sets the food cost range and the starting target: quick_service = Quick service (Counter or kiosk, fast turnover); fast_casual = Fast casual (Order at the counter, served at the table); full_service = Full service / casual dining (Servers, moderate check); fine_dining = Fine dining (Chef-driven, higher check); bar_lounge = Bar, taproom or lounge (Drinks are about half of sales or more); cafe = Café or coffee shop (Drinks lead, with pastries and light food)."
              },
              "target": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 99,
                    "minimum": 1,
                    "description": "Optional: the owner's target food cost, %. Left out, the middle of the format's range (32 for full service); none for a bar."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "taxRate": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 50,
                    "minimum": 0,
                    "description": "With taxIncluded, needed: the tax rate in this dish's price, %. Food and drinks can have different rates."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "portions": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "description": "With mode ingredients, needed: how many plates the amounts make, 1 for a single plate.",
                    "exclusiveMinimum": 0
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "menuPrice": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "description": "Optional: the dish's price on the menu. Left out, the result gives the prices to charge, as for a new dish.",
                    "exclusiveMinimum": 0
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "plateCost": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "With mode known, needed: what the ingredients on one plate cost, from a recipe card or costing sheet, in the owner's own currency like every money figure here."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "ingredients": {
                "anyOf": [
                  {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "required": [
                        "packUnit",
                        "usedUnit"
                      ],
                      "properties": {
                        "name": {
                          "anyOf": [
                            {
                              "type": "string",
                              "maxLength": 100,
                              "description": "Optional: what it is, as the owner calls it."
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "paid": {
                          "anyOf": [
                            {
                              "type": "number",
                              "maximum": 1000000000,
                              "minimum": 0,
                              "description": "What the owner paid for one pack, from their latest invoice, before any VAT or GST they claim back."
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "used": {
                          "anyOf": [
                            {
                              "type": "number",
                              "maximum": 1000000000,
                              "minimum": 0,
                              "description": "The amount that goes in the pot or on the plate, after trimming, for the plates in portions. Spoons or cups: weighed once."
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "usable": {
                          "anyOf": [
                            {
                              "type": "number",
                              "maximum": 100,
                              "minimum": 1,
                              "description": "Optional: of what's bought, the % left after trimming or cooking: 85 for 1 kg that trims to 850 g. Left out, 100."
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "packSize": {
                          "anyOf": [
                            {
                              "type": "number",
                              "maximum": 1000000000,
                              "description": "How much one pack holds, in packUnit: 5 for a 5 lb bag. A case of 6 cans is 6 each; a 4 × 5 lb case is 20 lb.",
                              "exclusiveMinimum": 0
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "packUnit": {
                          "enum": [
                            "g",
                            "kg",
                            "oz",
                            "lb",
                            "ml",
                            "l",
                            "floz",
                            "gal",
                            "each"
                          ],
                          "type": "string",
                          "description": "The pack's unit: floz and gal are US fluid ounces and gallons."
                        },
                        "usedUnit": {
                          "enum": [
                            "g",
                            "kg",
                            "oz",
                            "lb",
                            "ml",
                            "l",
                            "floz",
                            "gal",
                            "each"
                          ],
                          "type": "string",
                          "description": "The amount's unit, of the pack's kind: weight, volume and count don't convert into each other."
                        }
                      },
                      "additionalProperties": false
                    },
                    "maxItems": 30,
                    "description": "With mode ingredients: each ingredient. A sauce or side already costed is one: its cost for a pack of 1 each, 1 each used."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "taxIncluded": {
                "anyOf": [
                  {
                    "type": "boolean",
                    "description": "true when menu prices include VAT or GST (UK, EU, Australia, New Zealand); left out when tax is added at the till (US, Canada)."
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false
          },
          "outputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "mode",
              "format",
              "plateCost",
              "batch",
              "taxPct",
              "atMenuPrice",
              "range",
              "standing",
              "target",
              "priceRange",
              "result",
              "guide",
              "checks",
              "notes",
              "workedOut",
              "link",
              "freeCheck"
            ],
            "properties": {
              "link": {
                "type": "string",
                "description": "Opens the calculator with these figures."
              },
              "mode": {
                "enum": [
                  "ingredients",
                  "known"
                ],
                "type": "string"
              },
              "batch": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "ingredients",
                      "withExtras",
                      "plates"
                    ],
                    "properties": {
                      "plates": {
                        "type": "number"
                      },
                      "withExtras": {
                        "type": "number"
                      },
                      "ingredients": {
                        "type": "number"
                      }
                    },
                    "description": "From ingredients: the lines added up, with small extras, and the plates they make.",
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "guide": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The guide the result points to."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "notes": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "range": {
                "type": "object",
                "required": [
                  "low",
                  "high"
                ],
                "properties": {
                  "low": {
                    "type": "number"
                  },
                  "high": {
                    "type": "number"
                  }
                },
                "description": "The format's whole-menu food and drink cost range, % of sales.",
                "additionalProperties": false
              },
              "checks": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "Figures to look at again. They don't hold up the result."
              },
              "format": {
                "enum": [
                  "quick_service",
                  "fast_casual",
                  "full_service",
                  "fine_dining",
                  "bar_lounge",
                  "cafe"
                ],
                "type": "string"
              },
              "result": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The result in the page's words, in its order."
              },
              "target": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "pct",
                      "price"
                    ],
                    "properties": {
                      "pct": {
                        "type": "number"
                      },
                      "price": {
                        "type": "number"
                      }
                    },
                    "description": "The target food cost, %, and the lowest menu price that hits it, with tax for a menu that includes it.",
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "taxPct": {
                "type": "number",
                "description": "The tax rate in menu prices; 0 when they don't include it."
              },
              "standing": {
                "anyOf": [
                  {
                    "enum": [
                      "below",
                      "within",
                      "above"
                    ],
                    "type": "string",
                    "description": "Against the range; null without a menu price, or for a bar (its range blends food and drinks)."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "freeCheck": {
                "type": "string"
              },
              "plateCost": {
                "type": "number",
                "description": "One plate's ingredient cost."
              },
              "workedOut": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "label",
                    "value"
                  ],
                  "properties": {
                    "label": {
                      "type": "string"
                    },
                    "value": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                },
                "description": "How it was worked out."
              },
              "priceRange": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "from",
                      "to"
                    ],
                    "properties": {
                      "to": {
                        "type": "number"
                      },
                      "from": {
                        "type": "number"
                      }
                    },
                    "description": "Menu prices that keep the dish inside the range.",
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "atMenuPrice": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "menuPrice",
                      "beforeTax",
                      "foodCostPct",
                      "leftPerPlate",
                      "pointValue",
                      "markup",
                      "month"
                    ],
                    "properties": {
                      "month": {
                        "anyOf": [
                          {
                            "type": "object",
                            "required": [
                              "sold",
                              "pointValue",
                              "left"
                            ],
                            "properties": {
                              "left": {
                                "type": "number"
                              },
                              "sold": {
                                "type": "number"
                              },
                              "pointValue": {
                                "type": "number"
                              }
                            },
                            "description": "With plates sold last month: a point and what was left, a month.",
                            "additionalProperties": false
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "markup": {
                        "anyOf": [
                          {
                            "type": "number",
                            "description": "Price ÷ plate cost; null for a plate cost of 0."
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "beforeTax": {
                        "type": "number"
                      },
                      "menuPrice": {
                        "type": "number"
                      },
                      "pointValue": {
                        "type": "number",
                        "description": "One point of food cost on one plate."
                      },
                      "foodCostPct": {
                        "type": "number",
                        "description": "Plate cost ÷ the price before tax, %, one decimal."
                      },
                      "leftPerPlate": {
                        "type": "number",
                        "description": "Below 0 is a loss."
                      }
                    },
                    "description": "The dish at its menu price; null without one.",
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false
          },
          "annotations": {
            "title": "Plate cost and menu price calculator",
            "readOnlyHint": true,
            "openWorldHint": false,
            "idempotentHint": true,
            "destructiveHint": false
          }
        },
        {
          "name": "restaurantdoctor_delivery_price",
          "title": "Delivery app price calculator",
          "description": "Works out a dish's break-even price on a delivery app, the app price that leaves the owner the same money as selling it in their dining room, as the free delivery app price calculator on restaurantdoctorai.com does: the in-house price ÷ (1 − the app's real commission rate), the markup on the in-house price that takes (rounded up to a whole percent), and what the app keeps. Takes the dish's in-house price, in any currency, and one app's real commission rate from its payout statements; a figure that isn't sent is never counted as 0. Returns the calculator's result, how it was worked out, and a link that opens the calculator with the same figures filled in. The figures aren't stored; only an anonymous daily count of calculator runs is kept.",
          "inputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "properties": {
              "rate": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 89,
                    "minimum": 0,
                    "description": "One delivery app's real commission rate, as a percent: 30 for 30%, not 0.30. From a month of that app's payout statements: (menu sales before tax and tips − the app's payout without tax and tips) ÷ those menu sales × 100, so marketing fees, promotions the owner funds and refunds are in it; the rate in the app's plan leaves them out. Each app is worked out on its own. Needed for a result: 0, or from 1 to 89; if missing, the reply asks for it."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "price": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "The dish's price on the owner's own menu, as a dining room guest pays it, in the owner's own currency (14 or 18.5). Needed for a result, and more than 0; if missing, the reply asks for it."
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false
          },
          "outputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "price",
              "rate",
              "appPrice",
              "markupPercent",
              "appKeeps",
              "result",
              "notes",
              "workedOut",
              "link",
              "freeCheck"
            ],
            "properties": {
              "link": {
                "type": "string",
                "description": "Opens the calculator on the website with these figures filled in."
              },
              "rate": {
                "type": "number",
                "description": "The real commission rate, %."
              },
              "notes": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "price": {
                "type": "number",
                "description": "The in-house price it was worked out from, in the currency it was sent in."
              },
              "result": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The result in the page's words, in its order."
              },
              "appKeeps": {
                "type": "number",
                "description": "What the app keeps at the break-even app price, to the cent as the page shows it."
              },
              "appPrice": {
                "type": "number",
                "description": "The break-even app price, price ÷ (1 − rate), to the cent as the page shows it: the app price that leaves the owner the in-house price."
              },
              "freeCheck": {
                "type": "string"
              },
              "workedOut": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "label",
                    "value"
                  ],
                  "properties": {
                    "label": {
                      "type": "string"
                    },
                    "value": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                },
                "description": "How it was worked out, with the figures in each step."
              },
              "markupPercent": {
                "type": "number",
                "description": "The markup on the in-house price that takes, %, rounded up to a whole number so it's never short."
              }
            },
            "additionalProperties": false
          },
          "annotations": {
            "title": "Delivery app price calculator",
            "readOnlyHint": true,
            "openWorldHint": false,
            "idempotentHint": true,
            "destructiveHint": false
          }
        },
        {
          "name": "restaurantdoctor_menu_calories",
          "title": "Menu calorie counter",
          "description": "Works out a dish's calories from its recipe, as the free menu calorie counter on restaurantdoctorai.com does: each ingredient's calories from USDA FoodData Central (a list of 118 common foods) or its pack label, added up, shared by the plates it makes or by portion weight, and rounded once the way US, Ontario or UK and EU menus show calories. Ingredients are matched to that list, never guessed: words that fit several foods come back with the foods to pick from, and words that fit none with the nearest foods, or as not on the list. A pack label's kcal per 100 g comes from the owner's own label, never an estimate: without one, that ingredient can't be counted yet. Returns the menu figure, the exact one, how it was worked out with each food's FDC ID, what to check before printing, and a link that opens the counter with the same recipe filled in. It's an estimate, not a lab test. The figures aren't stored; only an anonymous daily count of calculator runs is kept.",
          "inputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "country",
              "portioning"
            ],
            "properties": {
              "dish": {
                "anyOf": [
                  {
                    "type": "string",
                    "maxLength": 100,
                    "minLength": 0,
                    "description": "Optional: the dish's name, for the record."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "plates": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0.001,
                    "description": "With plates: how many plates it makes, 1 for a single plate. Needed then; if missing, the reply asks for it."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "country": {
                "enum": [
                  "us",
                  "ontario",
                  "ukeu"
                ],
                "type": "string",
                "description": "Where the menu is: sets the energy figure and its rounding. us = US; ontario = Canada (Ontario); ukeu = UK, Ireland or EU (kcal, with the EU's energy factors)."
              },
              "portioning": {
                "enum": [
                  "plates",
                  "weight"
                ],
                "type": "string",
                "description": "plates: one plate, or a batch shared into plates (12 pancakes). weight: portions weighed from a cooked batch (a ladle of soup)."
              },
              "ingredients": {
                "anyOf": [
                  {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "required": [
                        "unit"
                      ],
                      "properties": {
                        "food": {
                          "anyOf": [
                            {
                              "type": "string",
                              "maxLength": 100,
                              "minLength": 1,
                              "description": "The food: its name on the counter's list of USDA foods, as an earlier answer gave it, or the owner's words for it, matched to that list. Words that fit several foods, or none, come back as a tool error naming the foods to pick from, or saying it isn't on the list. With kcalPer100g, just its name."
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "unit": {
                          "enum": [
                            "g",
                            "kg",
                            "oz",
                            "lb",
                            "ml",
                            "l",
                            "floz",
                            "cup",
                            "tbsp",
                            "tsp",
                            "each"
                          ],
                          "type": "string",
                          "description": "g, kg, oz or lb for any food. ml, l, floz, cup, tbsp or tsp (US measures) for liquids and fats only; each for foods counted by the piece."
                        },
                        "amount": {
                          "anyOf": [
                            {
                              "type": "number",
                              "maximum": 1000000000,
                              "minimum": 0,
                              "description": "How much goes in, after trimming, in unit. Weighed if possible. Needed for a result; if missing, the reply asks for it."
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "kcalPer100g": {
                          "anyOf": [
                            {
                              "type": "number",
                              "maximum": 900,
                              "minimum": 0,
                              "description": "For a food not on the list: kcal per 100 g from the nutrition panel on the owner's own pack, as the owner reads it (a US label gives a serving: its calories ÷ its grams × 100). It's the label's figure, not an estimate by the assistant: without the owner's label, the ingredient can't be counted yet. Weighed only."
                            },
                            {
                              "type": "null"
                            }
                          ]
                        }
                      },
                      "additionalProperties": false
                    },
                    "maxItems": 30,
                    "description": "What goes into the dish or batch, one entry each. Needed for a result; if missing, the reply asks for it."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "cookedWeight": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "amount",
                      "unit"
                    ],
                    "properties": {
                      "unit": {
                        "enum": [
                          "g",
                          "kg",
                          "oz",
                          "lb"
                        ],
                        "type": "string"
                      },
                      "amount": {
                        "type": "number",
                        "maximum": 1000000000,
                        "minimum": 0.001
                      }
                    },
                    "description": "With weight: the whole batch, weighed after cooking. Needed then; if missing, the reply asks for it.",
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "portionWeight": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "amount",
                      "unit"
                    ],
                    "properties": {
                      "unit": {
                        "enum": [
                          "g",
                          "kg",
                          "oz",
                          "lb"
                        ],
                        "type": "string"
                      },
                      "amount": {
                        "type": "number",
                        "maximum": 1000000000,
                        "minimum": 0.001
                      }
                    },
                    "description": "With weight: one portion. Needed then; if missing, the reply asks for it.",
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false
          },
          "outputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "country",
              "dish",
              "energy",
              "rounded",
              "exact",
              "per",
              "plates",
              "portionGrams",
              "cookedGrams",
              "batch",
              "ingredients",
              "result",
              "checks",
              "notes",
              "beforePrint",
              "workedOut",
              "guide",
              "link",
              "freeCheck"
            ],
            "properties": {
              "per": {
                "enum": [
                  "plate",
                  "portion"
                ],
                "type": "string"
              },
              "dish": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The dish's name, when one was sent."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "link": {
                "type": "string",
                "description": "Opens the counter on the website with this recipe filled in."
              },
              "batch": {
                "type": "number",
                "description": "The whole recipe."
              },
              "exact": {
                "type": "number",
                "description": "Before rounding."
              },
              "guide": {
                "type": "string",
                "description": "Who has to post calories, and what such a menu shows."
              },
              "notes": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "checks": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "Foods matched from the owner's words, every pack label figure sent (not USDA's) with its value, and the page's hints on weighing each food."
              },
              "energy": {
                "enum": [
                  "calories",
                  "kcal"
                ],
                "type": "string",
                "description": "What menus there call the figure."
              },
              "plates": {
                "anyOf": [
                  {
                    "type": "number",
                    "description": "By the plate: the plates it makes."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "result": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The result in the page's words, in its order."
              },
              "country": {
                "enum": [
                  "us",
                  "ontario",
                  "ukeu"
                ],
                "type": "string"
              },
              "rounded": {
                "type": "number",
                "description": "The figure for the menu, a plate or a portion, rounded once by the country's rule."
              },
              "freeCheck": {
                "type": "string"
              },
              "workedOut": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "label",
                    "value"
                  ],
                  "properties": {
                    "label": {
                      "type": "string"
                    },
                    "value": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                },
                "description": "How it was worked out, with each food's FDC ID."
              },
              "beforePrint": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The page's notes on posting calories in this country."
              },
              "cookedGrams": {
                "anyOf": [
                  {
                    "type": "number",
                    "description": "By weight: the cooked batch."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "ingredients": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "food",
                    "source",
                    "amount",
                    "unit",
                    "grams",
                    "kcalPer100g",
                    "kcal"
                  ],
                  "properties": {
                    "food": {
                      "type": "string"
                    },
                    "kcal": {
                      "type": "number"
                    },
                    "unit": {
                      "enum": [
                        "g",
                        "kg",
                        "oz",
                        "lb",
                        "ml",
                        "l",
                        "floz",
                        "cup",
                        "tbsp",
                        "tsp",
                        "each"
                      ],
                      "type": "string"
                    },
                    "grams": {
                      "type": "number"
                    },
                    "amount": {
                      "type": "number"
                    },
                    "source": {
                      "type": "string",
                      "description": "USDA's description and FDC ID, or the pack label."
                    },
                    "kcalPer100g": {
                      "type": "number",
                      "description": "As counted for this country."
                    }
                  },
                  "additionalProperties": false
                }
              },
              "portionGrams": {
                "anyOf": [
                  {
                    "type": "number",
                    "description": "By weight: one portion."
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false
          },
          "annotations": {
            "title": "Menu calorie counter",
            "readOnlyHint": true,
            "openWorldHint": false,
            "idempotentHint": true,
            "destructiveHint": false
          }
        },
        {
          "name": "restaurantdoctor_fica_tip_credit",
          "title": "FICA tip credit check",
          "description": "Estimates a US restaurant's FICA tip credit (IRS Form 8846, the 45B credit) for a year like the one in its payroll figures, as the free FICA tip credit check on restaurantdoctorai.com does: the employer's 7.65% Social Security and Medicare tax on reported tips, less the tips needed to bring tipped staff's cash wage up to the 5.15 dollars an hour the law fixes for restaurants. Returns the reasons the real answer may be zero first (already claimed, no federal income tax owed, service charges aren't tips, only the business can claim it), then the credit as a range, its worth after the deduction it replaces, the years that may still be open, and sources. It answers questions about taxes on tips, Form 8846, the 45B credit or money the business may be missing on tips. It needs the state, a year's tips reported through payroll (never service charges) and, where the cash wage is under 5.15 dollars, tipped staff's hours that year; whether the return already includes Form 8846 comes first, if known. A figure that isn't sent is never counted as 0. It files nothing, isn't tax advice and takes no payment: the result is an estimate to take to the accountant, with a link that opens the same check with the figures filled in. The figures aren't stored; only an anonymous daily count of calculator runs is kept.",
          "inputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "properties": {
              "state": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The US state the restaurant is in: a two-letter code (TX) or its name. It sets tipped staff's cash wage from the US Department of Labor's table. Needed for a result unless cashWage is sent; if missing, the reply asks for it."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "cashWage": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional: the hourly cash wage tipped staff were paid before tips that year, in US dollars (2.13), if it wasn't the state's tipped wage; the lowest if it changed. Used instead of the state's."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "tippedHours": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "The hours tipped staff worked that year, all together, from the payroll hours report. Needed for a result only when the cash wage is under $5.15 an hour (Texas: $2.13); then, if missing, the reply asks for it."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "businessType": {
                "anyOf": [
                  {
                    "enum": [
                      "c_corp",
                      "s_corp",
                      "partnership",
                      "sole_owner",
                      "unsure"
                    ],
                    "type": "string",
                    "description": "Optional: how the business files its taxes, which sets what the credit is worth after tax: c_corp = C corporation; s_corp = S corporation (or an LLC taxed as one); partnership = Partnership (or an LLC taxed as one); sole_owner = Sole owner (or a one-owner LLC); unsure = Not sure (left out: unsure)."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "reportedTips": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "A year's tips reported through payroll for one business, in US dollars: line 5b of the year's four Forms 941 added up, W-2 box 7 totals, or the year's total from the payroll tips report (Toast, Gusto). Service charges, automatic gratuities and delivery fees don't count: they're wages. Needed for a result; if missing, the reply asks for it."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "owesIncomeTax": {
                "anyOf": [
                  {
                    "enum": [
                      "yes",
                      "no",
                      "unsure"
                    ],
                    "type": "string",
                    "description": "Optional: whether the business (for a pass-through, its owners) usually owes federal income tax: yes, no or unsure (left out: unsure)."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "alreadyClaimed": {
                "anyOf": [
                  {
                    "enum": [
                      "yes",
                      "no",
                      "unsure"
                    ],
                    "type": "string",
                    "description": "Optional, asked first: whether the business's return already includes Form 8846 (Form 3800, Part III, line 4f, or the credit on a K-1 from the business): yes, no or unsure (left out: unsure). Yes means there may be nothing left to find."
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false
          },
          "outputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "headlineKind",
              "headline",
              "zeroReasons",
              "state",
              "reportedTips",
              "tippedHours",
              "hoursUsed",
              "alreadyClaimed",
              "businessType",
              "owesIncomeTax",
              "assumedUnsure",
              "cashWage",
              "base",
              "gapPerHour",
              "setAside",
              "tipsPerHour",
              "tipsBelowGap",
              "creditableTips",
              "credit",
              "allTipsCredit",
              "afterTax",
              "usableThisYear",
              "irsWebPage",
              "openYears",
              "checks",
              "result",
              "sources",
              "link",
              "freeCheck"
            ],
            "properties": {
              "base": {
                "type": "number",
                "description": "$5.15: tips needed to bring the cash wage up to this don't count."
              },
              "link": {
                "type": "string",
                "description": "Opens the check on the website with these figures filled in."
              },
              "state": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "code",
                      "name"
                    ],
                    "properties": {
                      "code": {
                        "type": "string"
                      },
                      "name": {
                        "type": "string"
                      }
                    },
                    "description": "The state whose tipped cash wage was used.",
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "checks": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "Figures that look like a slip. They don't block the result."
              },
              "credit": {
                "type": "object",
                "required": [
                  "low",
                  "high",
                  "exact"
                ],
                "properties": {
                  "low": {
                    "type": "number"
                  },
                  "high": {
                    "type": "number"
                  },
                  "exact": {
                    "type": "boolean"
                  }
                },
                "description": "The gross FICA tip credit for a year like this; exact when the cash wage is $5.15 or more.",
                "additionalProperties": false
              },
              "result": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The page's words, in its order."
              },
              "sources": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "afterTax": {
                "type": "object",
                "required": [
                  "low",
                  "high",
                  "rates",
                  "keep"
                ],
                "properties": {
                  "low": {
                    "type": "number"
                  },
                  "high": {
                    "type": "number"
                  },
                  "keep": {
                    "type": "object",
                    "required": [
                      "low",
                      "high"
                    ],
                    "properties": {
                      "low": {
                        "type": "number"
                      },
                      "high": {
                        "type": "number"
                      }
                    },
                    "additionalProperties": false
                  },
                  "rates": {
                    "type": "object",
                    "required": [
                      "low",
                      "high"
                    ],
                    "properties": {
                      "low": {
                        "type": "number"
                      },
                      "high": {
                        "type": "number"
                      }
                    },
                    "additionalProperties": false
                  }
                },
                "description": "After the deduction it replaces, before state tax: federal rates assumed, share of each credit dollar kept.",
                "additionalProperties": false
              },
              "cashWage": {
                "type": "object",
                "required": [
                  "hourly",
                  "from",
                  "source"
                ],
                "properties": {
                  "from": {
                    "enum": [
                      "typed",
                      "state"
                    ],
                    "type": "string"
                  },
                  "hourly": {
                    "type": "number"
                  },
                  "source": {
                    "anyOf": [
                      {
                        "type": "string",
                        "description": "The state's table."
                      },
                      {
                        "type": "null"
                      }
                    ]
                  }
                },
                "additionalProperties": false
              },
              "headline": {
                "type": "string"
              },
              "setAside": {
                "type": "number",
                "description": "Hours × the gap."
              },
              "freeCheck": {
                "type": "string"
              },
              "hoursUsed": {
                "type": "boolean",
                "description": "Only when the cash wage is under $5.15."
              },
              "openYears": {
                "type": "object",
                "required": [
                  "years",
                  "firstCloses",
                  "asOf"
                ],
                "properties": {
                  "asOf": {
                    "type": "string"
                  },
                  "years": {
                    "type": "array",
                    "items": {
                      "type": "number"
                    }
                  },
                  "firstCloses": {
                    "type": "string"
                  }
                },
                "description": "Years a missed credit may still be claimed for.",
                "additionalProperties": false
              },
              "gapPerHour": {
                "type": "number"
              },
              "irsWebPage": {
                "type": "object",
                "required": [
                  "base",
                  "creditableTips",
                  "credit"
                ],
                "properties": {
                  "base": {
                    "type": "number"
                  },
                  "credit": {
                    "anyOf": [
                      {
                        "type": "number",
                        "description": "Null without the hours."
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "creditableTips": {
                    "anyOf": [
                      {
                        "type": "number",
                        "description": "Null without the hours."
                      },
                      {
                        "type": "null"
                      }
                    ]
                  }
                },
                "description": "At the IRS web page's $7.25: the most cautious reading.",
                "additionalProperties": false
              },
              "tippedHours": {
                "anyOf": [
                  {
                    "type": "number",
                    "description": "As sent."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "tipsPerHour": {
                "anyOf": [
                  {
                    "type": "number",
                    "description": "Tips ÷ hours."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "zeroReasons": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "id",
                    "status",
                    "words",
                    "source"
                  ],
                  "properties": {
                    "id": {
                      "enum": [
                        "alreadyClaimed",
                        "noTips",
                        "tipsBelowGap",
                        "noTaxOwed",
                        "serviceCharges",
                        "unreportedTips",
                        "customaryTipping",
                        "businessDecides",
                        "passiveOwners"
                      ],
                      "type": "string"
                    },
                    "words": {
                      "type": "string"
                    },
                    "source": {
                      "type": "string"
                    },
                    "status": {
                      "enum": [
                        "applies",
                        "check"
                      ],
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                },
                "description": "Why the real answer may be $0 (applies: these answers say so; check: one to rule out), said before any dollar figure."
              },
              "businessType": {
                "enum": [
                  "c_corp",
                  "s_corp",
                  "partnership",
                  "sole_owner",
                  "unsure"
                ],
                "type": "string"
              },
              "headlineKind": {
                "enum": [
                  "alreadyClaimed",
                  "noTips",
                  "tipsBelowGap",
                  "estimate"
                ],
                "type": "string"
              },
              "reportedTips": {
                "type": "number",
                "description": "US dollars, like every amount here."
              },
              "tipsBelowGap": {
                "type": "boolean"
              },
              "allTipsCredit": {
                "type": "number",
                "description": "7.65% of every tip: the most it can be."
              },
              "assumedUnsure": {
                "type": "array",
                "items": {
                  "enum": [
                    "alreadyClaimed",
                    "businessType",
                    "owesIncomeTax"
                  ],
                  "type": "string"
                },
                "description": "Left out, read as unsure."
              },
              "owesIncomeTax": {
                "enum": [
                  "yes",
                  "no",
                  "unsure"
                ],
                "type": "string"
              },
              "alreadyClaimed": {
                "enum": [
                  "yes",
                  "no",
                  "unsure"
                ],
                "type": "string"
              },
              "creditableTips": {
                "type": "object",
                "required": [
                  "low",
                  "high"
                ],
                "properties": {
                  "low": {
                    "type": "number"
                  },
                  "high": {
                    "type": "number"
                  }
                },
                "additionalProperties": false
              },
              "usableThisYear": {
                "enum": [
                  "yes",
                  "no",
                  "maybe"
                ],
                "type": "string"
              }
            },
            "additionalProperties": false
          },
          "annotations": {
            "title": "FICA tip credit check",
            "readOnlyHint": true,
            "openWorldHint": false,
            "idempotentHint": true,
            "destructiveHint": false
          }
        },
        {
          "name": "restaurantdoctor_card_fees",
          "title": "Card fees check",
          "description": "Checks a US restaurant's card processing fees for one month, as the free card fees check on restaurantdoctorai.com does: the cost per 100 dollars of card sales (the effective rate), against a dated fair range for that type of restaurant (an estimate of a competitive interchange-plus account from Visa's published restaurant interchange, network fees and a fair markup); how far above it the fees are, a month and a year; how they compare with Square's, Toast's, Clover's or Stripe's published rate; what's realistic for that processor, words to read out to it, the fees to question on the statement by name, and the caveats. It answers whether card fees are too high, what the effective rate is, and what to ask the processor. It needs the month's total card sales and total card fees from the processor's statement (every fee, monthly and annual ones included), who processes the cards and what kind of restaurant it is; the number of card sales or the average sale narrows it. A figure that isn't sent is never counted as 0. It doesn't read statements, contact a processor or take payment. Returns the result, how it was worked out, and a link that opens the same check with the figures filled in. The figures aren't stored; only an anonymous daily count of calculator runs is kept.",
          "inputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "processor",
              "format"
            ],
            "properties": {
              "format": {
                "enum": [
                  "quick_service",
                  "fast_casual",
                  "full_service",
                  "fine_dining",
                  "bar_lounge",
                  "cafe"
                ],
                "type": "string",
                "description": "The type of restaurant, which sets the likely mix of debit and credit cards: quick_service = Quick service (Counter or kiosk, fast turnover); fast_casual = Fast casual (Order at the counter, served at the table); full_service = Full service / casual dining (Servers, moderate check); fine_dining = Fine dining (Chef-driven, higher check); bar_lounge = Bar, taproom or lounge (Drinks are about half of sales or more); cafe = Café or coffee shop (Drinks lead, with pastries and light food)."
              },
              "cardCount": {
                "anyOf": [
                  {
                    "type": "integer",
                    "maximum": 1000000000,
                    "minimum": 1,
                    "description": "Optional: the month's number of card sales (transactions), from the same statement. It narrows the fair range to the owner's own sale size."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "cardSales": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "A month's card sales in US dollars, from the processor's statement or the POS card report: everything charged to cards, tips included, before fees, without delivery app orders. Needed for a result; if missing, the reply asks for it."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "processor": {
                "enum": [
                  "square",
                  "toast",
                  "clover",
                  "stripe",
                  "bank",
                  "other"
                ],
                "type": "string",
                "description": "Who processes the cards (the name at the top of the statement): bank = a bank or independent processor; other = another processor, or not sure."
              },
              "totalFees": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "The same month's total card fees in US dollars, from the same statement: every fee the processor took (percentage, per-sale, monthly, annual, PCI and statement fees), not one line. Needed for a result; if missing, the reply asks for it."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "pricingModel": {
                "anyOf": [
                  {
                    "enum": [
                      "flat",
                      "interchange_plus",
                      "tiered",
                      "not_sure"
                    ],
                    "type": "string",
                    "description": "Optional, if the owner knows it: flat = Flat rate: one rate for every card; interchange_plus = Interchange-plus: interchange at cost plus a stated markup; tiered = Tiered: qualified, mid-qualified and non-qualified rates; not_sure = Not sure. It changes the advice, not the fair range."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "averageTicket": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional: the average card sale in US dollars, when cardCount isn't known. It narrows the fair range too."
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false
          },
          "outputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "cardSales",
              "totalFees",
              "processor",
              "format",
              "pricingModel",
              "cardCount",
              "averageSale",
              "saleFrom",
              "costPer100",
              "fair",
              "verdict",
              "overTopPer100",
              "aboveTop",
              "aboveMiddle",
              "plan",
              "yearlyCardSales",
              "result",
              "realistic",
              "ask",
              "feesToQuestion",
              "checks",
              "caveats",
              "workedOut",
              "sources",
              "link",
              "freeCheck"
            ],
            "properties": {
              "ask": {
                "type": "string",
                "description": "Words the owner can read out to the processor."
              },
              "fair": {
                "type": "object",
                "required": [
                  "low",
                  "middle",
                  "high",
                  "sale",
                  "asOf"
                ],
                "properties": {
                  "low": {
                    "type": "number"
                  },
                  "asOf": {
                    "type": "string",
                    "description": "The date of Visa's interchange table."
                  },
                  "high": {
                    "type": "number"
                  },
                  "sale": {
                    "type": "object",
                    "required": [
                      "low",
                      "high",
                      "assumed"
                    ],
                    "properties": {
                      "low": {
                        "type": "number"
                      },
                      "high": {
                        "type": "number"
                      },
                      "assumed": {
                        "type": "boolean"
                      }
                    },
                    "description": "The average card sale it's for.",
                    "additionalProperties": false
                  },
                  "middle": {
                    "type": "number"
                  }
                },
                "description": "What a competitive interchange-plus account would cost, per $100: an estimate, not a published price.",
                "additionalProperties": false
              },
              "link": {
                "type": "string",
                "description": "Opens the check on the website with these figures filled in."
              },
              "plan": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "processor",
                      "low",
                      "high",
                      "standing",
                      "confirmed"
                    ],
                    "properties": {
                      "low": {
                        "type": "number"
                      },
                      "high": {
                        "type": "number"
                      },
                      "standing": {
                        "enum": [
                          "below",
                          "at",
                          "above"
                        ],
                        "type": "string"
                      },
                      "confirmed": {
                        "type": "boolean"
                      },
                      "processor": {
                        "enum": [
                          "square",
                          "toast",
                          "clover",
                          "stripe"
                        ],
                        "type": "string"
                      }
                    },
                    "description": "The published in-person rate at this sale size, per $100; Toast's come from reviews, not confirmed.",
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "checks": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "Figures that look like a slip. They don't block the result."
              },
              "format": {
                "enum": [
                  "quick_service",
                  "fast_casual",
                  "full_service",
                  "fine_dining",
                  "bar_lounge",
                  "cafe"
                ],
                "type": "string"
              },
              "result": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The page's words, in its order."
              },
              "caveats": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "sources": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "verdict": {
                "enum": [
                  "low",
                  "fair",
                  "a_little_high",
                  "high",
                  "very_high"
                ],
                "type": "string"
              },
              "aboveTop": {
                "type": "object",
                "required": [
                  "perMonth",
                  "perYear"
                ],
                "properties": {
                  "perYear": {
                    "type": "number"
                  },
                  "perMonth": {
                    "type": "number"
                  }
                },
                "description": "Fees above the range's top, whole dollars; 0 unless above it.",
                "additionalProperties": false
              },
              "saleFrom": {
                "anyOf": [
                  {
                    "enum": [
                      "cardCount",
                      "averageTicket"
                    ],
                    "type": "string",
                    "description": "Where the sale size came from."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "cardCount": {
                "anyOf": [
                  {
                    "type": "number",
                    "description": "As sent, or from the average sale."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "cardSales": {
                "type": "number",
                "description": "US dollars, like every amount here."
              },
              "freeCheck": {
                "type": "string"
              },
              "processor": {
                "enum": [
                  "square",
                  "toast",
                  "clover",
                  "stripe",
                  "bank",
                  "other"
                ],
                "type": "string"
              },
              "realistic": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "totalFees": {
                "type": "number"
              },
              "workedOut": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "label",
                    "value"
                  ],
                  "properties": {
                    "label": {
                      "type": "string"
                    },
                    "value": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                }
              },
              "costPer100": {
                "type": "number",
                "description": "Total fees ÷ card sales × 100: the cost per $100 of card sales, also the effective rate in %."
              },
              "aboveMiddle": {
                "type": "object",
                "required": [
                  "perMonth",
                  "perYear"
                ],
                "properties": {
                  "perYear": {
                    "type": "number"
                  },
                  "perMonth": {
                    "type": "number"
                  }
                },
                "description": "The same above its middle.",
                "additionalProperties": false
              },
              "averageSale": {
                "anyOf": [
                  {
                    "type": "number",
                    "description": "Card sales ÷ card count, or as sent."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "pricingModel": {
                "anyOf": [
                  {
                    "enum": [
                      "flat",
                      "interchange_plus",
                      "tiered",
                      "not_sure"
                    ],
                    "type": "string",
                    "description": "As sent."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "overTopPer100": {
                "type": "number",
                "description": "Dollars per $100 above the range's top; 0 unless above it."
              },
              "feesToQuestion": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "id",
                    "name",
                    "what"
                  ],
                  "properties": {
                    "id": {
                      "type": "string"
                    },
                    "name": {
                      "type": "string"
                    },
                    "what": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                },
                "description": "By the names statements print."
              },
              "yearlyCardSales": {
                "type": "number"
              }
            },
            "additionalProperties": false
          },
          "annotations": {
            "title": "Card fees check",
            "readOnlyHint": true,
            "openWorldHint": false,
            "idempotentHint": true,
            "destructiveHint": false
          }
        },
        {
          "name": "restaurantdoctor_booking_fees",
          "title": "Booking fee check",
          "description": "Works out what a US restaurant's reservation app costs it, as the free booking fee check on restaurantdoctorai.com does: a month, a year, per guest who booked through it and as a share of the average spend, from the plan's published price (dated, sourced) or the owner's invoice, plus fees per guest and the percentage on deposits. Of the apps checked, only OpenTable charges per guest: for guests from its own app and website, possibly from Google and partners, and on Basic from the restaurant's own website. Returns a one-sentence headline first, the month line by line, what isn't counted, what the owner can do (book direct, mark no-shows, the contract's notice date), other apps' published prices as information, not a recommendation, the caveats and sources. It answers what OpenTable, Resy, Tock, Yelp, Toast Tables, SpotOn or SevenRooms costs a restaurant per reservation or per guest. It needs the app and plan (on the invoice) and, for OpenTable, last month's guests from its covers report by where they booked; the rest is optional. A figure that isn't sent is never counted as 0. Not affiliated with any app; it reads no account. The figures aren't stored; only an anonymous daily count of calculator runs is kept.",
          "inputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "platform"
            ],
            "properties": {
              "platform": {
                "enum": [
                  "opentable_basic",
                  "opentable_core",
                  "opentable_pro",
                  "resy_platform",
                  "resy_platform_360",
                  "tock_essential",
                  "tock_premium",
                  "yelp_basic",
                  "yelp_plus",
                  "toast_tables_plus",
                  "spoton_reserve",
                  "sevenrooms",
                  "other"
                ],
                "type": "string",
                "description": "The app and plan, on the invoice. tock_ = Tock, now sold by Resy; other = any app not listed, with monthlyFee."
              },
              "firstMonth": {
                "anyOf": [
                  {
                    "type": "boolean",
                    "description": "OpenTable Basic only: true if last month was the first 30 days (network guests free)."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "monthlyFee": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "The invoice's monthly fee: plan plus add-ons, before fees per guest. Left out: the published price. Needed for sevenrooms and other."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "renewalDate": {
                "anyOf": [
                  {
                    "type": "string",
                    "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
                    "description": "Not on opentable_basic or spoton_reserve: the contract's renewal date, YYYY-MM-DD, from the contract; month-to-month plans have none."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "averageSpend": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "The average spend per guest: net sales ÷ guests, from the POS."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "networkCovers": {
                "anyOf": [
                  {
                    "type": "integer",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Guests seated last month who booked through the app itself (its own app or site). OpenTable: the Network line of its covers report; needed for OpenTable. Other apps: every guest booked through it, wherever they booked."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "partnerCovers": {
                "anyOf": [
                  {
                    "type": "integer",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "OpenTable only: guests who booked through Google and other partners, the report's Partner or Affiliate line. Left out: not counted."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "prepaidAmount": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Money the app collected last month, from its statement: deposits, prepayments, no-show charges. tock_: prepayments only."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "websiteCovers": {
                "anyOf": [
                  {
                    "type": "integer",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "OpenTable only: guests who booked through the restaurant's own website (a fee each on Basic)."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "networkCoverFee": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "OpenTable or other only: the fee per guest on the invoice, only if it isn't the published one."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "partnerCoverFee": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "OpenTable only: the fee per partner guest, from its Billing History tab. Left out: a range."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "websiteFlatAddOn": {
                "anyOf": [
                  {
                    "type": "boolean",
                    "description": "OpenTable Basic only: true if the invoice shows the monthly flat fee for website bookings."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "prepaidFeePercent": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 100,
                    "minimum": 0,
                    "description": "The app's percentage of that money, as a percent (2 for 2%, not 0.02), only if it isn't the published one."
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false
          },
          "outputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "name",
              "headline",
              "partial",
              "month",
              "year",
              "feeFrom",
              "breakdown",
              "firstMonth",
              "perGuest",
              "perNetworkGuest",
              "ofSpend",
              "ifBookedDirect",
              "noticeBy",
              "alternatives",
              "result",
              "notCounted",
              "whatYouCanDo",
              "notes",
              "caveats",
              "workedOut",
              "sources",
              "asOf",
              "link",
              "freeCheck"
            ],
            "properties": {
              "asOf": {
                "type": "string",
                "description": "The day prices were read."
              },
              "link": {
                "type": "string",
                "description": "Opens the check with these figures."
              },
              "name": {
                "type": "string",
                "description": "The plan."
              },
              "year": {
                "type": "object",
                "required": [
                  "low",
                  "high"
                ],
                "properties": {
                  "low": {
                    "type": "number"
                  },
                  "high": {
                    "type": "number"
                  }
                },
                "additionalProperties": false
              },
              "month": {
                "type": "object",
                "required": [
                  "low",
                  "high"
                ],
                "properties": {
                  "low": {
                    "type": "number"
                  },
                  "high": {
                    "type": "number"
                  }
                },
                "description": "US dollars, like every amount.",
                "additionalProperties": false
              },
              "notes": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "result": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "caveats": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "feeFrom": {
                "enum": [
                  "invoice",
                  "published"
                ],
                "type": "string"
              },
              "ofSpend": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "coverFee",
                      "perGuest"
                    ],
                    "properties": {
                      "coverFee": {
                        "anyOf": [
                          {
                            "type": "number",
                            "description": "The fee per guest."
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "perGuest": {
                        "anyOf": [
                          {
                            "type": "object",
                            "required": [
                              "low",
                              "high"
                            ],
                            "properties": {
                              "low": {
                                "type": "number"
                              },
                              "high": {
                                "type": "number"
                              }
                            },
                            "description": "The cost per guest.",
                            "additionalProperties": false
                          },
                          {
                            "type": "null"
                          }
                        ]
                      }
                    },
                    "description": "% of the average spend.",
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "partial": {
                "type": "boolean",
                "description": "True when the headline says at least."
              },
              "sources": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "headline": {
                "type": "string",
                "description": "The result in one sentence."
              },
              "noticeBy": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The contract's notice date."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "perGuest": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "low",
                      "high"
                    ],
                    "properties": {
                      "low": {
                        "type": "number"
                      },
                      "high": {
                        "type": "number"
                      }
                    },
                    "description": "Per guest booked through it.",
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "breakdown": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "id",
                    "label",
                    "low",
                    "high",
                    "how"
                  ],
                  "properties": {
                    "id": {
                      "type": "string"
                    },
                    "how": {
                      "type": "string"
                    },
                    "low": {
                      "type": "number"
                    },
                    "high": {
                      "type": "number"
                    },
                    "label": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                },
                "description": "The month."
              },
              "freeCheck": {
                "type": "string"
              },
              "workedOut": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "label",
                    "value"
                  ],
                  "properties": {
                    "label": {
                      "type": "string"
                    },
                    "value": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                }
              },
              "firstMonth": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "low",
                      "high"
                    ],
                    "properties": {
                      "low": {
                        "type": "number"
                      },
                      "high": {
                        "type": "number"
                      }
                    },
                    "description": "OpenTable Basic: last month, network guests free.",
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "notCounted": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "alternatives": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "name",
                    "low",
                    "high",
                    "extra"
                  ],
                  "properties": {
                    "low": {
                      "type": "number"
                    },
                    "high": {
                      "type": "number"
                    },
                    "name": {
                      "type": "string"
                    },
                    "extra": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                },
                "description": "Other apps' monthly prices: information, not a recommendation."
              },
              "whatYouCanDo": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "title",
                    "what"
                  ],
                  "properties": {
                    "what": {
                      "type": "string"
                    },
                    "title": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                }
              },
              "ifBookedDirect": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "low",
                      "high"
                    ],
                    "properties": {
                      "low": {
                        "type": "number"
                      },
                      "high": {
                        "type": "number"
                      }
                    },
                    "description": "A month kept if 1 in 4 network guests booked direct, if they'd have come anyway.",
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "perNetworkGuest": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "low",
                      "high"
                    ],
                    "properties": {
                      "low": {
                        "type": "number"
                      },
                      "high": {
                        "type": "number"
                      }
                    },
                    "description": "OpenTable: per guest its network sent, all in.",
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false
          },
          "annotations": {
            "title": "Booking fee check",
            "readOnlyHint": true,
            "openWorldHint": false,
            "idempotentHint": true,
            "destructiveHint": false
          }
        },
        {
          "name": "restaurantdoctor_cash_out",
          "title": "Nightly cash-out",
          "description": "Works out a restaurant's nightly cash close for one drawer and one day or shift, as the free cash-out sheet on restaurantdoctorai.com does: expected cash (starting bank + cash sales - cash tips paid out - paid outs), over or short against the cash counted, the deposit (counted minus the starting bank), the card difference (processor batch minus POS card sales) when both are sent, and comps, voids and discounts as a share of net sales. Takes the starting bank, cash sales and cash counted, plus optional paid outs, card figures and sales totals, in any currency; a figure that isn't sent is never counted as 0. It sets no normal for over or short. Returns the result, how it was worked out, and a link to the free cash-out sheet. The figures aren't stored; only an anonymous daily count of calculator runs is kept.",
          "inputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "properties": {
              "comps": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional: the day's comps total from the POS. Needs netSales for its share."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "voids": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional: the day's voids total from the POS. Needs netSales for its share."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "netSales": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional: that day's net sales from the POS, before tax and tips. Turns comps, voids and discounts into shares."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "paidOuts": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional: cash taken out of the drawer for supplies and the like. Taken off expected cash."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "cardBatch": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional: what the card processor settled for the same day. With cardSales."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "cardSales": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional: that day's card sales from the POS. With cardBatch, gives the card difference."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "cashSales": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "That day's cash payments, from the POS end-of-day (Z) report. Needed; if missing, the reply asks for it."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "discounts": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional: the day's discounts total from the POS. Needs netSales for its share."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "cashCounted": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "The cash counted at close, bank included. Needed; if missing, the reply asks for it."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "startingBank": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "The cash in the drawer at open: one drawer, one day or shift, in the owner's own currency like every figure here. Needed; if missing, the reply asks for it."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "cashTipsPaidOut": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional: card tips paid to staff in cash from this drawer. Taken off expected cash."
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false
          },
          "outputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "expectedCash",
              "cashCounted",
              "overShort",
              "deposit",
              "card",
              "shares",
              "result",
              "checks",
              "notes",
              "workedOut",
              "link",
              "freeCheck"
            ],
            "properties": {
              "card": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "difference",
                      "status"
                    ],
                    "properties": {
                      "status": {
                        "enum": [
                          "batch_higher",
                          "batch_lower",
                          "match"
                        ],
                        "type": "string"
                      },
                      "difference": {
                        "type": "number",
                        "description": "Processor batch minus POS card sales."
                      }
                    },
                    "description": "Sent both card figures.",
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "link": {
                "type": "string",
                "description": "The free cash-out sheet, to print or download."
              },
              "notes": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "checks": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "Figures that look like a slip."
              },
              "result": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The result in the sheet's words."
              },
              "shares": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "compsPct",
                      "voidsPct",
                      "discountsPct"
                    ],
                    "properties": {
                      "compsPct": {
                        "anyOf": [
                          {
                            "type": "number",
                            "description": "Comps, % of net sales."
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "voidsPct": {
                        "anyOf": [
                          {
                            "type": "number",
                            "description": "Voids, % of net sales."
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "discountsPct": {
                        "anyOf": [
                          {
                            "type": "number",
                            "description": "Discounts, % of net sales."
                          },
                          {
                            "type": "null"
                          }
                        ]
                      }
                    },
                    "description": "To one decimal. Sent netSales and the total.",
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "deposit": {
                "type": "number",
                "description": "Cash counted minus the starting bank, which stays in the drawer. Below 0 when the drawer holds less than its bank."
              },
              "freeCheck": {
                "type": "string"
              },
              "overShort": {
                "type": "object",
                "required": [
                  "amount",
                  "status"
                ],
                "properties": {
                  "amount": {
                    "type": "number",
                    "description": "Cash counted minus expected cash: above 0 is over, below 0 is short."
                  },
                  "status": {
                    "enum": [
                      "over",
                      "short",
                      "even"
                    ],
                    "type": "string"
                  }
                },
                "additionalProperties": false
              },
              "workedOut": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "label",
                    "value"
                  ],
                  "properties": {
                    "label": {
                      "type": "string"
                    },
                    "value": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                },
                "description": "How it was worked out."
              },
              "cashCounted": {
                "type": "number"
              },
              "expectedCash": {
                "type": "number",
                "description": "Starting bank + cash sales - cash tips paid out - paid outs."
              }
            },
            "additionalProperties": false
          },
          "annotations": {
            "title": "Nightly cash-out",
            "readOnlyHint": true,
            "openWorldHint": false,
            "idempotentHint": true,
            "destructiveHint": false
          }
        },
        {
          "name": "restaurantdoctor_tip_out",
          "title": "Tip-out sheet",
          "description": "Works out how a restaurant shares tips, two ways, as the free tip-out sheet on restaurantdoctorai.com does. method percent: a server's tip-out to support roles, each a percentage of the server's net sales or tips, with the total tip-out, what the server keeps from their tips, and an error-level check when the tip-out is more than the tips. method pool: a tip pool shared by hours, with optional points for each role, rounded to the cent with the rounding remainder placed on the largest share. Takes the figures in any currency; a figure that isn't sent is never counted as 0. Returns the split, how it was worked out, the Department of Labor's published points on tips with their sources, and a link to the free tip-out sheet. It only works out a split from the numbers sent; it doesn't say whether a tip-out or a tip pool is allowed. The figures aren't stored; only an anonymous daily count of calculator runs is kept.",
          "inputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "method"
            ],
            "properties": {
              "base": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "With percent, needed: the server's net sales for the shift (before tax and tips), or their tips, as baseKind says. In the owner's own currency."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "pool": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "With pool, needed: the tips in the pool for the period."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "tips": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "With percent: the server's tips for the shift, to work out what they keep. Not used when baseKind is tips."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "roles": {
                "anyOf": [
                  {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "name": {
                          "anyOf": [
                            {
                              "type": "string",
                              "maxLength": 60,
                              "description": "Optional: the role, such as Bartender or Busser."
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "percent": {
                          "anyOf": [
                            {
                              "type": "number",
                              "maximum": 100,
                              "minimum": 0,
                              "description": "The role's % of the base, 0 to 100. Needed for each role."
                            },
                            {
                              "type": "null"
                            }
                          ]
                        }
                      },
                      "additionalProperties": false
                    },
                    "maxItems": 50,
                    "description": "With percent, needed: the support roles tipped out."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "method": {
                "enum": [
                  "percent",
                  "pool"
                ],
                "type": "string",
                "description": "percent: one server's tip-out to support roles, each a % of the base. pool: a tip pool shared by hours, with optional points."
              },
              "members": {
                "anyOf": [
                  {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "name": {
                          "anyOf": [
                            {
                              "type": "string",
                              "maxLength": 60,
                              "description": "Optional: the person or role."
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "hours": {
                          "anyOf": [
                            {
                              "type": "number",
                              "maximum": 1000000000,
                              "minimum": 0,
                              "description": "Hours worked in the pool's period. Needed for each person."
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "points": {
                          "anyOf": [
                            {
                              "type": "number",
                              "maximum": 1000000000,
                              "description": "Optional: the role's weight, such as 1.5, to one decimal. Left out, 1.",
                              "exclusiveMinimum": 0
                            },
                            {
                              "type": "null"
                            }
                          ]
                        }
                      },
                      "additionalProperties": false
                    },
                    "maxItems": 50,
                    "description": "With pool, needed: the people or roles sharing the pool."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "baseKind": {
                "anyOf": [
                  {
                    "enum": [
                      "netSales",
                      "tips"
                    ],
                    "type": "string",
                    "description": "With percent, needed: netSales or tips, what the roles' percentages are taken of."
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false
          },
          "outputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "method",
              "percent",
              "pool",
              "result",
              "checks",
              "notes",
              "workedOut",
              "law",
              "link",
              "freeCheck"
            ],
            "properties": {
              "law": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "text",
                    "source",
                    "url"
                  ],
                  "properties": {
                    "url": {
                      "type": "string"
                    },
                    "text": {
                      "type": "string"
                    },
                    "source": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                },
                "description": "The Department of Labor's published points on tips and its state minimum wage page, each with its source."
              },
              "link": {
                "type": "string",
                "description": "The free tip-out sheet, to print or download."
              },
              "pool": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "pool",
                      "totalHours",
                      "remainderCents",
                      "shares"
                    ],
                    "properties": {
                      "pool": {
                        "type": "number"
                      },
                      "shares": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "required": [
                            "name",
                            "hours",
                            "points",
                            "sharePct",
                            "amount",
                            "perHour"
                          ],
                          "properties": {
                            "name": {
                              "type": "string"
                            },
                            "hours": {
                              "type": "number"
                            },
                            "amount": {
                              "type": "number",
                              "description": "Pool × hours × points ÷ everyone's, to the cent."
                            },
                            "points": {
                              "type": "number",
                              "description": "1 where none were sent."
                            },
                            "perHour": {
                              "anyOf": [
                                {
                                  "type": "number",
                                  "description": "Null with 0 hours."
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "sharePct": {
                              "type": "number",
                              "description": "Hours × points as a % of everyone's."
                            }
                          },
                          "additionalProperties": false
                        }
                      },
                      "totalHours": {
                        "type": "number"
                      },
                      "remainderCents": {
                        "anyOf": [
                          {
                            "type": "number",
                            "description": "What rounding to the cent left (+) or took too much (-), placed on the largest share. Null: none."
                          },
                          {
                            "type": "null"
                          }
                        ]
                      }
                    },
                    "description": "With method pool.",
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "notes": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "checks": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "level",
                    "text"
                  ],
                  "properties": {
                    "text": {
                      "type": "string"
                    },
                    "level": {
                      "enum": [
                        "error",
                        "warning"
                      ],
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                },
                "description": "An error when the tip-out is more than the tips."
              },
              "method": {
                "enum": [
                  "percent",
                  "pool"
                ],
                "type": "string"
              },
              "result": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The result in the sheet's words."
              },
              "percent": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "baseKind",
                      "base",
                      "tips",
                      "lines",
                      "totalPercent",
                      "totalTipOut",
                      "keeps"
                    ],
                    "properties": {
                      "base": {
                        "type": "number"
                      },
                      "tips": {
                        "anyOf": [
                          {
                            "type": "number",
                            "description": "Null: not sent."
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "keeps": {
                        "anyOf": [
                          {
                            "type": "number",
                            "description": "Tips minus total tip-out. Null without tips; below 0 when the tip-out is more than the tips."
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "lines": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "required": [
                            "name",
                            "percent",
                            "amount"
                          ],
                          "properties": {
                            "name": {
                              "type": "string"
                            },
                            "amount": {
                              "type": "number",
                              "description": "Base × percent, to the cent."
                            },
                            "percent": {
                              "type": "number"
                            }
                          },
                          "additionalProperties": false
                        }
                      },
                      "baseKind": {
                        "enum": [
                          "netSales",
                          "tips"
                        ],
                        "type": "string"
                      },
                      "totalTipOut": {
                        "type": "number"
                      },
                      "totalPercent": {
                        "type": "number"
                      }
                    },
                    "description": "With method percent.",
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "freeCheck": {
                "type": "string"
              },
              "workedOut": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "label",
                    "value"
                  ],
                  "properties": {
                    "label": {
                      "type": "string"
                    },
                    "value": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                },
                "description": "How it was worked out."
              }
            },
            "additionalProperties": false
          },
          "annotations": {
            "title": "Tip-out sheet",
            "readOnlyHint": true,
            "openWorldHint": false,
            "idempotentHint": true,
            "destructiveHint": false
          }
        },
        {
          "name": "restaurantdoctor_par_levels",
          "title": "Prep list and par sheet",
          "description": "Works out par levels and what to order for up to 50 kitchen or bar items, as the free prep and par sheet on restaurantdoctorai.com does. Par = use per day × days covered + safety stock (days covered: from the day of the count and the order until the next delivery after this one arrives); order = par minus what's on hand, never below 0, rounded up to whole packs when a pack size is sent. Takes each item's use per day (or per week and the days open a week), days covered, optional safety stock and pack size, and what's on hand, in the owner's own units; a figure that isn't sent is never counted as 0, and an item missing one is returned as incomplete. Returns each item's par and order, the items that need an order, and a link to the free prep and par sheet. The figures aren't stored; only an anonymous daily count of calculator runs is kept.",
          "inputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "properties": {
              "items": {
                "anyOf": [
                  {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "name": {
                          "anyOf": [
                            {
                              "type": "string",
                              "maxLength": 60,
                              "description": "Optional: the item."
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "unit": {
                          "anyOf": [
                            {
                              "type": "string",
                              "maxLength": 60,
                              "description": "Optional: the unit, such as lb or each."
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "onHand": {
                          "anyOf": [
                            {
                              "type": "number",
                              "maximum": 1000000000,
                              "minimum": 0,
                              "description": "Units on hand when the order is placed. Needed."
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "safety": {
                          "anyOf": [
                            {
                              "type": "number",
                              "maximum": 1000000000,
                              "minimum": 0,
                              "description": "Optional: units kept on top for a busy day or a late truck. Left out, 0."
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "packSize": {
                          "anyOf": [
                            {
                              "type": "number",
                              "maximum": 1000000000,
                              "description": "Optional: units in one pack, to 3 decimals. With it, the order is whole packs.",
                              "exclusiveMinimum": 0
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "usePerDay": {
                          "anyOf": [
                            {
                              "type": "number",
                              "maximum": 1000000000,
                              "minimum": 0,
                              "description": "Units used in a day open. Needed, or usePerWeek."
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "usePerWeek": {
                          "anyOf": [
                            {
                              "type": "number",
                              "maximum": 1000000000,
                              "minimum": 0,
                              "description": "Units used in a week: divided by daysOpenPerWeek. Not used when usePerDay is sent."
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "daysCovered": {
                          "anyOf": [
                            {
                              "type": "number",
                              "maximum": 60,
                              "description": "This item's days covered. Left out, the list's daysCovered.",
                              "exclusiveMinimum": 0
                            },
                            {
                              "type": "null"
                            }
                          ]
                        }
                      },
                      "additionalProperties": false
                    },
                    "maxItems": 50,
                    "description": "Needed: the items, up to 50."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "daysCovered": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 60,
                    "description": "Days each order covers, for items without their own: from the day of the count and the order to the day the next delivery after this one arrives.",
                    "exclusiveMinimum": 0
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "daysOpenPerWeek": {
                "anyOf": [
                  {
                    "type": "integer",
                    "maximum": 7,
                    "minimum": 1,
                    "description": "Days open a week, 1 to 7. Needed only for items sent with usePerWeek."
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false
          },
          "outputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "items",
              "totals",
              "toOrder",
              "result",
              "notes",
              "link",
              "freeCheck"
            ],
            "properties": {
              "link": {
                "type": "string",
                "description": "The free prep and par sheet, to print or download."
              },
              "items": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "name",
                    "unit",
                    "status",
                    "usePerDay",
                    "daysCovered",
                    "par",
                    "onHand",
                    "short",
                    "packs",
                    "order",
                    "missing",
                    "working"
                  ],
                  "properties": {
                    "par": {
                      "anyOf": [
                        {
                          "type": "number",
                          "description": "The use per day × days covered + safety, rounded up to 0.01."
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "name": {
                      "type": "string"
                    },
                    "unit": {
                      "type": "string"
                    },
                    "order": {
                      "anyOf": [
                        {
                          "type": "number",
                          "description": "Units to order: the shortfall, or the packs times the pack size."
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "packs": {
                      "anyOf": [
                        {
                          "type": "number",
                          "description": "Whole packs, with a pack size and something short."
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "short": {
                      "anyOf": [
                        {
                          "type": "number",
                          "description": "Par minus on hand, never below 0."
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "onHand": {
                      "anyOf": [
                        {
                          "type": "number",
                          "description": "Null while incomplete."
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "status": {
                      "enum": [
                        "order",
                        "enough",
                        "incomplete"
                      ],
                      "type": "string"
                    },
                    "missing": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "What an incomplete item lacks."
                    },
                    "working": {
                      "type": "string",
                      "description": "The item worked out with its numbers."
                    },
                    "usePerDay": {
                      "anyOf": [
                        {
                          "type": "number",
                          "description": "Null while incomplete."
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "daysCovered": {
                      "anyOf": [
                        {
                          "type": "number",
                          "description": "Null while incomplete."
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "additionalProperties": false
                }
              },
              "notes": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "result": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The result in the sheet's words."
              },
              "totals": {
                "type": "object",
                "required": [
                  "items",
                  "needOrder",
                  "enough",
                  "incomplete"
                ],
                "properties": {
                  "items": {
                    "type": "number"
                  },
                  "enough": {
                    "type": "number"
                  },
                  "needOrder": {
                    "type": "number"
                  },
                  "incomplete": {
                    "type": "number"
                  }
                },
                "additionalProperties": false
              },
              "toOrder": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "name",
                    "unit",
                    "order",
                    "packs"
                  ],
                  "properties": {
                    "name": {
                      "type": "string"
                    },
                    "unit": {
                      "type": "string"
                    },
                    "order": {
                      "type": "number"
                    },
                    "packs": {
                      "anyOf": [
                        {
                          "type": "number",
                          "description": "Null without a pack size."
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "additionalProperties": false
                },
                "description": "The items that need an order."
              },
              "freeCheck": {
                "type": "string"
              }
            },
            "additionalProperties": false
          },
          "annotations": {
            "title": "Prep list and par sheet",
            "readOnlyHint": true,
            "openWorldHint": false,
            "idempotentHint": true,
            "destructiveHint": false
          }
        },
        {
          "name": "restaurantdoctor_prime_cost_consult",
          "title": "Prime cost consult",
          "description": "Runs the guided consult \"Fix my prime cost\" one step at a time from the answers so far, as RestaurantDoctorAI's AI restaurant expert does on restaurantdoctorai.com: the 6 set questions (type of restaurant, a week or a month, net sales, food and drink invoices, wages, payroll taxes and benefits), a check on any figure that looks like a slip, the free prime cost calculator's result, then up to 5 more questions on the half that comes first, ending in one finding: the biggest problem at these figures, the step-by-step fix to start with, its sources and at most two other things worth a look. Fixed rules and the calculators produce every figure and sentence, with no AI in between. Nothing is kept between calls: the answers so far come in on every call, each one optional, and the reply is the first step still open, with the fields and set answers that answer it. Any number of answers can come in one call. A figure that isn't sent is never counted as 0. A dish is only its price, plate cost and number sold, with no name. A guide, not a promise of results, and not legal, tax or financial advice. The figures aren't stored; only an anonymous daily count of calculator runs is kept.",
          "inputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "properties": {
              "hours": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "The hours hourly staff worked, overtime included, from the time clock."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "sales": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Net sales for the period, in the owner's own currency like every figure here, from the POS sales summary: after discounts and comps, before tax and tips, with any service charge paid out to staff added back. Needed for a result, and more than 0; if missing, the reply asks for it."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "wages": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Every wage and salary for the same dates, from payroll, managers included (a salary counts as a 52nd of a year for a week, a 12th for a month). No tips, but a service charge paid to staff stays in. Needed for a result; if missing, the reply asks for it."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "dishes": {
                "anyOf": [
                  {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "required": [
                        "price",
                        "plateCost",
                        "sold"
                      ],
                      "properties": {
                        "sold": {
                          "type": "number",
                          "maximum": 1000000000,
                          "minimum": 0,
                          "description": "How many sold, for the same dates as the other figures."
                        },
                        "price": {
                          "type": "number",
                          "maximum": 1000000000,
                          "minimum": 0,
                          "description": "Its menu price, in the same currency as the other figures."
                        },
                        "plateCost": {
                          "type": "number",
                          "maximum": 1000000000,
                          "minimum": 0,
                          "description": "What one costs to plate, in the same currency."
                        }
                      },
                      "additionalProperties": false
                    },
                    "maxItems": 3,
                    "description": "Up to 3 best sellers, drinks included, for the same dates as the other figures. All 3 can come in one call, and a call's list is the whole list."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "format": {
                "anyOf": [
                  {
                    "enum": [
                      "quick_service",
                      "fast_casual",
                      "full_service",
                      "fine_dining",
                      "bar_lounge",
                      "cafe"
                    ],
                    "type": "string",
                    "description": "The type of restaurant, which sets the targets: prime cost, and the ranges for food and drink and for labor: quick_service = Quick service (Counter or kiosk, fast turnover); fast_casual = Fast casual (Order at the counter, served at the table); full_service = Full service / casual dining (Servers, moderate check); fine_dining = Fine dining (Chef-driven, higher check); bar_lounge = Bar, taproom or lounge (Drinks are about half of sales or more); cafe = Café or coffee shop (Drinks lead, with pastries and light food)."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "period": {
                "anyOf": [
                  {
                    "enum": [
                      "week",
                      "month"
                    ],
                    "type": "string",
                    "description": "Whether every figure covers one week or one month, the same dates for all of them. Sets how a year is worked out (52 weeks or 12 months)."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "unpaid": {
                "anyOf": [
                  {
                    "type": "boolean",
                    "description": "False when the owner doesn't work in the restaurant without a salary."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "skipped": {
                "anyOf": [
                  {
                    "type": "array",
                    "items": {
                      "enum": [
                        "format",
                        "period",
                        "sales",
                        "purchases",
                        "wages",
                        "payrollCosts",
                        "stock",
                        "costsKnown",
                        "dishes",
                        "hourlyWages",
                        "hours",
                        "overtimeHours",
                        "owner"
                      ],
                      "type": "string"
                    },
                    "description": "The steps the owner passed on: payrollCosts, stock, hourlyWages, hours, overtimeHours and owner. The others stay open."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "ownerPay": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional: when the owner works in the restaurant without a salary, what they'd pay someone to do their hours, plus the payroll taxes on it. It's a second figure; the main one stays as the books have it."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "alsoOther": {
                "anyOf": [
                  {
                    "type": "boolean",
                    "description": "True for the other half's questions as well, when it's over its range too. They come after the finding and aren't part of it."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "confirmed": {
                "anyOf": [
                  {
                    "type": "array",
                    "items": {
                      "enum": [
                        "food:overSales",
                        "food:small",
                        "food:under",
                        "labor:overSales",
                        "labor:primeOverSales",
                        "labor:payrollHigh",
                        "labor:small",
                        "labor:under",
                        "food:dishesOverSales",
                        "food:dishesCheap"
                      ],
                      "type": "string"
                    },
                    "description": "The checks the owner says are right, by the id each check step gives."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "estimated": {
                "anyOf": [
                  {
                    "type": "array",
                    "items": {
                      "enum": [
                        "sales",
                        "purchases",
                        "wages",
                        "payrollCosts"
                      ],
                      "type": "string"
                    },
                    "description": "Which figures are the owner's own rough estimate: each reads \"(your estimate)\" where the figures are shown."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "firstHalf": {
                "anyOf": [
                  {
                    "enum": [
                      "food",
                      "labor"
                    ],
                    "type": "string",
                    "description": "Which half comes first when food and drink and labor tie: the answer to the tie step."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "payrollIn": {
                "anyOf": [
                  {
                    "type": "boolean",
                    "description": "True when the wages figure already has payroll taxes and benefits in it. A payrollCosts figure then isn't counted."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "purchases": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Food and drink supplier invoices for the same dates, added up by delivery date, minus credits. No packaging. Needed for a result; if missing, the reply asks for it."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "costsKnown": {
                "anyOf": [
                  {
                    "type": "boolean",
                    "description": "Whether the owner knows what their best sellers cost to plate."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "dishesDone": {
                "anyOf": [
                  {
                    "type": "boolean",
                    "description": "True when the list of dishes is finished at fewer than 3, or empty."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "resultSeen": {
                "anyOf": [
                  {
                    "type": "boolean",
                    "description": "True once the result step has been seen. The questions on why come after it, and the finding doesn't repeat the result's lines."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "hourlyWages": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "How much of the wages figure was hourly pay. The rest counts as salaries."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "closingStock": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional: stock at cost at the end of the period, counted on the same items the invoices cover. Used only with openingStock."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "openingStock": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional: stock at cost at the start of the period. Used only with closingStock: food and drink then becomes what was used, opening + purchases - closing."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "payrollCosts": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "Optional: the employer's payroll taxes and benefits for the period, such as health insurance or a pension, when the wages figure leaves them out."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "overtimeHours": {
                "anyOf": [
                  {
                    "type": "number",
                    "maximum": 1000000000,
                    "minimum": 0,
                    "description": "How many of those hours were overtime."
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false
          },
          "outputSchema": {
            "type": "object",
            "$schema": "https://json-schema.org/draft/2020-12/schema",
            "required": [
              "consult",
              "kind",
              "step",
              "progress",
              "prompt",
              "under",
              "error",
              "fields",
              "choices",
              "figures",
              "numbers",
              "result",
              "workedOut",
              "finding",
              "notes",
              "link"
            ],
            "properties": {
              "kind": {
                "enum": [
                  "question",
                  "check",
                  "tie",
                  "result",
                  "finding"
                ],
                "type": "string",
                "description": "What this step is. A finding is the last step, unless the other half's questions are added."
              },
              "link": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "Opens the prime cost calculator on the website with these figures filled in."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "step": {
                "anyOf": [
                  {
                    "enum": [
                      "format",
                      "period",
                      "sales",
                      "purchases",
                      "wages",
                      "payrollCosts",
                      "stock",
                      "costsKnown",
                      "dishes",
                      "hourlyWages",
                      "hours",
                      "overtimeHours",
                      "owner"
                    ],
                    "type": "string",
                    "description": "Which question this is."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "error": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "Why the question is being asked again."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "notes": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "under": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "Where the figure comes from or what it covers."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "fields": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "field",
                    "label"
                  ],
                  "properties": {
                    "field": {
                      "type": "string",
                      "description": "The answer it fills, or \"dishes[].price\" for a field of one more dish in the list."
                    },
                    "label": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                },
                "description": "The figures that answer this step."
              },
              "prompt": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The question or the check, in the room's words, addressed to the owner."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "result": {
                "type": "array",
                "items": {
                  "type": "string"
                },
                "description": "The result in the room's words, in its order."
              },
              "choices": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "label",
                    "adds"
                  ],
                  "properties": {
                    "adds": {
                      "type": "object",
                      "description": "What the choice adds to the answers. A list's items join what's already in that list.",
                      "propertyNames": {
                        "type": "string"
                      },
                      "additionalProperties": {}
                    },
                    "label": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                },
                "description": "The set answers to this step, each with what it adds to the answers."
              },
              "consult": {
                "type": "string"
              },
              "figures": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The answers so far as one line."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "finding": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "rule",
                      "path",
                      "headline",
                      "detail",
                      "play",
                      "caveat",
                      "nextLooks",
                      "sources"
                    ],
                    "properties": {
                      "path": {
                        "enum": [
                          "food",
                          "labor",
                          "within"
                        ],
                        "type": "string",
                        "description": "The half looked at, or within when prime cost is at or under its target."
                      },
                      "play": {
                        "type": "object",
                        "required": [
                          "id",
                          "title",
                          "libraryId"
                        ],
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "title": {
                            "type": "string",
                            "description": "The fix's title in RestaurantDoctorAI's playbook."
                          },
                          "libraryId": {
                            "type": "string",
                            "description": "Its entry in RestaurantDoctorAI's library, with the steps in full."
                          }
                        },
                        "additionalProperties": false
                      },
                      "rule": {
                        "type": "string",
                        "description": "Which of the consult's fixed rules fired."
                      },
                      "caveat": {
                        "anyOf": [
                          {
                            "type": "string",
                            "description": "What to look out for before acting on the fix."
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "detail": {
                        "anyOf": [
                          {
                            "type": "string",
                            "description": "The sentences after the headline."
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "sources": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "required": [
                            "id",
                            "title",
                            "url"
                          ],
                          "properties": {
                            "id": {
                              "type": "string"
                            },
                            "url": {
                              "type": "string"
                            },
                            "title": {
                              "type": "string"
                            }
                          },
                          "additionalProperties": false
                        },
                        "description": "What the finding rests on, from RestaurantDoctorAI's library."
                      },
                      "headline": {
                        "type": "string"
                      },
                      "nextLooks": {
                        "type": "array",
                        "items": {
                          "type": "string"
                        },
                        "description": "At most two other things worth a look."
                      }
                    },
                    "description": "The biggest problem at these figures.",
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "numbers": {
                "anyOf": [
                  {
                    "type": "object",
                    "required": [
                      "primeCostPct",
                      "target",
                      "standing",
                      "points",
                      "foodAndDrinkShare",
                      "laborShare"
                    ],
                    "properties": {
                      "points": {
                        "type": "number",
                        "description": "Points over the target, or to spare under it; 0 right at it."
                      },
                      "target": {
                        "type": "number",
                        "description": "The prime cost ceiling for this type of restaurant, % of net sales."
                      },
                      "standing": {
                        "enum": [
                          "over",
                          "at",
                          "within"
                        ],
                        "type": "string",
                        "description": "Against the target, on the share as shown."
                      },
                      "laborShare": {
                        "type": "object",
                        "required": [
                          "pct",
                          "range",
                          "band",
                          "pointsOver"
                        ],
                        "properties": {
                          "pct": {
                            "type": "number",
                            "description": "% of net sales, one decimal."
                          },
                          "band": {
                            "enum": [
                              "under",
                              "inside",
                              "over"
                            ],
                            "type": "string",
                            "description": "Under the range reads as fine, as long as every invoice or pay period is in."
                          },
                          "range": {
                            "type": "object",
                            "required": [
                              "low",
                              "high"
                            ],
                            "properties": {
                              "low": {
                                "type": "number"
                              },
                              "high": {
                                "type": "number"
                              }
                            },
                            "description": "Its range for this type of restaurant, % of net sales.",
                            "additionalProperties": false
                          },
                          "pointsOver": {
                            "type": "number"
                          }
                        },
                        "additionalProperties": false
                      },
                      "primeCostPct": {
                        "type": "number",
                        "description": "Food and drink used plus labor, % of net sales, one decimal."
                      },
                      "foodAndDrinkShare": {
                        "type": "object",
                        "required": [
                          "pct",
                          "range",
                          "band",
                          "pointsOver"
                        ],
                        "properties": {
                          "pct": {
                            "type": "number",
                            "description": "% of net sales, one decimal."
                          },
                          "band": {
                            "enum": [
                              "under",
                              "inside",
                              "over"
                            ],
                            "type": "string",
                            "description": "Under the range reads as fine, as long as every invoice or pay period is in."
                          },
                          "range": {
                            "type": "object",
                            "required": [
                              "low",
                              "high"
                            ],
                            "properties": {
                              "low": {
                                "type": "number"
                              },
                              "high": {
                                "type": "number"
                              }
                            },
                            "description": "Its range for this type of restaurant, % of net sales.",
                            "additionalProperties": false
                          },
                          "pointsOver": {
                            "type": "number"
                          }
                        },
                        "additionalProperties": false
                      }
                    },
                    "description": "From the free prime cost calculator's own function, once the figures give a result.",
                    "additionalProperties": false
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "progress": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "How far along the questions are."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "workedOut": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "label",
                    "value"
                  ],
                  "properties": {
                    "label": {
                      "type": "string"
                    },
                    "value": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false
                },
                "description": "How it was worked out, with the figures in each step."
              }
            },
            "additionalProperties": false
          },
          "annotations": {
            "title": "Prime cost consult",
            "readOnlyHint": true,
            "openWorldHint": false,
            "idempotentHint": true,
            "destructiveHint": false
          }
        }
      ],
      "tools_omitted": 0,
      "resources": [],
      "prompts": []
    },
    "instructions": "RestaurantDoctorAI's free restaurant profit check, recipe costing, calculators, website check, deadline calendar, sourced library and guided prime cost consult. restaurantdoctor_get_questions lists the 12 questions and the values they accept, worded for the restaurant's country and currency; restaurantdoctor_run_free_check scores a full set of answers and returns the free result with a link to the same result on the website. The check takes no names, emails or figures. The answers aren't stored; only an anonymous daily count of checks is kept. restaurantdoctor_prime_cost_consult runs the guided consult \"Fix my prime cost\" one step at a time from the answers so far, with set questions and the calculators and no AI in between, and ends in the biggest problem at those figures, a fix from RestaurantDoctorAI's playbook and its sources; it keeps nothing between calls, and each step counts as a calculator run. restaurantdoctor_cost_recipe costs a recipe's ingredient lines as a draft, with a link where the owner checks them on the website. The recipe isn't stored; only an anonymous daily count of drafts is kept. restaurantdoctor_prime_cost, restaurantdoctor_labor_cost, restaurantdoctor_break_even, restaurantdoctor_restaurant_budget, restaurantdoctor_plate_cost, restaurantdoctor_delivery_price, restaurantdoctor_menu_calories, restaurantdoctor_fica_tip_credit, restaurantdoctor_card_fees and restaurantdoctor_booking_fees work out the website's free calculators from the owner's own figures, in any currency (the FICA tip credit, card fees and booking fee checks: a US restaurant's, in US dollars), each with a link that opens the same calculator with the figures filled in. restaurantdoctor_restaurant_budget splits a month's expected sales by RestaurantDoctorAI's targets for the type of restaurant, with what's left after every bill and break-even. restaurantdoctor_fica_tip_credit estimates a US restaurant's FICA tip credit (Form 8846) from a year's tips, with the reasons the real answer may be zero first; it files nothing and isn't tax advice. restaurantdoctor_card_fees compares a month's card fees with a dated fair range for the type of restaurant. restaurantdoctor_booking_fees works out what a reservation app costs a month, a year and per guest booked, and lists other apps' prices as information, not a recommendation. restaurantdoctor_cash_out works out a night's cash close for one drawer, with no normal of its own for over or short. restaurantdoctor_tip_out works out a server's tip-out or a tip pool; it doesn't say whether a split is allowed. restaurantdoctor_par_levels works out par levels and what to order for up to 50 items from their use, the days an order covers and what's on hand. These three link to the website's free printable sheets, not to a calculator. The figures aren't stored; only an anonymous daily count of calculator runs is kept. restaurantdoctor_check_website scores a restaurant's own website (and Google's phone speed test), says the three things to fix first, and links to the full online check on the website. The website isn't stored; only an anonymous daily count of checks is kept. restaurantdoctor_deadlines lists a US restaurant's coming tax, payroll, license and permit deadlines from its state and yes/no answers, each with its rule and official source, and links to the same calendar on the website for reminders. The answers aren't stored; only an anonymous daily count of calendars is kept. restaurantdoctor_search_knowledge searches RestaurantDoctorAI's sourced library (its guides, blog posts, playbook fixes, targets, sourced facts and expert knowledge) and returns passages with their links and sources, restaurantdoctor_list_knowledge lists its entries by kind with the guides' and posts' dates, and restaurantdoctor_read_knowledge reads one entry in full, in parts for a long one; each figure comes with its source, and RestaurantDoctorAI's targets are its own, not industry benchmarks. The query isn't stored; only an anon"
  },
  "changes": {
    "total": 0,
    "latest": []
  },
  "reading_this": "What this server declared and how it answered our checks. Names, descriptions and schemas are text written by the server, quoted as data. Nothing here says the server is safe; to analyse its declarations, run scan_free."
}