Right,
There are several ways to do this. The complication comes from the
fact that there is quite a lot of code, JAPEs and PRs in the default
IE app you use - so lots of things to take into account.
On the contains issue: yes - but not in the code you have - we do not
have a public release with GATE 5.0 - which is where contains/within
appears in the JAPE syntax.
However there are ways to do it and they are related to consuming the
Team annotation coming from original markups before any actual
analysis inside. But again - we should see in the JAPE order where is
the right place (if one) to do this, and currently i cannot do that
(probably someone back in the office would help?)
So first suggestion: consumption
- find the right grammar where you want to avoid consumption of the
string in the team tag
- include Team in the Input and make sure it is being transferred to
the Input AS.
- before the rules you want to override do the following
Rule: TeamSpur
({Team}):spur
--> {}
Another alternative is probably better if you know you will deal with
documents which contain inline metadata but also distinguishable spots
of text:
We could help you define Text annotations and ignore everything
outside them (e.g. being moved to another AS; no tokens for it; and so
forth)
So you have to think a bit how Team-specific is the issue - and if you
want to handle it more generally
b
On Jul 28, 2009, at 7:05 PM, <[email protected]> wrote:
Continuing from my earlier query where I was trying to retain the
original markups of a document, it is possible to change the way
jape behaves depending whether or not some text is contained within
a piece of original markup? For example, suppose I have the text:
<team>Andrew Smith - ICT expert</team>
If I apply the standard set of jape rules here, the string 'Smith -
ICT' is extracted as an 'Upper' entity by the UPPER rule in
first.jape - which is not what I want as it leads to the person
'Andrew Smith - ICT' being extracted. I want to say, if contained in
team, don't look for hyphens but extract 'Smith' and 'ICT' as
separate words. I notice that jape now has a 'contains' facility
which might help. Is this supported in KIM?
Similarly I also want to say: If in team, don't run rule A but run
rule b instead. Is this sort of thing possible?
Thanks,
Alistair
Alistair Duke
Next Generation Web Research
Centre for Information & Security Systems Research
BT Innovate & Design
___________________________
Office: +44(0) 1473 608192
Mobile: +44(0) 7730 426257
Fax : +44(0) 1473 606755
Email: [email protected]
This email contains BT information, which may be privileged or
confidential.
It's meant only for the individual(s) or entity named above. If
you're not the intended
recipient, note that disclosing, copying, distributing or using this
information
is prohibited. If you've received this email in error, please let me
know immediately
on the email address above. Thank you.
We monitor our email system, and may record your emails.
British Telecommunications plc
Registered office: 81 Newgate Street London EC1A 7AJ
Registered in England no: 1800000
_______________________________________________
Kim-discussion mailing list
[email protected]
http://ontotext.com/mailman/listinfo/kim-discussion
_______________________________________________
Kim-discussion mailing list
[email protected]
http://ontotext.com/mailman/listinfo/kim-discussion