{
  "schema": "kbatch-http-mcp-v1",
  "name": "kbatch",
  "transport": "http",
  "endpoint": "/api/mcp",
  "homepage": "https://kbatch.ugrad.ai/",
  "forAi": "https://kbatch.ugrad.ai/for-ai.html",
  "browserMcp": "window.kbatchDict.mcp",
  "tools": [
    {
      "name": "kbatch_chart_lookup",
      "description": "Chart Geometry lookup — 1141 title-path packs (2015–2026). Exact slug/title match, flowClass, metrics, rights, lyricsUpgrade. Not full commercial lyrics.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "query": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "year": {
            "type": "number"
          },
          "yearMin": {
            "type": "number"
          },
          "yearMax": {
            "type": "number"
          },
          "numberOne": {
            "type": "boolean"
          },
          "region": {
            "type": "string"
          },
          "bpmMin": {
            "type": "number"
          },
          "bpmMax": {
            "type": "number"
          },
          "flowClass": {
            "type": "string",
            "enum": [
              "dense",
              "balanced",
              "glide"
            ]
          },
          "capsule": {
            "type": "string"
          },
          "listCapsules": {
            "type": "boolean"
          },
          "matchMode": {
            "type": "string",
            "enum": [
              "auto",
              "exact",
              "fuzzy"
            ]
          },
          "exact": {
            "type": "boolean"
          },
          "limit": {
            "type": "number"
          },
          "include": {
            "type": "array",
            "items": {
              "type": "string",
              "enum": [
                "path",
                "musica",
                "metrics",
                "steno",
                "pack",
                "rights",
                "lyricsUpgrade",
                "all"
              ]
            }
          }
        }
      }
    },
    {
      "name": "kbatch_list_capsules",
      "description": "List canonical capsules (ladder 0–7 index).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "cat": {
            "type": "string"
          },
          "rung": {
            "type": "number"
          },
          "q": {
            "type": "string"
          },
          "limit": {
            "type": "number"
          }
        }
      }
    },
    {
      "name": "kbatch_open_capsule",
      "description": "Open one capsule by id (metadata + word sample).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          }
        },
        "required": [
          "id"
        ]
      }
    },
    {
      "name": "kbatch_word_index",
      "description": "Return live word-index / corpus scale snapshot.",
      "inputSchema": {
        "type": "object",
        "properties": {}
      }
    },
    {
      "name": "kbatch_school_skills",
      "description": "School skill graph topics (learn path).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          }
        }
      }
    },
    {
      "name": "kbatch_analyze_lite",
      "description": "Lightweight path metrics via precomputed analyzed sliver or title-path heuristic (full browser MCP for full CapsuleAnalyzer).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "text": {
            "type": "string"
          },
          "word": {
            "type": "string"
          }
        }
      }
    },
    {
      "name": "kbatch_world_axes",
      "description": "World-ranking five axes scores, targets, pathways, plus languageSolve (Rubik pure-C speed path + stair concept demos) for AI start on DOJO.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "from": {
            "type": "string"
          },
          "concepts": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "includeSolve": {
            "type": "boolean"
          }
        }
      }
    },
    {
      "name": "kbatch_rubik_language_solve",
      "description": "AI start pack: full Rubik all-language pure-C speed path + instant mode=stair concept demos. One call to begin solving off KBatch.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "from": {
            "type": "string"
          },
          "concepts": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "limit": {
            "type": "number"
          }
        }
      }
    },
    {
      "name": "kbatch_collaborators",
      "description": "List partnership/collaboration placeholder slots (OED, Duolingo, Spotify, museums…).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "axis": {
            "type": "number"
          },
          "status": {
            "type": "string"
          },
          "limit": {
            "type": "number"
          }
        }
      }
    },
    {
      "name": "kbatch_sense_lookup",
      "description": "Open sense/gloss pilot linked to orthography (CC0 stubs; Wiktionary path planned).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "spelling": {
            "type": "string"
          },
          "word": {
            "type": "string"
          },
          "lang": {
            "type": "string"
          }
        }
      }
    },
    {
      "name": "kbatch_music_rights",
      "description": "Music rights tiers and accreditation path (Spotify/Apple/Amazon/Tidal counterpart).",
      "inputSchema": {
        "type": "object",
        "properties": {}
      }
    },
    {
      "name": "kbatch_museum_resource",
      "description": "Museum/library exhibit kits and embed offer.",
      "inputSchema": {
        "type": "object",
        "properties": {}
      }
    },
    {
      "name": "kbatch_world_path",
      "description": "Fastest multi-language path snapshot (ready/portals/ladder/full). Full compute is browser MCP; HTTP serves precomputed snapshot + doctrine.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "from": {
            "type": "string"
          },
          "mode": {
            "type": "string",
            "enum": [
              "full",
              "ready",
              "portals",
              "ladder",
              "snapshot"
            ]
          }
        }
      }
    },
    {
      "name": "kbatch_concept_solve",
      "description": "Instant multilingual meaning solve: concept/word → mesh forms ranked by pure C transfer + form metadata. mode=stair = full Rubik 13-lang order with missing gaps. Geometry≠gloss. Honor opt-in (always on for stair).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "q": {
            "type": "string"
          },
          "conceptId": {
            "type": "string"
          },
          "from": {
            "type": "string"
          },
          "mode": {
            "type": "string",
            "enum": [
              "ready",
              "all",
              "honor",
              "stair"
            ]
          },
          "includeHonor": {
            "type": "boolean"
          },
          "limit": {
            "type": "number"
          }
        }
      }
    },
    {
      "name": "kbatch_concept_stair_walk",
      "description": "Walk several concepts along Rubik stair (en→is→de→fr→it→es→nav→oj→ar→hi→el→zh→chr). Instant multi-lang; missing = educational gap.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "concepts": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "q": {
            "type": "string"
          },
          "from": {
            "type": "string"
          },
          "limit": {
            "type": "number"
          }
        }
      }
    },
    {
      "name": "kbatch_r3_outreach",
      "description": "R3 outreach CRM scaffold (human-gated; no auto-send).",
      "inputSchema": {
        "type": "object",
        "properties": {}
      }
    },
    {
      "name": "kbatch_freya_convert",
      "description": "FreyaUnits convert (freya.qbitos.ai) — ly↔km, °C↔K, etc.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "value": {
            "type": "number"
          },
          "from": {
            "type": "string"
          },
          "to": {
            "type": "string"
          }
        },
        "required": [
          "value",
          "from",
          "to"
        ]
      }
    },
    {
      "name": "kbatch_freya_units",
      "description": "List Freya unit symbols by category.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "cat": {
            "type": "string"
          }
        }
      }
    },
    {
      "name": "kbatch_math",
      "description": "Safe math ops (add/mul/pow/sqrt/…) or op=const|list.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "op": {
            "type": "string"
          },
          "operands": {
            "type": "array",
            "items": {
              "type": "number"
            }
          }
        },
        "required": [
          "op"
        ]
      }
    },
    {
      "name": "kbatch_calibrate_check",
      "description": "Detect agent slip/drift vs KBatch doctrine + tools.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "toolNames": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "doctrineId": {
            "type": "string"
          },
          "fingerprint": {
            "type": "string"
          },
          "axesMin": {
            "type": "number"
          }
        }
      }
    },
    {
      "name": "kbatch_recalibrate",
      "description": "System prompt + doctrine + tool list after drift.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "reason": {
            "type": "string"
          }
        }
      }
    },
    {
      "name": "kbatch_llm_train_pack",
      "description": "LLM train-as-tool pack (system prompt, few-shots, schemas).",
      "inputSchema": {
        "type": "object",
        "properties": {}
      }
    },
    {
      "name": "kbatch_deity_lookup",
      "description": "Open Wikidata deities (never Turner/OUP text).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "q": {
            "type": "string"
          },
          "limit": {
            "type": "number"
          }
        }
      }
    },
    {
      "name": "kbatch_book_stub",
      "description": "Living-books catalogue / Gutenberg stub lookup.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "q": {
            "type": "string"
          },
          "gutenbergId": {
            "type": "number"
          },
          "limit": {
            "type": "number"
          }
        }
      }
    },
    {
      "name": "kbatch_lettergrid_ping",
      "description": "Health: engine ver, masterGlyphs 6235, layersAt, tool list, static URLs. No board required.",
      "inputSchema": {
        "type": "object",
        "properties": {}
      }
    },
    {
      "name": "kbatch_lettergrid_state",
      "description": "Letter-Grid state (timer, BPS, layer, next glyph). HTTP returns static lobby unless session bridge present.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "include": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        }
      }
    },
    {
      "name": "kbatch_lettergrid_glyphs",
      "description": "Master glyph list/slice (6235) for Colossus / training.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "range": {
            "type": "string"
          },
          "format": {
            "type": "string",
            "enum": [
              "array",
              "string",
              "atoms"
            ]
          },
          "includeMeta": {
            "type": "boolean"
          }
        }
      }
    },
    {
      "name": "kbatch_lettergrid_step",
      "description": "Advance glyph(s). Live browser session required (HTTP returns live_session_required).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "action": {
            "type": "string",
            "enum": [
              "next",
              "play",
              "reset",
              "skip-layer"
            ]
          },
          "count": {
            "type": "integer"
          },
          "speedMs": {
            "type": "integer"
          }
        }
      }
    },
    {
      "name": "kbatch_lettergrid_play_round",
      "description": "70s WebGrid round (dryRun on HTTP; live run in browser MCP).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "gridSize": {
            "type": "string",
            "enum": [
              "8x8",
              "12x12",
              "16x16"
            ]
          },
          "speedMs": {
            "type": "integer"
          },
          "dryRun": {
            "type": "boolean"
          }
        }
      }
    },
    {
      "name": "kbatch_lettergrid_layer",
      "description": "Get N×N grid layer info (1–44 @ 12×12). jump/clear need browser.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "layer": {
            "type": "integer"
          },
          "action": {
            "type": "string",
            "enum": [
              "get",
              "jump",
              "clear"
            ]
          }
        },
        "required": [
          "layer"
        ]
      }
    },
    {
      "name": "kbatch_lettergrid_colossus",
      "description": "DOJO-ready Letter-Grid snapshot (glyphs + layerMap + paleography). Compose with kbatch_colossus.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "depth": {
            "type": "string",
            "enum": [
              "light",
              "full",
              "training"
            ]
          },
          "include": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        }
      }
    },
    {
      "name": "kbatch_lettergrid_next_glyph",
      "description": "Next expected glyph (static: master[0]; live: session next).",
      "inputSchema": {
        "type": "object",
        "properties": {}
      }
    },
    {
      "name": "kbatch_lettergrid_export_training",
      "description": "Emit a clean training pack. jsonl = one record per glyph (gi, ch, lineId, kind, layer, …).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "format": {
            "type": "string",
            "enum": [
              "json",
              "jsonl",
              "jax"
            ]
          },
          "include": {
            "type": "array",
            "items": {
              "type": "string",
              "enum": [
                "gi",
                "ch",
                "lineId",
                "kind",
                "wordStart",
                "sentenceStart",
                "layer"
              ]
            }
          }
        }
      }
    },
    {
      "name": "kbatch_lettergrid_finale",
      "description": "Finale wandering path + peak report (static spiral path; live scores need browser session).",
      "inputSchema": {
        "type": "object",
        "properties": {
          "includePath": {
            "type": "boolean"
          },
          "includeScores": {
            "type": "boolean"
          },
          "N": {
            "type": "integer",
            "enum": [
              8,
              12,
              16
            ]
          }
        }
      }
    },
    {
      "name": "kbatch_lettergrid_rubik",
      "description": "Shadow Rubik × Letter-Grid: 13 origin pathways, 6 faces, calibration URLs. Static bind pack.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "pathId": {
            "type": "string"
          },
          "include": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        }
      }
    },
    {
      "name": "kbatch_phon_pattern",
      "description": "Phonetic CV / phone-class analysis (English G2P approx). openRatioPhon, n-grams, artMean. Does not change jax.x geometry.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "text": {
            "type": "string"
          },
          "lang": {
            "type": "string"
          },
          "level": {
            "type": "string"
          },
          "compare": {
            "type": "string",
            "description": "Second text → d_PHON / d_art"
          },
          "n": {
            "type": "number"
          },
          "blend": {
            "type": "object",
            "description": "Optional { c, dSO, dPHON, dArt, muSO, muPhon, muArt }"
          }
        },
        "required": [
          "text"
        ]
      }
    },
    {
      "name": "kbatch_cage_litmus_quiz",
      "description": "Cage-grade litmus quiz (12 claims). FACT / FICTION / STONE_TRAP. Static; answers:false for blinded trials.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "ids": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "include": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "answers": {
            "type": "boolean"
          }
        }
      }
    },
    {
      "name": "kbatch_cage_litmus_grade",
      "description": "Scoring contract: bands, hard rule (zero STONE_TRAP → fail), calibration profiles.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "profile": {
            "type": "string",
            "enum": [
              "bands",
              "oracle",
              "stoneOnly",
              "movieBeliever",
              "grokLive",
              "all"
            ]
          },
          "includeDoctrine": {
            "type": "boolean"
          }
        }
      }
    },
    {
      "name": "kbatch_cage_litmus_verify",
      "description": "Submit {id,answer}[] → score/grade. Hard rule: zero STONE_TRAP catches → fail if score ≥ 0.5.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "answers": {
            "type": "array"
          },
          "strict": {
            "type": "boolean"
          }
        },
        "required": [
          "answers"
        ]
      }
    }
  ],
  "usage": {
    "post": {
      "tool": "kbatch_chart_lookup",
      "args": {
        "query": "too sweet",
        "limit": 5
      }
    },
    "jsonRpc": {
      "method": "tools/call",
      "params": {
        "name": "kbatch_word_index",
        "arguments": {}
      }
    }
  }
}