W dniu 2013-10-05 12:00, Kumara Bhikkhu pisze:
Daniel Naber wrote thus at 04:31 PM 05-10-13:
On 2013-10-05 09:21, Kumara Bhikkhu wrote:
> How do I indicate "zero or more token"?
> This doesn't work: <token min="0"/>
There's still a bug in our code, only "zero or one" currently works.
Your example should match zero or one token (max="1" is the default). If
it doesn't, please post a complete example.
OK. Promise you won't laugh. :-)
This rule wouldn't make much sense anyway. You will inevitably match
patterns between verb phrases if you don't have any conditions on the
token before "to".
I don't have a good head for details. That's why I need a good grammar
checker.
I'm trying to improve upon the "to infinitive" rule with this:
I already made some improvements. What kind of errors do you think we're
still missing?
Best,
Marcin
<rule id="TO_NON_BASE" name="'to' + non-base form">
<pattern>
<token min="1" postag_regexp="yes" postag="VBD|VBG|VBN|VBP|VBZ"/>
<token min="0"/>
<token>to</token>
<marker>
<token postag="VBD|VBG|VBN|VBZ"></token>
</marker>
</pattern>
<message>You might need to use the base form of the verb here:
<suggestion><match no="4" postag="VB"></match></suggestion>.</message>
<short>To + infinitive</short>
<example type="correct">I was surprised to <marker>learn</marker>
this.</example>
<example type="correct">He spoke to chosen people.</example>
<example correction="learn" type="incorrect">I was surprised to
<marker>learns</marker> this.</example>
</rule>
------------------------------------------------------------------------------
October Webinars: Code for Performance
Free Intel webinars can help you accelerate application performance.
Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from
the latest Intel processors and coprocessors. See abstracts and register >
http://pubads.g.doubleclick.net/gampad/clk?id=60134791&iu=/4140/ostg.clktrk
_______________________________________________
Languagetool-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/languagetool-devel