coding

Same text as previous page, but modify for coding first pass

sequence the following sentences:

Use "is" verb

man     is
woman   is
out     is
man     walk
woman   read

//
// "is" has nouns, verbs, adj and adv preceding it, "out" is noise - not a noun

//
// "is" object is:

           is{
        man =r_br   
      woman
        out
             }

//
// form G1 from branches in is

G1 {             
 br= is_p  man                       "is_p" = a programmatic object
           woman       
           out      
   }

//
// insert G1 lemma in all objects contained in G1

  man{                 woman{          out{   
  br = is_p G1           br = is_p G1      br = is_p G1
       walk                   read              is 
       is                     is               }
      }                      }

//
// now re-read the sentences

man    is
woman  is
out    is
man    walk
woman  read

//
// substitution yields: Substitute() uses is_p object

G1  is
G1  is
G1  is
G1  walk
G1  read

//
// "is" object becomes:

           is{
         G1 =r_br 
        man  
      woman
        out
             }

//
// G1 object becomes

G1 {               
br = is_p  man     
           woman   
           out
     is
     walk            
     read
   }

//
// Make G2 from branches in G1

G2 {             
 br= is_P  is
           walk 
           read     
    }

//
// link objects in G2 back to G2

         is{                walk{                  read{       
        br = is_p G2         br = is_p G2       br = is_p G2

        G1 = r_br            G1 = r_br              G1 = r_br
       man                  man                    man
     woman                      }                      }
       out
       }

//
// read sentences again

man     is
woman   is
out     is
man     walk
woman   read

//
// rereading "man is" does not add any new branches to any objects in obj_pool

//
// substitute, these sentences will add new branches

man     G2
woman   G2
out     G2
man     G2
woman   G2
G1      G2  x5       1st and 2nd word substituted

//

  man{                 woman{          out{   
  br = is_p G1           br = is_p G1      br = is_p G1

       G2                     G2                g2
       walk                   read              is 
       is                     is               }
      }                      }

//
// G2 and G1 become

G2 {             
 br= is_p  is  
           walk 
           read

   G1 = r_br 
  man
woman
  out
   }



G1 {               
br = is_p  man     
           woman   
           out

     G2
     is
     walk            
     read
   }

//
// remove duplicate branches

G2 {             
 br= is_p  is  
           walk 
           read

   G1 = r_br 
   }



G1 {               
br = is_p  man     
           woman   
           out

     G2
   }


  man{                 woman{          out{   
  br = is_p G1           br = is_p G1      br = is_p G1

       G2                     G2                g2
      }                      }                 }

//
// add sentence

   boy is
   boy G2


G2 {             
 br= is_p  is  
           walk 
           read

   G1 = r_br 
  boy
   }



G3 {               
br = is_p  G1
           boy

      G2
   }


   boy{          
   br = is_p G3

        G2 
       }

//
// process converged, add new sentence

boy  walk

boy  G2
G3   walk
G3   G2


   boy{          
   br = is_p G3

        G2 
        walk              
       }


G3 {               
br = is_p  G1
           boy

      G2
      walk
   }

Related

Wiki: noun-verb

MongoDB Logo MongoDB