{
  "id": "type-n07",
  "revision": "53670509fc3aaf0d5b93efd75f93136950f4b98c4e663cfc32f5c0055fb64595",
  "regions": [
    {
      "id": "web",
      "label": "Web",
      "parent": null
    },
    {
      "id": "common-logic",
      "label": "Common logic",
      "parent": null
    },
    {
      "id": "server",
      "label": "Server",
      "parent": null
    }
  ],
  "nodes": [
    {
      "id": "input",
      "label": "Search input",
      "kind": "N13",
      "region": "web",
      "ports": [
        {
          "id": "term",
          "profile": "P08",
          "contract": "SearchTermStateV1",
          "polarity": "Offer"
        }
      ]
    },
    {
      "id": "debounce",
      "label": "Debounce and distinct terms",
      "kind": "N07",
      "region": "common-logic",
      "ports": [
        {
          "id": "term",
          "profile": "P08",
          "contract": "SearchTermStateV1",
          "polarity": "Require"
        },
        {
          "id": "query",
          "profile": "P04",
          "contract": "SearchGenerationV1",
          "polarity": "Offer"
        },
        {
          "id": "empty",
          "profile": "P12",
          "contract": "ClearSearchResultsV1",
          "polarity": "Offer"
        }
      ]
    },
    {
      "id": "request",
      "label": "Latest-search controller",
      "kind": "N05",
      "region": "common-logic",
      "ports": [
        {
          "id": "query",
          "profile": "P04",
          "contract": "SearchGenerationV1",
          "polarity": "Require"
        },
        {
          "id": "fetch",
          "profile": "P02",
          "contract": "SearchGenerationResponseV1",
          "polarity": "Require"
        },
        {
          "id": "result",
          "profile": "P08",
          "contract": "SearchResultStateV1",
          "polarity": "Offer"
        },
        {
          "id": "clear",
          "profile": "P12",
          "contract": "ClearSearchResultsV1",
          "polarity": "Require"
        }
      ]
    },
    {
      "id": "api",
      "label": "Search API",
      "kind": "N19",
      "region": "server",
      "ports": [
        {
          "id": "search",
          "profile": "P02",
          "contract": "SearchGenerationResponseV1",
          "polarity": "Offer"
        }
      ]
    },
    {
      "id": "surface",
      "label": "Result Surface",
      "kind": "N11",
      "region": "web",
      "ports": [
        {
          "id": "result",
          "profile": "P08",
          "contract": "SearchResultStateV1",
          "polarity": "Require"
        }
      ]
    }
  ],
  "relations": [
    {
      "id": "terms",
      "kind": "H02",
      "incidences": [
        {
          "node": "input",
          "port": "term",
          "role": "source",
          "ordinal": 0
        },
        {
          "node": "debounce",
          "port": "term",
          "role": "target",
          "ordinal": 0
        }
      ]
    },
    {
      "id": "latest",
      "kind": "H04",
      "incidences": [
        {
          "node": "debounce",
          "port": "query",
          "role": "publisher",
          "ordinal": 0
        },
        {
          "node": "request",
          "port": "query",
          "role": "subscriber",
          "ordinal": 0
        }
      ]
    },
    {
      "id": "fetch",
      "kind": "H05",
      "incidences": [
        {
          "node": "request",
          "port": "fetch",
          "role": "caller",
          "ordinal": 0
        },
        {
          "node": "api",
          "port": "search",
          "role": "callee",
          "ordinal": 0
        }
      ]
    },
    {
      "id": "display",
      "kind": "H02",
      "incidences": [
        {
          "node": "request",
          "port": "result",
          "role": "source",
          "ordinal": 0
        },
        {
          "node": "surface",
          "port": "result",
          "role": "target",
          "ordinal": 0
        }
      ]
    },
    {
      "id": "empty",
      "kind": "H03",
      "incidences": [
        {
          "node": "debounce",
          "port": "empty",
          "role": "source",
          "ordinal": 0
        },
        {
          "node": "request",
          "port": "clear",
          "role": "target",
          "ordinal": 0
        }
      ]
    }
  ]
}
