You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@uima.apache.org by sc...@apache.org on 2008/05/07 21:54:26 UTC

svn commit: r654237 - in /incubator/uima/site/trunk/uima-website: docs/doc-uima-annotator.html xdocs/doc-uima-annotator.xml

Author: schor
Date: Wed May  7 12:54:25 2008
New Revision: 654237

URL: http://svn.apache.org/viewvc?rev=654237&view=rev
Log:
no jira - minor edits

Modified:
    incubator/uima/site/trunk/uima-website/docs/doc-uima-annotator.html
    incubator/uima/site/trunk/uima-website/xdocs/doc-uima-annotator.xml

Modified: incubator/uima/site/trunk/uima-website/docs/doc-uima-annotator.html
URL: http://svn.apache.org/viewvc/incubator/uima/site/trunk/uima-website/docs/doc-uima-annotator.html?rev=654237&r1=654236&r2=654237&view=diff
==============================================================================
--- incubator/uima/site/trunk/uima-website/docs/doc-uima-annotator.html (original)
+++ incubator/uima/site/trunk/uima-website/docs/doc-uima-annotator.html Wed May  7 12:54:25 2008
@@ -377,7 +377,7 @@
 				  will use for the RoomNumberAnnotator. The annotator will detect room numbers, so we will create 
 				  an annotation type called <code>org.apache.uima.tutorial.RoomNumber</code> that is inherited from
 				  <code>uima.tcas.Annotation</code>. Additionally we want to store some meta information 
-				  about the room we detected, therefore we will add a feature to the annotation 
+				  about the room we detected; therefore we will add a feature to the annotation 
 				  called <code>building</code> that will contain some additional building information about the 
 				  detected room.
 				</p>
@@ -388,7 +388,7 @@
           namespaces work like Java namespaces.
         </p>
                                                 <p>
-				  Let's go ahead and create the discussed type system in the recently created analysis engine 
+				  Let's go ahead and create this type system in the recently created analysis engine 
 				  descriptor. To add a new type to the descriptor:
 				  <ol>
 				    <li>
@@ -409,16 +409,22 @@
 				    </li>
 				  </ol>
 				  We just added the first type to our RoomNumberAnnotator type system. Now we want to add an additional 
-				  feature to the created type to store the annotation meta information 
+				  feature to the created type to store the annotation meta information. 
 				  <ol>
 				    <li>
 				      <p>Select the "org.apache.uima.tutorial.RoomNumber" type by clicking it.</p>
 				    </li>
 				    <li>
 				      <p>Click the "Add..." button to add a feature to the type and specify "building" 
-				         as feature name and "uima.cas.String" as range type.
-				         This means that the "building" feature is a String based feature. 
-				         Finish the dialog by clicking "OK".</p>
+				         as feature name and "uima.cas.String" as range type.  
+				         This means that the "building" feature is a String based feature.</p> 
+				         
+              <p>You can use Eclipse
+                 "auto-complete" function for the super-type.  For example, you may type an
+                 "s" (the first letter of "String", even in lower case), and then press
+                 the "CTRL-SPACE" key combination and see a list of suitable candidates - at
+                 which point you can pick one with the mouse.</p>
+              <p>Finish the dialog by clicking "OK".</p>
 				    </li>
 				    <li>
 				      <p>Save the descriptor file</p>
@@ -428,8 +434,12 @@
 				    </li>
 				  </ol>
 				  That's all - we defined the UIMA type system for the RoomNumberAnnotator that we use later when we 
-				  implement the annotator code. To use defined types easily the UIMA Component Descriptor Editor  
-				  can generate Java classes for the defined types. To generate these classes follow the steps below:
+				  implement the annotator code.</p>
+                                                <p>By default, the UIMA Component Descriptor Editor generates
+          the corresponding JCas classes for each type you define.  Defaults may be changed by clicking on the
+            UIMA menu item, or using Eclipse's Windows -&gt; Preferences -&gt; UIMA menu.</p>
+                                                <p>  You can also choose to manually
+          generate the JCas classes by following the steps below:
 				  <ol>
 				    <li>
 				      <p>Open the descriptor file in the Component Descriptor Editor and select the "Type System" tab.</p>
@@ -443,7 +453,7 @@
 				      
 				    </li>
 				  </ol> 
-				  Now all pre-work is done and can start implementing the annotator source code.
+				  Now all pre-work is done and you can start implementing the annotator source code.
 				</p>
                             </blockquote>
       </td></tr>
