LIMA
Libre Multilingual Analyzer — C++ API
Loading...
Searching...
No Matches
coreferentAnnotation.h
Go to the documentation of this file.
1// Copyright 2002-2013 CEA LIST
2// SPDX-FileCopyrightText: 2022 CEA LIST <gael.de-chalendar@cea.fr>
3//
4// SPDX-License-Identifier: MIT
5
16
17#ifndef LIMA_COREFSOLVING_COREFERENTANNOTATION_H
18#define LIMA_COREFSOLVING_COREFERENTANNOTATION_H
19
20#include "CorefSolvingExport.h"
26
27#include <string>
28
29
30
31namespace Lima
32{
33namespace Common {
34namespace AnnotationGraphs {
35 class AnnotationData;
36}
37}
39{
40namespace SyntacticAnalysis {
41class SyntacticData;
42}
43namespace Coreferences
44{
45
47{
48
49
50public:
51
52typedef std::set<CoreferentAnnotation*> Vertices;
53typedef std::map<CoreferentAnnotation*,std::set<CoreferentAnnotation*> > VerticesRelation;
54typedef std::map< CoreferentAnnotation*,std::map <CoreferentAnnotation*,float> > WeightedVerticesRelation;
55
57
58 CoreferentAnnotation(uint64_t id, const std::string& categ, const float salience, LinguisticGraphVertex v) :
60
63
66 m_id(id), m_categ("not initialized"), m_salience(-1), m_bindingSalience(0), m_morphVertex(v), m_newerRef(this) {}
67
68
70 {
71 m_id = ca.m_id;
72 m_categ = ca.m_categ;
74// m_av = ca.m_av;
78 return *this;
79 };
80
81
83
84 inline uint64_t id();
85 inline uint64_t id() const;
86 inline std::string& categ();
87 inline const std::string& categ() const;
88 inline float salience() const;
89 inline float bindingSalience() const;
90 inline LinguisticGraphVertex morphVertex();
91 inline LinguisticGraphVertex morphVertex() const;
93 inline AnnotationGraphVertex av() const;
95 inline CoreferentAnnotation* newerRef() const;
96 inline void id(uint64_t newId);
97 inline void categ(const std::string newType);
98 inline void salience(const float newSalience);
99 inline void bindingSalience(const float newBindingSalience);
100 inline void morphVertex(LinguisticGraphVertex v);
103 void dump( std::ostream& os, const Lima::Common::AnnotationGraphs::AnnotationData* ad ) const;
104 inline bool hasNewerRef(/*std::deque<Vertices>* npCandidates*/);
105
107
109 const LinguisticGraph* g,
110 MediaId language,
112 AnalysisContent& ac,
113 const std::set< LinguisticCode >& inNpCategs,
114 const Common::PropertyCode::PropertyAccessor* microAccessor) const;
115
118 MediaId language,
119 std::set<DependencyGraphVertex>* alreadyProcessed ) const;
120
122 const LinguisticGraph* g,
123 const std::set< LinguisticCode >& categs,
124 const Common::PropertyCode::PropertyAccessor* microAccessor) const;
125
126
128
130 const std::string& definiteRel,
131 const std::set< LinguisticCode >& definiteCategs,
132 const Common::PropertyCode::PropertyAccessor* microAccessor,
133 MediaId language) const ;
135 const std::string& m_pleonRel,
136 MediaId language) const;
137
138 bool isPronoun(const LinguisticGraph* g,
139 const Common::PropertyCode::PropertyAccessor* macroAccessor,
140 const LinguisticCode& L_PRON) const ;
141/*
142 bool isVerb(const LinguisticGraph* g,
143 const Common::PropertyCode::PropertyAccessor* macroAccessor,
144 const LinguisticCode& L_V) const ;*/
145
146 bool isConjCoord(
147 const Common::PropertyCode::PropertyAccessor* microAccessor,
149 const LinguisticCode& conjCoord) const;
150
151 std::string referentType(
153 const LinguisticGraph* g,
154 const Common::PropertyCode::PropertyAccessor* macroAccessor,
155 const Common::PropertyCode::PropertyAccessor* microAccessor,
156 const std::map<std::string,LinguisticCode>& tagLocalDef,
157 const std::map<std::string, std::deque<std::string> >& relLocalDef,
158 const std::set< LinguisticCode >& definiteCategs,
159 const std::set< LinguisticCode >& reflexiveReciprocalCategs,
160 const std::set< LinguisticCode >& undefPronounsCategs,
161 const std::set< LinguisticCode >& possPronounsCategs,
162 const Common::PropertyCode::PropertyAccessor* personAccessor,
164 MediaId language) const;
165
166bool isN3PPronoun(
167 const Common::PropertyCode::PropertyAccessor* personAccessor,
168 const LinguisticAnalysisStructure::AnalysisGraph* anagraph) const;
169
171
172 bool sentenceIsRecent() const;
173 bool beginWithColon(
175 LinguisticGraphVertex& beginSentence) const;
176 bool endWithColon(
178 LinguisticGraphVertex& endSentence) const;
179 bool isInAppos(
182 AnalysisContent& ac,
183 MediaId language,
184 std::set<DependencyGraphVertex>* alreadyProcessed) const;
185 bool isInQuantA(
187 const LinguisticAnalysisStructure::AnalysisGraph* anagraph) const;
188 bool isInSubordinate(
190 const Common::PropertyCode::PropertyAccessor* macroAccessor,
191 const std::map<std::string,LinguisticCode>& tagLocalDef,
192 MediaId language,
194 AnalysisContent& ac,
195 std::set<LinguisticGraphVertex>* alreadyProcessed) const;
198 const std::deque<std::string>& macroDependencyRelation,
199 MediaId language) const;
200
201
203
204
205 bool isVerb(
206 const Common::PropertyCode::PropertyAccessor* macroAccessor,
207 const std::map<std::string,LinguisticCode>& tagLocalDef,
208 const LinguisticAnalysisStructure::AnalysisGraph* anagraph) const;
209
212 const Common::PropertyCode::PropertyAccessor* genderAccessor,
213 MediaId language,
215 AnalysisContent& ac) const ;
216
217 // P and N have incompatible agreement features. (gender, number)
219 const CoreferentAnnotation& ca,
221 const Common::PropertyCode::PropertyAccessor* genderAccessor,
222 const Common::PropertyCode::PropertyAccessor* personAccessor,
223 const Common::PropertyCode::PropertyAccessor* numberAccessor,
224 MediaId language,
226 AnalysisContent& ac) const ;
227
228 // P is in the Argument Domain of N <=> P and N are both argument of the same head
230 const CoreferentAnnotation& ca,
232 MediaId language,
234 AnalysisContent& ac,
235 const Common::PropertyCode::PropertyAccessor* macroAccessor,
236 const Common::PropertyCode::PropertyAccessor* microAccessor,
237 const std::map<std::string,LinguisticCode>& tagLocalDef,
238 const LinguisticCode& conjCoord,
239 std::set<LinguisticGraphVertex>* alreadyProcessed) const ;
240
241 // P is in the Argument Domain of N <=> P and N are both argument of the same head
243 const CoreferentAnnotation& ca,
245 MediaId language,
247 AnalysisContent& ac,
248 const Common::PropertyCode::PropertyAccessor* macroAccessor,
249 const Common::PropertyCode::PropertyAccessor* microAccessor,
250 const std::map<std::string,LinguisticCode>& tagLocalDef,
251 const LinguisticCode& conjCoord,
252 std::set<LinguisticGraphVertex>* alreadyProcessed) const ;
253
254 // P is in the Adjunct Domain of N <=> N is an argument of a head H, P is the object of a preposition PREP, PREP is an adjunct of H
256 const CoreferentAnnotation& ca,
258 const LinguisticGraph* graph,
259 //const Common::PropertyCode::PropertyManager& microManager,
260 const Common::PropertyCode::PropertyAccessor* microAccessor,
261 const std::map<std::string,LinguisticCode>& tagLocalDef,
262 const std::map<std::string, std::deque<std::string> >& relLocalDef,
263 MediaId language) const;
264
265// P is the object of a preposition PREP,
266// and PREP is an adjunct of Q
268 const DependencyGraphVertex& qv,
270 const LinguisticGraph* graph,
271 const Common::PropertyCode::PropertyAccessor* microAccessor,
272 const std::map<std::string,LinguisticCode>& tagLocalDef,
273 const std::map<std::string, std::deque<std::string> >& relLocalDef,
274 MediaId language) const;
275
276 // P is an argument of a head H, N is not a pronoun,
277 // and N is contained in H.
278 bool sf4(
279 const CoreferentAnnotation& ca,
281 //const LinguisticGraph* g,
282 const Common::PropertyCode::PropertyAccessor* macroAccessor,
283 const LinguisticCode& L_PRON,
284 MediaId language,
286 AnalysisContent& ac) const;
287
288 // P is in the NP domain of N <=> N is a determiner of a noun Q, and:
289 // (i) P is an argument of Q.
290 // or (ii) P is an object of a preposition PREP and PREP is an adjunct of Q.
291 bool isInTheNpDomainOf(
292 const CoreferentAnnotation& ca,
294 const Common::PropertyCode::PropertyAccessor* microAccessor,
295 const std::map<std::string,LinguisticCode>& tagLocalDef,
296 const std::map<std::string,std::deque<std::string> >& relLocalDef,
297 MediaId language,
299 AnalysisContent& ac) const;
300
301 // P is contained in a phrase Q <=>
302 // (i) P is either an argument or an adjunct of Q (ie. P is immediately contained in Q.
303 // or (ii) P is immediately contained in some phrase R, and R is contained in Q.
304 bool isContainedIn(
305 const DependencyGraphVertex& dv,
306 MediaId language,
308 AnalysisContent& ac) const;
309
310 bool isDeterminer(
313 const std::map<std::string,std::deque<std::string> >& relLocalDef,
314 MediaId language,
316 AnalysisContent& ac) const;
317
318 // P is a determiner of a noun Q,
319 // and N is contained in Q.
320 bool sf6(
321 const CoreferentAnnotation& ca,
323 const std::map<std::string,std::deque<std::string> >& relLocalDef,
324 MediaId language,
326 AnalysisContent& ac) const;
327
328 // N is an argument of a verb V,
329 // there is an NP Q in the argument domain of N such that Q has no noun determiner,
330 // and
331 // (i) A is an argument of Q.
332 // or (ii) A is an argument of a preposition PREP and PREP is an adjunct of Q.
333 bool aba4(
334 const CoreferentAnnotation& ca,
335 //Common::AnnotationGraphs::AnnotationData* ad,
337 const std::map<std::string,LinguisticCode >& tagLocalDef,
338 const std::map<std::string,std::deque<std::string> >& relLocalDef,
339 const Common::PropertyCode::PropertyAccessor* macroAccessor,
340 const Common::PropertyCode::PropertyAccessor* microAccessor,
341 MediaId language,
342 const std::set< LinguisticCode >& inNpCategs,
344 AnalysisContent& ac,
345 const LinguisticCode& conjCoord,
346 std::deque<Vertices>* npCandidates) const;
347
348// [higher slot] subj > agent > obj > (iobj|pobj) [lower slot]
349int getSlotValue(
351 const std::map<std::string,std::deque<std::string> >& relLocalDef,
352 const std::map<std::string, int>& slotValues,
353 MediaId language) const;
354
355 // A is a determiner of a noun Q,
356 // and
357 // (i) Q is in the argument domain of N,
358 // and N fills a higher argument slot than Q.
359 // or (ii) Q is in the adjunct domain of N.
360 bool aba5(
361 const CoreferentAnnotation& ca,
363 const std::map<std::string,LinguisticCode>& tagLocalDef,
364 const std::map<std::string,std::deque<std::string> >& relLocalDef,
365 const Common::PropertyCode::PropertyAccessor* macroAccessor,
366 const Common::PropertyCode::PropertyAccessor* microAccessor,
367 MediaId language,
369 AnalysisContent& ac,
370 const std::map<std::string, int>& slotValues,
371 const LinguisticCode& conjCoord) const;
372
373
375
376 int classify(
377 LinguisticGraph* graph,
379 const Common::PropertyCode::PropertyAccessor* macroAccessor,
380 const Common::PropertyCode::PropertyAccessor* microAccessor,
381 const std::map<std::string,LinguisticCode>& tagLocalDef,
382 const std::map<std::string, std::deque<std::string> >& relLocalDef,
383 const std::set< LinguisticCode >& definiteCategs,
384 const std::set< LinguisticCode >& reflexiveReciprocalCategs,
385 const std::set< LinguisticCode >& undefPronouns,
386 const std::set< LinguisticCode >& possPronouns,
387 const bool& resolveDefinites,
388 const bool& resolveN3PPronouns,
389 const Common::PropertyCode::PropertyAccessor* personAccessor,
391 MediaId language) ;
392
393
394 float salienceWeighting(
395 const std::map<std::string,float>& weights,
397 const Common::PropertyCode::PropertyAccessor* macroAccessor,
399 MediaId language,
400 const std::map< std::string,LinguisticCode>& tagLocalDef,
401 const std::map< std::string,std::deque<std::string> >& relLocalDef,
402 AnalysisContent& ac,
403 LinguisticGraphVertex& beginSentence,
404 LinguisticGraphVertex& endSentence) const;
405
408 CoreferentAnnotation& antecedent) const;
409
410 virtual void outputXml(std::ostream& xmlStream,
411 const LinguisticGraph& g,
413
414
415private:
416
417protected:
418 uint64_t m_id;
419 std::string m_categ;
423// AnnotationGraphVertex m_av;
424
426};
427
429{
430 return m_id;
431}
432inline uint64_t CoreferentAnnotation::id() const
433{
434 return m_id;
435}
436inline std::string& CoreferentAnnotation::categ()
437{
438 return m_categ;
439}
440inline const std::string& CoreferentAnnotation::categ() const
441{
442 return m_categ;
443}
445{
446 return m_salience;
447}
449{
450 return m_bindingSalience;
451}
460// inline AnnotationGraphVertex CoreferentAnnotation::av()
461// {
462// return m_av;
463// }
464// inline AnnotationGraphVertex CoreferentAnnotation::av() const
465// {
466// return m_av;
467// }
476inline void CoreferentAnnotation::id(uint64_t newId)
477{
478 m_id = newId;
479}
480inline void CoreferentAnnotation::categ(const std::string newType)
481{
482 m_categ = newType;
483}
484inline void CoreferentAnnotation::salience(const float newSalience)
485{
486 m_salience = newSalience;
487}
488inline void CoreferentAnnotation::bindingSalience(const float newBindingSalience)
489{
490 m_bindingSalience = newBindingSalience;
491}
496// inline void CoreferentAnnotation::av(AnnotationGraphVertex av)
497// {
498// m_av = av;
499// }
505{
506return (newerRef()!=this);
507}
508
509
510
511
522{
523public:
525 virtual int dump(std::ostream& os, Common::AnnotationGraphs::GenericAnnotation& ga) const override;
526
527private:
529
530};
531
532
533} // closing namespace Coreferences
534} // closing namespace LinguisticProcessing
535} // closing namespace Lima
536
537#endif // LIMA_COREFSOLVING_COREFSOLVER_H
This file is the main header file for the data related to annotation graphs.
#define LIMA_COREFSOLVING_EXPORT
A graph that stores the relations of syntactic dependency between the elements of a DependencyGraph.
DependencyGraph::vertex_descriptor DependencyGraphVertex
A graph structure for linguistic analysis.
LinguisticGraph::vertex_descriptor LinguisticGraphVertex
boost::adjacency_list< boost::vecS, boost::vecS, boost::bidirectionalS, LinguisticVertexProperties > LinguisticGraph
Property to identify the chains in the graph.
Holds all data that pass through the ProcessUnits Analysis data are shared pointers,...
Holds an annotation graph and gives an API to manipulate it.
This class allows to convert any object into an annotation by inheritance.
Provide function to read write and check a property.
bool aba4(const CoreferentAnnotation &ca, const SyntacticAnalysis::SyntacticData *sd, const std::map< std::string, LinguisticCode > &tagLocalDef, const std::map< std::string, std::deque< std::string > > &relLocalDef, const Common::PropertyCode::PropertyAccessor *macroAccessor, const Common::PropertyCode::PropertyAccessor *microAccessor, MediaId language, const std::set< LinguisticCode > &inNpCategs, LinguisticAnalysisStructure::AnalysisGraph *anagraph, AnalysisContent &ac, const LinguisticCode &conjCoord, std::deque< Vertices > *npCandidates) const
bool endWithColon(const LinguisticAnalysisStructure::AnalysisGraph *anagraph, LinguisticGraphVertex &endSentence) const
int classify(LinguisticGraph *graph, SyntacticAnalysis::SyntacticData *sd, const Common::PropertyCode::PropertyAccessor *macroAccessor, const Common::PropertyCode::PropertyAccessor *microAccessor, const std::map< std::string, LinguisticCode > &tagLocalDef, const std::map< std::string, std::deque< std::string > > &relLocalDef, const std::set< LinguisticCode > &definiteCategs, const std::set< LinguisticCode > &reflexiveReciprocalCategs, const std::set< LinguisticCode > &undefPronouns, const std::set< LinguisticCode > &possPronouns, const bool &resolveDefinites, const bool &resolveN3PPronouns, const Common::PropertyCode::PropertyAccessor *personAccessor, const LinguisticAnalysisStructure::AnalysisGraph *anagraph, MediaId language)
main functions of the global algorithm (called by Corefsolver)
std::string referentType(const SyntacticAnalysis::SyntacticData *sd, const LinguisticGraph *g, const Common::PropertyCode::PropertyAccessor *macroAccessor, const Common::PropertyCode::PropertyAccessor *microAccessor, const std::map< std::string, LinguisticCode > &tagLocalDef, const std::map< std::string, std::deque< std::string > > &relLocalDef, const std::set< LinguisticCode > &definiteCategs, const std::set< LinguisticCode > &reflexiveReciprocalCategs, const std::set< LinguisticCode > &undefPronounsCategs, const std::set< LinguisticCode > &possPronounsCategs, const Common::PropertyCode::PropertyAccessor *personAccessor, const LinguisticAnalysisStructure::AnalysisGraph *anagraph, MediaId language) const
bool isTaggedAsOneOfThese(const LinguisticGraph *g, const std::set< LinguisticCode > &categs, const Common::PropertyCode::PropertyAccessor *microAccessor) const
bool isContainedIn(const DependencyGraphVertex &dv, MediaId language, const LinguisticAnalysisStructure::AnalysisGraph *anagraph, AnalysisContent &ac) const
bool isGovernedByMasculineCoordinate(const SyntacticAnalysis::SyntacticData *sd, const Common::PropertyCode::PropertyAccessor *genderAccessor, MediaId language, const LinguisticAnalysisStructure::AnalysisGraph *anagraph, AnalysisContent &ac) const
bool isInTheNpDomainOf(const CoreferentAnnotation &ca, const SyntacticAnalysis::SyntacticData *sd, const Common::PropertyCode::PropertyAccessor *microAccessor, const std::map< std::string, LinguisticCode > &tagLocalDef, const std::map< std::string, std::deque< std::string > > &relLocalDef, MediaId language, const LinguisticAnalysisStructure::AnalysisGraph *anagraph, AnalysisContent &ac) const
bool isDeterminer(DependencyGraphVertex *qv, const SyntacticAnalysis::SyntacticData *sd, const std::map< std::string, std::deque< std::string > > &relLocalDef, MediaId language, const LinguisticAnalysisStructure::AnalysisGraph *anagraph, AnalysisContent &ac) const
bool sf4(const CoreferentAnnotation &ca, const SyntacticAnalysis::SyntacticData *sd, const Common::PropertyCode::PropertyAccessor *macroAccessor, const LinguisticCode &L_PRON, MediaId language, const LinguisticAnalysisStructure::AnalysisGraph *anagraph, AnalysisContent &ac) const
bool isInTheAdjunctDomainOf(const CoreferentAnnotation &ca, const SyntacticAnalysis::SyntacticData *sd, const LinguisticGraph *graph, const Common::PropertyCode::PropertyAccessor *microAccessor, const std::map< std::string, LinguisticCode > &tagLocalDef, const std::map< std::string, std::deque< std::string > > &relLocalDef, MediaId language) const
void dump(std::ostream &os, const Lima::Common::AnnotationGraphs::AnnotationData *ad) const
float salienceWeighting(const std::map< std::string, float > &weights, const SyntacticAnalysis::SyntacticData *sd, const Common::PropertyCode::PropertyAccessor *macroAccessor, const LinguisticAnalysisStructure::AnalysisGraph *anagraph, MediaId language, const std::map< std::string, LinguisticCode > &tagLocalDef, const std::map< std::string, std::deque< std::string > > &relLocalDef, AnalysisContent &ac, LinguisticGraphVertex &beginSentence, LinguisticGraphVertex &endSentence) const
bool isInTheArgumentDomainOf(const CoreferentAnnotation &ca, const SyntacticAnalysis::SyntacticData *sd, MediaId language, const LinguisticAnalysisStructure::AnalysisGraph *anagraph, AnalysisContent &ac, const Common::PropertyCode::PropertyAccessor *macroAccessor, const Common::PropertyCode::PropertyAccessor *microAccessor, const std::map< std::string, LinguisticCode > &tagLocalDef, const LinguisticCode &conjCoord, std::set< LinguisticGraphVertex > *alreadyProcessed) const
virtual void outputXml(std::ostream &xmlStream, const LinguisticGraph &g, const Common::AnnotationGraphs::AnnotationData *ad) const
bool isInTheArgumentDomainOf2(const CoreferentAnnotation &ca, const SyntacticAnalysis::SyntacticData *sd, MediaId language, const LinguisticAnalysisStructure::AnalysisGraph *anagraph, AnalysisContent &ac, const Common::PropertyCode::PropertyAccessor *macroAccessor, const Common::PropertyCode::PropertyAccessor *microAccessor, const std::map< std::string, LinguisticCode > &tagLocalDef, const LinguisticCode &conjCoord, std::set< LinguisticGraphVertex > *alreadyProcessed) const
std::map< CoreferentAnnotation *, std::set< CoreferentAnnotation * > > VerticesRelation
bool beginWithColon(const LinguisticAnalysisStructure::AnalysisGraph *anagraph, LinguisticGraphVertex &beginSentence) const
test functions for the salience weighting
CoreferentAnnotation(uint64_t id, const std::string &categ, const float salience, LinguisticGraphVertex v)
bool isDefinite(const SyntacticAnalysis::SyntacticData *sd, const std::string &definiteRel, const std::set< LinguisticCode > &definiteCategs, const Common::PropertyCode::PropertyAccessor *microAccessor, MediaId language) const
test functions for the initial classification
AnnotationGraphVertex writeAnnotation(Common::AnnotationGraphs::AnnotationData *ad, CoreferentAnnotation &antecedent) const
bool sentenceIsRecent() const
test functions for the salience weighting
bool isPronoun(const LinguisticGraph *g, const Common::PropertyCode::PropertyAccessor *macroAccessor, const LinguisticCode &L_PRON) const
test functions for the initial classification
bool isPleonastic(const SyntacticAnalysis::SyntacticData *sd, const std::string &m_pleonRel, MediaId language) const
bool isInThePrepAdjunctNP(const DependencyGraphVertex &qv, const SyntacticAnalysis::SyntacticData *sd, const LinguisticGraph *graph, const Common::PropertyCode::PropertyAccessor *microAccessor, const std::map< std::string, LinguisticCode > &tagLocalDef, const std::map< std::string, std::deque< std::string > > &relLocalDef, MediaId language) const
bool isInSubordinate(const SyntacticAnalysis::SyntacticData *sd, const Common::PropertyCode::PropertyAccessor *macroAccessor, const std::map< std::string, LinguisticCode > &tagLocalDef, MediaId language, const LinguisticAnalysisStructure::AnalysisGraph *anagraph, AnalysisContent &ac, std::set< LinguisticGraphVertex > *alreadyProcessed) const
bool sf6(const CoreferentAnnotation &ca, const SyntacticAnalysis::SyntacticData *sd, const std::map< std::string, std::deque< std::string > > &relLocalDef, MediaId language, const LinguisticAnalysisStructure::AnalysisGraph *anagraph, AnalysisContent &ac) const
int getSlotValue(const SyntacticAnalysis::SyntacticData *sd, const std::map< std::string, std::deque< std::string > > &relLocalDef, const std::map< std::string, int > &slotValues, MediaId language) const
LinguisticGraphVertex npHeadVertex(const SyntacticAnalysis::SyntacticData *sd, MediaId language, std::set< DependencyGraphVertex > *alreadyProcessed) const
bool aba5(const CoreferentAnnotation &ca, const SyntacticAnalysis::SyntacticData *sd, const std::map< std::string, LinguisticCode > &tagLocalDef, const std::map< std::string, std::deque< std::string > > &relLocalDef, const Common::PropertyCode::PropertyAccessor *macroAccessor, const Common::PropertyCode::PropertyAccessor *microAccessor, MediaId language, LinguisticAnalysisStructure::AnalysisGraph *anagraph, AnalysisContent &ac, const std::map< std::string, int > &slotValues, const LinguisticCode &conjCoord) const
bool isConjCoord(const Common::PropertyCode::PropertyAccessor *microAccessor, const LinguisticAnalysisStructure::AnalysisGraph *anagraph, const LinguisticCode &conjCoord) const
CoreferentAnnotation & operator=(const CoreferentAnnotation &ca)
bool isAgreementCompatibleWith(const CoreferentAnnotation &ca, const SyntacticAnalysis::SyntacticData *sd, const Common::PropertyCode::PropertyAccessor *genderAccessor, const Common::PropertyCode::PropertyAccessor *personAccessor, const Common::PropertyCode::PropertyAccessor *numberAccessor, MediaId language, const LinguisticAnalysisStructure::AnalysisGraph *anagraph, AnalysisContent &ac) const
bool isFunctionMasterOf(const SyntacticAnalysis::SyntacticData *sd, const std::deque< std::string > &macroDependencyRelation, MediaId language) const
returns true if *this governs a macroDependencyRelation (cf.
bool isVerb(const Common::PropertyCode::PropertyAccessor *macroAccessor, const std::map< std::string, LinguisticCode > &tagLocalDef, const LinguisticAnalysisStructure::AnalysisGraph *anagraph) const
test functions for the syntactic filter and the reflexive binding algorithm
bool isIncludedInNounPhrase(const LinguisticGraph *g, MediaId language, const LinguisticAnalysisStructure::AnalysisGraph *anagraph, AnalysisContent &ac, const std::set< LinguisticCode > &inNpCategs, const Common::PropertyCode::PropertyAccessor *microAccessor) const
general test functions
std::map< CoreferentAnnotation *, std::map< CoreferentAnnotation *, float > > WeightedVerticesRelation
bool isInAppos(const SyntacticAnalysis::SyntacticData *sd, const LinguisticAnalysisStructure::AnalysisGraph *anagraph, AnalysisContent &ac, MediaId language, std::set< DependencyGraphVertex > *alreadyProcessed) const
bool isInQuantA(const SyntacticAnalysis::SyntacticData *sd, const LinguisticAnalysisStructure::AnalysisGraph *anagraph) const
bool isN3PPronoun(const Common::PropertyCode::PropertyAccessor *personAccessor, const LinguisticAnalysisStructure::AnalysisGraph *anagraph) const
DumpCoreferent(const Lima::Common::AnnotationGraphs::AnnotationData *ad)
virtual int dump(std::ostream &os, Common::AnnotationGraphs::GenericAnnotation &ga) const override
An AnalysisData containing a LinguisticGraph with a language and an id.
This class points to a graph, its dependency graph and the structure that holds the maping between th...
AnnotationGraph::vertex_descriptor AnnotationGraphVertex
NAUTITIA.