{
  "type": "minecraft:min",
  "argument1": {
    "type": "minecraft:squeeze",
    "argument": {
      "type": "minecraft:mul",
      "argument1": 0.64,
      "argument2": {
        "type": "minecraft:interpolated",
        "argument": {
          "type": "minecraft:blend_density",
          "argument": {
            "type": "minecraft:add",
            "argument1": 0.1171875,
            "argument2": {
              "type": "minecraft:mul",
              "argument1": {
                "type": "minecraft:y_clamped_gradient",
                "from_value": 0.0,
                "from_y": -64,
                "to_value": 1.0,
                "to_y": -40
              },
              "argument2": {
                "type": "minecraft:add",
                "argument1": -0.1171875,
                "argument2": {
                  "type": "minecraft:add",
                  "argument1": -0.078125,
                  "argument2": {
                    "type": "minecraft:mul",
                    "argument1": {
                      "type": "minecraft:y_clamped_gradient",
                      "from_value": 1.0,
                      "from_y": 250,
                      "to_value": 0.0,
                      "to_y": 292
                    },
                    "argument2": {
                      "type": "minecraft:add",
                      "argument1": 0.078125,
                      "argument2": {
                        "type": "minecraft:range_choice",
                        "input": "minecraft:overworld/sloped_cheese",
                        "min_inclusive": -1000000.0,
                        "max_exclusive": 1.5625,
                        "when_in_range": {
                          "type": "minecraft:min",
                          "argument1": {
                            "type": "minecraft:max",
                            "argument1": {
                              "type": "minecraft:add",
                              "argument1": "minecraft:overworld/sloped_cheese",
                              "argument2": {
                                "type": "minecraft:beardifier"
                              }
                            },
                            "argument2": "terralith:overworld/extra_terrain_sum"
                          },
                          "argument2": {
                            "type": "minecraft:mul",
                            "argument1": 5,
                            "argument2": {
                              "type": "minecraft:min",
                              "argument1": "minecraft:overworld/caves/entrances",
                              "argument2": "terralith:overworld/subtract_terrain_sum"
                            }
                          }
                        },
                        "when_out_of_range": {
                          "type": "minecraft:min",
                          "argument1": {
                            "type": "minecraft:max",
                            "argument1": {
                              "type": "minecraft:min",
                              "argument1": {
                                "type": "minecraft:min",
                                "argument1": {
                                  "type": "minecraft:add",
                                  "argument1": {
                                    "type": "minecraft:mul",
                                    "argument1": 4.0,
                                    "argument2": {
                                      "type": "minecraft:square",
                                      "argument": {
                                        "type": "minecraft:noise",
                                        "noise": "minecraft:cave_layer",
                                        "xz_scale": 1.0,
                                        "y_scale": 8.0
                                      }
                                    }
                                  },
                                  "argument2": {
                                    "type": "minecraft:add",
                                    "argument1": "terralith:overworld/reference/cave_cheese",
                                    "argument2": {
                                      "type": "minecraft:clamp",
                                      "input": {
                                        "type": "minecraft:add",
                                        "argument1": 1.5,
                                        "argument2": {
                                          "type": "minecraft:mul",
                                          "argument1": -0.64,
                                          "argument2": "minecraft:overworld/sloped_cheese"
                                        }
                                      },
                                      "max": 0.5,
                                      "min": 0.0
                                    }
                                  }
                                },
                                "argument2": "minecraft:overworld/caves/entrances"
                              },
                              "argument2": {
                                "type": "minecraft:add",
                                "argument1": "minecraft:overworld/caves/spaghetti_2d",
                                "argument2": "minecraft:overworld/caves/spaghetti_roughness_function"
                              }
                            },
                            "argument2": {
                              "type": "minecraft:range_choice",
                              "input": "minecraft:overworld/caves/pillars",
                              "min_inclusive": -1000000.0,
                              "max_exclusive": 0.03,
                              "when_in_range": -1000000.0,
                              "when_out_of_range": "minecraft:overworld/caves/pillars"
                            }
                          },
                          "argument2": "terralith:overworld/subtract_terrain_sum"
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "argument2": "minecraft:overworld/caves/noodle"
}