{
  "version": 1,
  "format": "json",
  "kind": "recommend-options",
  "mode": "quick",
  "rules_revision": "2026-10-18",
  "calibrated_presets": "20261017",
  "input": {
    "source": "file",
    "input_file_type": "openapi",
    "document": "OpenAPI 3.0.3",
    "analysed": true
  },
  "context": {
    "output_model_type": "pydantic_v2.BaseModel",
    "target_python_version": "3.14"
  },
  "signals": {
    "all_enums": 0,
    "boolean_exclusive_bounds": 1,
    "coercible_scalars": 5,
    "component_enums": 0,
    "component_title_duplicate_groups": 0,
    "component_titles_equal_other_key": 0,
    "component_titles_equal_own_key": 0,
    "component_titles_in_duplicate_groups": 0,
    "components": 1,
    "decimal_formats": 1,
    "discriminated_unions": 0,
    "dotted_key_namespaces": 0,
    "dotted_keys": 0,
    "dotted_namespace_reference_cycles": 0,
    "duplicate_inline_enum_shapes": 0,
    "duplicate_inline_enums": 0,
    "duplicate_inline_objects": 0,
    "duplicate_inline_shapes": 0,
    "estimated_models": 1,
    "formats": 6,
    "inline_enums": 0,
    "inline_names_equal_component": 0,
    "inline_object_union_variants": 0,
    "inline_objects": 0,
    "inline_scalar_union_variants": 0,
    "inline_tagged_union_branches": 0,
    "inline_title_max_repeat": 0,
    "inline_titled_objects": 0,
    "inline_titled_union_variants": 0,
    "inline_union_variants": 0,
    "integer_range_formats": 2,
    "max_inline_depth": 0,
    "multiple_of": 2,
    "nullable_keywords": 1,
    "operations": 0,
    "parent_copy_union_branches": 0,
    "pattern_properties": 0,
    "root_is_object": 0,
    "root_title_words": 0,
    "shared_inline_enum_names": 0,
    "shared_inline_names": 0,
    "shared_inline_object_names": 0,
    "single_key_required_open": 0,
    "single_key_union_branches": 0,
    "single_value_enum_union_branches": 0,
    "single_value_enums": 0,
    "tagged_behind_ref": 0,
    "titled_components": 0,
    "unions": 0,
    "unique_items": 1,
    "unmodeled_pattern_properties": 0
  },
  "facts": {
    "schema": "OpenAPI 3.0.3",
    "scopes": "schemas",
    "shared_inline_name_examples": "",
    "inline_title_examples": "",
    "duplicate_title_examples": "",
    "key_style": "PascalCase (1 of 1)",
    "root_title": "",
    "format_examples": "uuid x1, decimal x1, int32 x1, int64 x1"
  },
  "baseline": {
    "preset": "standard-py314-20261017",
    "family": "standard",
    "configured": false,
    "covers": []
  },
  "recommendations": [],
  "left_out": [],
  "consider": [],
  "validation": [
    {
      "rule": "validation.check-unique-items-and-pattern-properties",
      "decision": "schema-validators",
      "set": {
        "generate_schema_validators": true
      },
      "arguments": [
        "--generate-schema-validators"
      ],
      "reason": "The models leave out checks the schema declares (uniqueItems: 1; patternProperties that a typed map cannot express, beside declared properties, with several patterns, or with other keys allowed: 0 of 0): duplicate items pass, and those properties are checked wrongly or not at all. The experimental schema validators check both when a model validates.",
      "contested_reason": null,
      "caveats": [
        "Experimental: on some schemas the generated validators reject valid data or fail to import; validate sample data with the generated models before adopting it."
      ],
      "evidence": [
        "SchemaStore tsconfig and dependabot schemas, compose spec: 13 documents checked against the schemas, 5 judged wrongly by the preset (3 with duplicate items accepted, 2 with x- extension keys rejected), 0 with the validators",
        "Six patternProperties shapes a typed map cannot express (other keys allowed, several patterns, declared properties beside them), 22 documents: 7 judged wrongly by the preset, 0 with the validators; one pattern on a closed object without declared properties is exact without them"
      ],
      "trial": null
    }
  ],
  "policy": [
    {
      "rule": "policy.strict-scalar-types",
      "decision": "strict-types",
      "set": {
        "strict_types": [
          "int",
          "float",
          "bool"
        ]
      },
      "arguments": [
        "--strict-types",
        "int",
        "float",
        "bool"
      ],
      "reason": "Pydantic validates in lax mode, which coerces input into the 5 integer, number and boolean schemas: it accepts the string \"5\" and true as integers, \"1.5\" as a number, and \"true\" or 1 as booleans. Strict types reject such input. Whether to accept it depends on the project's clients, not on the schema; strict int also rejects 5.0, which JSON Schema counts as an integer, so leave int out to accept it.",
      "contested_reason": null,
      "caveats": [],
      "evidence": [
        "11 JSON documents for integer, number, boolean and string properties, 6 of them invalid: lax mode accepted 5 invalid ones; with int float bool, 0 accepted and 1 valid one rejected (5.0 as an integer); with float bool, 2 accepted (\"5\" and true as integers) and none rejected"
      ],
      "trial": null
    }
  ],
  "not_recommended": [],
  "disagreements": [],
  "trial": null,
  "notes": [],
  "arguments": [
    "--input",
    "validation.yaml",
    "--preset",
    "standard-py314-20261017",
    "--target-python-version",
    "3.14"
  ],
  "config": {
    "tool": {
      "datamodel-codegen": {
        "input": "validation.yaml",
        "preset": "standard-py314-20261017",
        "target-python-version": "3.14"
      }
    }
  },
  "config_complete": true,
  "content": "Option recommendations (experimental; quick mode; rules 2026-10-18)\n\nSchema  OpenAPI 3.0.3 (OpenAPI scopes: schemas)\n  components                       1, 0 operations\n  inline objects / enums           0 / 0, nesting depth 0\n  shared property names            0 (none)\n  inline names = component names   0\n  repeated inline objects / enums  0 of 0 shapes / 0 of 0 value sets\n  titled components                0: 0 shared titles (none), 0 equal another key, 0 equal their own key\n  inline titles                    0 objects, most repeated 0 (none)\n  unions                           0 oneOf/anyOf, 0 with a discriminator, 0 inline variants\n  union branch tags                0 tagged, 0 single required key, 0 tagged only through allOf $ref, 0 copy their parent\n  component keys                   PascalCase (1 of 1); 0 dotted in 0 namespaces\n  constraint keywords              uniqueItems 1, patternProperties 0 (0 beyond a typed map), multipleOf 2, OpenAPI 3.0 nullable 1, boolean exclusive bounds 1\n  formats                          6 (uuid x1, decimal x1, int32 x1, int64 x1), decimal 1; int32/int64 2, ranges not enforced\n  integer/number/boolean schemas   5\n\nStart from  --preset standard-py314-20261017\n\nAdd  nothing on top of the preset\n\nOptional (validation; not in the command)\n  --generate-schema-validators   [validation.check-unique-items-and-pattern-properties]\n      The models leave out checks the schema declares (uniqueItems: 1; patternProperties that a\n      typed map cannot express, beside declared properties, with several patterns, or with other\n      keys allowed: 0 of 0): duplicate items pass, and those properties are checked wrongly or not\n      at all. The experimental schema validators check both when a model validates.\n      caveat: Experimental: on some schemas the generated validators reject valid data or fail to\n      import; validate sample data with the generated models before adopting it.\n      measured: SchemaStore tsconfig and dependabot schemas, compose spec: 13 documents checked\n      against the schemas, 5 judged wrongly by the preset (3 with duplicate items accepted, 2 with\n      x- extension keys rejected), 0 with the validators\n      measured: Six patternProperties shapes a typed map cannot express (other keys allowed, several\n      patterns, declared properties beside them), 22 documents: 7 judged wrongly by the preset, 0\n      with the validators; one pattern on a closed object without declared properties is exact\n      without them\n\nOptional (policy; not in the command)\n  --strict-types int float bool   [policy.strict-scalar-types]\n      Pydantic validates in lax mode, which coerces input into the 5 integer, number and boolean\n      schemas: it accepts the string \"5\" and true as integers, \"1.5\" as a number, and \"true\" or 1 as\n      booleans. Strict types reject such input. Whether to accept it depends on the project's\n      clients, not on the schema; strict int also rejects 5.0, which JSON Schema counts as an\n      integer, so leave int out to accept it.\n      measured: 11 JSON documents for integer, number, boolean and string properties, 6 of them\n      invalid: lax mode accepted 5 invalid ones; with int float bool, 0 accepted and 1 valid one\n      rejected (5.0 as an integer); with float bool, 2 accepted (\"5\" and true as integers) and none\n      rejected\n\nCommand\n  datamodel-codegen --input validation.yaml --preset standard-py314-20261017 --target-python-version 3.14\n\npyproject.toml\n  [tool.datamodel-codegen]\n  input = \"validation.yaml\"\n  preset = \"standard-py314-20261017\"\n  target-python-version = \"3.14\"\n"
}
