{
  "slug": "bibtex-format",
  "name": "gizza-ai/bibtex-format",
  "version": "0.1.0",
  "title": "BibTeX Formatter & Validator — gizza.ai",
  "description": "Free BibTeX formatter and validator — pretty-print, sort and align .bib bibliography entries in your browser. Consistent indentation, no sign-up, no upload.",
  "tags": [
    "bibtex",
    "bibtex formatter",
    "bibtex validator",
    "bib file",
    "bibliography",
    "latex",
    "citation",
    "sort bibtex",
    "pretty print"
  ],
  "category": "data",
  "urls": {
    "page": "https://gizza.ai/tools/bibtex-format/",
    "markdown": "https://gizza.ai/tools/bibtex-format/index.md",
    "descriptor": "https://gizza.ai/tools/bibtex-format/tool.json",
    "deep_link_example": "https://gizza.ai/tools/bibtex-format/?bibtex=%40article%7Beinstein1905%2C%20title%3D%7BZur%20Elektrodynamik%20bewegter%20K%C3%B6rper%7D%2C%20author%3D%7BEinstein%2C%20Albert%7D%2C%20year%3D1905%7D&sort=none&sort_fields=true&indent=2&align_values=true&lowercase_type=true&check_duplicates=true"
  },
  "cli": "gizza tool bibtex-format \"@article{einstein1905, title={Zur Elektrodynamik bewegter Körper}, author={Einstein, Albert}, year=1905}\"",
  "tool": {
    "description": "Validate, sort, and pretty-print BibTeX bibliography entries. Pass the raw .bib source in 'bibtex'; the tool parses @article/@book/etc. entries plus @string/@preamble/@comment, reports any syntax error, then re-emits them cleanly with one field per indented line.",
    "parameters": {
      "additionalProperties": false,
      "properties": {
        "align_values": {
          "default": false,
          "description": "When true, pad field names so all '=' signs in an entry line up. Default false (a single space before '=').",
          "type": "boolean"
        },
        "bibtex": {
          "description": "The BibTeX bibliography source to validate and pretty-print.",
          "type": "string"
        },
        "check_duplicates": {
          "default": true,
          "description": "When true (default), error if two entries share a cite key (case-insensitive) — BibTeX silently keeps only the first, so a duplicate key is a real bug. Set false to format anyway.",
          "type": "boolean"
        },
        "indent": {
          "default": 2,
          "description": "Spaces to indent each field line, 0-16. Default 2.",
          "maximum": 16,
          "minimum": 0,
          "type": "integer"
        },
        "lowercase_type": {
          "default": true,
          "description": "When true (default), lowercase the entry type and the @string/@preamble/@comment keyword. Field names are always lowercased.",
          "type": "boolean"
        },
        "sort": {
          "default": "none",
          "description": "Reorder entries: 'none' (default) keeps source order; 'key' sorts case-insensitively by cite key; 'type-key' sorts by entry type then key. @string/@preamble/@comment items stay at the front.",
          "enum": [
            "none",
            "key",
            "type-key"
          ],
          "type": "string"
        },
        "sort_fields": {
          "default": false,
          "description": "When true, sort the fields within each entry alphabetically by name. Default false (keep source order).",
          "type": "boolean"
        }
      },
      "required": [
        "bibtex"
      ],
      "type": "object"
    }
  }
}