(verb: Token)
return subjs
Return all subjects of a verb according to the dependency parse.
Return all subjects of a verb according to the dependency parse.
Return all subjects of a verb according to the dependency parse .
def get_subjects_of_verb(verb: Token) -> List[Token]:
    """Return all subjects of a verb according to the dependency parse."""
    subjs = [tok for tok in verb.lefts if tok.dep_ in constants.SUBJ_DEPS]
    # get additional conjunct subjects
    subjs.extend(tok for subj in subjs for tok in _get_conjuncts(subj))
    return subjs
def get_subjects_of_verb ( verb : Token ) -> List [ Token ] : subjs = [ tok for tok in verb . lefts if tok . dep_ in constants . SUBJ_DEPS ] # get additional conjunct subjects subjs . extend ( tok for subj in subjs for tok in _get_conjuncts ( subj ) ) return subjs