{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://catalog.lintel.tools/schemas/schemastore/contextive-glossary/latest.json",
  "description": "<https://docs.contextive.tech/community/guides/setting-up-glossaries/>",
  "x-lintel": {
    "source": "https://www.schemastore.org/contextive-glossary.json",
    "sourceSha256": "ea9353d1eecfd7c44511baaca783bc9f7cc1d76eb9dda9ea2023018949025ff4",
    "fileMatch": [
      "**/.contextive/definitions.yml",
      "*.glossary.yml",
      "*.glossary.yaml"
    ],
    "parsers": [
      "yaml"
    ]
  },
  "type": "object",
  "anyOf": [
    {
      "properties": {
        "imports": {
          "description": "A list of urls, paths or relative paths to be imported into the current glossary scope. See <https://docs.contextive.tech/community/guides/setting-up-glossaries/#terms-defined-in-an-external-data-source>.",
          "type": "array",
          "items": {
            "type": "string"
          },
          "minItems": 1,
          "uniqueItems": true
        }
      },
      "required": [
        "imports"
      ],
      "type": "object"
    },
    {
      "properties": {
        "contexts": {
          "description": "A list of contexts. See <https://docs.contextive.tech/community/guides/setting-up-glossaries/#bounded-contexts>.",
          "type": "array",
          "items": {
            "title": "Context",
            "description": "A context in the ubiquitous language, consisting of a list of terms.",
            "type": "object",
            "properties": {
              "name": {
                "title": "Name",
                "description": "The name of the Context.",
                "type": "string",
                "examples": [
                  "The Context's Name"
                ]
              },
              "domainVisionStatement": {
                "title": "Domain Vision Statement",
                "description": "A statement that describes the purpose of the Context.",
                "type": "string",
                "examples": [
                  "A statement that describes the purpose of the context."
                ]
              },
              "paths": {
                "title": "Paths",
                "description": "A list of paths that the Context is involved in.",
                "type": "array",
                "items": {
                  "title": "Path",
                  "description": "A path that the Context is involved in.",
                  "type": "string"
                },
                "minItems": 1,
                "uniqueItems": true
              },
              "terms": {
                "title": "Terms",
                "description": "A list of Terms in the Context - see <https://docs.contextive.tech/ide/guides/defining-terminology/>.",
                "type": "array",
                "items": {
                  "title": "Term",
                  "description": "A Term in the Context.",
                  "type": "object",
                  "properties": {
                    "name": {
                      "title": "Name",
                      "description": "The name of the Term.",
                      "type": "string",
                      "examples": [
                        "The Term's Name"
                      ]
                    },
                    "definition": {
                      "title": "Definition",
                      "description": "A definition of the Term in this Context.",
                      "type": "string",
                      "examples": [
                        "A definition of the Term in this Context."
                      ]
                    },
                    "examples": {
                      "title": "Examples",
                      "description": "A list of example sentences using the Term.",
                      "type": "array",
                      "items": {
                        "title": "Example sentence",
                        "description": "An example sentence using the Term.",
                        "type": "string",
                        "examples": [
                          "An example sentence using the Term."
                        ]
                      },
                      "minItems": 1,
                      "uniqueItems": true
                    },
                    "aliases": {
                      "title": "Aliases",
                      "description": "A list of aliases for the Term.",
                      "type": "array",
                      "items": {
                        "title": "Alias",
                        "description": "An alias for the Term.",
                        "type": "string",
                        "examples": [
                          "An alias for the Term."
                        ]
                      },
                      "minItems": 1,
                      "uniqueItems": true
                    }
                  },
                  "required": [
                    "name"
                  ]
                },
                "minItems": 1,
                "uniqueItems": true
              }
            },
            "required": [
              "terms"
            ]
          },
          "minItems": 1,
          "uniqueItems": true
        }
      },
      "required": [
        "contexts"
      ],
      "type": "object"
    }
  ],
  "additionalProperties": true
}
