Dear Wiki user, You have subscribed to a wiki page or wiki category on "Devicemap Wiki" for change notification.
The "DataSpec2" page has been changed by rezan: https://wiki.apache.org/devicemap/DataSpec2?action=diff&rev1=48&rev2=49 Comment: JSON * Description * Publish date - TODO: define the JSON and example + === Pattern File === + {{{ + { + "SpecVersion": 2.0, + "Type": "pattern|attribute", + "Domain": "example", + "DomainVersion": "1.0", + "Description": "this is an example", + "PublishDate": "2015-06-19T09:17:37Z", + "InputParser": { InputParser }, + "PatternSet": { PatternSet }, + "Attributes": [ { Attribute } ] + } + }}} + + Note that defining attributes in a pattern file is optional. Attributes defined in the actual attribute file will override + attributes defined in the pattern file. + + + === InputParser === + + {{{ + { + "Transformers": [ { Transformer } ], + "TokenSeperators": [ "1", "two", "3" ], + "NgramConcatSize": 2 + } + }}} + + + === PatternSet === + + {{{ + { + "DefaultId": "someid", + "SimpleHashCount": 1400, + "Patterns" [ { Pattern } ] + } + }}} + + Note that SimpleHashCount must be defined before Patterns to facilitate efficient JSON stream parsing. + + + === Pattern === + + {{{ + { + "PatternId": "someid", + "RankType": "Strong|Weak|None", + "RankValue": 150, + "PatternType": "SimpleOrderedAnd|SimpleAnd|Simple", + "PatternTokens" [ "token1", "token2", "token3" ] + } + }}} + + + ... +
