LIMA
Libre Multilingual Analyzer — C++ API
Loading...
Searching...
No Matches
Lima::LinguisticProcessing::SemanticAnalysis::KnowledgeBasedSemanticRoleLabeler Class Reference

This is a MediaProcessUnit which do semantic role labeling using the knowledge-based SRL in python made by Quentin Pradet during his PhD thesis. More...

#include <linguisticProcessing/core/SemanticAnalysis/KnowledgeBasedSemanticRoleLabeler.h>

Inheritance diagram for Lima::LinguisticProcessing::SemanticAnalysis::KnowledgeBasedSemanticRoleLabeler:
Lima::MediaProcessUnit Lima::AbstractProcessUnit< MediaProcessUnit, MediaProcessUnitInitializationParameters > Lima::InitializableObject< Base, InitializationParameters >

Public Member Functions

 KnowledgeBasedSemanticRoleLabeler ()
 
virtual ~KnowledgeBasedSemanticRoleLabeler ()
 
void init (Common::XMLConfigurationFiles::GroupConfigurationStructure &unitConfiguration, Manager *manager) override
 initialize with parameters from configuration file.
 
LimaStatusCode process (AnalysisContent &analysis) const override
 Process on data in analysisContent.
 
- Public Member Functions inherited from Lima::InitializableObject< Base, InitializationParameters >
 InitializableObject ()
 
 InitializableObject (const InitializableObject &object)
 
InitializableObject & operator= (const InitializableObject &object)
 
virtual ~InitializableObject ()
 
const std::string & getId () const
 get the object id
 
void setId (const std::string &id)
 set the object id
 

Additional Inherited Members

- Public Types inherited from Lima::InitializableObject< Base, InitializationParameters >
typedef InitializableObjectManager< Base, InitializationParameters > Manager
 Manager is the type of the Manager associated to the initializableObject.
 
typedef InitializableObjectFactory< Base > Factory
 Factory is the type of the Factory associated to the initializableObject.
 
- Protected Attributes inherited from Lima::InitializableObject< Base, InitializationParameters >
std::string m_id
 

Detailed Description

This is a MediaProcessUnit which do semantic role labeling using the knowledge-based SRL in python made by Quentin Pradet during his PhD thesis.

As a ProcessUnit, it has an init and a process function. See ProcessUnit for details.

IOPES:

  • Input: an AnalysisContent and the following parameters in the configuration file:
    • debug: whether the debug option of the python module should be activated or not
    • path: the path to the knowledgesrl python package
    • mode: the semantic model to use to annotate. Either VerbNet (default) or FrameNet.
  • Output: an AnalysisContent
  • Preconditions: the AnalysisContent must the result of the syntactic analysis
  • Effects: the annotation graph will be updated with SRL annotations.

Definition at line 37 of file KnowledgeBasedSemanticRoleLabeler.h.

Constructor & Destructor Documentation

◆ KnowledgeBasedSemanticRoleLabeler()

Lima::LinguisticProcessing::SemanticAnalysis::KnowledgeBasedSemanticRoleLabeler::KnowledgeBasedSemanticRoleLabeler ( )

Definition at line 72 of file KnowledgeBasedSemanticRoleLabeler.cpp.

◆ ~KnowledgeBasedSemanticRoleLabeler()

Lima::LinguisticProcessing::SemanticAnalysis::KnowledgeBasedSemanticRoleLabeler::~KnowledgeBasedSemanticRoleLabeler ( )
virtual

Definition at line 76 of file KnowledgeBasedSemanticRoleLabeler.cpp.

Member Function Documentation

◆ init()

void Lima::LinguisticProcessing::SemanticAnalysis::KnowledgeBasedSemanticRoleLabeler::init ( Common::XMLConfigurationFiles::GroupConfigurationStructure &  unitConfiguration,
Manager *  manager 
)
overridevirtual

initialize with parameters from configuration file.

Parameters
unitConfiguration@IN : <group> tag in xml configuration file that contains parameters to initialize the object.
manager@IN : manager that asked for initialization and carries init params Use it to initialize other objects of same kind.
Exceptions
InvalidConfigurationwhen parameters are invalids.

Implements Lima::MediaProcessUnit.

Definition at line 96 of file KnowledgeBasedSemanticRoleLabeler.cpp.

◆ process()

LimaStatusCode Lima::LinguisticProcessing::SemanticAnalysis::KnowledgeBasedSemanticRoleLabeler::process ( AnalysisContent &  analysis) const
overridevirtual

Process on data in analysisContent.

This method should not return any exception

Parameters
analysisAnalysisContent object on which to process
Exceptions
UndefinedMethodif this method hasn't been specialized

Implements Lima::MediaProcessUnit.

Definition at line 307 of file KnowledgeBasedSemanticRoleLabeler.cpp.


The documentation for this class was generated from the following files: