Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- {
- "title": "Schema for validation Qordoba Spacy Match/Replace format",
- "type": "object",
- "definitions": {
- "spacyMatch": {
- "type": "array",
- "items": {
- "$ref": "#/definitions/spacyAttribute"
- },
- "minItems": 1
- },
- "spacyAttribute": {
- "type": "object",
- "properties": {
- "ORTH": {
- "$ref": "#/definitions/spacyValue"
- },
- "TEXT": {
- "$ref": "#/definitions/spacyValue"
- },
- "LOWER": {
- "$ref": "#/definitions/spacyValue"
- },
- "LENGTH": {
- "$ref": "#/definitions/spacyValue"
- },
- "POS": {
- "$ref": "#/definitions/spacyValue"
- },
- "TAG": {
- "$ref": "#/definitions/spacyValue"
- },
- "DEP": {
- "$ref": "#/definitions/spacyValue"
- },
- "SHAPE": {
- "$ref": "#/definitions/spacyValue"
- },
- "ENT_TYPE": {
- "$ref": "#/definitions/spacyValue"
- },
- "OP": {
- "enum": [
- "!",
- "?",
- "*",
- "+"
- ]
- }
- },
- "patternProperties": {
- "^IS_[A-Z]*$": {
- "type": "boolean"
- }
- }
- },
- "spacyOperator": {
- "type": "object",
- "additionalProperties": false,
- "properties": {
- "REGEX": {
- "type": "string"
- },
- "IN": {
- "type": "array",
- "items": {
- "type": "string"
- }
- },
- "NOT_IN": {
- "type": "array",
- "items": {
- "type": "string"
- }
- },
- "==": {
- "type": "number"
- },
- ">=": {
- "type": "number"
- },
- ">": {
- "type": "number"
- },
- "<=": {
- "type": "number"
- },
- "<": {
- "type": "number"
- }
- }
- },
- "spacyValue": {
- "oneOf": [
- {
- "type": "string"
- },
- {
- "type": "integer"
- },
- {
- "$ref": "#/definitions/spacyOperator"
- }
- ]
- }
- },
- "patternProperties": {
- "^[a-z_][A-Za-z0-9_]*$": {
- "type": "object",
- "properties": {
- "patterns": {
- "type": "array",
- "items": {
- "$ref": "#/definitions/spacyMatch"
- },
- "minItems": 1
- }
- },
- "required": [
- "patterns",
- "suggestions"
- ]
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement