NLP / Generation

Description

I did my assignment but the last part which is generation text does not work with me I thing the problem is the space, it need to handle I need to generate text that has as least word make sense I wrote multiple function you can use them it is in second part, my model is saved , and my code is providing. I need generation for text that has meaning not like what I did I can generate like eeeeeeeeeee, or nnnnnn The problem was in my code the space I think make every thing repating the pattern. <----------------------------------------------->Text generation: For only the bigram and trigram language models trained on English, extend your programs so that you can generate sentences. That is, given any English letter(s) as input and based on the n-gram model you should continue the sentence with the most likely characters. More specifically, given a letter to begin a sentence with, you should choose as the next character that character that yields the highest n-gram count when composed with previous characters into a n-gram. Thus, you will use the previous character for bigrams and previous two characters for trigrams. Your program should continue generating new characters until you have generated a 100 character sentence or you have reached a dead end (all n-gram counts are zero).generated text outputs for the following inputs: bigrams starting with 10 letters of your choice, and trigrams using those 10 letters as the first character with a second meaningful character of your choice. This is for English bigram and trigram models, both unsmoothed and smoothedcritical analysis of your generation results: e.g., are there any difference between the sentences generated by bigrams and trigrams, or by the unsmoothed versus smoothed models? Give examples to back up your conclusions.

Don't use plagiarized sources. Get Your Custom Assignment on
NLP / Generation
From as Little as $13/Page