-
Notifications
You must be signed in to change notification settings - Fork 197
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
French Verbs Transformation #250
base: main
Are you sure you want to change the base?
French Verbs Transformation #250
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this is an interesting transformation for French. It is at an early stage but it is promising.
|
||
This transformation change some words with synonyms according to if their POS tag is a VERB for simple french sentences. It requires Spacy_lefff (an extention of spacy for french POS and lemmatizing) and nltk package with the open multilingual wordnet dictionary. | ||
|
||
Authors : Lisa Barthe and Louanes Hamla from Fablab by Inetum in Paris |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please, add email. Maybe, you can use this style:
- Author name:
- Author email:
- Author Affiliation:
TaskType.TEXT_TAGGING, | ||
] | ||
languages = ["fr"] | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add the some keywords too.
languages = ["fr"] | ||
|
||
def __init__(self, seed=0, max_outputs=1): | ||
super().__init__(seed, max_outputs=max_outputs) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You don't use the param max_outputs. It means that you are generating all possible candidates?
return POSTagger() | ||
|
||
|
||
nlp = spacy.load('fr_core_news_md') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You might want to use spacy like this.
from spacy.language import Language | ||
from nltk.corpus import wordnet | ||
import nltk | ||
nltk.download('omw') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe you might add the nltk in a similar way to spacy in initialize.py
"sentence": "J'ai enfin pu faire remorquer la voiture !" | ||
}, | ||
"outputs": [{ | ||
"sentence": "J'ai enfin pu faire rouler la voiture !" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am not sure if you only change one verb per instance, i.e., you only generate one additional sentence per instance?
Hi, thanks for the submission! Two questions: (i) does the substitution only affect infinitive verbs? And if so, is there a way to overcome this limitation? (ii) do we have an idea of the coverage of the lexicon? Another comment: is this transformation covered by https://github.com/GEM-benchmark/NL-Augmenter/pull/234/files? (although the latter is for English) Should there be just one transformation for Verbs, Nouns #247 and Adjectives #249, since the method seems to be the same? The transformation could be called "Lexical susbstitutions for French". |
@Louanes1 ping |
Hi, |
Hi @Louanes1 : You've already merged the 3 PRs into one right? If so, we can close this PR. Let me know. |
No description provided.