Question

I'm looking for something that may or may not exist. Is there such a thing as an 'English grammar rules engine' available on the Windows platform (specifically for something like .NET or C#)?

Specifically, I'm looking for something that would be able to take a sentence in the 'future tense' and change it to the 'past tense' (based on English grammar rules) ... like:

Work on widget software and then meet with Ricardo

to this:

Worked on widget software and then met with Ricardo

Is there a rules engine that does that already?

Was it helpful?

Solution

Talk to this guy, he might have some ideas for you. In general, English is too ambiguous for this type of thing. For example:

Cut paper in half.

Is this an imperative command, or a past-tense sentence fragment? And my personal favourite:

Time flies like an arrow; fruit flies like a banana.

Any human can parse that, but only because of a great deal of semantic knowledge.

That being said, there are some things that might be worth looking into, like SharpNLP

OTHER TIPS

As others have stated, this is a very hard problem and has not been solved in the general case. However, there are some systems that do pretty well. Princeton's WordNet is one of them. It can identify parts of speech, synonyms, etc (perhaps including tense) with some degree of accuracy. I think you may be interested in these functions, which appear to find the root of a word given a particular conjugation and may also be able to find a particular conjugation given the root (but that page doesn't provide examples, so I can't be sure I'm interpreting the docs correctly).

The short answer is no, general NLP parsing engines don't exist.

The long answer is "kinda", but there's 50 years of research showing that it's a Very Hard Problem, in the general case. There might be one doing specific tense transformations. Regardless, C# probably won't have one.

Check this out, it's called Grammatica. It may not be precisely what you're after but it's definitely a good start to parsing English grammar rules in C#.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top