{
  "schema": "bsmt_canonical_notation_and_encoding",
  "schema_version": "1.0.0",
  "status": "CANONICAL_WORKING_SPEC",
  "generated_on": "2026-09-30",
  "authority": {
    "society_bg": "Българско сдружение за музикална теория",
    "society_en": "Bulgarian Society for Music Theory",
    "acronym": "BSMT",
    "primary_reference": "Parashkev Hadjiev",
    "principle": "Preferred house notation; not mandatory author notation."
  },
  "layers": {
    "terminology": "Canonical English terminology for journal prose.",
    "source_encoding": "ASCII-friendly editor/author/tool input.",
    "semantic_registry": "Typed meaning of functions, scale degrees, chord members, modifiers and figures.",
    "rendered_notation": "Accessible HTML/MathML/LaTeX output."
  },
  "pitch_system": {
    "preferred_house_letters": [
      "C",
      "D",
      "E",
      "F",
      "G",
      "A",
      "H"
    ],
    "H": "B-natural",
    "B": "B-flat",
    "accidentals": {
      "sharp": "♯",
      "double_sharp": "𝄪",
      "flat": "♭",
      "double_flat": "𝄫",
      "natural": "♮"
    }
  },
  "scale_degrees": {
    "canonical": [
      "I",
      "II",
      "III",
      "IV",
      "V",
      "VI",
      "VII"
    ],
    "case": "UPPERCASE",
    "rule": "Roman-numeral case does not encode chord quality."
  },
  "function_tokens": {
    "T": "tonic",
    "S": "subdominant",
    "D": "dominant",
    "W": "lower mediant",
    "M": {
      "meaning": "upper mediant",
      "status": "SOURCE_SPECIFIC"
    }
  },
  "canonical_source_grammar": {
    "ebnf": "expression := [left_upper '|'] base { '(' index ')' } ;",
    "human_form": "[LEFT_UPPER|]BASE(INDEX1)(INDEX2)(INDEX3)...",
    "left_upper_separator": "|",
    "index_open": "(",
    "index_close": ")",
    "whitespace": "DISALLOWED_WITHIN_EXPRESSION",
    "parentheses_visible_in_render": false,
    "nesting": "Each successive parenthesized token is a lower index of the immediately preceding element.",
    "semantic_rule": "The nesting syntax defines geometry only; semantic interpretation is resolved by symbol-family rules."
  },
  "modifiers": {
    "0": {
      "role": "left_upper_modifier",
      "keyboard_alias_for": "°",
      "render_as": "°",
      "placement": "upper-left",
      "source_meaning": "Chord in major under influence of the same-name minor.",
      "note": "ASCII 0 is input syntax only and must never be rendered as the digit zero. This mode-influence marker is distinct from notation that alters an individual chord tone.",
      "source_meaning_bg": "Акорд в мажор под влияние на едноименния минор."
    },
    "+": {
      "role": "left_upper_modifier",
      "render_as": "+",
      "placement": "upper-left",
      "source_meaning": "Chord in minor under influence of the same-name major.",
      "note": "This mode-influence marker is distinct from notation that raises an individual chord tone.",
      "source_meaning_bg": "Акорд в минор под влияние на едноименния мажор."
    }
  },
  "W_rule": {
    "input": "W",
    "render_as": "W",
    "meaning": "lower mediant",
    "turned_M": false,
    "rotated_M": false,
    "unicode_turned_M": false
  },
  "examples": [
    {
      "input": "S(II)",
      "parse": {
        "base": {
          "token": "S",
          "role": "function",
          "meaning": "subdominant"
        },
        "lower_index": {
          "token": "II",
          "role": "scale_degree"
        }
      },
      "render_intent": "S with II as lower index"
    },
    {
      "input": "T(VI)",
      "parse": {
        "base": {
          "token": "T",
          "role": "function",
          "meaning": "tonic"
        },
        "lower_index": {
          "token": "VI",
          "role": "scale_degree"
        }
      },
      "render_intent": "T with VI as lower index"
    },
    {
      "input": "D(VII)",
      "parse": {
        "base": {
          "token": "D",
          "role": "function",
          "meaning": "dominant"
        },
        "lower_index": {
          "token": "VII",
          "role": "scale_degree"
        }
      },
      "render_intent": "D with VII as lower index"
    },
    {
      "input": "0|W(5)(3)(3)",
      "canonical": true,
      "meaning_bg": "долна медианта в мажор под влияние на едноименния минор, в основно положение, с квинтов тон и удвоен терцов тон",
      "meaning_en": "lower mediant in major under influence of the same-name minor, in root position, with fifth and doubled third",
      "parse": {
        "left_upper": {
          "input": "0",
          "render": "°"
        },
        "base": {
          "token": "W",
          "meaning": "lower mediant"
        },
        "lower_index": {
          "token": "5",
          "semantic_role": "fifth",
          "lower_index": {
            "token": "3",
            "semantic_role": "third",
            "lower_index": {
              "token": "3",
              "semantic_role": "doubled third"
            }
          }
        }
      },
      "latex_fallback": "{}^{\\circ}\\!W_{5_{3_{3}}}",
      "plain_text_fallback": "0|W(5)(3)(3)"
    }
  ],
  "semantic_families": {
    "function_degree": {
      "example": "S(II)",
      "sequence": [
        "function",
        "scale_degree"
      ]
    },
    "function_degree_figures": {
      "example": "S(II)(6)(5)",
      "sequence": [
        "function",
        "scale_degree",
        "figure",
        "figure"
      ],
      "warning": "Do not assume that every figure chain is figured-bass notation without consulting the registered family."
    },
    "chord_member_stack": {
      "example": "W(5)(3)(3)",
      "sequence": [
        "function",
        "chord_member",
        "chord_member",
        "duplicated_chord_member"
      ]
    }
  },
  "terminology_contract": {
    "triads": {
      "root_position": "triad in root position",
      "first_inversion": "triad in first inversion",
      "second_inversion": "triad in second inversion"
    },
    "seventh_chords": {
      "root_position": "seventh chord in root position",
      "first_inversion": "seventh chord in first inversion",
      "second_inversion": "seventh chord in second inversion",
      "third_inversion": "seventh chord in third inversion"
    },
    "ninth_chords": {
      "root_position": {
        "bg_source_name": "нонакорд",
        "en": "ninth chord in root position"
      },
      "first_inversion": {
        "bg_source_name": "секстсептакорд",
        "en": "ninth chord in first inversion"
      },
      "second_inversion": {
        "bg_source_name": "квартквинтакорд",
        "en": "ninth chord in second inversion"
      },
      "third_inversion": {
        "bg_source_name": "секундтерцакорд",
        "en": "ninth chord in third inversion"
      },
      "fourth_inversion": {
        "bg_source_name": null,
        "en": "ninth chord in fourth inversion",
        "hadjiev_status": "NOT_USED"
      }
    },
    "eleventh_chords": {
      "root_position": "eleventh chord in root position",
      "inversions": [
        "eleventh chord in first inversion",
        "eleventh chord in second inversion",
        "eleventh chord in third inversion",
        "eleventh chord in fourth inversion",
        "eleventh chord in fifth inversion"
      ]
    },
    "thirteenth_chords": {
      "root_position": "thirteenth chord in root position",
      "inversions": [
        "thirteenth chord in first inversion",
        "thirteenth chord in second inversion",
        "thirteenth chord in third inversion",
        "thirteenth chord in fourth inversion",
        "thirteenth chord in fifth inversion",
        "thirteenth chord in sixth inversion"
      ]
    }
  },
  "website_markup": {
    "recommended_wrapper": "[[h:...]]",
    "example": "[[h:0|W(5)(3)(3)]]",
    "wrapper_is_part_of_symbol": false,
    "rationale": "Avoid conflicts with Astro/MDX/JSX brace syntax."
  },
  "render_targets": {
    "html": {
      "preferred": [
        "MathML",
        "structured nested spans"
      ],
      "forbid": [
        "flattened Unicode approximation",
        "image-only notation where semantic rendering is possible"
      ]
    },
    "mathml": {
      "preferred": true,
      "requirement": "Preserve recursive index structure and accessible semantics."
    },
    "latex": {
      "role": "generated publication output",
      "author_facing_source": false
    },
    "svg": {
      "role": "fallback for special geometry only"
    }
  },
  "accessibility": {
    "require_semantic_text": true,
    "require_plain_text_fallback": true,
    "canonical_example": {
      "input": "0|W(5)(3)(3)",
      "spoken_en": "lower mediant in major under influence of the same-name minor, in root position, with fifth and doubled third",
      "spoken_bg": "долна медианта в мажор под влияние на едноименния минор, в основно положение, с квинтов тон и удвоен терцов тон"
    }
  },
  "unresolved_graphical_micro_syntax": [
    "exact placement of chord-member alterations",
    "secondary-function arrow syntax",
    "variant notation",
    "special Lydian-source symbol if retained"
  ],
  "implementation_contract": {
    "parser": "Parse source encoding into a typed AST.",
    "semantic_resolution": "Resolve meaning through registered symbol families.",
    "renderer": "Generate accessible HTML/MathML and LaTeX from the AST.",
    "validator": "Reject malformed expressions and semantically impossible registered combinations.",
    "reuse": "The same grammar and renderer should be consumed by the society site, journal-facing web presentation, and publication-production tooling."
  },
  "author_policy": {
    "house_notation": "PREFERRED",
    "mandatory": false,
    "editors_must_not_force_conversion": true
  },
  "mode_influence_distinction": {
    "rule": "Left-side degree/plus markers identify influence between same-name major and minor; they are not individual chord-tone alteration signs.",
    "major_under_same_name_minor": "°",
    "minor_under_same_name_major": "+",
    "rule_bg": "Левите знаци градус/плюс означават влияние между едноименни мажор и минор; те не са знаци за алтерация на отделен акордов тон."
  },
  "individual_chord_tone_alteration": {
    "status": "SEMANTIC_SUPPORT_REQUIRED_GRAPHICAL_MICRO_SYNTAX_UNRESOLVED",
    "distinction_en": "Individual chord-tone alteration notation is distinct from the left-side mode-influence prescripts.",
    "distinction_bg": "Означаването на алтерация на отделен акордов тон е различно от левите прескриптни знаци за влияние между едноименни мажор и минор.",
    "implementation_rule": "Do not approximate unresolved graphical micro-syntax; preserve the semantic distinction and fail closed until an exact notation rule is frozen."
  }
}
