|
|
syntax = "proto2"; |
|
|
|
|
|
package edu.stanford.nlp.pipeline; |
|
|
|
|
|
option java_package = "edu.stanford.nlp.pipeline"; |
|
|
option java_outer_classname = "CoreNLPProtos"; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
enum Language { |
|
|
Unknown = 0; |
|
|
Any = 1; |
|
|
Arabic = 2; |
|
|
Chinese = 3; |
|
|
English = 4; |
|
|
German = 5; |
|
|
French = 6; |
|
|
Hebrew = 7; |
|
|
Spanish = 8; |
|
|
UniversalEnglish = 9; |
|
|
UniversalChinese = 10; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message Document { |
|
|
required string text = 1; |
|
|
repeated Sentence sentence = 2; |
|
|
repeated CorefChain corefChain = 3; |
|
|
optional string docID = 4; |
|
|
optional string docDate = 7; |
|
|
optional uint64 calendar = 8; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
repeated Token sentencelessToken = 5; |
|
|
repeated Token character = 10; |
|
|
|
|
|
repeated Quote quote = 6; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
repeated NERMention mentions = 9; |
|
|
optional bool hasEntityMentionsAnnotation = 13; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
optional bool xmlDoc = 11; |
|
|
repeated Section sections = 12; |
|
|
|
|
|
|
|
|
repeated Mention mentionsForCoref = 14; |
|
|
optional bool hasCorefMentionAnnotation = 15; |
|
|
optional bool hasCorefAnnotation = 16; |
|
|
repeated int32 corefMentionToEntityMentionMappings = 17; |
|
|
repeated int32 entityMentionToCorefMentionMappings = 18; |
|
|
|
|
|
extensions 100 to 255; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message Sentence { |
|
|
repeated Token token = 1; |
|
|
required uint32 tokenOffsetBegin = 2; |
|
|
required uint32 tokenOffsetEnd = 3; |
|
|
optional uint32 sentenceIndex = 4; |
|
|
optional uint32 characterOffsetBegin = 5; |
|
|
optional uint32 characterOffsetEnd = 6; |
|
|
optional ParseTree parseTree = 7; |
|
|
optional ParseTree binarizedParseTree = 31; |
|
|
optional ParseTree annotatedParseTree = 32; |
|
|
optional string sentiment = 33; |
|
|
repeated ParseTree kBestParseTrees = 34; |
|
|
optional DependencyGraph basicDependencies = 8; |
|
|
optional DependencyGraph collapsedDependencies = 9; |
|
|
optional DependencyGraph collapsedCCProcessedDependencies = 10; |
|
|
optional DependencyGraph alternativeDependencies = 13; |
|
|
repeated RelationTriple openieTriple = 14; |
|
|
repeated RelationTriple kbpTriple = 16; |
|
|
repeated SentenceFragment entailedSentence = 15; |
|
|
repeated SentenceFragment entailedClause = 35; |
|
|
optional DependencyGraph enhancedDependencies = 17; |
|
|
optional DependencyGraph enhancedPlusPlusDependencies = 18; |
|
|
repeated Token character = 19; |
|
|
|
|
|
optional uint32 paragraph = 11; |
|
|
|
|
|
optional string text = 12; |
|
|
|
|
|
optional uint32 lineNumber = 20; |
|
|
|
|
|
|
|
|
optional bool hasRelationAnnotations = 51; |
|
|
repeated Entity entity = 52; |
|
|
repeated Relation relation = 53; |
|
|
optional bool hasNumerizedTokensAnnotation = 54; |
|
|
repeated NERMention mentions = 55; |
|
|
repeated Mention mentionsForCoref = 56; |
|
|
optional bool hasCorefMentionsAnnotation = 57; |
|
|
|
|
|
optional string sentenceID = 58; |
|
|
optional string sectionDate = 59; |
|
|
optional uint32 sectionIndex = 60; |
|
|
optional string sectionName = 61; |
|
|
optional string sectionAuthor = 62; |
|
|
optional string docID = 63; |
|
|
optional bool sectionQuoted = 64; |
|
|
|
|
|
optional bool hasEntityMentionsAnnotation = 65; |
|
|
optional bool hasKBPTriplesAnnotation = 68; |
|
|
optional bool hasOpenieTriplesAnnotation = 69; |
|
|
|
|
|
|
|
|
optional uint32 chapterIndex = 66; |
|
|
optional uint32 paragraphIndex = 67; |
|
|
|
|
|
optional Sentence enhancedSentence = 70; |
|
|
|
|
|
|
|
|
optional string speaker = 71; |
|
|
optional string speakerType = 72; |
|
|
|
|
|
extensions 100 to 255; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message Token { |
|
|
|
|
|
optional string word = 1; |
|
|
optional string pos = 2; |
|
|
optional string value = 3; |
|
|
optional string category = 4; |
|
|
optional string before = 5; |
|
|
optional string after = 6; |
|
|
optional string originalText = 7; |
|
|
optional string ner = 8; |
|
|
optional string coarseNER = 62; |
|
|
optional string fineGrainedNER = 63; |
|
|
repeated string nerLabelProbs = 66; |
|
|
optional string normalizedNER = 9; |
|
|
optional string lemma = 10; |
|
|
optional uint32 beginChar = 11; |
|
|
optional uint32 endChar = 12; |
|
|
optional uint32 utterance = 13; |
|
|
optional string speaker = 14; |
|
|
optional string speakerType = 77; |
|
|
optional uint32 beginIndex = 15; |
|
|
optional uint32 endIndex = 16; |
|
|
optional uint32 tokenBeginIndex = 17; |
|
|
optional uint32 tokenEndIndex = 18; |
|
|
optional Timex timexValue = 19; |
|
|
optional bool hasXmlContext = 21; |
|
|
repeated string xmlContext = 22; |
|
|
optional uint32 corefClusterID = 23; |
|
|
optional string answer = 24; |
|
|
|
|
|
optional uint32 headWordIndex = 26; |
|
|
optional Operator operator = 27; |
|
|
optional Polarity polarity = 28; |
|
|
optional string polarity_dir = 39; |
|
|
optional Span span = 29; |
|
|
optional string sentiment = 30; |
|
|
optional int32 quotationIndex = 31; |
|
|
optional MapStringString conllUFeatures = 32; |
|
|
optional string coarseTag = 33; |
|
|
optional Span conllUTokenSpan = 34; |
|
|
optional string conllUMisc = 35; |
|
|
optional MapStringString conllUSecondaryDeps = 36; |
|
|
optional string wikipediaEntity = 37; |
|
|
optional bool isNewline = 38; |
|
|
|
|
|
|
|
|
|
|
|
optional string gender = 51; |
|
|
optional string trueCase = 52; |
|
|
optional string trueCaseText = 53; |
|
|
|
|
|
|
|
|
optional string chineseChar = 54; |
|
|
optional string chineseSeg = 55; |
|
|
optional string chineseXMLChar = 60; |
|
|
|
|
|
|
|
|
optional string arabicSeg = 76; |
|
|
|
|
|
|
|
|
optional string sectionName = 56; |
|
|
optional string sectionAuthor = 57; |
|
|
optional string sectionDate = 58; |
|
|
optional string sectionEndLabel = 59; |
|
|
|
|
|
|
|
|
optional string parent = 61; |
|
|
|
|
|
|
|
|
repeated uint32 corefMentionIndex = 64; |
|
|
optional uint32 entityMentionIndex = 65; |
|
|
|
|
|
|
|
|
optional bool isMWT = 67; |
|
|
optional bool isFirstMWT = 68; |
|
|
optional string mwtText = 69; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
optional string mwtMisc = 78; |
|
|
|
|
|
|
|
|
optional uint64 numericValue = 70; |
|
|
optional string numericType = 71; |
|
|
optional uint64 numericCompositeValue = 72; |
|
|
optional string numericCompositeType = 73; |
|
|
|
|
|
optional uint32 codepointOffsetBegin = 74; |
|
|
optional uint32 codepointOffsetEnd = 75; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
optional uint32 index = 79; |
|
|
optional uint32 emptyIndex = 80; |
|
|
|
|
|
extensions 100 to 255; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
enum Sentiment { |
|
|
STRONG_NEGATIVE = 0; |
|
|
WEAK_NEGATIVE = 1; |
|
|
NEUTRAL = 2; |
|
|
WEAK_POSITIVE = 3; |
|
|
STRONG_POSITIVE = 4; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message Quote { |
|
|
optional string text = 1; |
|
|
optional uint32 begin = 2; |
|
|
optional uint32 end = 3; |
|
|
optional uint32 sentenceBegin = 5; |
|
|
optional uint32 sentenceEnd = 6; |
|
|
optional uint32 tokenBegin = 7; |
|
|
optional uint32 tokenEnd = 8; |
|
|
optional string docid = 9; |
|
|
optional uint32 index = 10; |
|
|
optional string author = 11; |
|
|
optional string mention = 12; |
|
|
optional uint32 mentionBegin = 13; |
|
|
optional uint32 mentionEnd = 14; |
|
|
optional string mentionType = 15; |
|
|
optional string mentionSieve = 16; |
|
|
optional string speaker = 17; |
|
|
optional string speakerSieve = 18; |
|
|
optional string canonicalMention = 19; |
|
|
optional uint32 canonicalMentionBegin = 20; |
|
|
optional uint32 canonicalMentionEnd = 21; |
|
|
optional DependencyGraph attributionDependencyGraph = 22; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message ParseTree { |
|
|
repeated ParseTree child = 1; |
|
|
optional string value = 2; |
|
|
optional uint32 yieldBeginIndex = 3; |
|
|
optional uint32 yieldEndIndex = 4; |
|
|
optional double score = 5; |
|
|
optional Sentiment sentiment = 6; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message DependencyGraph { |
|
|
message Node { |
|
|
required uint32 sentenceIndex = 1; |
|
|
required uint32 index = 2; |
|
|
optional uint32 copyAnnotation = 3; |
|
|
optional uint32 emptyIndex = 4; |
|
|
} |
|
|
|
|
|
message Edge { |
|
|
required uint32 source = 1; |
|
|
required uint32 target = 2; |
|
|
optional string dep = 3; |
|
|
optional bool isExtra = 4; |
|
|
optional uint32 sourceCopy = 5; |
|
|
optional uint32 targetCopy = 6; |
|
|
optional uint32 sourceEmpty = 8; |
|
|
optional uint32 targetEmpty = 9; |
|
|
optional Language language = 7 [default=Unknown]; |
|
|
} |
|
|
|
|
|
repeated Node node = 1; |
|
|
repeated Edge edge = 2; |
|
|
repeated uint32 root = 3 [packed=true]; |
|
|
|
|
|
|
|
|
repeated Token token = 4; |
|
|
|
|
|
|
|
|
|
|
|
repeated uint32 rootNode = 5 [packed=true]; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message CorefChain { |
|
|
message CorefMention { |
|
|
optional int32 mentionID = 1; |
|
|
optional string mentionType = 2; |
|
|
optional string number = 3; |
|
|
optional string gender = 4; |
|
|
optional string animacy = 5; |
|
|
optional uint32 beginIndex = 6; |
|
|
optional uint32 endIndex = 7; |
|
|
optional uint32 headIndex = 9; |
|
|
optional uint32 sentenceIndex = 10; |
|
|
optional uint32 position = 11; |
|
|
} |
|
|
|
|
|
required int32 chainID = 1; |
|
|
repeated CorefMention mention = 2; |
|
|
required uint32 representative = 3; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message Mention { |
|
|
optional int32 mentionID = 1; |
|
|
optional string mentionType = 2; |
|
|
optional string number = 3; |
|
|
optional string gender = 4; |
|
|
optional string animacy = 5; |
|
|
optional string person = 6; |
|
|
optional uint32 startIndex = 7; |
|
|
optional uint32 endIndex = 9; |
|
|
optional int32 headIndex = 10; |
|
|
optional string headString = 11; |
|
|
optional string nerString = 12; |
|
|
optional int32 originalRef = 13; |
|
|
optional int32 goldCorefClusterID = 14; |
|
|
optional int32 corefClusterID = 15; |
|
|
optional int32 mentionNum = 16; |
|
|
optional int32 sentNum = 17; |
|
|
optional int32 utter = 18; |
|
|
optional int32 paragraph = 19; |
|
|
optional bool isSubject = 20; |
|
|
optional bool isDirectObject = 21; |
|
|
optional bool isIndirectObject = 22; |
|
|
optional bool isPrepositionObject = 23; |
|
|
optional bool hasTwin = 24; |
|
|
optional bool generic = 25; |
|
|
optional bool isSingleton = 26; |
|
|
optional bool hasBasicDependency = 27; |
|
|
optional bool hasEnhancedDependency = 28; |
|
|
optional bool hasContextParseTree = 29; |
|
|
optional IndexedWord headIndexedWord = 30; |
|
|
optional IndexedWord dependingVerb = 31; |
|
|
optional IndexedWord headWord = 32; |
|
|
optional SpeakerInfo speakerInfo = 33; |
|
|
|
|
|
repeated IndexedWord sentenceWords = 50; |
|
|
repeated IndexedWord originalSpan = 51; |
|
|
repeated string dependents = 52; |
|
|
repeated string preprocessedTerms = 53; |
|
|
repeated int32 appositions = 54; |
|
|
repeated int32 predicateNominatives = 55; |
|
|
repeated int32 relativePronouns = 56; |
|
|
repeated int32 listMembers = 57; |
|
|
repeated int32 belongToLists = 58; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message IndexedWord { |
|
|
optional int32 sentenceNum = 1; |
|
|
optional int32 tokenIndex = 2; |
|
|
optional int32 docID = 3; |
|
|
optional uint32 copyCount = 4; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message SpeakerInfo { |
|
|
optional string speakerName = 1; |
|
|
repeated int32 mentions = 2; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message Span { |
|
|
required uint32 begin = 1; |
|
|
required uint32 end = 2; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message Timex { |
|
|
optional string value = 1; |
|
|
optional string altValue = 2; |
|
|
optional string text = 3; |
|
|
optional string type = 4; |
|
|
optional string tid = 5; |
|
|
optional uint32 beginPoint = 6; |
|
|
optional uint32 endPoint = 7; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message Entity { |
|
|
optional uint32 headStart = 6; |
|
|
optional uint32 headEnd = 7; |
|
|
optional string mentionType = 8; |
|
|
optional string normalizedName = 9; |
|
|
optional uint32 headTokenIndex = 10; |
|
|
optional string corefID = 11; |
|
|
|
|
|
optional string objectID = 1; |
|
|
optional uint32 extentStart = 2; |
|
|
optional uint32 extentEnd = 3; |
|
|
optional string type = 4; |
|
|
optional string subtype = 5; |
|
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message Relation { |
|
|
repeated string argName = 6; |
|
|
repeated Entity arg = 7; |
|
|
optional string signature = 8; |
|
|
|
|
|
optional string objectID = 1; |
|
|
optional uint32 extentStart = 2; |
|
|
optional uint32 extentEnd = 3; |
|
|
optional string type = 4; |
|
|
optional string subtype = 5; |
|
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message Operator { |
|
|
required string name = 1; |
|
|
required int32 quantifierSpanBegin = 2; |
|
|
required int32 quantifierSpanEnd = 3; |
|
|
required int32 subjectSpanBegin = 4; |
|
|
required int32 subjectSpanEnd = 5; |
|
|
required int32 objectSpanBegin = 6; |
|
|
required int32 objectSpanEnd = 7; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
enum NaturalLogicRelation { |
|
|
EQUIVALENCE = 0; |
|
|
FORWARD_ENTAILMENT = 1; |
|
|
REVERSE_ENTAILMENT = 2; |
|
|
NEGATION = 3; |
|
|
ALTERNATION = 4; |
|
|
COVER = 5; |
|
|
INDEPENDENCE = 6; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message Polarity { |
|
|
required NaturalLogicRelation projectEquivalence = 1; |
|
|
required NaturalLogicRelation projectForwardEntailment = 2; |
|
|
required NaturalLogicRelation projectReverseEntailment = 3; |
|
|
required NaturalLogicRelation projectNegation = 4; |
|
|
required NaturalLogicRelation projectAlternation = 5; |
|
|
required NaturalLogicRelation projectCover = 6; |
|
|
required NaturalLogicRelation projectIndependence = 7; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message NERMention { |
|
|
optional uint32 sentenceIndex = 1; |
|
|
required uint32 tokenStartInSentenceInclusive = 2; |
|
|
required uint32 tokenEndInSentenceExclusive = 3; |
|
|
required string ner = 4; |
|
|
optional string normalizedNER = 5; |
|
|
optional string entityType = 6; |
|
|
optional Timex timex = 7; |
|
|
optional string wikipediaEntity = 8; |
|
|
optional string gender = 9; |
|
|
optional uint32 entityMentionIndex = 10; |
|
|
optional uint32 canonicalEntityMentionIndex = 11; |
|
|
optional string entityMentionText = 12; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message SentenceFragment { |
|
|
repeated uint32 tokenIndex = 1; |
|
|
optional uint32 root = 2; |
|
|
optional bool assumedTruth = 3; |
|
|
optional double score = 4; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message TokenLocation { |
|
|
optional uint32 sentenceIndex = 1; |
|
|
optional uint32 tokenIndex = 2; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message RelationTriple { |
|
|
optional string subject = 1; |
|
|
optional string relation = 2; |
|
|
optional string object = 3; |
|
|
optional double confidence = 4; |
|
|
repeated TokenLocation subjectTokens = 13; |
|
|
repeated TokenLocation relationTokens = 14; |
|
|
repeated TokenLocation objectTokens = 15; |
|
|
optional DependencyGraph tree = 8; |
|
|
optional bool istmod = 9; |
|
|
optional bool prefixBe = 10; |
|
|
optional bool suffixBe = 11; |
|
|
optional bool suffixOf = 12; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message MapStringString { |
|
|
repeated string key = 1; |
|
|
repeated string value = 2; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message MapIntString { |
|
|
repeated uint32 key = 1; |
|
|
repeated string value = 2; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message Section { |
|
|
required uint32 charBegin = 1; |
|
|
required uint32 charEnd = 2; |
|
|
optional string author = 3; |
|
|
repeated uint32 sentenceIndexes = 4; |
|
|
optional string datetime = 5; |
|
|
repeated Quote quotes = 6; |
|
|
optional uint32 authorCharBegin = 7; |
|
|
optional uint32 authorCharEnd = 8; |
|
|
required Token xmlTag = 9; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message SemgrexRequest { |
|
|
message Dependencies { |
|
|
repeated Token token = 1; |
|
|
required DependencyGraph graph = 2; |
|
|
} |
|
|
|
|
|
repeated string semgrex = 1; |
|
|
repeated Dependencies query = 2; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message SemgrexResponse { |
|
|
message NamedNode { |
|
|
required string name = 1; |
|
|
required int32 matchIndex = 2; |
|
|
} |
|
|
|
|
|
message NamedRelation { |
|
|
required string name = 1; |
|
|
required string reln = 2; |
|
|
} |
|
|
|
|
|
message NamedEdge { |
|
|
required string name = 1; |
|
|
required int32 source = 2; |
|
|
required int32 target = 3; |
|
|
optional string reln = 4; |
|
|
optional bool isExtra = 5; |
|
|
optional uint32 sourceCopy = 6; |
|
|
optional uint32 targetCopy = 7; |
|
|
} |
|
|
|
|
|
message Match { |
|
|
required int32 matchIndex = 1; |
|
|
repeated NamedNode node = 2; |
|
|
repeated NamedRelation reln = 3; |
|
|
repeated NamedEdge edge = 6; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
optional int32 graphIndex = 4; |
|
|
|
|
|
|
|
|
optional int32 semgrexIndex = 5; |
|
|
} |
|
|
|
|
|
message SemgrexResult { |
|
|
repeated Match match = 1; |
|
|
} |
|
|
|
|
|
message GraphResult { |
|
|
repeated SemgrexResult result = 1; |
|
|
} |
|
|
|
|
|
repeated GraphResult result = 1; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message SsurgeonRequest { |
|
|
message Ssurgeon { |
|
|
optional string semgrex = 1; |
|
|
repeated string operation = 2; |
|
|
optional string id = 3; |
|
|
optional string notes = 4; |
|
|
optional string language = 5; |
|
|
} |
|
|
|
|
|
repeated Ssurgeon ssurgeon = 1; |
|
|
repeated DependencyGraph graph = 2; |
|
|
} |
|
|
|
|
|
message SsurgeonResponse { |
|
|
message SsurgeonResult { |
|
|
optional DependencyGraph graph = 1; |
|
|
optional bool changed = 2; |
|
|
} |
|
|
|
|
|
repeated SsurgeonResult result = 1; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
message TokensRegexRequest { |
|
|
required Document doc = 1; |
|
|
repeated string pattern = 2; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
message TokensRegexResponse { |
|
|
message MatchLocation { |
|
|
optional string text = 1; |
|
|
optional int32 begin = 2; |
|
|
optional int32 end = 3; |
|
|
} |
|
|
|
|
|
message Match { |
|
|
required int32 sentence = 1; |
|
|
required MatchLocation match = 2; |
|
|
repeated MatchLocation group = 3; |
|
|
} |
|
|
|
|
|
message PatternMatch { |
|
|
repeated Match match = 1; |
|
|
} |
|
|
|
|
|
repeated PatternMatch match = 1; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
message DependencyEnhancerRequest { |
|
|
required Document document = 1; |
|
|
|
|
|
oneof ref { |
|
|
Language language = 2; |
|
|
|
|
|
string relativePronouns = 3; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
message FlattenedParseTree { |
|
|
message Node { |
|
|
oneof contents { |
|
|
bool openNode = 1; |
|
|
bool closeNode = 2; |
|
|
string value = 3; |
|
|
} |
|
|
|
|
|
optional double score = 4; |
|
|
} |
|
|
|
|
|
repeated Node nodes = 1; |
|
|
} |
|
|
|
|
|
|
|
|
message EvaluateParserRequest { |
|
|
message ParseResult { |
|
|
required FlattenedParseTree gold = 1; |
|
|
|
|
|
|
|
|
repeated FlattenedParseTree predicted = 2; |
|
|
} |
|
|
|
|
|
repeated ParseResult treebank = 1; |
|
|
} |
|
|
|
|
|
message EvaluateParserResponse { |
|
|
required double f1 = 1; |
|
|
optional double kbestF1 = 2; |
|
|
|
|
|
repeated double treeF1 = 3; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
message TsurgeonRequest { |
|
|
message Operation { |
|
|
required string tregex = 1; |
|
|
repeated string tsurgeon = 2; |
|
|
} |
|
|
repeated Operation operations = 1; |
|
|
repeated FlattenedParseTree trees = 2; |
|
|
} |
|
|
|
|
|
|
|
|
message TsurgeonResponse { |
|
|
repeated FlattenedParseTree trees = 1; |
|
|
} |
|
|
|
|
|
|
|
|
message MorphologyRequest { |
|
|
message TaggedWord { |
|
|
required string word = 1; |
|
|
optional string xpos = 2; |
|
|
} |
|
|
|
|
|
repeated TaggedWord words = 1; |
|
|
} |
|
|
|
|
|
|
|
|
message MorphologyResponse { |
|
|
message WordTagLemma { |
|
|
required string word = 1; |
|
|
optional string xpos = 2; |
|
|
required string lemma = 3; |
|
|
} |
|
|
|
|
|
repeated WordTagLemma words = 1; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
message DependencyConverterRequest { |
|
|
repeated FlattenedParseTree trees = 1; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
message DependencyConverterResponse { |
|
|
message DependencyConversion { |
|
|
required DependencyGraph graph = 1; |
|
|
optional FlattenedParseTree tree = 2; |
|
|
} |
|
|
|
|
|
repeated DependencyConversion conversions = 1; |
|
|
} |
|
|
|
|
|
|