@@ -475,7 +485,7 @@
 						</li>
 						<li>
 							<p>
-								A wizard is upcoming where you can specify the Java class information shown below. 
+								A wizard dialog appears where you can specify the Java class information shown below. 
 								We will create a Java class called <code>RoomNumberAnnotator</code> that inherits 
 								from the base class called	<code>org.apache.uima.analysis_component.JCasAnnotator_ImplBase</code>. 
 								This is the base for all UIMA annotator implementations.
@@ -528,9 +538,8 @@
   public void process(JCas aJCas) {
     
     // The JCas object is the data object inside UIMA where all the 
-    // information is stored. It contains based on the defined 
-    // types system all annotations created by previous annotators
-    // and also the document text that should be analyzed.
+    // information is stored. It contains all annotations created by 
+    // previous annotators, and the document text to be analyzed.
     
     // get document text from JCas
     String docText = aJCas.getDocumentText();
@@ -568,7 +577,9 @@
                                                 <p>
 				In the current implementation we don't use the method <code>initialize()</code>. Typically
 				the <code>initialize()</code> method is used to get annotator configuration parameters that can be
-				configured by the user. In our case this could be for example the used regular expressions used 
+				configured by the user, and to do one-time initialization, such as loading data tables that
+          the implementation might need. In our case, we could have a parameter that 
+          specifies the regular expressions used 
 				to detect the room numbers.	For more details about configuration parameters, please refer to the
 				UIMA documentation at chapter  
 				<a href="http://incubator.apache.org/uima/downloads/releaseDocs/2.2.2-incubating/docs/html/tutorials_and_users_guides/tutorials_and_users_guides.html#ugr.tug.aae.configuration_parameters">
@@ -625,13 +636,15 @@
 							</p> 
 						</li>
 						<li>
-							<p>Apply the classpath settings using the "Apply" button and run the CVD by selecting "Run".</p>
+							<p>Run the CVD by selecting "Run".</p>
 						</li>
 					</ol>
 				</p>
                                                 <p>
-				  Note: The classpath settings must only we configured once, after that you can start the CVD directly from 
-				  the Eclipse "Run dialog".
+				  Note: The classpath settings must only we configured once; after that, Eclipse will remember them 
+          in this "launch configuration" and
+           you can start the CVD directly from 
+				  the Eclipse "Run dialog" using this saved "launch configuration".
 				</p>
                                                 <p>
 					To test the RoomNumberAnnotator in the CVD we have to load the created RoomNumberAnnotator 
@@ -672,9 +685,9 @@
 					    </p>
 					    <p>
 					      To view the analysis result produced by the annotator, click "Annotation Index" on the left and
-					      choose on of the "org.apache.uima.tutorial.RoomNumber" annotations shown below. When 
+					      choose one of the "org.apache.uima.tutorial.RoomNumber" annotations shown below. When 
 					      selecting one of the annotations you get the text highlighted on the right that is covered by
-					      this annotation. If there are no annotations available - the annotator does not work correctly.
+					      this annotation. If there are no annotations available - the annotator is not working correctly.
 					      Check the log file for possible errors "Tools -&gt; View Log File". 
 					    </p>
 					  </li>
@@ -757,8 +770,8 @@
 				  	</li>
 				  	<li>
 				  	  <p> 
-				  	    Starting the PEAR package generation process by pressing the "Finish" button.
-				  	    Once the packaging is done, an message dialog comes up with a success message. 
+				  	    Run the PEAR package generation process by pressing the "Finish" button.
+				  	    Once the packaging is done, a message dialog comes up with a success message. 
 				  	    The created PEAR package is available at the specified location.
 				  	  </p>
 				  	</li>
@@ -767,8 +780,8 @@
                                                 <p>
 				  At this point we are done with the annotator development. We created an annotator PEAR package
 				  that allows us to use the annotator component easily in different applications. 
-				  How we handle and use PEAR packages and how we install it to other applications is not part 
-				  of this guide, please refer to the UIMA documentation at the 
+				  How we handle and use PEAR packages and how we install it in other applications is not part 
+				  of this guide; please refer to the UIMA documentation at the 
 				  <a href="http://incubator.apache.org/uima/downloads/releaseDocs/2.2.2-incubating/docs/html/tools/tools.html#ugr.tools.pear.installer">
 				  PEAR Installer User's Guide</a> for additional information about this topic. 
 				</p>

Modified: incubator/uima/site/trunk/uima-website/xdocs/doc-uima-annotator.xml
URL: http://svn.apache.org/viewvc/incubator/uima/site/trunk/uima-website/xdocs/doc-uima-annotator.xml?rev=654237&r1=654236&r2=654237&view=diff
==============================================================================
--- incubator/uima/site/trunk/uima-website/xdocs/doc-uima-annotator.xml (original)
+++ incubator/uima/site/trunk/uima-website/xdocs/doc-uima-annotator.xml Wed May  7 12:54:25 2008
@@ -198,14 +198,13 @@
 				  in the UIMA documentation in the chapter
 				   <a href="http://incubator.apache.org/uima/downloads/releaseDocs/2.2.2-incubating/docs/html/tutorials_and_users_guides/tutorials_and_users_guides.html#ugr.tug.aae.defining_types">
 				   Defining Types</a>.
-				</p>
-        <!--     schor edits to here  6:50 PM 4/24 -->
+				</p>
 				<p>
 				  After this brief UIMA type system instruction, let's start and model the type system that we
 				  will use for the RoomNumberAnnotator. The annotator will detect room numbers, so we will create 
 				  an annotation type called <code>org.apache.uima.tutorial.RoomNumber</code> that is inherited from
 				  <code>uima.tcas.Annotation</code>. Additionally we want to store some meta information 
-				  about the room we detected, therefore we will add a feature to the annotation 
+				  about the room we detected; therefore we will add a feature to the annotation 
 				  called <code>building</code> that will contain some additional building information about the 
 				  detected room.
 				</p>
@@ -216,7 +215,7 @@
           namespaces work like Java namespaces.
         </p>
 				<p>
-				  Let's go ahead and create the discussed type system in the recently created analysis engine 
+				  Let's go ahead and create this type system in the recently created analysis engine 
 				  descriptor. To add a new type to the descriptor:
 				  <ol>
 				    <li>
@@ -237,16 +236,22 @@
 				    </li>
 				  </ol>
 				  We just added the first type to our RoomNumberAnnotator type system. Now we want to add an additional 
-				  feature to the created type to store the annotation meta information 
+				  feature to the created type to store the annotation meta information. 
 				  <ol>
 				    <li>
 				      <p>Select the "org.apache.uima.tutorial.RoomNumber" type by clicking it.</p>
 				    </li>
 				    <li>
 				      <p>Click the "Add..." button to add a feature to the type and specify "building" 
-				         as feature name and "uima.cas.String" as range type.
-				         This means that the "building" feature is a String based feature. 
-				         Finish the dialog by clicking "OK".</p>
+				         as feature name and "uima.cas.String" as range type.  
+				         This means that the "building" feature is a String based feature.</p> 
+				         
+              <p>You can use Eclipse
+                 "auto-complete" function for the super-type.  For example, you may type an
+                 "s" (the first letter of "String", even in lower case), and then press
+                 the "CTRL-SPACE" key combination and see a list of suitable candidates - at
+                 which point you can pick one with the mouse.</p>
+              <p>Finish the dialog by clicking "OK".</p>
 				    </li>
 				    <li>
 				      <p>Save the descriptor file</p>
@@ -256,8 +261,13 @@
 				    </li>
 				  </ol>
 				  That's all - we defined the UIMA type system for the RoomNumberAnnotator that we use later when we 
-				  implement the annotator code. To use defined types easily the UIMA Component Descriptor Editor  
-				  can generate Java classes for the defined types. To generate these classes follow the steps below:
+				  implement the annotator code.</p>
+        
+          <p>By default, the UIMA Component Descriptor Editor generates
+          the corresponding JCas classes for each type you define.  Defaults may be changed by clicking on the
+            UIMA menu item, or using Eclipse's Windows -> Preferences -> UIMA menu.</p> 
+          <p>  You can also choose to manually
+          generate the JCas classes by following the steps below:
 				  <ol>
 				    <li>
 				      <p>Open the descriptor file in the Component Descriptor Editor and select the "Type System" tab.</p>
@@ -271,7 +281,7 @@
 				      
 				    </li>
 				  </ol> 
-				  Now all pre-work is done and can start implementing the annotator source code.
+				  Now all pre-work is done and you can start implementing the annotator source code.
 				</p>
 			</subsection>
 			<subsection name="Writing the annotator code">
@@ -291,7 +301,7 @@
 						</li>
 						<li>
 							<p>
-								A wizard is upcoming where you can specify the Java class information shown below. 
+								A wizard dialog appears where you can specify the Java class information shown below. 
 								We will create a Java class called <code>RoomNumberAnnotator</code> that inherits 
 								from the base class called	<code>org.apache.uima.analysis_component.JCasAnnotator_ImplBase</code>. 
 								This is the base for all UIMA annotator implementations.
@@ -344,9 +354,8 @@
   public void process(JCas aJCas) {
     
     // The JCas object is the data object inside UIMA where all the 
-    // information is stored. It contains based on the defined 
-    // types system all annotations created by previous annotators
-    // and also the document text that should be analyzed.
+    // information is stored. It contains all annotations created by 
+    // previous annotators, and the document text to be analyzed.
     
     // get document text from JCas
     String docText = aJCas.getDocumentText();
@@ -384,7 +393,9 @@
 				<p>
 				In the current implementation we don't use the method <code>initialize()</code>. Typically
 				the <code>initialize()</code> method is used to get annotator configuration parameters that can be
-				configured by the user. In our case this could be for example the used regular expressions used 
+				configured by the user, and to do one-time initialization, such as loading data tables that
+          the implementation might need. In our case, we could have a parameter that 
+          specifies the regular expressions used 
 				to detect the room numbers.	For more details about configuration parameters, please refer to the
 				UIMA documentation at chapter  
 				<a href="http://incubator.apache.org/uima/downloads/releaseDocs/2.2.2-incubating/docs/html/tutorials_and_users_guides/tutorials_and_users_guides.html#ugr.tug.aae.configuration_parameters">
@@ -429,13 +440,15 @@
 							</p> 
 						</li>
 						<li>
-							<p>Apply the classpath settings using the "Apply" button and run the CVD by selecting "Run".</p>
+							<p>Run the CVD by selecting "Run".</p>
 						</li>
 					</ol>
 				</p>
 				<p>
-				  Note: The classpath settings must only we configured once, after that you can start the CVD directly from 
-				  the Eclipse "Run dialog".
+				  Note: The classpath settings must only we configured once; after that, Eclipse will remember them 
+          in this "launch configuration" and
+           you can start the CVD directly from 
+				  the Eclipse "Run dialog" using this saved "launch configuration".
 				</p>
 				<p>
 					To test the RoomNumberAnnotator in the CVD we have to load the created RoomNumberAnnotator 
@@ -476,9 +489,9 @@
 					    </p>
 					    <p>
 					      To view the analysis result produced by the annotator, click "Annotation Index" on the left and
-					      choose on of the "org.apache.uima.tutorial.RoomNumber" annotations shown below. When 
+					      choose one of the "org.apache.uima.tutorial.RoomNumber" annotations shown below. When 
 					      selecting one of the annotations you get the text highlighted on the right that is covered by
-					      this annotation. If there are no annotations available - the annotator does not work correctly.
+					      this annotation. If there are no annotations available - the annotator is not working correctly.
 					      Check the log file for possible errors "Tools -> View Log File". 
 					    </p>
 					  </li>
@@ -549,8 +562,8 @@
 				  	</li>
 				  	<li>
 				  	  <p> 
-				  	    Starting the PEAR package generation process by pressing the "Finish" button.
-				  	    Once the packaging is done, an message dialog comes up with a success message. 
+				  	    Run the PEAR package generation process by pressing the "Finish" button.
+				  	    Once the packaging is done, a message dialog comes up with a success message. 
 				  	    The created PEAR package is available at the specified location.
 				  	  </p>
 				  	</li>
@@ -559,8 +572,8 @@
 				<p>
 				  At this point we are done with the annotator development. We created an annotator PEAR package
 				  that allows us to use the annotator component easily in different applications. 
-				  How we handle and use PEAR packages and how we install it to other applications is not part 
-				  of this guide, please refer to the UIMA documentation at the 
+				  How we handle and use PEAR packages and how we install it in other applications is not part 
+				  of this guide; please refer to the UIMA documentation at the 
 				  <a href="http://incubator.apache.org/uima/downloads/releaseDocs/2.2.2-incubating/docs/html/tools/tools.html#ugr.tools.pear.installer">
 				  PEAR Installer User's Guide</a> for additional information about this topic. 
 				</p>