In this task, the model gets the string with text with the error and the exact span of the error and should return the comment in natural language, which explains the nature of the error.
How to use
!pip install feedback_generation_nigula
from feedback_generation_nigula.generator import FeedbackGenerator
fg = FeedbackGenerator(cuda_index = 0)
text_with_error = "The smoke flow my face ."
error_span = (10,17)
fg.get_feedback([text_with_error ], [error_span ])
# expected output ["When the <verb> <<flow>> is used as an <intransitive verb> to express'' to move in a stream'', a <preposition> needs to be placed to indicate the direction"]
Model training details
Data
The data was provided in the following way
input sentence [\t] offset range [\t] feedback comment
Here are some examples
The smoke flow my face . 10:17 When the <verb> <<flow>> is used as an <intransitive verb> to express ''to move in a stream'', a <preposition> needs to be placed to indicate the direction. 'To' and 'towards' are <prepositions> that indicate direction.
I want to stop smoking during driving bicycle . 23:29 A <gerund> does not normally follow the <preposition> <<during>>. Think of an expression using the <conjunction> 'while' instead of a <preposition>.
Grammar termins are highlighted with '< ... >' marks and word examples - with '<< ... >>'
Data preprocessing
We lowercased the text, split it from any punctuation, including task specific marks (<< >>) and explicitly pointed out the error in the original text using << >>.
the smoke < < flow > > < < my > > face . 10:17 When the < verb > < < flow > > is used as an < intransitive verb > to express '' to move in a stream '', a < preposition > needs to be placed to indicate the direction. ' to ' and ' towards ' are < prepositions > that indicate direction .
i want to stop smoking < < during > > driving bicycle . 23:29 a < gerund > does not normally follow the < preposition > < < during > > . think of an expression using the < conjunction > ' while ' instead of a < preposition > .
Data augmentation
The main feature of our training pipeline was data augmentation. The idea of the augmentation is as follows: we cut the existing text with error after the last word which was syntactically connected to the words inside the error span (syntactic dependencies were automatically parsed with spacy) and this cut version of the text with error was used as a prompt for language model (we used
GPT-Neo 1.3B
).
Using both initial and augmented data we fine-tuned
t5-large
.
Runs of s-nlp GenChal_2022_nigula on huggingface.co
14
Total runs
0
24-hour runs
-1
3-day runs
-3
7-day runs
3
30-day runs
More Information About GenChal_2022_nigula huggingface.co Model
GenChal_2022_nigula huggingface.co
GenChal_2022_nigula huggingface.co is an AI model on huggingface.co that provides GenChal_2022_nigula's model effect (), which can be used instantly with this s-nlp GenChal_2022_nigula model. huggingface.co supports a free trial of the GenChal_2022_nigula model, and also provides paid use of the GenChal_2022_nigula. Support call GenChal_2022_nigula model through api, including Node.js, Python, http.
GenChal_2022_nigula huggingface.co is an online trial and call api platform, which integrates GenChal_2022_nigula's modeling effects, including api services, and provides a free online trial of GenChal_2022_nigula, you can try GenChal_2022_nigula online for free by clicking the link below.
s-nlp GenChal_2022_nigula online free url in huggingface.co:
GenChal_2022_nigula is an open source model from GitHub that offers a free installation service, and any user can find GenChal_2022_nigula on GitHub to install. At the same time, huggingface.co provides the effect of GenChal_2022_nigula install, users can directly use GenChal_2022_nigula installed effect in huggingface.co for debugging and trial. It also supports api for free installation.
GenChal_2022_nigula install url in huggingface.co: