Skip to content

edsnlp.conjugator

conjugate_verb [source]

Conjugates the verb using an instance of mlconjug3, and formats the results in a pandas DataFrame.

Parameters

PARAMETER DESCRIPTION
verb

Verb to conjugate.

TYPE: str

conjugator

mlconjug3 instance for conjugating.

TYPE: Conjugator

RETURNS DESCRIPTION
DataFrame

Normalized dataframe containing all conjugated forms for the verb.

conjugate [source]

Conjugate a list of verbs.

Parameters

PARAMETER DESCRIPTION
verbs

List of verbs to conjugate

TYPE: Union[str, List[str]]

language

Language to conjugate. Defaults to French (fr).

TYPE: str DEFAULT: 'fr'

RETURNS DESCRIPTION
DataFrame

Dataframe containing the conjugations for the provided verbs. Columns: verb, mode, tense, person, term

get_conjugated_verbs [source]

Get a list of conjugated verbs.

Parameters

PARAMETER DESCRIPTION
verbs

List of verbs to conjugate.

TYPE: Union[str, List[str]]

matches

List of dictionary describing the mode/tense/persons to keep.

TYPE: Union[List[Dict[str, str]], Dict[str, str]]

language

[description], by default "fr" (French)

TYPE: str DEFAULT: 'fr'

RETURNS DESCRIPTION
List[str]

List of terms to look for.

Examples

get_conjugated_verbs( "aimer", dict(mode="Indicatif", tense="Présent", person="1p"), ) ['aimons']