{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "@context": [
    "https://schemas.meta-aiml.org/v3.0.0/context.jsonld"
  ],
  "@id": "https://schemas.meta-aiml.org/v3.0.0/entity/software_product.json",
  "$id": "https://schemas.meta-aiml.org/v3.0.0/entity/software_product.json",
  "@type": "SoftwareProduct",
  "schemaVersion": "3.0.0",
  "aimlVersion": "3.0.0",
  "title": "Software Product Entity Schema",
  "description": "v3 schema for software products as product artifacts (not services), including packaging, licensing, release lifecycle, and inventory characteristics.",
  "examples": [
    {
      "description": "Commercial desktop software package with annual maintenance entitlement",
      "reference": "software_product_example_desktop"
    },
    {
      "description": "Developer tool delivered as versioned digital package with license pool",
      "reference": "software_product_example_developer_tool"
    }
  ],
  "type": "object",
  "additionalProperties": false,
  "allOf": [
    {
      "$ref": "../ontology/product_entity.json"
    }
  ],
  "properties": {
    "@type": {
      "const": "SoftwareProduct"
    },
    "ontologicalMode": {
      "const": "ProductEntity"
    },
    "domain": {
      "const": "Technology"
    },
    "businessModel": {
      "type": "array",
      "items": {
        "type": "string",
        "enum": [
          "License",
          "Subscription",
          "PerSeat",
          "Freemium"
        ]
      }
    },
    "deliveryFormat": {
      "type": "array",
      "items": {
        "type": "string",
        "enum": [
          "DigitalDownload",
          "LicenseKeyDelivery",
          "PackageRegistry",
          "ContainerImage"
        ]
      }
    },
    "name": {
      "$ref": "../components/multilingual_format.json#/$defs/LocalizedText"
    },
    "description": {
      "$ref": "../components/multilingual_format.json#/$defs/LocalizedText"
    },
    "shortDescription": {
      "type": "string"
    },
    "url": {
      "type": "string",
      "format": "uri"
    },
    "foundingDate": {
      "type": "string",
      "format": "date"
    },
    "productType": {
      "const": "digital"
    },
    "inventory": {
      "type": "object",
      "required": [
        "availableQuantity",
        "stockStatus"
      ],
      "properties": {
        "availableQuantity": {
          "type": "integer",
          "minimum": 0
        },
        "stockStatus": {
          "type": "string",
          "enum": [
            "in_stock",
            "out_of_stock",
            "backorder"
          ]
        },
        "licensePoolType": {
          "type": "string",
          "enum": [
            "limited",
            "unlimited",
            "metered"
          ]
        }
      }
    },
    "properties": {
      "type": "object",
      "properties": {
        "productCategory": {
          "type": "string",
          "enum": [
            "desktop_app",
            "developer_tool",
            "security_suite",
            "analytics_tool",
            "productivity_suite"
          ]
        },
        "supportedPlatforms": {
          "type": "array",
          "items": {
            "type": "string",
            "enum": [
              "windows",
              "macos",
              "linux",
              "cross_platform",
              "web"
            ]
          }
        },
        "releaseChannel": {
          "type": "string",
          "enum": [
            "stable",
            "beta",
            "lts"
          ]
        },
        "activationRequired": {
          "type": "boolean"
        },
        "supportsOfflineUsage": {
          "type": "boolean"
        }
      }
    },
    "capabilities": {
      "type": "object",
      "properties": {
        "commerce": {
          "$ref": "../components/capability_groups.json#/$defs/CommerceCapabilities"
        },
        "financial": {
          "$ref": "../components/capability_groups.json#/$defs/FinancialCapabilities"
        },
        "content": {
          "$ref": "../components/capability_groups.json#/$defs/ContentCapabilities"
        },
        "interaction": {
          "$ref": "../components/capability_groups.json#/$defs/InteractionCapabilities"
        }
      }
    },
    "modules": {
      "type": "object",
      "properties": {
        "licensing": {
          "type": "object",
          "properties": {
            "seatReassignmentEnabled": {
              "type": "boolean"
            },
            "offlineActivationSupported": {
              "type": "boolean"
            },
            "maxActivationsPerLicense": {
              "type": "integer",
              "minimum": 1
            }
          }
        },
        "updates": {
          "type": "object",
          "properties": {
            "autoUpdatesSupported": {
              "type": "boolean"
            },
            "securityPatchSlaDays": {
              "type": "integer",
              "minimum": 0
            },
            "releaseNotesUrl": {
              "type": "string",
              "format": "uri"
            }
          }
        },
        "support": {
          "type": "object",
          "properties": {
            "knowledgeBaseAvailable": {
              "type": "boolean"
            },
            "supportPortalUrl": {
              "type": "string",
              "format": "uri"
            },
            "slaTier": {
              "type": "string",
              "enum": [
                "basic",
                "business",
                "enterprise"
              ]
            }
          }
        }
      }
    },
    "structuralMetadata": {
      "type": "object",
      "properties": {
        "entityNature": {
          "const": "product_item"
        },
        "distributionModel": {
          "type": "string",
          "enum": [
            "download",
            "registry",
            "hybrid"
          ]
        },
        "versioningModel": {
          "type": "string",
          "enum": [
            "semantic_versioning",
            "calendar_versioning",
            "custom"
          ]
        },
        "contentOwnership": {
          "const": "platform"
        }
      }
    },
    "targetAudience": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "siteCapabilities": {
      "type": "object",
      "properties": {
        "supportedDevices": {
          "type": "array",
          "items": {
            "type": "string",
            "enum": [
              "desktop",
              "mobile",
              "tablet"
            ]
          }
        },
        "languages": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "accessibilityFeatures": {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      }
    }
  },
  "required": [
    "@type",
    "ontologicalMode",
    "domain",
    "name",
    "description",
    "deliveryFormat",
    "productType",
    "inventory",
    "capabilities",
    "structuralMetadata",
    "modules"
  ],
  "validationMetadata": {
    "schemaVersion": "3.0.0",
    "phase": "entity",
    "status": "draft",
    "lastValidated": "2026-02-20T12:00:00Z",
    "validator": "META-AIML QA"
  },
  "semanticAnnotations": {
    "classificationRationale": "SoftwareProduct is modeled as ProductEntity because the schema describes a software artifact and license inventory rather than live service behavior.",
    "disambiguationNotes": "ProductEntity does not carry interactionArchetype; service delivery must be modeled in a separate DigitalEntity schema."
  },
  "governanceMetadata": {
    "entityVersion": "3.0.0",
    "introducedIn": "META-AIML v3.0.0",
    "stabilityLevel": "draft",
    "sdkValidationRules": [
      "RULE-SWPRD-001: @type MUST equal \"SoftwareProduct\"",
      "RULE-SWPRD-002: ontologicalMode MUST equal \"ProductEntity\"",
      "RULE-SWPRD-003: interactionArchetype MUST NOT be present",
      "RULE-SWPRD-004: productType MUST equal \"digital\"",
      "RULE-SWPRD-005: inventory.availableQuantity and inventory.stockStatus MUST be present",
      "RULE-SWPRD-006: allOf MUST reference only product_entity ontology"
    ]
  }
}
