# pydantic 2.14.2 (MIT), harvested by tools/harvest_corpus.py
=== input
Generates a JSON schema for a model class.

        Args:
            by_alias: Whether to use field aliases as keys in the generated JSON Schema. If `None` (the default),
                aliases are used unless disabled by the configuration (i.e. `validate_by_alias=False` for validation
                schemas). An explicit value takes precedence over the configuration.
            ref_template: The reference template.
            union_format: The format to use when combining schemas from unions together. Can be one of:

                - `'any_of'`: Use the [`anyOf`](https://json-schema.org/understanding-json-schema/reference/combining#anyOf)
                keyword to combine schemas (the default).
                - `'primitive_type_array'`: Use the [`type`](https://json-schema.org/understanding-json-schema/reference/type)
                keyword as an array of strings, containing each type of the combination. If any of the schemas is not a primitive
                type (`string`, `boolean`, `null`, `integer` or `number`) or contains constraints/metadata, falls back to
                `any_of`.
            schema_generator: To override the logic used to generate the JSON schema, as a subclass of
                `GenerateJsonSchema` with your desired modifications
            mode: The mode in which to generate the schema.

        Returns:
            The JSON schema for the given model class.
        
=== parse google
short_description: 'Generates a JSON schema for a model class.'
blank_after_short_description: True
blank_after_long_description: False
style: google
- DocstringParam
  description: |
    Whether to use field aliases as keys in the generated JSON Schema. If `None` (the default),
    aliases are used unless disabled by the configuration (i.e. `validate_by_alias=False` for validation
    schemas). An explicit value takes precedence over the configuration.
  kind: param
  key: 'param'
  arg_name: 'by_alias'
  is_optional: False
- DocstringParam
  description: 'The reference template.'
  kind: param
  key: 'param'
  arg_name: 'ref_template'
  is_optional: False
- DocstringParam
  description: |
    The format to use when combining schemas from unions together. Can be one of:
    
    - `'any_of'`: Use the [`anyOf`](https://json-schema.org/understanding-json-schema/reference/combining#anyOf)
    keyword to combine schemas (the default).
    - `'primitive_type_array'`: Use the [`type`](https://json-schema.org/understanding-json-schema/reference/type)
    keyword as an array of strings, containing each type of the combination. If any of the schemas is not a primitive
    type (`string`, `boolean`, `null`, `integer` or `number`) or contains constraints/metadata, falls back to
    `any_of`.
  kind: param
  key: 'param'
  arg_name: 'union_format'
  is_optional: False
- DocstringParam
  description: |
    To override the logic used to generate the JSON schema, as a subclass of
    `GenerateJsonSchema` with your desired modifications
  kind: param
  key: 'param'
  arg_name: 'schema_generator'
  is_optional: False
- DocstringParam
  description: 'The mode in which to generate the schema.'
  kind: param
  key: 'param'
  arg_name: 'mode'
  is_optional: False
- DocstringReturns
  description: 'The JSON schema for the given model class.'
  kind: returns
  key: 'returns'
  is_generator: False
=== detect
google
=== compose google
Generates a JSON schema for a model class.

Args:
    by_alias: Whether to use field aliases as keys in the generated JSON Schema. If `None` (the default),
        aliases are used unless disabled by the configuration (i.e. `validate_by_alias=False` for validation
        schemas). An explicit value takes precedence over the configuration.
    ref_template: The reference template.
    union_format: The format to use when combining schemas from unions together. Can be one of:

        - `'any_of'`: Use the [`anyOf`](https://json-schema.org/understanding-json-schema/reference/combining#anyOf)
        keyword to combine schemas (the default).
        - `'primitive_type_array'`: Use the [`type`](https://json-schema.org/understanding-json-schema/reference/type)
        keyword as an array of strings, containing each type of the combination. If any of the schemas is not a primitive
        type (`string`, `boolean`, `null`, `integer` or `number`) or contains constraints/metadata, falls back to
        `any_of`.
    schema_generator: To override the logic used to generate the JSON schema, as a subclass of
        `GenerateJsonSchema` with your desired modifications
    mode: The mode in which to generate the schema.

Returns:
    The JSON schema for the given model class.
