src.dackar.workflows.OperatorShiftLogsProcessing¶
Created on April, 2024
@author: wangc, mandd
Attributes¶
Classes¶
Class to process OPG Operator Shift Logs dataset |
Module Contents¶
- class src.dackar.workflows.OperatorShiftLogsProcessing.OperatorShiftLogs(nlp, entID='SSC', causalKeywordID='causal', *args, **kwargs)[source]¶
Bases:
src.dackar.workflows.WorkflowBase.WorkflowBase
Class to process OPG Operator Shift Logs dataset
- _extractedInfoNames = ['Entity', 'Status', 'Amod', 'Action', 'Dep', 'Alias', 'Negation', 'Conjecture', 'Sentence'][source]¶
- textProcess()[source]¶
Function to clean text
- Parameters:
None
- Returns:
procObj, DACKAR.Preprocessing object
- extractStatus(matchedSents, predSynonyms=[], exclPrepos=[])[source]¶
Extract health status and relation
- Parameters:
matchedSents – list, the matched sentences
predSynonyms – list, predicate synonyms
exclPrepos – list, exclude the prepositions
- extractRelDep(matchedSents)[source]¶
- Parameters:
matchedSents – list, the list of matched sentences
- Returns:
generator, the extracted causal relation
- Return type:
(subject tuple, predicate, object tuple)