UNPKG

tpmkms

Version:

Reusable libraries for Entodicton, a natural language to json converter

1,972 lines 150 kB
[ { "associations": [ [ [ "atmosphere", 0 ], [ "convertToUnits", 0 ], [ "integer", 0 ], [ "is", 0 ], [ "pascal", 0 ], [ "what", 0 ] ], [ [ "atmosphere", 0 ], [ "convertToUnits", 0 ], [ "is", 0 ], [ "pascal", 0 ], [ "what", 0 ] ], [ [ "convertToUnits", 0 ], [ "dimension", 0 ], [ "is", 0 ] ], [ [ "convertToUnits", 0 ], [ "is", 0 ] ], [ [ "convertToUnits", 0 ], [ "is", 0 ], [ "pascal", 0 ], [ "what", 0 ] ], [ [ "convertToUnits", 0 ], [ "is", 0 ], [ "what", 0 ] ] ], "config": { }, "contexts": [ { "context_index": 1, "dead": true, "evalue": { "default": true, "focusable": [ "two", "one" ], "marker": "is", "one": { "dead": true, "default": true, "from": { "amount": { "dead": true, "instance": true, "level": 1, "marker": "integer", "range": { "end": 9, "start": 9 }, "text": "2", "types": [ "integer" ], "value": 2, "word": "2" }, "dead": true, "level": 1, "marker": "dimension", "range": { "end": 21, "start": 9 }, "text": "2 atmospheres", "types": [ "dimension" ], "unit": { "dead": true, "level": 1, "marker": "atmosphere", "number": "many", "range": { "end": 21, "start": 11 }, "text": "atmospheres", "types": [ "atmosphere" ], "value": "atmosphere", "word": "atmospheres" }, "value": 2 }, "level": 1, "marker": "convertToUnits", "range": { "end": 32, "start": 9 }, "text": "2 atmospheres in pascals", "to": { "dead": true, "level": 1, "marker": "pascal", "number": "many", "range": { "end": 32, "start": 26 }, "text": "pascals", "types": [ "pascal" ], "value": "pascal", "word": "pascals" }, "types": [ "convertToUnits" ], "word": "in" }, "two": { "dead": true, "default": true, "evalue": { "amount": { "evalue": { "dead": true, "evalue": 202650, "instance": true, "isResponse": true, "level": 1, "marker": "timesExpression", "number": "one", "range": { "end": 29, "start": 10 }, "text": "atmospheres * 101325", "touchedBy": [ "pressure#call4", "pressure#call3" ], "types": [ "number", "timesExpression" ], "value": null, "word": "*", "x": { "dead": true, "level": 1, "marker": "atmosphere", "number": "many", "range": { "end": 20, "start": 10 }, "text": "atmospheres", "types": [ "atmosphere" ], "value": "atmosphere", "word": "atmospheres" }, "y": { "dead": true, "instance": true, "level": 1, "marker": "integer", "range": { "end": 29, "start": 24 }, "text": "101325", "types": [ "integer" ], "value": 101325, "word": "101325" } } }, "level": 1, "marker": "dimension", "paraphrase": true, "unit": { "dead": true, "level": 1, "marker": "pascal", "number": "many", "range": { "end": 32, "start": 26 }, "text": "pascals", "types": [ "pascal" ], "value": "pascal", "word": "pascals" } }, "focus": true, "from": { "amount": { "dead": true, "instance": true, "level": 1, "marker": "integer", "range": { "end": 9, "start": 9 }, "text": "2", "types": [ "integer" ], "value": 2, "word": "2" }, "dead": true, "level": 1, "marker": "dimension", "range": { "end": 21, "start": 9 }, "text": "2 atmospheres", "types": [ "dimension" ], "unit": { "dead": true, "level": 1, "marker": "atmosphere", "number": "many", "range": { "end": 21, "start": 11 }, "text": "atmospheres", "types": [ "atmosphere" ], "value": "atmosphere", "word": "atmospheres" }, "value": 2 }, "instance": true, "level": 1, "marker": "convertToUnits", "range": { "end": 32, "start": 9 }, "text": "2 atmospheres in pascals", "to": { "dead": true, "level": 1, "marker": "pascal", "number": "many", "range": { "end": 32, "start": 26 }, "text": "pascals", "types": [ "pascal" ], "value": "pascal", "word": "pascals" }, "touchedBy": [ "pressure#call3", "pressure#call2" ], "types": [ "convertToUnits" ], "word": "in" }, "word": "is" }, "isResponse": true, "level": 2, "marker": "is", "number": "many", "one": { "dead": true, "default": true, "determined": true, "level": 1, "marker": "what", "number": "many", "query": [ "what" ], "range": { "end": 32, "start": 0 }, "text": "what", "types": [ "what" ], "value": "what", "word": "what" }, "query": [ "what" ], "range": { "end": 32, "start": 0 }, "text": "what are 2 atmospheres in pascals", "topLevel": true, "touchedBy": [ "pressure#call2" ], "two": { "dead": true, "default": true, "from": { "amount": { "dead": true, "instance": true, "level": 1, "marker": "integer", "range": { "end": 9, "start": 9 }, "text": "2", "types": [ "integer" ], "value": 2, "word": "2" }, "dead": true, "level": 1, "marker": "dimension", "range": { "end": 21, "start": 9 }, "text": "2 atmospheres", "types": [ "dimension" ], "unit": { "dead": true, "level": 1, "marker": "atmosphere", "number": "many", "range": { "end": 21, "start": 11 }, "text": "atmospheres", "types": [ "atmosphere" ], "value": "atmosphere", "word": "atmospheres" }, "value": 2 }, "level": 1, "marker": "convertToUnits", "range": { "end": 32, "start": 9 }, "text": "2 atmospheres in pascals", "to": { "dead": true, "level": 1, "marker": "pascal", "number": "many", "range": { "end": 32, "start": 26 }, "text": "pascals", "types": [ "pascal" ], "value": "pascal", "word": "pascals" }, "types": [ "convertToUnits" ], "word": "in" }, "word": "are" } ], "generatedParenthesized": [ "(((((2) (atmospheres)) in (pascals)) is ((((202650)) (pascals)))))" ], "metadata": { "opChoices": [ { "counter": 1, "op": [ "integer", 0 ], "ops": [ [ "atmosphere", 0 ], [ "convertToUnits", 0 ], [ "integer", 0 ], [ "is", 0 ], [ "pascal", 0 ], [ "what", 0 ] ] }, { "counter": 2, "op": [ "atmosphere", 0 ], "ops": [ [ "amountOfDimension", 0 ], [ "atmosphere", 0 ], [ "convertToUnits", 0 ], [ "is", 0 ], [ "pascal", 0 ], [ "what", 0 ] ] }, { "counter": 3, "op": [ "pascal", 0 ], "ops": [ [ "amountOfDimension", 0 ], [ "convertToUnits", 0 ], [ "is", 0 ], [ "pascal", 0 ], [ "what", 0 ] ] }, { "counter": 4, "op": [ "what", 0 ], "ops": [ [ "amountOfDimension", 0 ], [ "convertToUnits", 0 ], [ "is", 0 ], [ "what", 0 ] ] }, { "counter": 5, "op": [ "amountOfDimension", 0 ], "ops": [ [ "amountOfDimension", 0 ], [ "convertToUnits", 0 ], [ "is", 0 ] ] }, { "counter": 6, "op": [ "dimension", 0 ], "ops": [ [ "convertToUnits", 0 ], [ "dimension", 0 ], [ "is", 0 ] ] }, { "counter": 7, "op": [ "convertToUnits", 0 ], "ops": [ [ "convertToUnits", 0 ], [ "is", 0 ] ] }, { "counter": 8, "op": [ "is", 0 ], "ops": [ [ "is", 0 ] ] }, { "counter": 9, "op": [ "is", 1 ], "ops": [ [ "is", 1 ] ] } ] }, "objects": { "nameToUUID": { "articles": "articles2", "asking": "asking2", "comparable": "comparable2", "concept": "concept2", "conjunction": "conjunction2", "countable": "countable2", "dialogues": "dialogues2", "dimension": "dimension2", "evaluate": "evaluate2", "formulas": "formulas2", "gdefaults": "gdefaults2", "hierarchy": "hierarchy2", "math": "math2", "meta": "meta2", "negation": "negation2", "numbers": "numbers2", "pos": "pos2", "pressure": "pressure1", "properties": "properties2", "punctuation": "punctuation2", "sdefaults": "sdefaults2", "stm": "stm2", "testing": "testing2", "tokenize": "tokenize2" }, "namespaced": { "articles2": { }, "asking2": { }, "comparable2": { }, "concept2": { "defaultTypesForHierarchy": { }, "valueToWords": [ ] }, "conjunction2": { }, "countable2": { }, "dialogues2": { "idSuffix": "", "mentioned": [ ], "variables": { } }, "dimension2": { }, "evaluate2": { }, "formulas2": { "formulas": { "atmosphere": [ { "equality": { "context_index": 1, "dead": true, "left": { "dead": true, "level": 1, "marker": "atmosphere", "number": "many", "range": { "end": 10, "start": 0 }, "text": "atmospheres", "types": [ "atmosphere" ], "value": "atmosphere", "word": "atmospheres" }, "level": 1, "marker": "equals", "range": { "end": 29, "start": 0 }, "right": { "dead": true, "evaluate": true, "isResponse": true, "level": 1, "marker": "divideByExpression", "number": "one", "range": { "end": 29, "start": 14 }, "text": "pascals / 101325", "types": [ "divideByExpression", "number" ], "value": null, "word": "/", "x": { "dead": true, "level": 1, "marker": "pascal", "number": "many", "range": { "end": 20, "start": 14 }, "text": "pascals", "types": [ "pascal" ], "value": "pascal", "word": "pascals" }, "y": { "dead": true, "instance": true, "level": 1, "marker": "integer", "range": { "end": 29, "start": 24 }, "text": "101325", "types": [ "integer" ], "value": 101325, "word": "101325" } }, "text": "atmospheres = pascals / 101325", "topLevel": true, "touchedBy": [ "pressure#call2", "instance3#pressure#call2" ], "value": "equals", "word": "=" }, "formula": { "dead": true, "evaluate": true, "isResponse": true, "level": 1, "marker": "divideByExpression", "number": "one", "range": { "end": 29, "start": 14 }, "text": "pascals / 101325", "types": [ "divideByExpression", "number" ], "value": null, "word": "/", "x": { "dead": true, "level": 1, "marker": "pascal", "number": "many", "range": { "end": 20, "start": 14 }, "text": "pascals", "types": [ "pascal" ], "value": "pascal", "word": "pascals" }, "y": { "dead": true, "instance": true, "level": 1, "marker": "integer", "range": { "end": 29, "start": 24 }, "text": "101325", "types": [ "integer" ], "value": 101325, "word": "101325" } }, "name": { "dead": true, "level": 1, "marker": "atmosphere", "number": "many", "range": { "end": 10, "start": 0 }, "text": "atmospheres", "types": [ "atmosphere" ], "value": "atmosphere", "word": "atmospheres" } } ], "pascal": [ { "equality": { "context_index": 1, "dead": true, "left": { "dead": true, "level": 1, "marker": "pascal", "number": "many", "range": { "end": 6, "start": 0 }, "text": "pascals", "types": [ "pascal" ], "value": "pascal", "word": "pascals" }, "level": 1, "marker": "equals", "range": { "end": 29, "start": 0 }, "right": { "dead": true, "evaluate": true, "isResponse": true, "level": 1, "marker": "timesExpression", "number": "one", "range": { "end": 29, "start": 10 }, "text": "atmospheres * 101325", "types": [ "number", "timesExpression" ], "value": null, "word": "*", "x": { "dead": true, "level": 1, "marker": "atmosphere", "number": "many", "range": { "end": 20, "start": 10 }, "text": "atmospheres", "types": [ "atmosphere" ], "value": "atmosphere", "word": "atmospheres" }, "y": { "dead": true, "instance": true, "level": 1, "marker": "integer", "range": { "end": 29, "start": 24 }, "text": "101325", "types": [ "integer" ], "value": 101325, "word": "101325" } }, "text": "pascals = atmospheres * 101325", "topLevel": true, "touchedBy": [ "pressure#call2", "instance2#pressure#call2" ], "value": "equals", "word": "=" }, "formula": { "dead": true, "evaluate": true, "isResponse": true, "level": 1, "marker": "timesExpression", "number": "one", "range": { "end": 29, "start": 10 }, "text": "atmospheres * 101325", "types": [ "number", "timesExpression" ], "value": null, "word": "*", "x": { "dead": true, "level": 1, "marker": "atmosphere", "number": "many", "range": { "end": 20, "start": 10 }, "text": "atmospheres", "types": [ "atmosphere" ], "value": "atmosphere", "word": "atmospheres" }, "y": { "dead": true, "instance": true, "level": 1, "marker": "integer", "range": { "end": 29, "start": 24 }, "text": "101325", "types": [ "integer" ], "value": 101325, "word": "101325" } }, "name": { "dead": true, "level": 1, "marker": "pascal", "number": "many", "range": { "end": 6, "start": 0 }, "text": "pascals", "types": [ "pascal" ], "value": "pascal", "word": "pascals" } } ] } }, "gdefaults2": { }, "hierarchy2": { }, "math2": { }, "meta2": { }, "negation2": { }, "numbers2": { }, "pos2": { }, "pressure1": { }, "properties2": { "children": { "adjective": [ "stm_before" ], "article": [ "a", "the", "each", "every" ], "canBeDoQuestion": [ "have" ], "canBeQuestion": [ "have", "is" ], "concept": [ "formula", "dimension", "unit" ], "dimension": [ "pressure" ], "hierarchyAble": [ "unknown" ], "ifAble": [ "orAble" ], "object": [ "what", "whose" ], "preposition": [ "between", "propertyOf", "to" ], "pronoun": [ "it", "this" ], "punctuation": [ "questionMark" ], "queryable": [ "xfx", "hierarchyAble", "readonly", "property", "object", "concept", "doubleQuote", "theAble", "unknown", "it", "what", "whatAble", "negatable", "this", "reason", "distributable", "thisitthat" ], "sort_ordering": [ "ascending", "descending" ], "theAble": [ "property", "object", "concept", "unknown", "reason", "memorable", "noun" ], "thisitthat": [ "it", "this", "that" ], "toAble": [ "it" ], "unit": [ "pascal", "atmosphere" ], "verb": [ "modifies", "is", "remember", "evaluate" ] }, "concepts": [ "properties", "unknown", "hierarchyAble", "what", "object", "xfx", "queryable", "between", "preposition", "readonly", "have", "canBeDoQuestion", "canBeQuestion", "property", "theAble", "propertyOf", "whose", "concept", "modifies", "verb", "doubleQuote", "it", "pronoun", "this", "questionMark", "punctuation", "a", "article", "the", "whatAble", "negatable", "is", "toAble", "to", "reason", "memorable", "remember", "stm_before", "adjective", "orAble", "ifAble", "evaluate", "each", "every", "distributable", "noun", "thisitthat", "that", "ascending", "sort_ordering", "descending", "formula", "dimension", "unit", "pressure", "pascal", "atmosphere" ], "parents": { "a": [ "article" ], "ascending": [ "sort_ordering" ], "atmosphere": [ "unit" ], "between": [ "preposition" ], "concept": [ "theAble", "queryable" ], "descending": [ "sort_ordering" ], "dimension": [ "concept" ], "distributable": [ "queryable" ], "doubleQuote": [ "queryable" ], "each": [ "article" ], "evaluate": [ "verb" ], "every": [ "article" ], "formula": [ "concept" ], "have": [ "canBeDoQuestion", "canBeQuestion" ], "hierarchyAble": [ "queryable" ], "is": [ "canBeQuestion", "verb" ], "it": [ "pronoun", "queryable", "toAble", "thisitthat" ], "memorable": [ "theAble" ], "modifies": [ "verb" ], "negatable": [ "queryable" ], "noun": [ "theAble" ], "object": [ "queryable", "theAble" ], "orAble": [ "ifAble" ], "pascal": [ "unit" ], "pressure": [ "dimension" ], "property": [ "queryable", "theAble" ], "propertyOf": [ "preposition" ], "questionMark": [ "punctuation" ], "readonly": [ "queryable" ], "reason": [ "theAble", "queryable" ], "remember": [ "verb" ], "stm_before": [ "adjective" ], "that": [ "thisitthat" ], "the": [ "article" ], "theAble": [ "queryable" ], "this": [ "pronoun", "queryable", "thisitthat" ], "thisitthat": [ "queryable" ], "to": [ "preposition" ], "unit": [ "concept" ], "unknown": [ "hierarchyAble", "theAble", "queryable" ], "what": [ "object", "queryable" ], "whatAble": [ "queryable" ], "whose": [ "object" ], "xfx": [ "queryable" ] }, "properties": { "handlers": { }, "initHandlers": [ ], "root": { "a": { }, "adjective": { }, "article": { }, "ascending": { }, "atmosphere": { }, "between": { }, "canBeDoQuestion": { }, "canBeQuestion": { }, "concept": { }, "descending": { }, "dimension": { }, "distributable": { }, "doubleQuote": { }, "each": { }, "evaluate": { }, "every": { }, "formula": { }, "have": { }, "hierarchyAble": { }, "ifAble": { }, "is": { }, "it": { }, "memorable": { }, "modifies": { }, "negatable": { }, "noun": { }, "object": { }, "orAble": { }, "pascal": { }, "preposition": { }, "pressure": { }, "pronoun": { }, "property": { }, "propertyOf": { }, "punctuation": { }, "queryable": { }, "questionMark": { }, "readonly": { }, "reason": { }, "remember": { }, "sort_ordering": { }, "stm_before": { }, "that": { }, "the": { }, "theAble": { }, "this": { }, "thisitthat": { }, "to": { }, "toAble": { }, "unit": { }, "unknown": { }, "verb": { }, "what": { }, "whatAble": { }, "whose": { }, "xfx": { } } }, "property": { }, "relations": [ ], "valueToWords": { } }, "punctuation2": { }, "sdefaults2": { }, "stm2": { "mentioned": [ { "fromSTM": true, "marker": "atmosphere", "pullFromContext": false, "stm": { "id": 1 }, "value": { "dead": true, "instance": true, "level": 1, "marker": "integer", "range": { "end": 9, "start": 9 }, "text": "2", "types": [ "integer" ], "value": 2, "word": "2" } } ], "variables": { } }, "testing2": { }, "tokenize2": { } }, "processed": [ { "context": { "context_index": 1, "dead": true, "evalue": { "default": true, "focusable": [ "two", "one" ], "marker": "is", "one": { "dead": true, "default": true, "from": { "amount": { "dead": true, "instance": true, "level": 1, "marker": "integer", "range": { "end": 9, "start": 9 }, "text": "2", "types": [ "integer" ], "value": 2, "word": "2" }, "dead": true, "level": 1, "marker": "dimension", "range": { "end": 21, "start": 9 }, "text": "2 atmospheres", "types": [ "dimension" ], "unit": { "dead": true, "level": 1, "marker": "atmosphere", "number": "many", "range": { "end": 21, "start": 11 }, "text": "atmospheres", "types": [ "atmosphere" ], "value": "atmosphere", "word": "atmospheres" }, "value": 2 }, "level": 1, "marker": "convertToUnits", "range": { "end": 32, "start": 9 }, "text": "2 atmospheres in pascals", "to": { "dead": true, "level": 1, "marker": "pascal", "number": "many", "range": { "end": 32, "start": 26 }, "text": "pascals", "types": [ "pascal" ], "value": "pascal", "word": "pascals" }, "types": [ "convertToUnits" ], "word": "in" }, "two": { "dead": true, "default": true, "evalue": { "amount": { "evalue": { "dead": true, "evalue": 202650, "instance": true, "isResponse": true, "level": 1, "marker": "timesExpression", "number": "one", "range": { "end": 29, "start": 10 }, "text": "atmospheres * 101325", "touchedBy": [ "pressure#call4", "pressure#call3" ], "types": [ "number", "timesExpression" ], "value": null, "word": "*", "x": { "dead": true, "level": 1, "marker": "atmosphere", "number": "many", "range": { "end": 20, "start": 10 }, "text": "atmospheres", "types": [ "atmosphere" ], "value": "atmosphere", "word": "atmospheres" }, "y": { "dead": true, "instance": true, "level": 1, "marker": "integer", "range": { "end": 29, "start": 24 }, "text": "101325", "types": [ "integer" ], "value": 101325, "word": "101325" } } }, "level": 1, "marker": "dimension", "paraphrase": true, "unit": { "dead": true, "level": 1, "marker": "pascal", "number": "many", "range": { "end": 32, "start": 26 }, "text": "pascals", "types": [ "pascal" ], "value": "pascal", "word": "pascals" } }, "focus": true, "from": { "amount": { "dead": true, "instance": true, "level": 1, "marker": "integer", "range": { "end": 9, "start": 9 }, "text": "2", "types": [ "integer" ], "value": 2, "word": "2" }, "dead": true, "level": 1, "marker": "dimension", "range": { "end": 21, "start": 9 }, "text": "2 atmospheres", "types": [ "dimension" ], "unit": { "dead": true, "level": 1, "marker": "atmosphere", "number": "many", "range": { "end": 21, "start": 11 }, "text": "atmospheres", "types": [ "atmosphere" ], "value": "atmosphere", "word": "atmospheres" }, "value": 2 }, "instance": true, "level": 1, "marker": "convertToUnits", "range": { "end": 32, "start": 9 }, "text": "2 atmospheres in pascals", "to": { "dead": true, "level": 1, "marker": "pascal", "number": "many", "range": { "end": 32, "start": 26 }, "text": "pascals", "types": [ "pascal" ], "value": "pascal", "word": "pascals" }, "touchedBy": [ "pressure#call3", "pressure#call2" ], "types": [ "convertToUnits" ], "word": "in" }, "word": "is" }, "isResponse": true, "level": 2, "marker": "is", "number": "many", "one": { "dead": true, "default": true, "determined": true, "level": 1, "marker": "what", "number": "many", "query": [ "what" ], "range": { "end": 32, "start": 0 }, "text": "what", "types": [ "what" ], "value": "what", "word": "what" }, "query": [ "what" ], "range": { "end": 32, "start": 0 }, "text": "what are 2 atmospheres in pascals", "topLevel": true, "touchedBy": [ "pressure#call2" ], "two": { "dead": true, "default": true, "from": { "amount": { "dead": true, "instance": true, "level": 1, "marker": "integer", "range": { "end": 9, "start": 9 }, "text": "2", "types": [ "integer" ], "value": 2, "word": "2" }, "dead": true, "level": 1, "marker": "dimension", "range": { "end": 21, "start": 9 }, "text": "2 atmospheres", "types": [ "dimension" ], "unit": { "dead": true, "level": 1, "marker": "atmosphere", "number": "many", "range": { "end": 21, "start": 11 }, "text": "atmospheres", "types": [ "atmosphere" ], "value": "atmosphere", "word": "atmospheres" }, "value": 2 }, "level": 1, "marker": "convertToUnits", "range": { "end": 32, "start": 9 }, "text": "2 atmospheres in pascals", "to": { "dead": true, "level": 1, "marker": "pascal", "number": "many", "range": { "end": 32, "start": 26 }, "text": "pascals", "types": [ "pascal" ], "value": "pascal", "word": "pascals" }, "types": [ "convertToUnits" ], "word": "in" }, "word": "are" }, "generatedParenthesized": "(((((2) (atmospheres)) in (pascals)) is ((((202650)) (pascals)))))", "paraphrases": "what are 2 atmospheres in pascals?", "paraphrasesParenthesized": "(((what) are (((2) (atmospheres)) in (pascals)))?)", "responses": [ "2 atmospheres in pascals is 202650 pascals" ] }, { "context": { "context_index": 1, "dead": true, "left": { "dead": true, "level": 1, "marker": "atmosphere", "number": "many", "range": { "end": 10, "start": 0 }, "text": "atmospheres", "types": [ "atmosphere" ], "value": "atmosphere", "word": "atmospheres" }, "level": 1, "marker": "equals", "range": { "end": 29, "start": 0 }, "right": { "dead": true, "evaluate": true, "isResponse": true, "level": 1, "marker": "divideByExpression", "number": "one", "range": { "end": 29, "start": 14 }, "text": "pascals / 101325", "types": [ "divideByExpression", "number" ], "value": null, "word": "/", "x": { "