packages feed

hydra-kernel-0.18.1: hydra-kernel-json/hydra/core/decode/diff.json

{
  "name": "hydra.core.decode.diff",
  "metadata": {"description": "Term decoders for hydra.core.diff", "comments": [], "seeAlso": [], "provisions": []},
  "dependencies": [
    {"module": "hydra.core.extract.model"},
    {"module": "hydra.core.lexical"},
    {"module": "hydra.core.rewriting"},
    {"module": "hydra.core.diff"},
    {"module": "hydra.core.util"}],
  "definitions": [
    {
      "term": {
        "name": "hydra.core.decode.diff.edit",
        "signature": {
          "typeParameters": [{"name": "a", "constraints": []}, {"name": "s", "constraints": []}],
          "parameters": [
            {
              "name": "arg0",
              "type": {
                "function": {
                  "domain": {"variable": "hydra.core.graph.Graph"},
                  "codomain": {
                    "function": {
                      "domain": {"variable": "hydra.core.model.Term"},
                      "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "a"}}}}}}},
              "isLazy": false},
            {
              "name": "arg1",
              "type": {
                "function": {
                  "domain": {"variable": "hydra.core.graph.Graph"},
                  "codomain": {
                    "function": {
                      "domain": {"variable": "hydra.core.model.Term"},
                      "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "s"}}}}}}},
              "isLazy": false},
            {"name": "arg2", "type": {"variable": "hydra.core.graph.Graph"}, "isLazy": false},
            {"name": "arg3", "type": {"variable": "hydra.core.model.Term"}, "isLazy": false}],
          "result": {
            "type": {
              "either": {
                "left": {"variable": "hydra.core.errors.DecodingError"},
                "right": {
                  "application": {
                    "function": {"application": {"function": {"variable": "hydra.core.diff.Edit"}, "argument": {"variable": "a"}}},
                    "argument": {"variable": "s"}}}}}}},
        "body": {
          "annotated": {
            "body": {
              "lambda": {
                "parameter": "a",
                "domain": {
                  "function": {
                    "domain": {"variable": "hydra.core.graph.Graph"},
                    "codomain": {
                      "function": {
                        "domain": {"variable": "hydra.core.model.Term"},
                        "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "a"}}}}}}},
                "body": {
                  "lambda": {
                    "parameter": "s",
                    "domain": {
                      "function": {
                        "domain": {"variable": "hydra.core.graph.Graph"},
                        "codomain": {
                          "function": {
                            "domain": {"variable": "hydra.core.model.Term"},
                            "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "s"}}}}}}},
                    "body": {
                      "lambda": {
                        "parameter": "cx",
                        "domain": {"variable": "hydra.core.graph.Graph"},
                        "body": {
                          "lambda": {
                            "parameter": "raw",
                            "domain": {"variable": "hydra.core.model.Term"},
                            "body": {
                              "application": {
                                "function": {
                                  "application": {
                                    "function": {
                                      "application": {
                                        "function": {
                                          "typeApplication": {
                                            "body": {
                                              "typeApplication": {
                                                "body": {
                                                  "typeApplication": {"body": {"variable": "hydra.core.lib.eithers.either"}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                "type": {"variable": "hydra.core.model.Term"}}},
                                            "type": {
                                              "either": {
                                                "left": {"variable": "hydra.core.errors.DecodingError"},
                                                "right": {
                                                  "application": {
                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.Edit"}, "argument": {"variable": "a"}}},
                                                    "argument": {"variable": "s"}}}}}}},
                                        "argument": {
                                          "lambda": {
                                            "parameter": "err",
                                            "domain": {"variable": "hydra.core.errors.DecodingError"},
                                            "body": {
                                              "typeApplication": {
                                                "body": {
                                                  "typeApplication": {"body": {"either": {"left": {"variable": "err"}}}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                "type": {
                                                  "application": {
                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.Edit"}, "argument": {"variable": "a"}}},
                                                    "argument": {"variable": "s"}}}}}}}}},
                                    "argument": {
                                      "lambda": {
                                        "parameter": "stripped",
                                        "domain": {"variable": "hydra.core.model.Term"},
                                        "body": {
                                          "application": {
                                            "function": {
                                              "cases": {
                                                "typeName": "hydra.core.model.Term",
                                                "default": {
                                                  "typeApplication": {
                                                    "body": {
                                                      "typeApplication": {
                                                        "body": {
                                                          "either": {"left": {"wrap": {"typeName": "hydra.core.errors.DecodingError", "body": {"literal": {"string": "expected union"}}}}}},
                                                        "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                    "type": {
                                                      "application": {
                                                        "function": {"application": {"function": {"variable": "hydra.core.diff.Edit"}, "argument": {"variable": "a"}}},
                                                        "argument": {"variable": "s"}}}}},
                                                "cases": [
                                                  {
                                                    "name": "inject",
                                                    "handler": {
                                                      "lambda": {
                                                        "parameter": "inj",
                                                        "domain": {"variable": "hydra.core.model.Injection"},
                                                        "body": {
                                                          "let": {
                                                            "bindings": [
                                                              {
                                                                "name": "field",
                                                                "term": {
                                                                  "application": {
                                                                    "function": {"project": {"typeName": "hydra.core.model.Injection", "fieldName": "field"}},
                                                                    "argument": {"variable": "inj"}}},
                                                                "typeScheme": {"variables": [], "body": {"variable": "hydra.core.model.Field"}, "constraints": []}},
                                                              {
                                                                "name": "fname",
                                                                "term": {
                                                                  "application": {
                                                                    "function": {"project": {"typeName": "hydra.core.model.Field", "fieldName": "name"}},
                                                                    "argument": {"variable": "field"}}},
                                                                "typeScheme": {"variables": [], "body": {"variable": "hydra.core.model.Name"}, "constraints": []}},
                                                              {
                                                                "name": "fterm",
                                                                "term": {
                                                                  "application": {
                                                                    "function": {"project": {"typeName": "hydra.core.model.Field", "fieldName": "term"}},
                                                                    "argument": {"variable": "field"}}},
                                                                "typeScheme": {"variables": [], "body": {"variable": "hydra.core.model.Term"}, "constraints": []}},
                                                              {
                                                                "name": "variantMap",
                                                                "term": {
                                                                  "application": {
                                                                    "function": {
                                                                      "typeApplication": {
                                                                        "body": {
                                                                          "typeApplication": {"body": {"variable": "hydra.core.lib.maps.fromList"}, "type": {"variable": "hydra.core.model.Name"}}},
                                                                        "type": {
                                                                          "function": {
                                                                            "domain": {"variable": "hydra.core.model.Term"},
                                                                            "codomain": {
                                                                              "either": {
                                                                                "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                                "right": {
                                                                                  "application": {
                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.Edit"}, "argument": {"variable": "a"}}},
                                                                                    "argument": {"variable": "s"}}}}}}}}},
                                                                    "argument": {
                                                                      "list": [
                                                                        {
                                                                          "typeApplication": {
                                                                            "body": {
                                                                              "typeApplication": {
                                                                                "body": {
                                                                                  "pair": {
                                                                                    "first": {"wrap": {"typeName": "hydra.core.model.Name", "body": {"literal": {"string": "retain"}}}},
                                                                                    "second": {
                                                                                      "lambda": {
                                                                                        "parameter": "input",
                                                                                        "domain": {"variable": "hydra.core.model.Term"},
                                                                                        "body": {
                                                                                          "application": {
                                                                                            "function": {
                                                                                              "application": {
                                                                                                "function": {
                                                                                                  "typeApplication": {
                                                                                                    "body": {
                                                                                                      "typeApplication": {
                                                                                                        "body": {"typeApplication": {"body": {"variable": "hydra.core.lib.eithers.map"}, "type": "unit"}},
                                                                                                        "type": {
                                                                                                          "application": {
                                                                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.Edit"}, "argument": {"variable": "a"}}},
                                                                                                            "argument": {"variable": "s"}}}}},
                                                                                                    "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                                "argument": {
                                                                                                  "lambda": {
                                                                                                    "parameter": "t",
                                                                                                    "domain": "unit",
                                                                                                    "body": {"inject": {"typeName": "hydra.core.diff.Edit", "field": {"name": "retain", "term": {"variable": "t"}}}}}}}},
                                                                                            "argument": {
                                                                                              "application": {
                                                                                                "function": {
                                                                                                  "application": {
                                                                                                    "function": {
                                                                                                      "lambda": {
                                                                                                        "parameter": "cx",
                                                                                                        "domain": {"variable": "hydra.core.graph.Graph"},
                                                                                                        "body": {
                                                                                                          "lambda": {
                                                                                                            "parameter": "t",
                                                                                                            "domain": {"variable": "hydra.core.model.Term"},
                                                                                                            "body": {
                                                                                                              "application": {
                                                                                                                "function": {"application": {"function": {"variable": "hydra.core.extract.model.decodeUnit"}, "argument": {"variable": "cx"}}},
                                                                                                                "argument": {"variable": "t"}}}}}}},
                                                                                                    "argument": {"variable": "cx"}}},
                                                                                                "argument": {"variable": "input"}}}}}}}}},
                                                                                "type": {"variable": "hydra.core.model.Name"}}},
                                                                            "type": {
                                                                              "function": {
                                                                                "domain": {"variable": "hydra.core.model.Term"},
                                                                                "codomain": {
                                                                                  "either": {
                                                                                    "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                                    "right": {
                                                                                      "application": {
                                                                                        "function": {"application": {"function": {"variable": "hydra.core.diff.Edit"}, "argument": {"variable": "a"}}},
                                                                                        "argument": {"variable": "s"}}}}}}}}},
                                                                        {
                                                                          "typeApplication": {
                                                                            "body": {
                                                                              "typeApplication": {
                                                                                "body": {
                                                                                  "pair": {
                                                                                    "first": {"wrap": {"typeName": "hydra.core.model.Name", "body": {"literal": {"string": "set"}}}},
                                                                                    "second": {
                                                                                      "lambda": {
                                                                                        "parameter": "input",
                                                                                        "domain": {"variable": "hydra.core.model.Term"},
                                                                                        "body": {
                                                                                          "application": {
                                                                                            "function": {
                                                                                              "application": {
                                                                                                "function": {
                                                                                                  "typeApplication": {
                                                                                                    "body": {
                                                                                                      "typeApplication": {
                                                                                                        "body": {"typeApplication": {"body": {"variable": "hydra.core.lib.eithers.map"}, "type": {"variable": "a"}}},
                                                                                                        "type": {
                                                                                                          "application": {
                                                                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.Edit"}, "argument": {"variable": "a"}}},
                                                                                                            "argument": {"variable": "s"}}}}},
                                                                                                    "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                                "argument": {
                                                                                                  "lambda": {
                                                                                                    "parameter": "t",
                                                                                                    "domain": {"variable": "a"},
                                                                                                    "body": {"inject": {"typeName": "hydra.core.diff.Edit", "field": {"name": "set", "term": {"variable": "t"}}}}}}}},
                                                                                            "argument": {
                                                                                              "application": {
                                                                                                "function": {"application": {"function": {"variable": "a"}, "argument": {"variable": "cx"}}},
                                                                                                "argument": {"variable": "input"}}}}}}}}},
                                                                                "type": {"variable": "hydra.core.model.Name"}}},
                                                                            "type": {
                                                                              "function": {
                                                                                "domain": {"variable": "hydra.core.model.Term"},
                                                                                "codomain": {
                                                                                  "either": {
                                                                                    "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                                    "right": {
                                                                                      "application": {
                                                                                        "function": {"application": {"function": {"variable": "hydra.core.diff.Edit"}, "argument": {"variable": "a"}}},
                                                                                        "argument": {"variable": "s"}}}}}}}}},
                                                                        {
                                                                          "typeApplication": {
                                                                            "body": {
                                                                              "typeApplication": {
                                                                                "body": {
                                                                                  "pair": {
                                                                                    "first": {"wrap": {"typeName": "hydra.core.model.Name", "body": {"literal": {"string": "delete"}}}},
                                                                                    "second": {
                                                                                      "lambda": {
                                                                                        "parameter": "input",
                                                                                        "domain": {"variable": "hydra.core.model.Term"},
                                                                                        "body": {
                                                                                          "application": {
                                                                                            "function": {
                                                                                              "application": {
                                                                                                "function": {
                                                                                                  "typeApplication": {
                                                                                                    "body": {
                                                                                                      "typeApplication": {
                                                                                                        "body": {"typeApplication": {"body": {"variable": "hydra.core.lib.eithers.map"}, "type": "unit"}},
                                                                                                        "type": {
                                                                                                          "application": {
                                                                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.Edit"}, "argument": {"variable": "a"}}},
                                                                                                            "argument": {"variable": "s"}}}}},
                                                                                                    "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                                "argument": {
                                                                                                  "lambda": {
                                                                                                    "parameter": "t",
                                                                                                    "domain": "unit",
                                                                                                    "body": {"inject": {"typeName": "hydra.core.diff.Edit", "field": {"name": "delete", "term": {"variable": "t"}}}}}}}},
                                                                                            "argument": {
                                                                                              "application": {
                                                                                                "function": {
                                                                                                  "application": {
                                                                                                    "function": {
                                                                                                      "lambda": {
                                                                                                        "parameter": "cx",
                                                                                                        "domain": {"variable": "hydra.core.graph.Graph"},
                                                                                                        "body": {
                                                                                                          "lambda": {
                                                                                                            "parameter": "t",
                                                                                                            "domain": {"variable": "hydra.core.model.Term"},
                                                                                                            "body": {
                                                                                                              "application": {
                                                                                                                "function": {"application": {"function": {"variable": "hydra.core.extract.model.decodeUnit"}, "argument": {"variable": "cx"}}},
                                                                                                                "argument": {"variable": "t"}}}}}}},
                                                                                                    "argument": {"variable": "cx"}}},
                                                                                                "argument": {"variable": "input"}}}}}}}}},
                                                                                "type": {"variable": "hydra.core.model.Name"}}},
                                                                            "type": {
                                                                              "function": {
                                                                                "domain": {"variable": "hydra.core.model.Term"},
                                                                                "codomain": {
                                                                                  "either": {
                                                                                    "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                                    "right": {
                                                                                      "application": {
                                                                                        "function": {"application": {"function": {"variable": "hydra.core.diff.Edit"}, "argument": {"variable": "a"}}},
                                                                                        "argument": {"variable": "s"}}}}}}}}},
                                                                        {
                                                                          "typeApplication": {
                                                                            "body": {
                                                                              "typeApplication": {
                                                                                "body": {
                                                                                  "pair": {
                                                                                    "first": {"wrap": {"typeName": "hydra.core.model.Name", "body": {"literal": {"string": "descend"}}}},
                                                                                    "second": {
                                                                                      "lambda": {
                                                                                        "parameter": "input",
                                                                                        "domain": {"variable": "hydra.core.model.Term"},
                                                                                        "body": {
                                                                                          "application": {
                                                                                            "function": {
                                                                                              "application": {
                                                                                                "function": {
                                                                                                  "typeApplication": {
                                                                                                    "body": {
                                                                                                      "typeApplication": {
                                                                                                        "body": {
                                                                                                          "typeApplication": {
                                                                                                            "body": {"variable": "hydra.core.lib.eithers.map"},
                                                                                                            "type": {
                                                                                                              "list": {
                                                                                                                "application": {
                                                                                                                  "function": {"application": {"function": {"variable": "hydra.core.diff.StepEdit"}, "argument": {"variable": "a"}}},
                                                                                                                  "argument": {"variable": "s"}}}}}},
                                                                                                        "type": {
                                                                                                          "application": {
                                                                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.Edit"}, "argument": {"variable": "a"}}},
                                                                                                            "argument": {"variable": "s"}}}}},
                                                                                                    "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                                "argument": {
                                                                                                  "lambda": {
                                                                                                    "parameter": "t",
                                                                                                    "domain": {
                                                                                                      "list": {
                                                                                                        "application": {
                                                                                                          "function": {"application": {"function": {"variable": "hydra.core.diff.StepEdit"}, "argument": {"variable": "a"}}},
                                                                                                          "argument": {"variable": "s"}}}},
                                                                                                    "body": {"inject": {"typeName": "hydra.core.diff.Edit", "field": {"name": "descend", "term": {"variable": "t"}}}}}}}},
                                                                                            "argument": {
                                                                                              "application": {
                                                                                                "function": {
                                                                                                  "application": {
                                                                                                    "function": {
                                                                                                      "application": {
                                                                                                        "function": {
                                                                                                          "typeApplication": {
                                                                                                            "body": {"variable": "hydra.core.extract.model.decodeList"},
                                                                                                            "type": {
                                                                                                              "application": {
                                                                                                                "function": {"application": {"function": {"variable": "hydra.core.diff.StepEdit"}, "argument": {"variable": "a"}}},
                                                                                                                "argument": {"variable": "s"}}}}},
                                                                                                        "argument": {
                                                                                                          "application": {
                                                                                                            "function": {
                                                                                                              "typeApplication": {
                                                                                                                "body": {
                                                                                                                  "application": {
                                                                                                                    "function": {"typeApplication": {"body": {"variable": "hydra.core.decode.diff.stepEdit"}, "type": {"variable": "a"}}},
                                                                                                                    "argument": {"variable": "a"}}},
                                                                                                                "type": {"variable": "s"}}},
                                                                                                            "argument": {"variable": "s"}}}}},
                                                                                                    "argument": {"variable": "cx"}}},
                                                                                                "argument": {"variable": "input"}}}}}}}}},
                                                                                "type": {"variable": "hydra.core.model.Name"}}},
                                                                            "type": {
                                                                              "function": {
                                                                                "domain": {"variable": "hydra.core.model.Term"},
                                                                                "codomain": {
                                                                                  "either": {
                                                                                    "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                                    "right": {
                                                                                      "application": {
                                                                                        "function": {"application": {"function": {"variable": "hydra.core.diff.Edit"}, "argument": {"variable": "a"}}},
                                                                                        "argument": {"variable": "s"}}}}}}}}}]}}},
                                                                "typeScheme": {
                                                                  "variables": [],
                                                                  "body": {
                                                                    "map": {
                                                                      "keys": {"variable": "hydra.core.model.Name"},
                                                                      "values": {
                                                                        "function": {
                                                                          "domain": {"variable": "hydra.core.model.Term"},
                                                                          "codomain": {
                                                                            "either": {
                                                                              "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                              "right": {
                                                                                "application": {
                                                                                  "function": {"application": {"function": {"variable": "hydra.core.diff.Edit"}, "argument": {"variable": "a"}}},
                                                                                  "argument": {"variable": "s"}}}}}}}}},
                                                                  "constraints": []}}],
                                                            "body": {
                                                              "application": {
                                                                "function": {
                                                                  "application": {
                                                                    "function": {
                                                                      "application": {
                                                                        "function": {
                                                                          "typeApplication": {
                                                                            "body": {
                                                                              "typeApplication": {
                                                                                "body": {"variable": "hydra.core.lib.optionals.match"},
                                                                                "type": {
                                                                                  "function": {
                                                                                    "domain": {"variable": "hydra.core.model.Term"},
                                                                                    "codomain": {
                                                                                      "either": {
                                                                                        "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                                        "right": {
                                                                                          "application": {
                                                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.Edit"}, "argument": {"variable": "a"}}},
                                                                                            "argument": {"variable": "s"}}}}}}}}},
                                                                            "type": {
                                                                              "either": {
                                                                                "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                                "right": {
                                                                                  "application": {
                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.Edit"}, "argument": {"variable": "a"}}},
                                                                                    "argument": {"variable": "s"}}}}}}},
                                                                        "argument": {
                                                                          "application": {
                                                                            "function": {
                                                                              "application": {
                                                                                "function": {
                                                                                  "typeApplication": {
                                                                                    "body": {"typeApplication": {"body": {"variable": "hydra.core.lib.maps.lookup"}, "type": {"variable": "hydra.core.model.Name"}}},
                                                                                    "type": {
                                                                                      "function": {
                                                                                        "domain": {"variable": "hydra.core.model.Term"},
                                                                                        "codomain": {
                                                                                          "either": {
                                                                                            "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                                            "right": {
                                                                                              "application": {
                                                                                                "function": {"application": {"function": {"variable": "hydra.core.diff.Edit"}, "argument": {"variable": "a"}}},
                                                                                                "argument": {"variable": "s"}}}}}}}}},
                                                                                "argument": {"variable": "fname"}}},
                                                                            "argument": {"variable": "variantMap"}}}}},
                                                                    "argument": {
                                                                      "typeApplication": {
                                                                        "body": {
                                                                          "typeApplication": {
                                                                            "body": {
                                                                              "either": {
                                                                                "left": {
                                                                                  "wrap": {
                                                                                    "typeName": "hydra.core.errors.DecodingError",
                                                                                    "body": {
                                                                                      "application": {
                                                                                        "function": {"variable": "hydra.core.lib.strings.concat"},
                                                                                        "argument": {
                                                                                          "list": [
                                                                                            {"literal": {"string": "no such field "}},
                                                                                            {"application": {"function": {"unwrap": "hydra.core.model.Name"}, "argument": {"variable": "fname"}}},
                                                                                            {"literal": {"string": " in union"}}]}}}}}}},
                                                                            "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                        "type": {
                                                                          "application": {
                                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.Edit"}, "argument": {"variable": "a"}}},
                                                                            "argument": {"variable": "s"}}}}}}},
                                                                "argument": {
                                                                  "lambda": {
                                                                    "parameter": "f",
                                                                    "domain": {
                                                                      "function": {
                                                                        "domain": {"variable": "hydra.core.model.Term"},
                                                                        "codomain": {
                                                                          "either": {
                                                                            "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                            "right": {
                                                                              "application": {
                                                                                "function": {"application": {"function": {"variable": "hydra.core.diff.Edit"}, "argument": {"variable": "a"}}},
                                                                                "argument": {"variable": "s"}}}}}}},
                                                                    "body": {"application": {"function": {"variable": "f"}, "argument": {"variable": "fterm"}}}}}}}}}}}}]}},
                                            "argument": {"variable": "stripped"}}}}}}},
                                "argument": {
                                  "application": {
                                    "function": {
                                      "application": {"function": {"variable": "hydra.core.extract.model.stripWithDecodingError"}, "argument": {"variable": "cx"}}},
                                    "argument": {"variable": "raw"}}}}}}}}}}}}},
            "annotation": {"map": [{"key": {"variable": "description"}, "value": {"literal": {"string": "Decoder for hydra.core.diff.Edit"}}}]}}}}},
    {
      "term": {
        "name": "hydra.core.decode.diff.hole",
        "signature": {
          "typeParameters": [{"name": "t", "constraints": []}, {"name": "s", "constraints": []}],
          "parameters": [
            {
              "name": "arg0",
              "type": {
                "function": {
                  "domain": {"variable": "hydra.core.graph.Graph"},
                  "codomain": {
                    "function": {
                      "domain": {"variable": "hydra.core.model.Term"},
                      "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "t"}}}}}}},
              "isLazy": false},
            {
              "name": "arg1",
              "type": {
                "function": {
                  "domain": {"variable": "hydra.core.graph.Graph"},
                  "codomain": {
                    "function": {
                      "domain": {"variable": "hydra.core.model.Term"},
                      "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "s"}}}}}}},
              "isLazy": false},
            {"name": "arg2", "type": {"variable": "hydra.core.graph.Graph"}, "isLazy": false},
            {"name": "arg3", "type": {"variable": "hydra.core.model.Term"}, "isLazy": false}],
          "result": {
            "type": {
              "either": {
                "left": {"variable": "hydra.core.errors.DecodingError"},
                "right": {
                  "application": {
                    "function": {"application": {"function": {"variable": "hydra.core.diff.Hole"}, "argument": {"variable": "t"}}},
                    "argument": {"variable": "s"}}}}}}},
        "body": {
          "annotated": {
            "body": {
              "lambda": {
                "parameter": "t",
                "domain": {
                  "function": {
                    "domain": {"variable": "hydra.core.graph.Graph"},
                    "codomain": {
                      "function": {
                        "domain": {"variable": "hydra.core.model.Term"},
                        "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "t"}}}}}}},
                "body": {
                  "lambda": {
                    "parameter": "s",
                    "domain": {
                      "function": {
                        "domain": {"variable": "hydra.core.graph.Graph"},
                        "codomain": {
                          "function": {
                            "domain": {"variable": "hydra.core.model.Term"},
                            "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "s"}}}}}}},
                    "body": {
                      "lambda": {
                        "parameter": "cx",
                        "domain": {"variable": "hydra.core.graph.Graph"},
                        "body": {
                          "lambda": {
                            "parameter": "raw",
                            "domain": {"variable": "hydra.core.model.Term"},
                            "body": {
                              "application": {
                                "function": {
                                  "application": {
                                    "function": {
                                      "application": {
                                        "function": {
                                          "typeApplication": {
                                            "body": {
                                              "typeApplication": {
                                                "body": {
                                                  "typeApplication": {"body": {"variable": "hydra.core.lib.eithers.either"}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                "type": {"variable": "hydra.core.model.Term"}}},
                                            "type": {
                                              "either": {
                                                "left": {"variable": "hydra.core.errors.DecodingError"},
                                                "right": {
                                                  "application": {
                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.Hole"}, "argument": {"variable": "t"}}},
                                                    "argument": {"variable": "s"}}}}}}},
                                        "argument": {
                                          "lambda": {
                                            "parameter": "err",
                                            "domain": {"variable": "hydra.core.errors.DecodingError"},
                                            "body": {
                                              "typeApplication": {
                                                "body": {
                                                  "typeApplication": {"body": {"either": {"left": {"variable": "err"}}}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                "type": {
                                                  "application": {
                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.Hole"}, "argument": {"variable": "t"}}},
                                                    "argument": {"variable": "s"}}}}}}}}},
                                    "argument": {
                                      "lambda": {
                                        "parameter": "stripped",
                                        "domain": {"variable": "hydra.core.model.Term"},
                                        "body": {
                                          "application": {
                                            "function": {
                                              "cases": {
                                                "typeName": "hydra.core.model.Term",
                                                "default": {
                                                  "typeApplication": {
                                                    "body": {
                                                      "typeApplication": {
                                                        "body": {
                                                          "either": {
                                                            "left": {
                                                              "wrap": {
                                                                "typeName": "hydra.core.errors.DecodingError",
                                                                "body": {"literal": {"string": "expected a record of type hydra.core.diff.Hole"}}}}}},
                                                        "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                    "type": {
                                                      "application": {
                                                        "function": {"application": {"function": {"variable": "hydra.core.diff.Hole"}, "argument": {"variable": "t"}}},
                                                        "argument": {"variable": "s"}}}}},
                                                "cases": [
                                                  {
                                                    "name": "record",
                                                    "handler": {
                                                      "lambda": {
                                                        "parameter": "record",
                                                        "domain": {"variable": "hydra.core.model.Record"},
                                                        "body": {
                                                          "let": {
                                                            "bindings": [
                                                              {
                                                                "name": "fieldMap",
                                                                "term": {"application": {"function": {"variable": "hydra.core.extract.model.toFieldMap"}, "argument": {"variable": "record"}}},
                                                                "typeScheme": {
                                                                  "variables": [],
                                                                  "body": {"map": {"keys": {"variable": "hydra.core.model.Name"}, "values": {"variable": "hydra.core.model.Term"}}},
                                                                  "constraints": []}}],
                                                            "body": {
                                                              "application": {
                                                                "function": {
                                                                  "application": {
                                                                    "function": {
                                                                      "typeApplication": {
                                                                        "body": {
                                                                          "typeApplication": {
                                                                            "body": {
                                                                              "typeApplication": {"body": {"variable": "hydra.core.lib.eithers.bind"}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                            "type": {"list": {"variable": "s"}}}},
                                                                        "type": {
                                                                          "application": {
                                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.Hole"}, "argument": {"variable": "t"}}},
                                                                            "argument": {"variable": "s"}}}}},
                                                                    "argument": {
                                                                      "application": {
                                                                        "function": {
                                                                          "application": {
                                                                            "function": {
                                                                              "application": {
                                                                                "function": {
                                                                                  "application": {
                                                                                    "function": {
                                                                                      "typeApplication": {
                                                                                        "body": {
                                                                                          "typeApplication": {
                                                                                            "body": {
                                                                                              "typeApplication": {"body": {"variable": "hydra.core.extract.model.requireField"}, "type": {"variable": "hydra.core.graph.Graph"}}},
                                                                                            "type": {"variable": "hydra.core.model.Term"}}},
                                                                                        "type": {"list": {"variable": "s"}}}},
                                                                                    "argument": {"literal": {"string": "path"}}}},
                                                                                "argument": {
                                                                                  "application": {
                                                                                    "function": {"typeApplication": {"body": {"variable": "hydra.core.extract.model.decodeList"}, "type": {"variable": "s"}}},
                                                                                    "argument": {"variable": "s"}}}}},
                                                                            "argument": {"variable": "fieldMap"}}},
                                                                        "argument": {"variable": "cx"}}}}},
                                                                "argument": {
                                                                  "lambda": {
                                                                    "parameter": "field_path",
                                                                    "domain": {"list": {"variable": "s"}},
                                                                    "body": {
                                                                      "application": {
                                                                        "function": {
                                                                          "application": {
                                                                            "function": {
                                                                              "typeApplication": {
                                                                                "body": {
                                                                                  "typeApplication": {
                                                                                    "body": {
                                                                                      "typeApplication": {"body": {"variable": "hydra.core.lib.eithers.bind"}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                    "type": {"variable": "t"}}},
                                                                                "type": {
                                                                                  "application": {
                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.Hole"}, "argument": {"variable": "t"}}},
                                                                                    "argument": {"variable": "s"}}}}},
                                                                            "argument": {
                                                                              "application": {
                                                                                "function": {
                                                                                  "application": {
                                                                                    "function": {
                                                                                      "application": {
                                                                                        "function": {
                                                                                          "application": {
                                                                                            "function": {
                                                                                              "typeApplication": {
                                                                                                "body": {
                                                                                                  "typeApplication": {
                                                                                                    "body": {
                                                                                                      "typeApplication": {"body": {"variable": "hydra.core.extract.model.requireField"}, "type": {"variable": "hydra.core.graph.Graph"}}},
                                                                                                    "type": {"variable": "hydra.core.model.Term"}}},
                                                                                                "type": {"variable": "t"}}},
                                                                                            "argument": {"literal": {"string": "type"}}}},
                                                                                        "argument": {"variable": "t"}}},
                                                                                    "argument": {"variable": "fieldMap"}}},
                                                                                "argument": {"variable": "cx"}}}}},
                                                                        "argument": {
                                                                          "lambda": {
                                                                            "parameter": "field_type",
                                                                            "domain": {"variable": "t"},
                                                                            "body": {
                                                                              "typeApplication": {
                                                                                "body": {
                                                                                  "typeApplication": {
                                                                                    "body": {
                                                                                      "either": {
                                                                                        "right": {
                                                                                          "record": {
                                                                                            "typeName": "hydra.core.diff.Hole",
                                                                                            "fields": [{"name": "path", "term": {"variable": "field_path"}}, {"name": "type", "term": {"variable": "field_type"}}]}}}},
                                                                                    "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                "type": {
                                                                                  "application": {
                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.Hole"}, "argument": {"variable": "t"}}},
                                                                                    "argument": {"variable": "s"}}}}}}}}}}}}}}}}}}]}},
                                            "argument": {"variable": "stripped"}}}}}}},
                                "argument": {
                                  "application": {
                                    "function": {
                                      "application": {"function": {"variable": "hydra.core.extract.model.stripWithDecodingError"}, "argument": {"variable": "cx"}}},
                                    "argument": {"variable": "raw"}}}}}}}}}}}}},
            "annotation": {"map": [{"key": {"variable": "description"}, "value": {"literal": {"string": "Decoder for hydra.core.diff.Hole"}}}]}}}}},
    {
      "term": {
        "name": "hydra.core.decode.diff.holeFiller",
        "signature": {
          "typeParameters": [{"name": "v", "constraints": []}, {"name": "s", "constraints": []}],
          "parameters": [
            {
              "name": "arg0",
              "type": {
                "function": {
                  "domain": {"variable": "hydra.core.graph.Graph"},
                  "codomain": {
                    "function": {
                      "domain": {"variable": "hydra.core.model.Term"},
                      "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "v"}}}}}}},
              "isLazy": false},
            {
              "name": "arg1",
              "type": {
                "function": {
                  "domain": {"variable": "hydra.core.graph.Graph"},
                  "codomain": {
                    "function": {
                      "domain": {"variable": "hydra.core.model.Term"},
                      "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "s"}}}}}}},
              "isLazy": false},
            {"name": "arg2", "type": {"variable": "hydra.core.graph.Graph"}, "isLazy": false},
            {"name": "arg3", "type": {"variable": "hydra.core.model.Term"}, "isLazy": false}],
          "result": {
            "type": {
              "either": {
                "left": {"variable": "hydra.core.errors.DecodingError"},
                "right": {
                  "application": {
                    "function": {"application": {"function": {"variable": "hydra.core.diff.HoleFiller"}, "argument": {"variable": "v"}}},
                    "argument": {"variable": "s"}}}}}}},
        "body": {
          "annotated": {
            "body": {
              "lambda": {
                "parameter": "v",
                "domain": {
                  "function": {
                    "domain": {"variable": "hydra.core.graph.Graph"},
                    "codomain": {
                      "function": {
                        "domain": {"variable": "hydra.core.model.Term"},
                        "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "v"}}}}}}},
                "body": {
                  "lambda": {
                    "parameter": "s",
                    "domain": {
                      "function": {
                        "domain": {"variable": "hydra.core.graph.Graph"},
                        "codomain": {
                          "function": {
                            "domain": {"variable": "hydra.core.model.Term"},
                            "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "s"}}}}}}},
                    "body": {
                      "lambda": {
                        "parameter": "cx",
                        "domain": {"variable": "hydra.core.graph.Graph"},
                        "body": {
                          "lambda": {
                            "parameter": "raw",
                            "domain": {"variable": "hydra.core.model.Term"},
                            "body": {
                              "application": {
                                "function": {
                                  "application": {
                                    "function": {
                                      "application": {
                                        "function": {
                                          "typeApplication": {
                                            "body": {
                                              "typeApplication": {
                                                "body": {
                                                  "typeApplication": {"body": {"variable": "hydra.core.lib.eithers.either"}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                "type": {"variable": "hydra.core.model.Term"}}},
                                            "type": {
                                              "either": {
                                                "left": {"variable": "hydra.core.errors.DecodingError"},
                                                "right": {
                                                  "application": {
                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.HoleFiller"}, "argument": {"variable": "v"}}},
                                                    "argument": {"variable": "s"}}}}}}},
                                        "argument": {
                                          "lambda": {
                                            "parameter": "err",
                                            "domain": {"variable": "hydra.core.errors.DecodingError"},
                                            "body": {
                                              "typeApplication": {
                                                "body": {
                                                  "typeApplication": {"body": {"either": {"left": {"variable": "err"}}}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                "type": {
                                                  "application": {
                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.HoleFiller"}, "argument": {"variable": "v"}}},
                                                    "argument": {"variable": "s"}}}}}}}}},
                                    "argument": {
                                      "lambda": {
                                        "parameter": "stripped",
                                        "domain": {"variable": "hydra.core.model.Term"},
                                        "body": {
                                          "application": {
                                            "function": {
                                              "cases": {
                                                "typeName": "hydra.core.model.Term",
                                                "default": {
                                                  "typeApplication": {
                                                    "body": {
                                                      "typeApplication": {
                                                        "body": {
                                                          "either": {
                                                            "left": {
                                                              "wrap": {
                                                                "typeName": "hydra.core.errors.DecodingError",
                                                                "body": {"literal": {"string": "expected a record of type hydra.core.diff.HoleFiller"}}}}}},
                                                        "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                    "type": {
                                                      "application": {
                                                        "function": {"application": {"function": {"variable": "hydra.core.diff.HoleFiller"}, "argument": {"variable": "v"}}},
                                                        "argument": {"variable": "s"}}}}},
                                                "cases": [
                                                  {
                                                    "name": "record",
                                                    "handler": {
                                                      "lambda": {
                                                        "parameter": "record",
                                                        "domain": {"variable": "hydra.core.model.Record"},
                                                        "body": {
                                                          "let": {
                                                            "bindings": [
                                                              {
                                                                "name": "fieldMap",
                                                                "term": {"application": {"function": {"variable": "hydra.core.extract.model.toFieldMap"}, "argument": {"variable": "record"}}},
                                                                "typeScheme": {
                                                                  "variables": [],
                                                                  "body": {"map": {"keys": {"variable": "hydra.core.model.Name"}, "values": {"variable": "hydra.core.model.Term"}}},
                                                                  "constraints": []}}],
                                                            "body": {
                                                              "application": {
                                                                "function": {
                                                                  "application": {
                                                                    "function": {
                                                                      "typeApplication": {
                                                                        "body": {
                                                                          "typeApplication": {
                                                                            "body": {
                                                                              "typeApplication": {"body": {"variable": "hydra.core.lib.eithers.bind"}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                            "type": {"list": {"variable": "s"}}}},
                                                                        "type": {
                                                                          "application": {
                                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.HoleFiller"}, "argument": {"variable": "v"}}},
                                                                            "argument": {"variable": "s"}}}}},
                                                                    "argument": {
                                                                      "application": {
                                                                        "function": {
                                                                          "application": {
                                                                            "function": {
                                                                              "application": {
                                                                                "function": {
                                                                                  "application": {
                                                                                    "function": {
                                                                                      "typeApplication": {
                                                                                        "body": {
                                                                                          "typeApplication": {
                                                                                            "body": {
                                                                                              "typeApplication": {"body": {"variable": "hydra.core.extract.model.requireField"}, "type": {"variable": "hydra.core.graph.Graph"}}},
                                                                                            "type": {"variable": "hydra.core.model.Term"}}},
                                                                                        "type": {"list": {"variable": "s"}}}},
                                                                                    "argument": {"literal": {"string": "path"}}}},
                                                                                "argument": {
                                                                                  "application": {
                                                                                    "function": {"typeApplication": {"body": {"variable": "hydra.core.extract.model.decodeList"}, "type": {"variable": "s"}}},
                                                                                    "argument": {"variable": "s"}}}}},
                                                                            "argument": {"variable": "fieldMap"}}},
                                                                        "argument": {"variable": "cx"}}}}},
                                                                "argument": {
                                                                  "lambda": {
                                                                    "parameter": "field_path",
                                                                    "domain": {"list": {"variable": "s"}},
                                                                    "body": {
                                                                      "application": {
                                                                        "function": {
                                                                          "application": {
                                                                            "function": {
                                                                              "typeApplication": {
                                                                                "body": {
                                                                                  "typeApplication": {
                                                                                    "body": {
                                                                                      "typeApplication": {"body": {"variable": "hydra.core.lib.eithers.bind"}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                    "type": {"variable": "v"}}},
                                                                                "type": {
                                                                                  "application": {
                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.HoleFiller"}, "argument": {"variable": "v"}}},
                                                                                    "argument": {"variable": "s"}}}}},
                                                                            "argument": {
                                                                              "application": {
                                                                                "function": {
                                                                                  "application": {
                                                                                    "function": {
                                                                                      "application": {
                                                                                        "function": {
                                                                                          "application": {
                                                                                            "function": {
                                                                                              "typeApplication": {
                                                                                                "body": {
                                                                                                  "typeApplication": {
                                                                                                    "body": {
                                                                                                      "typeApplication": {"body": {"variable": "hydra.core.extract.model.requireField"}, "type": {"variable": "hydra.core.graph.Graph"}}},
                                                                                                    "type": {"variable": "hydra.core.model.Term"}}},
                                                                                                "type": {"variable": "v"}}},
                                                                                            "argument": {"literal": {"string": "value"}}}},
                                                                                        "argument": {"variable": "v"}}},
                                                                                    "argument": {"variable": "fieldMap"}}},
                                                                                "argument": {"variable": "cx"}}}}},
                                                                        "argument": {
                                                                          "lambda": {
                                                                            "parameter": "field_value",
                                                                            "domain": {"variable": "v"},
                                                                            "body": {
                                                                              "typeApplication": {
                                                                                "body": {
                                                                                  "typeApplication": {
                                                                                    "body": {
                                                                                      "either": {
                                                                                        "right": {
                                                                                          "record": {
                                                                                            "typeName": "hydra.core.diff.HoleFiller",
                                                                                            "fields": [{"name": "path", "term": {"variable": "field_path"}}, {"name": "value", "term": {"variable": "field_value"}}]}}}},
                                                                                    "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                "type": {
                                                                                  "application": {
                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.HoleFiller"}, "argument": {"variable": "v"}}},
                                                                                    "argument": {"variable": "s"}}}}}}}}}}}}}}}}}}]}},
                                            "argument": {"variable": "stripped"}}}}}}},
                                "argument": {
                                  "application": {
                                    "function": {
                                      "application": {"function": {"variable": "hydra.core.extract.model.stripWithDecodingError"}, "argument": {"variable": "cx"}}},
                                    "argument": {"variable": "raw"}}}}}}}}}}}}},
            "annotation": {
              "map": [{"key": {"variable": "description"}, "value": {"literal": {"string": "Decoder for hydra.core.diff.HoleFiller"}}}]}}}}},
    {
      "term": {
        "name": "hydra.core.decode.diff.invalidFillError",
        "signature": {
          "typeParameters": [{"name": "t", "constraints": []}, {"name": "v", "constraints": []}, {"name": "s", "constraints": []}],
          "parameters": [
            {
              "name": "arg0",
              "type": {
                "function": {
                  "domain": {"variable": "hydra.core.graph.Graph"},
                  "codomain": {
                    "function": {
                      "domain": {"variable": "hydra.core.model.Term"},
                      "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "t"}}}}}}},
              "isLazy": false},
            {
              "name": "arg1",
              "type": {
                "function": {
                  "domain": {"variable": "hydra.core.graph.Graph"},
                  "codomain": {
                    "function": {
                      "domain": {"variable": "hydra.core.model.Term"},
                      "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "v"}}}}}}},
              "isLazy": false},
            {
              "name": "arg2",
              "type": {
                "function": {
                  "domain": {"variable": "hydra.core.graph.Graph"},
                  "codomain": {
                    "function": {
                      "domain": {"variable": "hydra.core.model.Term"},
                      "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "s"}}}}}}},
              "isLazy": false},
            {"name": "arg3", "type": {"variable": "hydra.core.graph.Graph"}, "isLazy": false},
            {"name": "arg4", "type": {"variable": "hydra.core.model.Term"}, "isLazy": false}],
          "result": {
            "type": {
              "either": {
                "left": {"variable": "hydra.core.errors.DecodingError"},
                "right": {
                  "application": {
                    "function": {
                      "application": {
                        "function": {"application": {"function": {"variable": "hydra.core.diff.InvalidFillError"}, "argument": {"variable": "t"}}},
                        "argument": {"variable": "v"}}},
                    "argument": {"variable": "s"}}}}}}},
        "body": {
          "annotated": {
            "body": {
              "lambda": {
                "parameter": "t",
                "domain": {
                  "function": {
                    "domain": {"variable": "hydra.core.graph.Graph"},
                    "codomain": {
                      "function": {
                        "domain": {"variable": "hydra.core.model.Term"},
                        "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "t"}}}}}}},
                "body": {
                  "lambda": {
                    "parameter": "v",
                    "domain": {
                      "function": {
                        "domain": {"variable": "hydra.core.graph.Graph"},
                        "codomain": {
                          "function": {
                            "domain": {"variable": "hydra.core.model.Term"},
                            "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "v"}}}}}}},
                    "body": {
                      "lambda": {
                        "parameter": "s",
                        "domain": {
                          "function": {
                            "domain": {"variable": "hydra.core.graph.Graph"},
                            "codomain": {
                              "function": {
                                "domain": {"variable": "hydra.core.model.Term"},
                                "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "s"}}}}}}},
                        "body": {
                          "lambda": {
                            "parameter": "cx",
                            "domain": {"variable": "hydra.core.graph.Graph"},
                            "body": {
                              "lambda": {
                                "parameter": "raw",
                                "domain": {"variable": "hydra.core.model.Term"},
                                "body": {
                                  "application": {
                                    "function": {
                                      "application": {
                                        "function": {
                                          "application": {
                                            "function": {
                                              "typeApplication": {
                                                "body": {
                                                  "typeApplication": {
                                                    "body": {
                                                      "typeApplication": {"body": {"variable": "hydra.core.lib.eithers.either"}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                    "type": {"variable": "hydra.core.model.Term"}}},
                                                "type": {
                                                  "either": {
                                                    "left": {"variable": "hydra.core.errors.DecodingError"},
                                                    "right": {
                                                      "application": {
                                                        "function": {
                                                          "application": {
                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.InvalidFillError"}, "argument": {"variable": "t"}}},
                                                            "argument": {"variable": "v"}}},
                                                        "argument": {"variable": "s"}}}}}}},
                                            "argument": {
                                              "lambda": {
                                                "parameter": "err",
                                                "domain": {"variable": "hydra.core.errors.DecodingError"},
                                                "body": {
                                                  "typeApplication": {
                                                    "body": {
                                                      "typeApplication": {"body": {"either": {"left": {"variable": "err"}}}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                    "type": {
                                                      "application": {
                                                        "function": {
                                                          "application": {
                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.InvalidFillError"}, "argument": {"variable": "t"}}},
                                                            "argument": {"variable": "v"}}},
                                                        "argument": {"variable": "s"}}}}}}}}},
                                        "argument": {
                                          "lambda": {
                                            "parameter": "stripped",
                                            "domain": {"variable": "hydra.core.model.Term"},
                                            "body": {
                                              "application": {
                                                "function": {
                                                  "cases": {
                                                    "typeName": "hydra.core.model.Term",
                                                    "default": {
                                                      "typeApplication": {
                                                        "body": {
                                                          "typeApplication": {
                                                            "body": {
                                                              "either": {"left": {"wrap": {"typeName": "hydra.core.errors.DecodingError", "body": {"literal": {"string": "expected union"}}}}}},
                                                            "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                        "type": {
                                                          "application": {
                                                            "function": {
                                                              "application": {
                                                                "function": {"application": {"function": {"variable": "hydra.core.diff.InvalidFillError"}, "argument": {"variable": "t"}}},
                                                                "argument": {"variable": "v"}}},
                                                            "argument": {"variable": "s"}}}}},
                                                    "cases": [
                                                      {
                                                        "name": "inject",
                                                        "handler": {
                                                          "lambda": {
                                                            "parameter": "inj",
                                                            "domain": {"variable": "hydra.core.model.Injection"},
                                                            "body": {
                                                              "let": {
                                                                "bindings": [
                                                                  {
                                                                    "name": "field",
                                                                    "term": {
                                                                      "application": {
                                                                        "function": {"project": {"typeName": "hydra.core.model.Injection", "fieldName": "field"}},
                                                                        "argument": {"variable": "inj"}}},
                                                                    "typeScheme": {"variables": [], "body": {"variable": "hydra.core.model.Field"}, "constraints": []}},
                                                                  {
                                                                    "name": "fname",
                                                                    "term": {
                                                                      "application": {
                                                                        "function": {"project": {"typeName": "hydra.core.model.Field", "fieldName": "name"}},
                                                                        "argument": {"variable": "field"}}},
                                                                    "typeScheme": {"variables": [], "body": {"variable": "hydra.core.model.Name"}, "constraints": []}},
                                                                  {
                                                                    "name": "fterm",
                                                                    "term": {
                                                                      "application": {
                                                                        "function": {"project": {"typeName": "hydra.core.model.Field", "fieldName": "term"}},
                                                                        "argument": {"variable": "field"}}},
                                                                    "typeScheme": {"variables": [], "body": {"variable": "hydra.core.model.Term"}, "constraints": []}},
                                                                  {
                                                                    "name": "variantMap",
                                                                    "term": {
                                                                      "application": {
                                                                        "function": {
                                                                          "typeApplication": {
                                                                            "body": {
                                                                              "typeApplication": {"body": {"variable": "hydra.core.lib.maps.fromList"}, "type": {"variable": "hydra.core.model.Name"}}},
                                                                            "type": {
                                                                              "function": {
                                                                                "domain": {"variable": "hydra.core.model.Term"},
                                                                                "codomain": {
                                                                                  "either": {
                                                                                    "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                                    "right": {
                                                                                      "application": {
                                                                                        "function": {
                                                                                          "application": {
                                                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.InvalidFillError"}, "argument": {"variable": "t"}}},
                                                                                            "argument": {"variable": "v"}}},
                                                                                        "argument": {"variable": "s"}}}}}}}}},
                                                                        "argument": {
                                                                          "list": [
                                                                            {
                                                                              "typeApplication": {
                                                                                "body": {
                                                                                  "typeApplication": {
                                                                                    "body": {
                                                                                      "pair": {
                                                                                        "first": {"wrap": {"typeName": "hydra.core.model.Name", "body": {"literal": {"string": "illTyped"}}}},
                                                                                        "second": {
                                                                                          "lambda": {
                                                                                            "parameter": "input",
                                                                                            "domain": {"variable": "hydra.core.model.Term"},
                                                                                            "body": {
                                                                                              "application": {
                                                                                                "function": {
                                                                                                  "application": {
                                                                                                    "function": {
                                                                                                      "typeApplication": {
                                                                                                        "body": {
                                                                                                          "typeApplication": {
                                                                                                            "body": {
                                                                                                              "typeApplication": {
                                                                                                                "body": {"variable": "hydra.core.lib.eithers.map"},
                                                                                                                "type": {
                                                                                                                  "application": {
                                                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.Hole"}, "argument": {"variable": "t"}}},
                                                                                                                    "argument": {"variable": "s"}}}}},
                                                                                                            "type": {
                                                                                                              "application": {
                                                                                                                "function": {
                                                                                                                  "application": {
                                                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.InvalidFillError"}, "argument": {"variable": "t"}}},
                                                                                                                    "argument": {"variable": "v"}}},
                                                                                                                "argument": {"variable": "s"}}}}},
                                                                                                        "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                                    "argument": {
                                                                                                      "lambda": {
                                                                                                        "parameter": "t",
                                                                                                        "domain": {
                                                                                                          "application": {
                                                                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.Hole"}, "argument": {"variable": "t"}}},
                                                                                                            "argument": {"variable": "s"}}},
                                                                                                        "body": {"inject": {"typeName": "hydra.core.diff.InvalidFillError", "field": {"name": "illTyped", "term": {"variable": "t"}}}}}}}},
                                                                                                "argument": {
                                                                                                  "application": {
                                                                                                    "function": {
                                                                                                      "application": {
                                                                                                        "function": {
                                                                                                          "application": {
                                                                                                            "function": {
                                                                                                              "typeApplication": {
                                                                                                                "body": {
                                                                                                                  "application": {
                                                                                                                    "function": {"typeApplication": {"body": {"variable": "hydra.core.decode.diff.hole"}, "type": {"variable": "t"}}},
                                                                                                                    "argument": {"variable": "t"}}},
                                                                                                                "type": {"variable": "s"}}},
                                                                                                            "argument": {"variable": "s"}}},
                                                                                                        "argument": {"variable": "cx"}}},
                                                                                                    "argument": {"variable": "input"}}}}}}}}},
                                                                                    "type": {"variable": "hydra.core.model.Name"}}},
                                                                                "type": {
                                                                                  "function": {
                                                                                    "domain": {"variable": "hydra.core.model.Term"},
                                                                                    "codomain": {
                                                                                      "either": {
                                                                                        "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                                        "right": {
                                                                                          "application": {
                                                                                            "function": {
                                                                                              "application": {
                                                                                                "function": {"application": {"function": {"variable": "hydra.core.diff.InvalidFillError"}, "argument": {"variable": "t"}}},
                                                                                                "argument": {"variable": "v"}}},
                                                                                            "argument": {"variable": "s"}}}}}}}}},
                                                                            {
                                                                              "typeApplication": {
                                                                                "body": {
                                                                                  "typeApplication": {
                                                                                    "body": {
                                                                                      "pair": {
                                                                                        "first": {"wrap": {"typeName": "hydra.core.model.Name", "body": {"literal": {"string": "missingFill"}}}},
                                                                                        "second": {
                                                                                          "lambda": {
                                                                                            "parameter": "input",
                                                                                            "domain": {"variable": "hydra.core.model.Term"},
                                                                                            "body": {
                                                                                              "application": {
                                                                                                "function": {
                                                                                                  "application": {
                                                                                                    "function": {
                                                                                                      "typeApplication": {
                                                                                                        "body": {
                                                                                                          "typeApplication": {
                                                                                                            "body": {
                                                                                                              "typeApplication": {
                                                                                                                "body": {"variable": "hydra.core.lib.eithers.map"},
                                                                                                                "type": {
                                                                                                                  "application": {
                                                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.Hole"}, "argument": {"variable": "t"}}},
                                                                                                                    "argument": {"variable": "s"}}}}},
                                                                                                            "type": {
                                                                                                              "application": {
                                                                                                                "function": {
                                                                                                                  "application": {
                                                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.InvalidFillError"}, "argument": {"variable": "t"}}},
                                                                                                                    "argument": {"variable": "v"}}},
                                                                                                                "argument": {"variable": "s"}}}}},
                                                                                                        "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                                    "argument": {
                                                                                                      "lambda": {
                                                                                                        "parameter": "t",
                                                                                                        "domain": {
                                                                                                          "application": {
                                                                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.Hole"}, "argument": {"variable": "t"}}},
                                                                                                            "argument": {"variable": "s"}}},
                                                                                                        "body": {
                                                                                                          "inject": {"typeName": "hydra.core.diff.InvalidFillError", "field": {"name": "missingFill", "term": {"variable": "t"}}}}}}}},
                                                                                                "argument": {
                                                                                                  "application": {
                                                                                                    "function": {
                                                                                                      "application": {
                                                                                                        "function": {
                                                                                                          "application": {
                                                                                                            "function": {
                                                                                                              "typeApplication": {
                                                                                                                "body": {
                                                                                                                  "application": {
                                                                                                                    "function": {"typeApplication": {"body": {"variable": "hydra.core.decode.diff.hole"}, "type": {"variable": "t"}}},
                                                                                                                    "argument": {"variable": "t"}}},
                                                                                                                "type": {"variable": "s"}}},
                                                                                                            "argument": {"variable": "s"}}},
                                                                                                        "argument": {"variable": "cx"}}},
                                                                                                    "argument": {"variable": "input"}}}}}}}}},
                                                                                    "type": {"variable": "hydra.core.model.Name"}}},
                                                                                "type": {
                                                                                  "function": {
                                                                                    "domain": {"variable": "hydra.core.model.Term"},
                                                                                    "codomain": {
                                                                                      "either": {
                                                                                        "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                                        "right": {
                                                                                          "application": {
                                                                                            "function": {
                                                                                              "application": {
                                                                                                "function": {"application": {"function": {"variable": "hydra.core.diff.InvalidFillError"}, "argument": {"variable": "t"}}},
                                                                                                "argument": {"variable": "v"}}},
                                                                                            "argument": {"variable": "s"}}}}}}}}},
                                                                            {
                                                                              "typeApplication": {
                                                                                "body": {
                                                                                  "typeApplication": {
                                                                                    "body": {
                                                                                      "pair": {
                                                                                        "first": {"wrap": {"typeName": "hydra.core.model.Name", "body": {"literal": {"string": "extraFill"}}}},
                                                                                        "second": {
                                                                                          "lambda": {
                                                                                            "parameter": "input",
                                                                                            "domain": {"variable": "hydra.core.model.Term"},
                                                                                            "body": {
                                                                                              "application": {
                                                                                                "function": {
                                                                                                  "application": {
                                                                                                    "function": {
                                                                                                      "typeApplication": {
                                                                                                        "body": {
                                                                                                          "typeApplication": {
                                                                                                            "body": {"typeApplication": {"body": {"variable": "hydra.core.lib.eithers.map"}, "type": {"literal": {"integer": "int32"}}}},
                                                                                                            "type": {
                                                                                                              "application": {
                                                                                                                "function": {
                                                                                                                  "application": {
                                                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.InvalidFillError"}, "argument": {"variable": "t"}}},
                                                                                                                    "argument": {"variable": "v"}}},
                                                                                                                "argument": {"variable": "s"}}}}},
                                                                                                        "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                                    "argument": {
                                                                                                      "lambda": {
                                                                                                        "parameter": "t",
                                                                                                        "domain": {"literal": {"integer": "int32"}},
                                                                                                        "body": {"inject": {"typeName": "hydra.core.diff.InvalidFillError", "field": {"name": "extraFill", "term": {"variable": "t"}}}}}}}},
                                                                                                "argument": {
                                                                                                  "application": {
                                                                                                    "function": {
                                                                                                      "application": {
                                                                                                        "function": {
                                                                                                          "lambda": {
                                                                                                            "parameter": "cx",
                                                                                                            "domain": {"variable": "hydra.core.graph.Graph"},
                                                                                                            "body": {
                                                                                                              "lambda": {
                                                                                                                "parameter": "raw",
                                                                                                                "domain": {"variable": "hydra.core.model.Term"},
                                                                                                                "body": {
                                                                                                                  "application": {
                                                                                                                    "function": {
                                                                                                                      "application": {
                                                                                                                        "function": {
                                                                                                                          "application": {
                                                                                                                            "function": {
                                                                                                                              "typeApplication": {
                                                                                                                                "body": {
                                                                                                                                  "typeApplication": {
                                                                                                                                    "body": {
                                                                                                                                      "typeApplication": {"body": {"variable": "hydra.core.lib.eithers.either"}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                                                                    "type": {"variable": "hydra.core.model.Term"}}},
                                                                                                                                "type": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"literal": {"integer": "int32"}}}}}},
                                                                                                                            "argument": {
                                                                                                                              "lambda": {
                                                                                                                                "parameter": "err",
                                                                                                                                "domain": {"variable": "hydra.core.errors.DecodingError"},
                                                                                                                                "body": {
                                                                                                                                  "typeApplication": {
                                                                                                                                    "body": {
                                                                                                                                      "typeApplication": {"body": {"either": {"left": {"variable": "err"}}}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                                                                    "type": {"literal": {"integer": "int32"}}}}}}}},
                                                                                                                        "argument": {
                                                                                                                          "lambda": {
                                                                                                                            "parameter": "stripped",
                                                                                                                            "domain": {"variable": "hydra.core.model.Term"},
                                                                                                                            "body": {
                                                                                                                              "application": {
                                                                                                                                "function": {
                                                                                                                                  "cases": {
                                                                                                                                    "typeName": "hydra.core.model.Term",
                                                                                                                                    "default": {
                                                                                                                                      "typeApplication": {
                                                                                                                                        "body": {
                                                                                                                                          "typeApplication": {
                                                                                                                                            "body": {
                                                                                                                                              "either": {"left": {"wrap": {"typeName": "hydra.core.errors.DecodingError", "body": {"literal": {"string": "expected literal"}}}}}},
                                                                                                                                            "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                                                                        "type": {"literal": {"integer": "int32"}}}},
                                                                                                                                    "cases": [
                                                                                                                                      {
                                                                                                                                        "name": "literal",
                                                                                                                                        "handler": {
                                                                                                                                          "lambda": {
                                                                                                                                            "parameter": "v",
                                                                                                                                            "domain": {"variable": "hydra.core.model.Literal"},
                                                                                                                                            "body": {
                                                                                                                                              "application": {
                                                                                                                                                "function": {
                                                                                                                                                  "cases": {
                                                                                                                                                    "typeName": "hydra.core.model.Literal",
                                                                                                                                                    "default": {
                                                                                                                                                      "typeApplication": {
                                                                                                                                                        "body": {
                                                                                                                                                          "typeApplication": {
                                                                                                                                                            "body": {
                                                                                                                                                              "either": {
                                                                                                                                                                "left": {"wrap": {"typeName": "hydra.core.errors.DecodingError", "body": {"literal": {"string": "expected int32 literal"}}}}}},
                                                                                                                                                            "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                                                                                        "type": {"literal": {"integer": "int32"}}}},
                                                                                                                                                    "cases": [
                                                                                                                                                      {
                                                                                                                                                        "name": "integer",
                                                                                                                                                        "handler": {
                                                                                                                                                          "cases": {
                                                                                                                                                            "typeName": "hydra.core.model.IntegerValue",
                                                                                                                                                            "default": {
                                                                                                                                                              "typeApplication": {
                                                                                                                                                                "body": {
                                                                                                                                                                  "typeApplication": {
                                                                                                                                                                    "body": {
                                                                                                                                                                      "either": {
                                                                                                                                                                        "left": {"wrap": {"typeName": "hydra.core.errors.DecodingError", "body": {"literal": {"string": "expected int32 value"}}}}}},
                                                                                                                                                                    "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                                                                                                "type": {"literal": {"integer": "int32"}}}},
                                                                                                                                                            "cases": [
                                                                                                                                                              {
                                                                                                                                                                "name": "int32",
                                                                                                                                                                "handler": {
                                                                                                                                                                  "lambda": {
                                                                                                                                                                    "parameter": "i",
                                                                                                                                                                    "domain": {"literal": {"integer": "int32"}},
                                                                                                                                                                    "body": {
                                                                                                                                                                      "typeApplication": {
                                                                                                                                                                        "body": {
                                                                                                                                                                          "typeApplication": {"body": {"either": {"right": {"variable": "i"}}}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                                                                                                        "type": {"literal": {"integer": "int32"}}}}}}}]}}}]}},
                                                                                                                                                "argument": {"variable": "v"}}}}}}]}},
                                                                                                                                "argument": {"variable": "stripped"}}}}}}},
                                                                                                                    "argument": {
                                                                                                                      "application": {
                                                                                                                        "function": {
                                                                                                                          "application": {"function": {"variable": "hydra.core.extract.model.stripWithDecodingError"}, "argument": {"variable": "cx"}}},
                                                                                                                        "argument": {"variable": "raw"}}}}}}}}},
                                                                                                        "argument": {"variable": "cx"}}},
                                                                                                    "argument": {"variable": "input"}}}}}}}}},
                                                                                    "type": {"variable": "hydra.core.model.Name"}}},
                                                                                "type": {
                                                                                  "function": {
                                                                                    "domain": {"variable": "hydra.core.model.Term"},
                                                                                    "codomain": {
                                                                                      "either": {
                                                                                        "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                                        "right": {
                                                                                          "application": {
                                                                                            "function": {
                                                                                              "application": {
                                                                                                "function": {"application": {"function": {"variable": "hydra.core.diff.InvalidFillError"}, "argument": {"variable": "t"}}},
                                                                                                "argument": {"variable": "v"}}},
                                                                                            "argument": {"variable": "s"}}}}}}}}}]}}},
                                                                    "typeScheme": {
                                                                      "variables": [],
                                                                      "body": {
                                                                        "map": {
                                                                          "keys": {"variable": "hydra.core.model.Name"},
                                                                          "values": {
                                                                            "function": {
                                                                              "domain": {"variable": "hydra.core.model.Term"},
                                                                              "codomain": {
                                                                                "either": {
                                                                                  "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                                  "right": {
                                                                                    "application": {
                                                                                      "function": {
                                                                                        "application": {
                                                                                          "function": {"application": {"function": {"variable": "hydra.core.diff.InvalidFillError"}, "argument": {"variable": "t"}}},
                                                                                          "argument": {"variable": "v"}}},
                                                                                      "argument": {"variable": "s"}}}}}}}}},
                                                                      "constraints": []}}],
                                                                "body": {
                                                                  "application": {
                                                                    "function": {
                                                                      "application": {
                                                                        "function": {
                                                                          "application": {
                                                                            "function": {
                                                                              "typeApplication": {
                                                                                "body": {
                                                                                  "typeApplication": {
                                                                                    "body": {"variable": "hydra.core.lib.optionals.match"},
                                                                                    "type": {
                                                                                      "function": {
                                                                                        "domain": {"variable": "hydra.core.model.Term"},
                                                                                        "codomain": {
                                                                                          "either": {
                                                                                            "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                                            "right": {
                                                                                              "application": {
                                                                                                "function": {
                                                                                                  "application": {
                                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.InvalidFillError"}, "argument": {"variable": "t"}}},
                                                                                                    "argument": {"variable": "v"}}},
                                                                                                "argument": {"variable": "s"}}}}}}}}},
                                                                                "type": {
                                                                                  "either": {
                                                                                    "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                                    "right": {
                                                                                      "application": {
                                                                                        "function": {
                                                                                          "application": {
                                                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.InvalidFillError"}, "argument": {"variable": "t"}}},
                                                                                            "argument": {"variable": "v"}}},
                                                                                        "argument": {"variable": "s"}}}}}}},
                                                                            "argument": {
                                                                              "application": {
                                                                                "function": {
                                                                                  "application": {
                                                                                    "function": {
                                                                                      "typeApplication": {
                                                                                        "body": {"typeApplication": {"body": {"variable": "hydra.core.lib.maps.lookup"}, "type": {"variable": "hydra.core.model.Name"}}},
                                                                                        "type": {
                                                                                          "function": {
                                                                                            "domain": {"variable": "hydra.core.model.Term"},
                                                                                            "codomain": {
                                                                                              "either": {
                                                                                                "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                                                "right": {
                                                                                                  "application": {
                                                                                                    "function": {
                                                                                                      "application": {
                                                                                                        "function": {"application": {"function": {"variable": "hydra.core.diff.InvalidFillError"}, "argument": {"variable": "t"}}},
                                                                                                        "argument": {"variable": "v"}}},
                                                                                                    "argument": {"variable": "s"}}}}}}}}},
                                                                                    "argument": {"variable": "fname"}}},
                                                                                "argument": {"variable": "variantMap"}}}}},
                                                                        "argument": {
                                                                          "typeApplication": {
                                                                            "body": {
                                                                              "typeApplication": {
                                                                                "body": {
                                                                                  "either": {
                                                                                    "left": {
                                                                                      "wrap": {
                                                                                        "typeName": "hydra.core.errors.DecodingError",
                                                                                        "body": {
                                                                                          "application": {
                                                                                            "function": {"variable": "hydra.core.lib.strings.concat"},
                                                                                            "argument": {
                                                                                              "list": [
                                                                                                {"literal": {"string": "no such field "}},
                                                                                                {"application": {"function": {"unwrap": "hydra.core.model.Name"}, "argument": {"variable": "fname"}}},
                                                                                                {"literal": {"string": " in union"}}]}}}}}}},
                                                                                "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                            "type": {
                                                                              "application": {
                                                                                "function": {
                                                                                  "application": {
                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.InvalidFillError"}, "argument": {"variable": "t"}}},
                                                                                    "argument": {"variable": "v"}}},
                                                                                "argument": {"variable": "s"}}}}}}},
                                                                    "argument": {
                                                                      "lambda": {
                                                                        "parameter": "f",
                                                                        "domain": {
                                                                          "function": {
                                                                            "domain": {"variable": "hydra.core.model.Term"},
                                                                            "codomain": {
                                                                              "either": {
                                                                                "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                                "right": {
                                                                                  "application": {
                                                                                    "function": {
                                                                                      "application": {
                                                                                        "function": {"application": {"function": {"variable": "hydra.core.diff.InvalidFillError"}, "argument": {"variable": "t"}}},
                                                                                        "argument": {"variable": "v"}}},
                                                                                    "argument": {"variable": "s"}}}}}}},
                                                                        "body": {"application": {"function": {"variable": "f"}, "argument": {"variable": "fterm"}}}}}}}}}}}}]}},
                                                "argument": {"variable": "stripped"}}}}}}},
                                    "argument": {
                                      "application": {
                                        "function": {
                                          "application": {"function": {"variable": "hydra.core.extract.model.stripWithDecodingError"}, "argument": {"variable": "cx"}}},
                                        "argument": {"variable": "raw"}}}}}}}}}}}}}}},
            "annotation": {
              "map": [{"key": {"variable": "description"}, "value": {"literal": {"string": "Decoder for hydra.core.diff.InvalidFillError"}}}]}}}}},
    {
      "term": {
        "name": "hydra.core.decode.diff.migrationError",
        "signature": {
          "typeParameters": [{"name": "t", "constraints": []}, {"name": "v", "constraints": []}, {"name": "s", "constraints": []}],
          "parameters": [
            {
              "name": "arg0",
              "type": {
                "function": {
                  "domain": {"variable": "hydra.core.graph.Graph"},
                  "codomain": {
                    "function": {
                      "domain": {"variable": "hydra.core.model.Term"},
                      "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "t"}}}}}}},
              "isLazy": false},
            {
              "name": "arg1",
              "type": {
                "function": {
                  "domain": {"variable": "hydra.core.graph.Graph"},
                  "codomain": {
                    "function": {
                      "domain": {"variable": "hydra.core.model.Term"},
                      "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "v"}}}}}}},
              "isLazy": false},
            {
              "name": "arg2",
              "type": {
                "function": {
                  "domain": {"variable": "hydra.core.graph.Graph"},
                  "codomain": {
                    "function": {
                      "domain": {"variable": "hydra.core.model.Term"},
                      "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "s"}}}}}}},
              "isLazy": false},
            {"name": "arg3", "type": {"variable": "hydra.core.graph.Graph"}, "isLazy": false},
            {"name": "arg4", "type": {"variable": "hydra.core.model.Term"}, "isLazy": false}],
          "result": {
            "type": {
              "either": {
                "left": {"variable": "hydra.core.errors.DecodingError"},
                "right": {
                  "application": {
                    "function": {
                      "application": {
                        "function": {"application": {"function": {"variable": "hydra.core.diff.MigrationError"}, "argument": {"variable": "t"}}},
                        "argument": {"variable": "v"}}},
                    "argument": {"variable": "s"}}}}}}},
        "body": {
          "annotated": {
            "body": {
              "lambda": {
                "parameter": "t",
                "domain": {
                  "function": {
                    "domain": {"variable": "hydra.core.graph.Graph"},
                    "codomain": {
                      "function": {
                        "domain": {"variable": "hydra.core.model.Term"},
                        "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "t"}}}}}}},
                "body": {
                  "lambda": {
                    "parameter": "v",
                    "domain": {
                      "function": {
                        "domain": {"variable": "hydra.core.graph.Graph"},
                        "codomain": {
                          "function": {
                            "domain": {"variable": "hydra.core.model.Term"},
                            "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "v"}}}}}}},
                    "body": {
                      "lambda": {
                        "parameter": "s",
                        "domain": {
                          "function": {
                            "domain": {"variable": "hydra.core.graph.Graph"},
                            "codomain": {
                              "function": {
                                "domain": {"variable": "hydra.core.model.Term"},
                                "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "s"}}}}}}},
                        "body": {
                          "lambda": {
                            "parameter": "cx",
                            "domain": {"variable": "hydra.core.graph.Graph"},
                            "body": {
                              "lambda": {
                                "parameter": "raw",
                                "domain": {"variable": "hydra.core.model.Term"},
                                "body": {
                                  "application": {
                                    "function": {
                                      "application": {
                                        "function": {
                                          "application": {
                                            "function": {
                                              "typeApplication": {
                                                "body": {
                                                  "typeApplication": {
                                                    "body": {
                                                      "typeApplication": {"body": {"variable": "hydra.core.lib.eithers.either"}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                    "type": {"variable": "hydra.core.model.Term"}}},
                                                "type": {
                                                  "either": {
                                                    "left": {"variable": "hydra.core.errors.DecodingError"},
                                                    "right": {
                                                      "application": {
                                                        "function": {
                                                          "application": {
                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.MigrationError"}, "argument": {"variable": "t"}}},
                                                            "argument": {"variable": "v"}}},
                                                        "argument": {"variable": "s"}}}}}}},
                                            "argument": {
                                              "lambda": {
                                                "parameter": "err",
                                                "domain": {"variable": "hydra.core.errors.DecodingError"},
                                                "body": {
                                                  "typeApplication": {
                                                    "body": {
                                                      "typeApplication": {"body": {"either": {"left": {"variable": "err"}}}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                    "type": {
                                                      "application": {
                                                        "function": {
                                                          "application": {
                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.MigrationError"}, "argument": {"variable": "t"}}},
                                                            "argument": {"variable": "v"}}},
                                                        "argument": {"variable": "s"}}}}}}}}},
                                        "argument": {
                                          "lambda": {
                                            "parameter": "stripped",
                                            "domain": {"variable": "hydra.core.model.Term"},
                                            "body": {
                                              "application": {
                                                "function": {
                                                  "cases": {
                                                    "typeName": "hydra.core.model.Term",
                                                    "default": {
                                                      "typeApplication": {
                                                        "body": {
                                                          "typeApplication": {
                                                            "body": {
                                                              "either": {"left": {"wrap": {"typeName": "hydra.core.errors.DecodingError", "body": {"literal": {"string": "expected union"}}}}}},
                                                            "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                        "type": {
                                                          "application": {
                                                            "function": {
                                                              "application": {
                                                                "function": {"application": {"function": {"variable": "hydra.core.diff.MigrationError"}, "argument": {"variable": "t"}}},
                                                                "argument": {"variable": "v"}}},
                                                            "argument": {"variable": "s"}}}}},
                                                    "cases": [
                                                      {
                                                        "name": "inject",
                                                        "handler": {
                                                          "lambda": {
                                                            "parameter": "inj",
                                                            "domain": {"variable": "hydra.core.model.Injection"},
                                                            "body": {
                                                              "let": {
                                                                "bindings": [
                                                                  {
                                                                    "name": "field",
                                                                    "term": {
                                                                      "application": {
                                                                        "function": {"project": {"typeName": "hydra.core.model.Injection", "fieldName": "field"}},
                                                                        "argument": {"variable": "inj"}}},
                                                                    "typeScheme": {"variables": [], "body": {"variable": "hydra.core.model.Field"}, "constraints": []}},
                                                                  {
                                                                    "name": "fname",
                                                                    "term": {
                                                                      "application": {
                                                                        "function": {"project": {"typeName": "hydra.core.model.Field", "fieldName": "name"}},
                                                                        "argument": {"variable": "field"}}},
                                                                    "typeScheme": {"variables": [], "body": {"variable": "hydra.core.model.Name"}, "constraints": []}},
                                                                  {
                                                                    "name": "fterm",
                                                                    "term": {
                                                                      "application": {
                                                                        "function": {"project": {"typeName": "hydra.core.model.Field", "fieldName": "term"}},
                                                                        "argument": {"variable": "field"}}},
                                                                    "typeScheme": {"variables": [], "body": {"variable": "hydra.core.model.Term"}, "constraints": []}},
                                                                  {
                                                                    "name": "variantMap",
                                                                    "term": {
                                                                      "application": {
                                                                        "function": {
                                                                          "typeApplication": {
                                                                            "body": {
                                                                              "typeApplication": {"body": {"variable": "hydra.core.lib.maps.fromList"}, "type": {"variable": "hydra.core.model.Name"}}},
                                                                            "type": {
                                                                              "function": {
                                                                                "domain": {"variable": "hydra.core.model.Term"},
                                                                                "codomain": {
                                                                                  "either": {
                                                                                    "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                                    "right": {
                                                                                      "application": {
                                                                                        "function": {
                                                                                          "application": {
                                                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.MigrationError"}, "argument": {"variable": "t"}}},
                                                                                            "argument": {"variable": "v"}}},
                                                                                        "argument": {"variable": "s"}}}}}}}}},
                                                                        "argument": {
                                                                          "list": [
                                                                            {
                                                                              "typeApplication": {
                                                                                "body": {
                                                                                  "typeApplication": {
                                                                                    "body": {
                                                                                      "pair": {
                                                                                        "first": {"wrap": {"typeName": "hydra.core.model.Name", "body": {"literal": {"string": "notAnInstance"}}}},
                                                                                        "second": {
                                                                                          "lambda": {
                                                                                            "parameter": "input",
                                                                                            "domain": {"variable": "hydra.core.model.Term"},
                                                                                            "body": {
                                                                                              "application": {
                                                                                                "function": {
                                                                                                  "application": {
                                                                                                    "function": {
                                                                                                      "typeApplication": {
                                                                                                        "body": {
                                                                                                          "typeApplication": {
                                                                                                            "body": {"typeApplication": {"body": {"variable": "hydra.core.lib.eithers.map"}, "type": {"variable": "v"}}},
                                                                                                            "type": {
                                                                                                              "application": {
                                                                                                                "function": {
                                                                                                                  "application": {
                                                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.MigrationError"}, "argument": {"variable": "t"}}},
                                                                                                                    "argument": {"variable": "v"}}},
                                                                                                                "argument": {"variable": "s"}}}}},
                                                                                                        "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                                    "argument": {
                                                                                                      "lambda": {
                                                                                                        "parameter": "t",
                                                                                                        "domain": {"variable": "v"},
                                                                                                        "body": {
                                                                                                          "inject": {"typeName": "hydra.core.diff.MigrationError", "field": {"name": "notAnInstance", "term": {"variable": "t"}}}}}}}},
                                                                                                "argument": {
                                                                                                  "application": {
                                                                                                    "function": {"application": {"function": {"variable": "v"}, "argument": {"variable": "cx"}}},
                                                                                                    "argument": {"variable": "input"}}}}}}}}},
                                                                                    "type": {"variable": "hydra.core.model.Name"}}},
                                                                                "type": {
                                                                                  "function": {
                                                                                    "domain": {"variable": "hydra.core.model.Term"},
                                                                                    "codomain": {
                                                                                      "either": {
                                                                                        "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                                        "right": {
                                                                                          "application": {
                                                                                            "function": {
                                                                                              "application": {
                                                                                                "function": {"application": {"function": {"variable": "hydra.core.diff.MigrationError"}, "argument": {"variable": "t"}}},
                                                                                                "argument": {"variable": "v"}}},
                                                                                            "argument": {"variable": "s"}}}}}}}}},
                                                                            {
                                                                              "typeApplication": {
                                                                                "body": {
                                                                                  "typeApplication": {
                                                                                    "body": {
                                                                                      "pair": {
                                                                                        "first": {"wrap": {"typeName": "hydra.core.model.Name", "body": {"literal": {"string": "outOfRange"}}}},
                                                                                        "second": {
                                                                                          "lambda": {
                                                                                            "parameter": "input",
                                                                                            "domain": {"variable": "hydra.core.model.Term"},
                                                                                            "body": {
                                                                                              "application": {
                                                                                                "function": {
                                                                                                  "application": {
                                                                                                    "function": {
                                                                                                      "typeApplication": {
                                                                                                        "body": {
                                                                                                          "typeApplication": {
                                                                                                            "body": {"typeApplication": {"body": {"variable": "hydra.core.lib.eithers.map"}, "type": {"variable": "v"}}},
                                                                                                            "type": {
                                                                                                              "application": {
                                                                                                                "function": {
                                                                                                                  "application": {
                                                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.MigrationError"}, "argument": {"variable": "t"}}},
                                                                                                                    "argument": {"variable": "v"}}},
                                                                                                                "argument": {"variable": "s"}}}}},
                                                                                                        "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                                    "argument": {
                                                                                                      "lambda": {
                                                                                                        "parameter": "t",
                                                                                                        "domain": {"variable": "v"},
                                                                                                        "body": {"inject": {"typeName": "hydra.core.diff.MigrationError", "field": {"name": "outOfRange", "term": {"variable": "t"}}}}}}}},
                                                                                                "argument": {
                                                                                                  "application": {
                                                                                                    "function": {"application": {"function": {"variable": "v"}, "argument": {"variable": "cx"}}},
                                                                                                    "argument": {"variable": "input"}}}}}}}}},
                                                                                    "type": {"variable": "hydra.core.model.Name"}}},
                                                                                "type": {
                                                                                  "function": {
                                                                                    "domain": {"variable": "hydra.core.model.Term"},
                                                                                    "codomain": {
                                                                                      "either": {
                                                                                        "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                                        "right": {
                                                                                          "application": {
                                                                                            "function": {
                                                                                              "application": {
                                                                                                "function": {"application": {"function": {"variable": "hydra.core.diff.MigrationError"}, "argument": {"variable": "t"}}},
                                                                                                "argument": {"variable": "v"}}},
                                                                                            "argument": {"variable": "s"}}}}}}}}},
                                                                            {
                                                                              "typeApplication": {
                                                                                "body": {
                                                                                  "typeApplication": {
                                                                                    "body": {
                                                                                      "pair": {
                                                                                        "first": {"wrap": {"typeName": "hydra.core.model.Name", "body": {"literal": {"string": "rejectedVariant"}}}},
                                                                                        "second": {
                                                                                          "lambda": {
                                                                                            "parameter": "input",
                                                                                            "domain": {"variable": "hydra.core.model.Term"},
                                                                                            "body": {
                                                                                              "application": {
                                                                                                "function": {
                                                                                                  "application": {
                                                                                                    "function": {
                                                                                                      "typeApplication": {
                                                                                                        "body": {
                                                                                                          "typeApplication": {
                                                                                                            "body": {"typeApplication": {"body": {"variable": "hydra.core.lib.eithers.map"}, "type": {"variable": "v"}}},
                                                                                                            "type": {
                                                                                                              "application": {
                                                                                                                "function": {
                                                                                                                  "application": {
                                                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.MigrationError"}, "argument": {"variable": "t"}}},
                                                                                                                    "argument": {"variable": "v"}}},
                                                                                                                "argument": {"variable": "s"}}}}},
                                                                                                        "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                                    "argument": {
                                                                                                      "lambda": {
                                                                                                        "parameter": "t",
                                                                                                        "domain": {"variable": "v"},
                                                                                                        "body": {
                                                                                                          "inject": {"typeName": "hydra.core.diff.MigrationError", "field": {"name": "rejectedVariant", "term": {"variable": "t"}}}}}}}},
                                                                                                "argument": {
                                                                                                  "application": {
                                                                                                    "function": {"application": {"function": {"variable": "v"}, "argument": {"variable": "cx"}}},
                                                                                                    "argument": {"variable": "input"}}}}}}}}},
                                                                                    "type": {"variable": "hydra.core.model.Name"}}},
                                                                                "type": {
                                                                                  "function": {
                                                                                    "domain": {"variable": "hydra.core.model.Term"},
                                                                                    "codomain": {
                                                                                      "either": {
                                                                                        "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                                        "right": {
                                                                                          "application": {
                                                                                            "function": {
                                                                                              "application": {
                                                                                                "function": {"application": {"function": {"variable": "hydra.core.diff.MigrationError"}, "argument": {"variable": "t"}}},
                                                                                                "argument": {"variable": "v"}}},
                                                                                            "argument": {"variable": "s"}}}}}}}}},
                                                                            {
                                                                              "typeApplication": {
                                                                                "body": {
                                                                                  "typeApplication": {
                                                                                    "body": {
                                                                                      "pair": {
                                                                                        "first": {"wrap": {"typeName": "hydra.core.model.Name", "body": {"literal": {"string": "illTypedResult"}}}},
                                                                                        "second": {
                                                                                          "lambda": {
                                                                                            "parameter": "input",
                                                                                            "domain": {"variable": "hydra.core.model.Term"},
                                                                                            "body": {
                                                                                              "application": {
                                                                                                "function": {
                                                                                                  "application": {
                                                                                                    "function": {
                                                                                                      "typeApplication": {
                                                                                                        "body": {
                                                                                                          "typeApplication": {
                                                                                                            "body": {
                                                                                                              "typeApplication": {
                                                                                                                "body": {"variable": "hydra.core.lib.eithers.map"},
                                                                                                                "type": {
                                                                                                                  "application": {
                                                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.Mistyped"}, "argument": {"variable": "t"}}},
                                                                                                                    "argument": {"variable": "v"}}}}},
                                                                                                            "type": {
                                                                                                              "application": {
                                                                                                                "function": {
                                                                                                                  "application": {
                                                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.MigrationError"}, "argument": {"variable": "t"}}},
                                                                                                                    "argument": {"variable": "v"}}},
                                                                                                                "argument": {"variable": "s"}}}}},
                                                                                                        "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                                    "argument": {
                                                                                                      "lambda": {
                                                                                                        "parameter": "t",
                                                                                                        "domain": {
                                                                                                          "application": {
                                                                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.Mistyped"}, "argument": {"variable": "t"}}},
                                                                                                            "argument": {"variable": "v"}}},
                                                                                                        "body": {
                                                                                                          "inject": {"typeName": "hydra.core.diff.MigrationError", "field": {"name": "illTypedResult", "term": {"variable": "t"}}}}}}}},
                                                                                                "argument": {
                                                                                                  "application": {
                                                                                                    "function": {
                                                                                                      "application": {
                                                                                                        "function": {
                                                                                                          "application": {
                                                                                                            "function": {
                                                                                                              "typeApplication": {
                                                                                                                "body": {
                                                                                                                  "application": {
                                                                                                                    "function": {"typeApplication": {"body": {"variable": "hydra.core.decode.diff.mistyped"}, "type": {"variable": "t"}}},
                                                                                                                    "argument": {"variable": "t"}}},
                                                                                                                "type": {"variable": "v"}}},
                                                                                                            "argument": {"variable": "v"}}},
                                                                                                        "argument": {"variable": "cx"}}},
                                                                                                    "argument": {"variable": "input"}}}}}}}}},
                                                                                    "type": {"variable": "hydra.core.model.Name"}}},
                                                                                "type": {
                                                                                  "function": {
                                                                                    "domain": {"variable": "hydra.core.model.Term"},
                                                                                    "codomain": {
                                                                                      "either": {
                                                                                        "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                                        "right": {
                                                                                          "application": {
                                                                                            "function": {
                                                                                              "application": {
                                                                                                "function": {"application": {"function": {"variable": "hydra.core.diff.MigrationError"}, "argument": {"variable": "t"}}},
                                                                                                "argument": {"variable": "v"}}},
                                                                                            "argument": {"variable": "s"}}}}}}}}},
                                                                            {
                                                                              "typeApplication": {
                                                                                "body": {
                                                                                  "typeApplication": {
                                                                                    "body": {
                                                                                      "pair": {
                                                                                        "first": {"wrap": {"typeName": "hydra.core.model.Name", "body": {"literal": {"string": "unfilledHole"}}}},
                                                                                        "second": {
                                                                                          "lambda": {
                                                                                            "parameter": "input",
                                                                                            "domain": {"variable": "hydra.core.model.Term"},
                                                                                            "body": {
                                                                                              "application": {
                                                                                                "function": {
                                                                                                  "application": {
                                                                                                    "function": {
                                                                                                      "typeApplication": {
                                                                                                        "body": {
                                                                                                          "typeApplication": {
                                                                                                            "body": {
                                                                                                              "typeApplication": {
                                                                                                                "body": {"variable": "hydra.core.lib.eithers.map"},
                                                                                                                "type": {
                                                                                                                  "application": {
                                                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.Hole"}, "argument": {"variable": "t"}}},
                                                                                                                    "argument": {"variable": "s"}}}}},
                                                                                                            "type": {
                                                                                                              "application": {
                                                                                                                "function": {
                                                                                                                  "application": {
                                                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.MigrationError"}, "argument": {"variable": "t"}}},
                                                                                                                    "argument": {"variable": "v"}}},
                                                                                                                "argument": {"variable": "s"}}}}},
                                                                                                        "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                                    "argument": {
                                                                                                      "lambda": {
                                                                                                        "parameter": "t",
                                                                                                        "domain": {
                                                                                                          "application": {
                                                                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.Hole"}, "argument": {"variable": "t"}}},
                                                                                                            "argument": {"variable": "s"}}},
                                                                                                        "body": {"inject": {"typeName": "hydra.core.diff.MigrationError", "field": {"name": "unfilledHole", "term": {"variable": "t"}}}}}}}},
                                                                                                "argument": {
                                                                                                  "application": {
                                                                                                    "function": {
                                                                                                      "application": {
                                                                                                        "function": {
                                                                                                          "application": {
                                                                                                            "function": {
                                                                                                              "typeApplication": {
                                                                                                                "body": {
                                                                                                                  "application": {
                                                                                                                    "function": {"typeApplication": {"body": {"variable": "hydra.core.decode.diff.hole"}, "type": {"variable": "t"}}},
                                                                                                                    "argument": {"variable": "t"}}},
                                                                                                                "type": {"variable": "s"}}},
                                                                                                            "argument": {"variable": "s"}}},
                                                                                                        "argument": {"variable": "cx"}}},
                                                                                                    "argument": {"variable": "input"}}}}}}}}},
                                                                                    "type": {"variable": "hydra.core.model.Name"}}},
                                                                                "type": {
                                                                                  "function": {
                                                                                    "domain": {"variable": "hydra.core.model.Term"},
                                                                                    "codomain": {
                                                                                      "either": {
                                                                                        "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                                        "right": {
                                                                                          "application": {
                                                                                            "function": {
                                                                                              "application": {
                                                                                                "function": {"application": {"function": {"variable": "hydra.core.diff.MigrationError"}, "argument": {"variable": "t"}}},
                                                                                                "argument": {"variable": "v"}}},
                                                                                            "argument": {"variable": "s"}}}}}}}}}]}}},
                                                                    "typeScheme": {
                                                                      "variables": [],
                                                                      "body": {
                                                                        "map": {
                                                                          "keys": {"variable": "hydra.core.model.Name"},
                                                                          "values": {
                                                                            "function": {
                                                                              "domain": {"variable": "hydra.core.model.Term"},
                                                                              "codomain": {
                                                                                "either": {
                                                                                  "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                                  "right": {
                                                                                    "application": {
                                                                                      "function": {
                                                                                        "application": {
                                                                                          "function": {"application": {"function": {"variable": "hydra.core.diff.MigrationError"}, "argument": {"variable": "t"}}},
                                                                                          "argument": {"variable": "v"}}},
                                                                                      "argument": {"variable": "s"}}}}}}}}},
                                                                      "constraints": []}}],
                                                                "body": {
                                                                  "application": {
                                                                    "function": {
                                                                      "application": {
                                                                        "function": {
                                                                          "application": {
                                                                            "function": {
                                                                              "typeApplication": {
                                                                                "body": {
                                                                                  "typeApplication": {
                                                                                    "body": {"variable": "hydra.core.lib.optionals.match"},
                                                                                    "type": {
                                                                                      "function": {
                                                                                        "domain": {"variable": "hydra.core.model.Term"},
                                                                                        "codomain": {
                                                                                          "either": {
                                                                                            "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                                            "right": {
                                                                                              "application": {
                                                                                                "function": {
                                                                                                  "application": {
                                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.MigrationError"}, "argument": {"variable": "t"}}},
                                                                                                    "argument": {"variable": "v"}}},
                                                                                                "argument": {"variable": "s"}}}}}}}}},
                                                                                "type": {
                                                                                  "either": {
                                                                                    "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                                    "right": {
                                                                                      "application": {
                                                                                        "function": {
                                                                                          "application": {
                                                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.MigrationError"}, "argument": {"variable": "t"}}},
                                                                                            "argument": {"variable": "v"}}},
                                                                                        "argument": {"variable": "s"}}}}}}},
                                                                            "argument": {
                                                                              "application": {
                                                                                "function": {
                                                                                  "application": {
                                                                                    "function": {
                                                                                      "typeApplication": {
                                                                                        "body": {"typeApplication": {"body": {"variable": "hydra.core.lib.maps.lookup"}, "type": {"variable": "hydra.core.model.Name"}}},
                                                                                        "type": {
                                                                                          "function": {
                                                                                            "domain": {"variable": "hydra.core.model.Term"},
                                                                                            "codomain": {
                                                                                              "either": {
                                                                                                "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                                                "right": {
                                                                                                  "application": {
                                                                                                    "function": {
                                                                                                      "application": {
                                                                                                        "function": {"application": {"function": {"variable": "hydra.core.diff.MigrationError"}, "argument": {"variable": "t"}}},
                                                                                                        "argument": {"variable": "v"}}},
                                                                                                    "argument": {"variable": "s"}}}}}}}}},
                                                                                    "argument": {"variable": "fname"}}},
                                                                                "argument": {"variable": "variantMap"}}}}},
                                                                        "argument": {
                                                                          "typeApplication": {
                                                                            "body": {
                                                                              "typeApplication": {
                                                                                "body": {
                                                                                  "either": {
                                                                                    "left": {
                                                                                      "wrap": {
                                                                                        "typeName": "hydra.core.errors.DecodingError",
                                                                                        "body": {
                                                                                          "application": {
                                                                                            "function": {"variable": "hydra.core.lib.strings.concat"},
                                                                                            "argument": {
                                                                                              "list": [
                                                                                                {"literal": {"string": "no such field "}},
                                                                                                {"application": {"function": {"unwrap": "hydra.core.model.Name"}, "argument": {"variable": "fname"}}},
                                                                                                {"literal": {"string": " in union"}}]}}}}}}},
                                                                                "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                            "type": {
                                                                              "application": {
                                                                                "function": {
                                                                                  "application": {
                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.MigrationError"}, "argument": {"variable": "t"}}},
                                                                                    "argument": {"variable": "v"}}},
                                                                                "argument": {"variable": "s"}}}}}}},
                                                                    "argument": {
                                                                      "lambda": {
                                                                        "parameter": "f",
                                                                        "domain": {
                                                                          "function": {
                                                                            "domain": {"variable": "hydra.core.model.Term"},
                                                                            "codomain": {
                                                                              "either": {
                                                                                "left": {"variable": "hydra.core.errors.DecodingError"},
                                                                                "right": {
                                                                                  "application": {
                                                                                    "function": {
                                                                                      "application": {
                                                                                        "function": {"application": {"function": {"variable": "hydra.core.diff.MigrationError"}, "argument": {"variable": "t"}}},
                                                                                        "argument": {"variable": "v"}}},
                                                                                    "argument": {"variable": "s"}}}}}}},
                                                                        "body": {"application": {"function": {"variable": "f"}, "argument": {"variable": "fterm"}}}}}}}}}}}}]}},
                                                "argument": {"variable": "stripped"}}}}}}},
                                    "argument": {
                                      "application": {
                                        "function": {
                                          "application": {"function": {"variable": "hydra.core.extract.model.stripWithDecodingError"}, "argument": {"variable": "cx"}}},
                                        "argument": {"variable": "raw"}}}}}}}}}}}}}}},
            "annotation": {
              "map": [{"key": {"variable": "description"}, "value": {"literal": {"string": "Decoder for hydra.core.diff.MigrationError"}}}]}}}}},
    {
      "term": {
        "name": "hydra.core.decode.diff.migrationPlan",
        "signature": {
          "typeParameters": [
            {"name": "n", "constraints": [{"simple": "ordering"}]},
            {"name": "t", "constraints": []},
            {"name": "s", "constraints": []}],
          "parameters": [
            {
              "name": "arg0",
              "type": {
                "function": {
                  "domain": {"variable": "hydra.core.graph.Graph"},
                  "codomain": {
                    "function": {
                      "domain": {"variable": "hydra.core.model.Term"},
                      "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "n"}}}}}}},
              "isLazy": false},
            {
              "name": "arg1",
              "type": {
                "function": {
                  "domain": {"variable": "hydra.core.graph.Graph"},
                  "codomain": {
                    "function": {
                      "domain": {"variable": "hydra.core.model.Term"},
                      "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "t"}}}}}}},
              "isLazy": false},
            {
              "name": "arg2",
              "type": {
                "function": {
                  "domain": {"variable": "hydra.core.graph.Graph"},
                  "codomain": {
                    "function": {
                      "domain": {"variable": "hydra.core.model.Term"},
                      "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "s"}}}}}}},
              "isLazy": false},
            {"name": "arg3", "type": {"variable": "hydra.core.graph.Graph"}, "isLazy": false},
            {"name": "arg4", "type": {"variable": "hydra.core.model.Term"}, "isLazy": false}],
          "result": {
            "type": {
              "either": {
                "left": {"variable": "hydra.core.errors.DecodingError"},
                "right": {
                  "application": {
                    "function": {
                      "application": {
                        "function": {"application": {"function": {"variable": "hydra.core.diff.MigrationPlan"}, "argument": {"variable": "n"}}},
                        "argument": {"variable": "t"}}},
                    "argument": {"variable": "s"}}}}}}},
        "body": {
          "annotated": {
            "body": {
              "lambda": {
                "parameter": "n",
                "domain": {
                  "function": {
                    "domain": {"variable": "hydra.core.graph.Graph"},
                    "codomain": {
                      "function": {
                        "domain": {"variable": "hydra.core.model.Term"},
                        "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "n"}}}}}}},
                "body": {
                  "lambda": {
                    "parameter": "t",
                    "domain": {
                      "function": {
                        "domain": {"variable": "hydra.core.graph.Graph"},
                        "codomain": {
                          "function": {
                            "domain": {"variable": "hydra.core.model.Term"},
                            "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "t"}}}}}}},
                    "body": {
                      "lambda": {
                        "parameter": "s",
                        "domain": {
                          "function": {
                            "domain": {"variable": "hydra.core.graph.Graph"},
                            "codomain": {
                              "function": {
                                "domain": {"variable": "hydra.core.model.Term"},
                                "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "s"}}}}}}},
                        "body": {
                          "lambda": {
                            "parameter": "cx",
                            "domain": {"variable": "hydra.core.graph.Graph"},
                            "body": {
                              "lambda": {
                                "parameter": "raw",
                                "domain": {"variable": "hydra.core.model.Term"},
                                "body": {
                                  "application": {
                                    "function": {
                                      "application": {
                                        "function": {
                                          "application": {
                                            "function": {
                                              "typeApplication": {
                                                "body": {
                                                  "typeApplication": {
                                                    "body": {
                                                      "typeApplication": {"body": {"variable": "hydra.core.lib.eithers.either"}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                    "type": {"variable": "hydra.core.model.Term"}}},
                                                "type": {
                                                  "either": {
                                                    "left": {"variable": "hydra.core.errors.DecodingError"},
                                                    "right": {
                                                      "application": {
                                                        "function": {
                                                          "application": {
                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.MigrationPlan"}, "argument": {"variable": "n"}}},
                                                            "argument": {"variable": "t"}}},
                                                        "argument": {"variable": "s"}}}}}}},
                                            "argument": {
                                              "lambda": {
                                                "parameter": "err",
                                                "domain": {"variable": "hydra.core.errors.DecodingError"},
                                                "body": {
                                                  "typeApplication": {
                                                    "body": {
                                                      "typeApplication": {"body": {"either": {"left": {"variable": "err"}}}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                    "type": {
                                                      "application": {
                                                        "function": {
                                                          "application": {
                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.MigrationPlan"}, "argument": {"variable": "n"}}},
                                                            "argument": {"variable": "t"}}},
                                                        "argument": {"variable": "s"}}}}}}}}},
                                        "argument": {
                                          "lambda": {
                                            "parameter": "stripped",
                                            "domain": {"variable": "hydra.core.model.Term"},
                                            "body": {
                                              "application": {
                                                "function": {
                                                  "cases": {
                                                    "typeName": "hydra.core.model.Term",
                                                    "default": {
                                                      "typeApplication": {
                                                        "body": {
                                                          "typeApplication": {
                                                            "body": {
                                                              "either": {
                                                                "left": {
                                                                  "wrap": {
                                                                    "typeName": "hydra.core.errors.DecodingError",
                                                                    "body": {"literal": {"string": "expected a record of type hydra.core.diff.MigrationPlan"}}}}}},
                                                            "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                        "type": {
                                                          "application": {
                                                            "function": {
                                                              "application": {
                                                                "function": {"application": {"function": {"variable": "hydra.core.diff.MigrationPlan"}, "argument": {"variable": "n"}}},
                                                                "argument": {"variable": "t"}}},
                                                            "argument": {"variable": "s"}}}}},
                                                    "cases": [
                                                      {
                                                        "name": "record",
                                                        "handler": {
                                                          "lambda": {
                                                            "parameter": "record",
                                                            "domain": {"variable": "hydra.core.model.Record"},
                                                            "body": {
                                                              "let": {
                                                                "bindings": [
                                                                  {
                                                                    "name": "fieldMap",
                                                                    "term": {"application": {"function": {"variable": "hydra.core.extract.model.toFieldMap"}, "argument": {"variable": "record"}}},
                                                                    "typeScheme": {
                                                                      "variables": [],
                                                                      "body": {"map": {"keys": {"variable": "hydra.core.model.Name"}, "values": {"variable": "hydra.core.model.Term"}}},
                                                                      "constraints": []}}],
                                                                "body": {
                                                                  "application": {
                                                                    "function": {
                                                                      "application": {
                                                                        "function": {
                                                                          "typeApplication": {
                                                                            "body": {
                                                                              "typeApplication": {
                                                                                "body": {
                                                                                  "typeApplication": {"body": {"variable": "hydra.core.lib.eithers.bind"}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                "type": {
                                                                                  "map": {
                                                                                    "keys": {"variable": "n"},
                                                                                    "values": {
                                                                                      "application": {
                                                                                        "function": {"application": {"function": {"variable": "hydra.core.diff.Edit"}, "argument": {"variable": "t"}}},
                                                                                        "argument": {"variable": "s"}}}}}}},
                                                                            "type": {
                                                                              "application": {
                                                                                "function": {
                                                                                  "application": {
                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.MigrationPlan"}, "argument": {"variable": "n"}}},
                                                                                    "argument": {"variable": "t"}}},
                                                                                "argument": {"variable": "s"}}}}},
                                                                        "argument": {
                                                                          "application": {
                                                                            "function": {
                                                                              "application": {
                                                                                "function": {
                                                                                  "application": {
                                                                                    "function": {
                                                                                      "application": {
                                                                                        "function": {
                                                                                          "typeApplication": {
                                                                                            "body": {
                                                                                              "typeApplication": {
                                                                                                "body": {
                                                                                                  "typeApplication": {"body": {"variable": "hydra.core.extract.model.requireField"}, "type": {"variable": "hydra.core.graph.Graph"}}},
                                                                                                "type": {"variable": "hydra.core.model.Term"}}},
                                                                                            "type": {
                                                                                              "map": {
                                                                                                "keys": {"variable": "n"},
                                                                                                "values": {
                                                                                                  "application": {
                                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.Edit"}, "argument": {"variable": "t"}}},
                                                                                                    "argument": {"variable": "s"}}}}}}},
                                                                                        "argument": {"literal": {"string": "edits"}}}},
                                                                                    "argument": {
                                                                                      "application": {
                                                                                        "function": {
                                                                                          "application": {
                                                                                            "function": {
                                                                                              "typeApplication": {
                                                                                                "body": {"typeApplication": {"body": {"variable": "hydra.core.extract.model.decodeMap"}, "type": {"variable": "n"}}},
                                                                                                "type": {
                                                                                                  "application": {
                                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.Edit"}, "argument": {"variable": "t"}}},
                                                                                                    "argument": {"variable": "s"}}}}},
                                                                                            "argument": {"variable": "n"}}},
                                                                                        "argument": {
                                                                                          "application": {
                                                                                            "function": {
                                                                                              "typeApplication": {
                                                                                                "body": {
                                                                                                  "application": {
                                                                                                    "function": {"typeApplication": {"body": {"variable": "hydra.core.decode.diff.edit"}, "type": {"variable": "t"}}},
                                                                                                    "argument": {"variable": "t"}}},
                                                                                                "type": {"variable": "s"}}},
                                                                                            "argument": {"variable": "s"}}}}}}},
                                                                                "argument": {"variable": "fieldMap"}}},
                                                                            "argument": {"variable": "cx"}}}}},
                                                                    "argument": {
                                                                      "lambda": {
                                                                        "parameter": "field_edits",
                                                                        "domain": {
                                                                          "map": {
                                                                            "keys": {"variable": "n"},
                                                                            "values": {
                                                                              "application": {
                                                                                "function": {"application": {"function": {"variable": "hydra.core.diff.Edit"}, "argument": {"variable": "t"}}},
                                                                                "argument": {"variable": "s"}}}}},
                                                                        "body": {
                                                                          "application": {
                                                                            "function": {
                                                                              "application": {
                                                                                "function": {
                                                                                  "typeApplication": {
                                                                                    "body": {
                                                                                      "typeApplication": {
                                                                                        "body": {
                                                                                          "typeApplication": {"body": {"variable": "hydra.core.lib.eithers.bind"}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                        "type": {
                                                                                          "list": {
                                                                                            "application": {
                                                                                              "function": {
                                                                                                "application": {
                                                                                                  "function": {"application": {"function": {"variable": "hydra.core.diff.SchemaHole"}, "argument": {"variable": "n"}}},
                                                                                                  "argument": {"variable": "t"}}},
                                                                                              "argument": {"variable": "s"}}}}}},
                                                                                    "type": {
                                                                                      "application": {
                                                                                        "function": {
                                                                                          "application": {
                                                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.MigrationPlan"}, "argument": {"variable": "n"}}},
                                                                                            "argument": {"variable": "t"}}},
                                                                                        "argument": {"variable": "s"}}}}},
                                                                                "argument": {
                                                                                  "application": {
                                                                                    "function": {
                                                                                      "application": {
                                                                                        "function": {
                                                                                          "application": {
                                                                                            "function": {
                                                                                              "application": {
                                                                                                "function": {
                                                                                                  "typeApplication": {
                                                                                                    "body": {
                                                                                                      "typeApplication": {
                                                                                                        "body": {
                                                                                                          "typeApplication": {"body": {"variable": "hydra.core.extract.model.requireField"}, "type": {"variable": "hydra.core.graph.Graph"}}},
                                                                                                        "type": {"variable": "hydra.core.model.Term"}}},
                                                                                                    "type": {
                                                                                                      "list": {
                                                                                                        "application": {
                                                                                                          "function": {
                                                                                                            "application": {
                                                                                                              "function": {"application": {"function": {"variable": "hydra.core.diff.SchemaHole"}, "argument": {"variable": "n"}}},
                                                                                                              "argument": {"variable": "t"}}},
                                                                                                          "argument": {"variable": "s"}}}}}},
                                                                                                "argument": {"literal": {"string": "holes"}}}},
                                                                                            "argument": {
                                                                                              "application": {
                                                                                                "function": {
                                                                                                  "typeApplication": {
                                                                                                    "body": {"variable": "hydra.core.extract.model.decodeList"},
                                                                                                    "type": {
                                                                                                      "application": {
                                                                                                        "function": {
                                                                                                          "application": {
                                                                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.SchemaHole"}, "argument": {"variable": "n"}}},
                                                                                                            "argument": {"variable": "t"}}},
                                                                                                        "argument": {"variable": "s"}}}}},
                                                                                                "argument": {
                                                                                                  "application": {
                                                                                                    "function": {
                                                                                                      "typeApplication": {
                                                                                                        "body": {
                                                                                                          "application": {
                                                                                                            "function": {
                                                                                                              "typeApplication": {
                                                                                                                "body": {
                                                                                                                  "application": {
                                                                                                                    "function": {"typeApplication": {"body": {"variable": "hydra.core.decode.diff.schemaHole"}, "type": {"variable": "n"}}},
                                                                                                                    "argument": {"variable": "n"}}},
                                                                                                                "type": {"variable": "t"}}},
                                                                                                            "argument": {"variable": "t"}}},
                                                                                                        "type": {"variable": "s"}}},
                                                                                                    "argument": {"variable": "s"}}}}}}},
                                                                                        "argument": {"variable": "fieldMap"}}},
                                                                                    "argument": {"variable": "cx"}}}}},
                                                                            "argument": {
                                                                              "lambda": {
                                                                                "parameter": "field_holes",
                                                                                "domain": {
                                                                                  "list": {
                                                                                    "application": {
                                                                                      "function": {
                                                                                        "application": {
                                                                                          "function": {"application": {"function": {"variable": "hydra.core.diff.SchemaHole"}, "argument": {"variable": "n"}}},
                                                                                          "argument": {"variable": "t"}}},
                                                                                      "argument": {"variable": "s"}}}},
                                                                                "body": {
                                                                                  "typeApplication": {
                                                                                    "body": {
                                                                                      "typeApplication": {
                                                                                        "body": {
                                                                                          "either": {
                                                                                            "right": {
                                                                                              "record": {
                                                                                                "typeName": "hydra.core.diff.MigrationPlan",
                                                                                                "fields": [{"name": "edits", "term": {"variable": "field_edits"}}, {"name": "holes", "term": {"variable": "field_holes"}}]}}}},
                                                                                        "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                    "type": {
                                                                                      "application": {
                                                                                        "function": {
                                                                                          "application": {
                                                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.MigrationPlan"}, "argument": {"variable": "n"}}},
                                                                                            "argument": {"variable": "t"}}},
                                                                                        "argument": {"variable": "s"}}}}}}}}}}}}}}}}}}]}},
                                                "argument": {"variable": "stripped"}}}}}}},
                                    "argument": {
                                      "application": {
                                        "function": {
                                          "application": {"function": {"variable": "hydra.core.extract.model.stripWithDecodingError"}, "argument": {"variable": "cx"}}},
                                        "argument": {"variable": "raw"}}}}}}}}}}}}}}},
            "annotation": {
              "map": [{"key": {"variable": "description"}, "value": {"literal": {"string": "Decoder for hydra.core.diff.MigrationPlan"}}}]}}}}},
    {
      "term": {
        "name": "hydra.core.decode.diff.mistyped",
        "signature": {
          "typeParameters": [{"name": "t", "constraints": []}, {"name": "v", "constraints": []}],
          "parameters": [
            {
              "name": "arg0",
              "type": {
                "function": {
                  "domain": {"variable": "hydra.core.graph.Graph"},
                  "codomain": {
                    "function": {
                      "domain": {"variable": "hydra.core.model.Term"},
                      "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "t"}}}}}}},
              "isLazy": false},
            {
              "name": "arg1",
              "type": {
                "function": {
                  "domain": {"variable": "hydra.core.graph.Graph"},
                  "codomain": {
                    "function": {
                      "domain": {"variable": "hydra.core.model.Term"},
                      "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "v"}}}}}}},
              "isLazy": false},
            {"name": "arg2", "type": {"variable": "hydra.core.graph.Graph"}, "isLazy": false},
            {"name": "arg3", "type": {"variable": "hydra.core.model.Term"}, "isLazy": false}],
          "result": {
            "type": {
              "either": {
                "left": {"variable": "hydra.core.errors.DecodingError"},
                "right": {
                  "application": {
                    "function": {"application": {"function": {"variable": "hydra.core.diff.Mistyped"}, "argument": {"variable": "t"}}},
                    "argument": {"variable": "v"}}}}}}},
        "body": {
          "annotated": {
            "body": {
              "lambda": {
                "parameter": "t",
                "domain": {
                  "function": {
                    "domain": {"variable": "hydra.core.graph.Graph"},
                    "codomain": {
                      "function": {
                        "domain": {"variable": "hydra.core.model.Term"},
                        "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "t"}}}}}}},
                "body": {
                  "lambda": {
                    "parameter": "v",
                    "domain": {
                      "function": {
                        "domain": {"variable": "hydra.core.graph.Graph"},
                        "codomain": {
                          "function": {
                            "domain": {"variable": "hydra.core.model.Term"},
                            "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "v"}}}}}}},
                    "body": {
                      "lambda": {
                        "parameter": "cx",
                        "domain": {"variable": "hydra.core.graph.Graph"},
                        "body": {
                          "lambda": {
                            "parameter": "raw",
                            "domain": {"variable": "hydra.core.model.Term"},
                            "body": {
                              "application": {
                                "function": {
                                  "application": {
                                    "function": {
                                      "application": {
                                        "function": {
                                          "typeApplication": {
                                            "body": {
                                              "typeApplication": {
                                                "body": {
                                                  "typeApplication": {"body": {"variable": "hydra.core.lib.eithers.either"}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                "type": {"variable": "hydra.core.model.Term"}}},
                                            "type": {
                                              "either": {
                                                "left": {"variable": "hydra.core.errors.DecodingError"},
                                                "right": {
                                                  "application": {
                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.Mistyped"}, "argument": {"variable": "t"}}},
                                                    "argument": {"variable": "v"}}}}}}},
                                        "argument": {
                                          "lambda": {
                                            "parameter": "err",
                                            "domain": {"variable": "hydra.core.errors.DecodingError"},
                                            "body": {
                                              "typeApplication": {
                                                "body": {
                                                  "typeApplication": {"body": {"either": {"left": {"variable": "err"}}}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                "type": {
                                                  "application": {
                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.Mistyped"}, "argument": {"variable": "t"}}},
                                                    "argument": {"variable": "v"}}}}}}}}},
                                    "argument": {
                                      "lambda": {
                                        "parameter": "stripped",
                                        "domain": {"variable": "hydra.core.model.Term"},
                                        "body": {
                                          "application": {
                                            "function": {
                                              "cases": {
                                                "typeName": "hydra.core.model.Term",
                                                "default": {
                                                  "typeApplication": {
                                                    "body": {
                                                      "typeApplication": {
                                                        "body": {
                                                          "either": {
                                                            "left": {
                                                              "wrap": {
                                                                "typeName": "hydra.core.errors.DecodingError",
                                                                "body": {"literal": {"string": "expected a record of type hydra.core.diff.Mistyped"}}}}}},
                                                        "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                    "type": {
                                                      "application": {
                                                        "function": {"application": {"function": {"variable": "hydra.core.diff.Mistyped"}, "argument": {"variable": "t"}}},
                                                        "argument": {"variable": "v"}}}}},
                                                "cases": [
                                                  {
                                                    "name": "record",
                                                    "handler": {
                                                      "lambda": {
                                                        "parameter": "record",
                                                        "domain": {"variable": "hydra.core.model.Record"},
                                                        "body": {
                                                          "let": {
                                                            "bindings": [
                                                              {
                                                                "name": "fieldMap",
                                                                "term": {"application": {"function": {"variable": "hydra.core.extract.model.toFieldMap"}, "argument": {"variable": "record"}}},
                                                                "typeScheme": {
                                                                  "variables": [],
                                                                  "body": {"map": {"keys": {"variable": "hydra.core.model.Name"}, "values": {"variable": "hydra.core.model.Term"}}},
                                                                  "constraints": []}}],
                                                            "body": {
                                                              "application": {
                                                                "function": {
                                                                  "application": {
                                                                    "function": {
                                                                      "typeApplication": {
                                                                        "body": {
                                                                          "typeApplication": {
                                                                            "body": {
                                                                              "typeApplication": {"body": {"variable": "hydra.core.lib.eithers.bind"}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                            "type": {"variable": "v"}}},
                                                                        "type": {
                                                                          "application": {
                                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.Mistyped"}, "argument": {"variable": "t"}}},
                                                                            "argument": {"variable": "v"}}}}},
                                                                    "argument": {
                                                                      "application": {
                                                                        "function": {
                                                                          "application": {
                                                                            "function": {
                                                                              "application": {
                                                                                "function": {
                                                                                  "application": {
                                                                                    "function": {
                                                                                      "typeApplication": {
                                                                                        "body": {
                                                                                          "typeApplication": {
                                                                                            "body": {
                                                                                              "typeApplication": {"body": {"variable": "hydra.core.extract.model.requireField"}, "type": {"variable": "hydra.core.graph.Graph"}}},
                                                                                            "type": {"variable": "hydra.core.model.Term"}}},
                                                                                        "type": {"variable": "v"}}},
                                                                                    "argument": {"literal": {"string": "value"}}}},
                                                                                "argument": {"variable": "v"}}},
                                                                            "argument": {"variable": "fieldMap"}}},
                                                                        "argument": {"variable": "cx"}}}}},
                                                                "argument": {
                                                                  "lambda": {
                                                                    "parameter": "field_value",
                                                                    "domain": {"variable": "v"},
                                                                    "body": {
                                                                      "application": {
                                                                        "function": {
                                                                          "application": {
                                                                            "function": {
                                                                              "typeApplication": {
                                                                                "body": {
                                                                                  "typeApplication": {
                                                                                    "body": {
                                                                                      "typeApplication": {"body": {"variable": "hydra.core.lib.eithers.bind"}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                    "type": {"variable": "t"}}},
                                                                                "type": {
                                                                                  "application": {
                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.Mistyped"}, "argument": {"variable": "t"}}},
                                                                                    "argument": {"variable": "v"}}}}},
                                                                            "argument": {
                                                                              "application": {
                                                                                "function": {
                                                                                  "application": {
                                                                                    "function": {
                                                                                      "application": {
                                                                                        "function": {
                                                                                          "application": {
                                                                                            "function": {
                                                                                              "typeApplication": {
                                                                                                "body": {
                                                                                                  "typeApplication": {
                                                                                                    "body": {
                                                                                                      "typeApplication": {"body": {"variable": "hydra.core.extract.model.requireField"}, "type": {"variable": "hydra.core.graph.Graph"}}},
                                                                                                    "type": {"variable": "hydra.core.model.Term"}}},
                                                                                                "type": {"variable": "t"}}},
                                                                                            "argument": {"literal": {"string": "type"}}}},
                                                                                        "argument": {"variable": "t"}}},
                                                                                    "argument": {"variable": "fieldMap"}}},
                                                                                "argument": {"variable": "cx"}}}}},
                                                                        "argument": {
                                                                          "lambda": {
                                                                            "parameter": "field_type",
                                                                            "domain": {"variable": "t"},
                                                                            "body": {
                                                                              "typeApplication": {
                                                                                "body": {
                                                                                  "typeApplication": {
                                                                                    "body": {
                                                                                      "either": {
                                                                                        "right": {
                                                                                          "record": {
                                                                                            "typeName": "hydra.core.diff.Mistyped",
                                                                                            "fields": [{"name": "value", "term": {"variable": "field_value"}}, {"name": "type", "term": {"variable": "field_type"}}]}}}},
                                                                                    "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                "type": {
                                                                                  "application": {
                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.Mistyped"}, "argument": {"variable": "t"}}},
                                                                                    "argument": {"variable": "v"}}}}}}}}}}}}}}}}}}]}},
                                            "argument": {"variable": "stripped"}}}}}}},
                                "argument": {
                                  "application": {
                                    "function": {
                                      "application": {"function": {"variable": "hydra.core.extract.model.stripWithDecodingError"}, "argument": {"variable": "cx"}}},
                                    "argument": {"variable": "raw"}}}}}}}}}}}}},
            "annotation": {
              "map": [{"key": {"variable": "description"}, "value": {"literal": {"string": "Decoder for hydra.core.diff.Mistyped"}}}]}}}}},
    {
      "term": {
        "name": "hydra.core.decode.diff.schemaHole",
        "signature": {
          "typeParameters": [{"name": "n", "constraints": []}, {"name": "t", "constraints": []}, {"name": "s", "constraints": []}],
          "parameters": [
            {
              "name": "arg0",
              "type": {
                "function": {
                  "domain": {"variable": "hydra.core.graph.Graph"},
                  "codomain": {
                    "function": {
                      "domain": {"variable": "hydra.core.model.Term"},
                      "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "n"}}}}}}},
              "isLazy": false},
            {
              "name": "arg1",
              "type": {
                "function": {
                  "domain": {"variable": "hydra.core.graph.Graph"},
                  "codomain": {
                    "function": {
                      "domain": {"variable": "hydra.core.model.Term"},
                      "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "t"}}}}}}},
              "isLazy": false},
            {
              "name": "arg2",
              "type": {
                "function": {
                  "domain": {"variable": "hydra.core.graph.Graph"},
                  "codomain": {
                    "function": {
                      "domain": {"variable": "hydra.core.model.Term"},
                      "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "s"}}}}}}},
              "isLazy": false},
            {"name": "arg3", "type": {"variable": "hydra.core.graph.Graph"}, "isLazy": false},
            {"name": "arg4", "type": {"variable": "hydra.core.model.Term"}, "isLazy": false}],
          "result": {
            "type": {
              "either": {
                "left": {"variable": "hydra.core.errors.DecodingError"},
                "right": {
                  "application": {
                    "function": {
                      "application": {
                        "function": {"application": {"function": {"variable": "hydra.core.diff.SchemaHole"}, "argument": {"variable": "n"}}},
                        "argument": {"variable": "t"}}},
                    "argument": {"variable": "s"}}}}}}},
        "body": {
          "annotated": {
            "body": {
              "lambda": {
                "parameter": "n",
                "domain": {
                  "function": {
                    "domain": {"variable": "hydra.core.graph.Graph"},
                    "codomain": {
                      "function": {
                        "domain": {"variable": "hydra.core.model.Term"},
                        "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "n"}}}}}}},
                "body": {
                  "lambda": {
                    "parameter": "t",
                    "domain": {
                      "function": {
                        "domain": {"variable": "hydra.core.graph.Graph"},
                        "codomain": {
                          "function": {
                            "domain": {"variable": "hydra.core.model.Term"},
                            "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "t"}}}}}}},
                    "body": {
                      "lambda": {
                        "parameter": "s",
                        "domain": {
                          "function": {
                            "domain": {"variable": "hydra.core.graph.Graph"},
                            "codomain": {
                              "function": {
                                "domain": {"variable": "hydra.core.model.Term"},
                                "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "s"}}}}}}},
                        "body": {
                          "lambda": {
                            "parameter": "cx",
                            "domain": {"variable": "hydra.core.graph.Graph"},
                            "body": {
                              "lambda": {
                                "parameter": "raw",
                                "domain": {"variable": "hydra.core.model.Term"},
                                "body": {
                                  "application": {
                                    "function": {
                                      "application": {
                                        "function": {
                                          "application": {
                                            "function": {
                                              "typeApplication": {
                                                "body": {
                                                  "typeApplication": {
                                                    "body": {
                                                      "typeApplication": {"body": {"variable": "hydra.core.lib.eithers.either"}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                    "type": {"variable": "hydra.core.model.Term"}}},
                                                "type": {
                                                  "either": {
                                                    "left": {"variable": "hydra.core.errors.DecodingError"},
                                                    "right": {
                                                      "application": {
                                                        "function": {
                                                          "application": {
                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.SchemaHole"}, "argument": {"variable": "n"}}},
                                                            "argument": {"variable": "t"}}},
                                                        "argument": {"variable": "s"}}}}}}},
                                            "argument": {
                                              "lambda": {
                                                "parameter": "err",
                                                "domain": {"variable": "hydra.core.errors.DecodingError"},
                                                "body": {
                                                  "typeApplication": {
                                                    "body": {
                                                      "typeApplication": {"body": {"either": {"left": {"variable": "err"}}}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                    "type": {
                                                      "application": {
                                                        "function": {
                                                          "application": {
                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.SchemaHole"}, "argument": {"variable": "n"}}},
                                                            "argument": {"variable": "t"}}},
                                                        "argument": {"variable": "s"}}}}}}}}},
                                        "argument": {
                                          "lambda": {
                                            "parameter": "stripped",
                                            "domain": {"variable": "hydra.core.model.Term"},
                                            "body": {
                                              "application": {
                                                "function": {
                                                  "cases": {
                                                    "typeName": "hydra.core.model.Term",
                                                    "default": {
                                                      "typeApplication": {
                                                        "body": {
                                                          "typeApplication": {
                                                            "body": {
                                                              "either": {
                                                                "left": {
                                                                  "wrap": {
                                                                    "typeName": "hydra.core.errors.DecodingError",
                                                                    "body": {"literal": {"string": "expected a record of type hydra.core.diff.SchemaHole"}}}}}},
                                                            "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                        "type": {
                                                          "application": {
                                                            "function": {
                                                              "application": {
                                                                "function": {"application": {"function": {"variable": "hydra.core.diff.SchemaHole"}, "argument": {"variable": "n"}}},
                                                                "argument": {"variable": "t"}}},
                                                            "argument": {"variable": "s"}}}}},
                                                    "cases": [
                                                      {
                                                        "name": "record",
                                                        "handler": {
                                                          "lambda": {
                                                            "parameter": "record",
                                                            "domain": {"variable": "hydra.core.model.Record"},
                                                            "body": {
                                                              "let": {
                                                                "bindings": [
                                                                  {
                                                                    "name": "fieldMap",
                                                                    "term": {"application": {"function": {"variable": "hydra.core.extract.model.toFieldMap"}, "argument": {"variable": "record"}}},
                                                                    "typeScheme": {
                                                                      "variables": [],
                                                                      "body": {"map": {"keys": {"variable": "hydra.core.model.Name"}, "values": {"variable": "hydra.core.model.Term"}}},
                                                                      "constraints": []}}],
                                                                "body": {
                                                                  "application": {
                                                                    "function": {
                                                                      "application": {
                                                                        "function": {
                                                                          "typeApplication": {
                                                                            "body": {
                                                                              "typeApplication": {
                                                                                "body": {
                                                                                  "typeApplication": {"body": {"variable": "hydra.core.lib.eithers.bind"}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                "type": {"variable": "n"}}},
                                                                            "type": {
                                                                              "application": {
                                                                                "function": {
                                                                                  "application": {
                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.SchemaHole"}, "argument": {"variable": "n"}}},
                                                                                    "argument": {"variable": "t"}}},
                                                                                "argument": {"variable": "s"}}}}},
                                                                        "argument": {
                                                                          "application": {
                                                                            "function": {
                                                                              "application": {
                                                                                "function": {
                                                                                  "application": {
                                                                                    "function": {
                                                                                      "application": {
                                                                                        "function": {
                                                                                          "typeApplication": {
                                                                                            "body": {
                                                                                              "typeApplication": {
                                                                                                "body": {
                                                                                                  "typeApplication": {"body": {"variable": "hydra.core.extract.model.requireField"}, "type": {"variable": "hydra.core.graph.Graph"}}},
                                                                                                "type": {"variable": "hydra.core.model.Term"}}},
                                                                                            "type": {"variable": "n"}}},
                                                                                        "argument": {"literal": {"string": "typeName"}}}},
                                                                                    "argument": {"variable": "n"}}},
                                                                                "argument": {"variable": "fieldMap"}}},
                                                                            "argument": {"variable": "cx"}}}}},
                                                                    "argument": {
                                                                      "lambda": {
                                                                        "parameter": "field_typeName",
                                                                        "domain": {"variable": "n"},
                                                                        "body": {
                                                                          "application": {
                                                                            "function": {
                                                                              "application": {
                                                                                "function": {
                                                                                  "typeApplication": {
                                                                                    "body": {
                                                                                      "typeApplication": {
                                                                                        "body": {
                                                                                          "typeApplication": {"body": {"variable": "hydra.core.lib.eithers.bind"}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                        "type": {
                                                                                          "application": {
                                                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.Hole"}, "argument": {"variable": "t"}}},
                                                                                            "argument": {"variable": "s"}}}}},
                                                                                    "type": {
                                                                                      "application": {
                                                                                        "function": {
                                                                                          "application": {
                                                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.SchemaHole"}, "argument": {"variable": "n"}}},
                                                                                            "argument": {"variable": "t"}}},
                                                                                        "argument": {"variable": "s"}}}}},
                                                                                "argument": {
                                                                                  "application": {
                                                                                    "function": {
                                                                                      "application": {
                                                                                        "function": {
                                                                                          "application": {
                                                                                            "function": {
                                                                                              "application": {
                                                                                                "function": {
                                                                                                  "typeApplication": {
                                                                                                    "body": {
                                                                                                      "typeApplication": {
                                                                                                        "body": {
                                                                                                          "typeApplication": {"body": {"variable": "hydra.core.extract.model.requireField"}, "type": {"variable": "hydra.core.graph.Graph"}}},
                                                                                                        "type": {"variable": "hydra.core.model.Term"}}},
                                                                                                    "type": {
                                                                                                      "application": {
                                                                                                        "function": {"application": {"function": {"variable": "hydra.core.diff.Hole"}, "argument": {"variable": "t"}}},
                                                                                                        "argument": {"variable": "s"}}}}},
                                                                                                "argument": {"literal": {"string": "hole"}}}},
                                                                                            "argument": {
                                                                                              "application": {
                                                                                                "function": {
                                                                                                  "typeApplication": {
                                                                                                    "body": {
                                                                                                      "application": {
                                                                                                        "function": {"typeApplication": {"body": {"variable": "hydra.core.decode.diff.hole"}, "type": {"variable": "t"}}},
                                                                                                        "argument": {"variable": "t"}}},
                                                                                                    "type": {"variable": "s"}}},
                                                                                                "argument": {"variable": "s"}}}}},
                                                                                        "argument": {"variable": "fieldMap"}}},
                                                                                    "argument": {"variable": "cx"}}}}},
                                                                            "argument": {
                                                                              "lambda": {
                                                                                "parameter": "field_hole",
                                                                                "domain": {
                                                                                  "application": {
                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.Hole"}, "argument": {"variable": "t"}}},
                                                                                    "argument": {"variable": "s"}}},
                                                                                "body": {
                                                                                  "typeApplication": {
                                                                                    "body": {
                                                                                      "typeApplication": {
                                                                                        "body": {
                                                                                          "either": {
                                                                                            "right": {
                                                                                              "record": {
                                                                                                "typeName": "hydra.core.diff.SchemaHole",
                                                                                                "fields": [{"name": "typeName", "term": {"variable": "field_typeName"}}, {"name": "hole", "term": {"variable": "field_hole"}}]}}}},
                                                                                        "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                    "type": {
                                                                                      "application": {
                                                                                        "function": {
                                                                                          "application": {
                                                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.SchemaHole"}, "argument": {"variable": "n"}}},
                                                                                            "argument": {"variable": "t"}}},
                                                                                        "argument": {"variable": "s"}}}}}}}}}}}}}}}}}}]}},
                                                "argument": {"variable": "stripped"}}}}}}},
                                    "argument": {
                                      "application": {
                                        "function": {
                                          "application": {"function": {"variable": "hydra.core.extract.model.stripWithDecodingError"}, "argument": {"variable": "cx"}}},
                                        "argument": {"variable": "raw"}}}}}}}}}}}}}}},
            "annotation": {
              "map": [{"key": {"variable": "description"}, "value": {"literal": {"string": "Decoder for hydra.core.diff.SchemaHole"}}}]}}}}},
    {
      "term": {
        "name": "hydra.core.decode.diff.stepEdit",
        "signature": {
          "typeParameters": [{"name": "a", "constraints": []}, {"name": "s", "constraints": []}],
          "parameters": [
            {
              "name": "arg0",
              "type": {
                "function": {
                  "domain": {"variable": "hydra.core.graph.Graph"},
                  "codomain": {
                    "function": {
                      "domain": {"variable": "hydra.core.model.Term"},
                      "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "a"}}}}}}},
              "isLazy": false},
            {
              "name": "arg1",
              "type": {
                "function": {
                  "domain": {"variable": "hydra.core.graph.Graph"},
                  "codomain": {
                    "function": {
                      "domain": {"variable": "hydra.core.model.Term"},
                      "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "s"}}}}}}},
              "isLazy": false},
            {"name": "arg2", "type": {"variable": "hydra.core.graph.Graph"}, "isLazy": false},
            {"name": "arg3", "type": {"variable": "hydra.core.model.Term"}, "isLazy": false}],
          "result": {
            "type": {
              "either": {
                "left": {"variable": "hydra.core.errors.DecodingError"},
                "right": {
                  "application": {
                    "function": {"application": {"function": {"variable": "hydra.core.diff.StepEdit"}, "argument": {"variable": "a"}}},
                    "argument": {"variable": "s"}}}}}}},
        "body": {
          "annotated": {
            "body": {
              "lambda": {
                "parameter": "a",
                "domain": {
                  "function": {
                    "domain": {"variable": "hydra.core.graph.Graph"},
                    "codomain": {
                      "function": {
                        "domain": {"variable": "hydra.core.model.Term"},
                        "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "a"}}}}}}},
                "body": {
                  "lambda": {
                    "parameter": "s",
                    "domain": {
                      "function": {
                        "domain": {"variable": "hydra.core.graph.Graph"},
                        "codomain": {
                          "function": {
                            "domain": {"variable": "hydra.core.model.Term"},
                            "codomain": {"either": {"left": {"variable": "hydra.core.errors.DecodingError"}, "right": {"variable": "s"}}}}}}},
                    "body": {
                      "lambda": {
                        "parameter": "cx",
                        "domain": {"variable": "hydra.core.graph.Graph"},
                        "body": {
                          "lambda": {
                            "parameter": "raw",
                            "domain": {"variable": "hydra.core.model.Term"},
                            "body": {
                              "application": {
                                "function": {
                                  "application": {
                                    "function": {
                                      "application": {
                                        "function": {
                                          "typeApplication": {
                                            "body": {
                                              "typeApplication": {
                                                "body": {
                                                  "typeApplication": {"body": {"variable": "hydra.core.lib.eithers.either"}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                "type": {"variable": "hydra.core.model.Term"}}},
                                            "type": {
                                              "either": {
                                                "left": {"variable": "hydra.core.errors.DecodingError"},
                                                "right": {
                                                  "application": {
                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.StepEdit"}, "argument": {"variable": "a"}}},
                                                    "argument": {"variable": "s"}}}}}}},
                                        "argument": {
                                          "lambda": {
                                            "parameter": "err",
                                            "domain": {"variable": "hydra.core.errors.DecodingError"},
                                            "body": {
                                              "typeApplication": {
                                                "body": {
                                                  "typeApplication": {"body": {"either": {"left": {"variable": "err"}}}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                "type": {
                                                  "application": {
                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.StepEdit"}, "argument": {"variable": "a"}}},
                                                    "argument": {"variable": "s"}}}}}}}}},
                                    "argument": {
                                      "lambda": {
                                        "parameter": "stripped",
                                        "domain": {"variable": "hydra.core.model.Term"},
                                        "body": {
                                          "application": {
                                            "function": {
                                              "cases": {
                                                "typeName": "hydra.core.model.Term",
                                                "default": {
                                                  "typeApplication": {
                                                    "body": {
                                                      "typeApplication": {
                                                        "body": {
                                                          "either": {
                                                            "left": {
                                                              "wrap": {
                                                                "typeName": "hydra.core.errors.DecodingError",
                                                                "body": {"literal": {"string": "expected a record of type hydra.core.diff.StepEdit"}}}}}},
                                                        "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                    "type": {
                                                      "application": {
                                                        "function": {"application": {"function": {"variable": "hydra.core.diff.StepEdit"}, "argument": {"variable": "a"}}},
                                                        "argument": {"variable": "s"}}}}},
                                                "cases": [
                                                  {
                                                    "name": "record",
                                                    "handler": {
                                                      "lambda": {
                                                        "parameter": "record",
                                                        "domain": {"variable": "hydra.core.model.Record"},
                                                        "body": {
                                                          "let": {
                                                            "bindings": [
                                                              {
                                                                "name": "fieldMap",
                                                                "term": {"application": {"function": {"variable": "hydra.core.extract.model.toFieldMap"}, "argument": {"variable": "record"}}},
                                                                "typeScheme": {
                                                                  "variables": [],
                                                                  "body": {"map": {"keys": {"variable": "hydra.core.model.Name"}, "values": {"variable": "hydra.core.model.Term"}}},
                                                                  "constraints": []}}],
                                                            "body": {
                                                              "application": {
                                                                "function": {
                                                                  "application": {
                                                                    "function": {
                                                                      "typeApplication": {
                                                                        "body": {
                                                                          "typeApplication": {
                                                                            "body": {
                                                                              "typeApplication": {"body": {"variable": "hydra.core.lib.eithers.bind"}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                            "type": {"variable": "s"}}},
                                                                        "type": {
                                                                          "application": {
                                                                            "function": {"application": {"function": {"variable": "hydra.core.diff.StepEdit"}, "argument": {"variable": "a"}}},
                                                                            "argument": {"variable": "s"}}}}},
                                                                    "argument": {
                                                                      "application": {
                                                                        "function": {
                                                                          "application": {
                                                                            "function": {
                                                                              "application": {
                                                                                "function": {
                                                                                  "application": {
                                                                                    "function": {
                                                                                      "typeApplication": {
                                                                                        "body": {
                                                                                          "typeApplication": {
                                                                                            "body": {
                                                                                              "typeApplication": {"body": {"variable": "hydra.core.extract.model.requireField"}, "type": {"variable": "hydra.core.graph.Graph"}}},
                                                                                            "type": {"variable": "hydra.core.model.Term"}}},
                                                                                        "type": {"variable": "s"}}},
                                                                                    "argument": {"literal": {"string": "step"}}}},
                                                                                "argument": {"variable": "s"}}},
                                                                            "argument": {"variable": "fieldMap"}}},
                                                                        "argument": {"variable": "cx"}}}}},
                                                                "argument": {
                                                                  "lambda": {
                                                                    "parameter": "field_step",
                                                                    "domain": {"variable": "s"},
                                                                    "body": {
                                                                      "application": {
                                                                        "function": {
                                                                          "application": {
                                                                            "function": {
                                                                              "typeApplication": {
                                                                                "body": {
                                                                                  "typeApplication": {
                                                                                    "body": {
                                                                                      "typeApplication": {"body": {"variable": "hydra.core.lib.eithers.bind"}, "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                    "type": {
                                                                                      "application": {
                                                                                        "function": {"application": {"function": {"variable": "hydra.core.diff.Edit"}, "argument": {"variable": "a"}}},
                                                                                        "argument": {"variable": "s"}}}}},
                                                                                "type": {
                                                                                  "application": {
                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.StepEdit"}, "argument": {"variable": "a"}}},
                                                                                    "argument": {"variable": "s"}}}}},
                                                                            "argument": {
                                                                              "application": {
                                                                                "function": {
                                                                                  "application": {
                                                                                    "function": {
                                                                                      "application": {
                                                                                        "function": {
                                                                                          "application": {
                                                                                            "function": {
                                                                                              "typeApplication": {
                                                                                                "body": {
                                                                                                  "typeApplication": {
                                                                                                    "body": {
                                                                                                      "typeApplication": {"body": {"variable": "hydra.core.extract.model.requireField"}, "type": {"variable": "hydra.core.graph.Graph"}}},
                                                                                                    "type": {"variable": "hydra.core.model.Term"}}},
                                                                                                "type": {
                                                                                                  "application": {
                                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.Edit"}, "argument": {"variable": "a"}}},
                                                                                                    "argument": {"variable": "s"}}}}},
                                                                                            "argument": {"literal": {"string": "edit"}}}},
                                                                                        "argument": {
                                                                                          "application": {
                                                                                            "function": {
                                                                                              "typeApplication": {
                                                                                                "body": {
                                                                                                  "application": {
                                                                                                    "function": {"typeApplication": {"body": {"variable": "hydra.core.decode.diff.edit"}, "type": {"variable": "a"}}},
                                                                                                    "argument": {"variable": "a"}}},
                                                                                                "type": {"variable": "s"}}},
                                                                                            "argument": {"variable": "s"}}}}},
                                                                                    "argument": {"variable": "fieldMap"}}},
                                                                                "argument": {"variable": "cx"}}}}},
                                                                        "argument": {
                                                                          "lambda": {
                                                                            "parameter": "field_edit",
                                                                            "domain": {
                                                                              "application": {
                                                                                "function": {"application": {"function": {"variable": "hydra.core.diff.Edit"}, "argument": {"variable": "a"}}},
                                                                                "argument": {"variable": "s"}}},
                                                                            "body": {
                                                                              "typeApplication": {
                                                                                "body": {
                                                                                  "typeApplication": {
                                                                                    "body": {
                                                                                      "either": {
                                                                                        "right": {
                                                                                          "record": {
                                                                                            "typeName": "hydra.core.diff.StepEdit",
                                                                                            "fields": [{"name": "step", "term": {"variable": "field_step"}}, {"name": "edit", "term": {"variable": "field_edit"}}]}}}},
                                                                                    "type": {"variable": "hydra.core.errors.DecodingError"}}},
                                                                                "type": {
                                                                                  "application": {
                                                                                    "function": {"application": {"function": {"variable": "hydra.core.diff.StepEdit"}, "argument": {"variable": "a"}}},
                                                                                    "argument": {"variable": "s"}}}}}}}}}}}}}}}}}}]}},
                                            "argument": {"variable": "stripped"}}}}}}},
                                "argument": {
                                  "application": {
                                    "function": {
                                      "application": {"function": {"variable": "hydra.core.extract.model.stripWithDecodingError"}, "argument": {"variable": "cx"}}},
                                    "argument": {"variable": "raw"}}}}}}}}}}}}},
            "annotation": {
              "map": [{"key": {"variable": "description"}, "value": {"literal": {"string": "Decoder for hydra.core.diff.StepEdit"}}}]}}}}}]}