# Make a directory, cd, get    g2p4j

mkdir newdirectory
cd newdirectory
wget http://g2p4j.sourceforge.net/g2p4j
wget http://g2p4j.sourceforge.net/cv-fest-lookup
wget http://g2p4j.sourceforge.net/cv-lower
wget http://g2p4j.sourceforge.net/cv-make-paren
wget http://g2p4j.sourceforge.net/cv-tab-0
wget http://g2p4j.sourcefor4e.net/cv-upper
chmod 777 *

# Download or create your own input word list or dictionary called     in.p4j

wget http://g2p4j.sourceforge.net/in.p4j
g2p4j 

# $ g2p4j     see the intital screen

 GRAPHEME 2 PHONEME FORGE             Copyright (C) D. M. Tan Creti 2009
 Input:in.p4j               h=help                      Output:patch.p4j

 space=next    -=back       speak ;=edit  0=festival  1-9=file  q  exits
 ui=vowel      o=p o speech p=insert blank      TAB ;*0-9 save patch.p4j
 jk=column     l=stress     ;=speak  edit line  BACKSPACE vim  patch.p4j
 m,=consonent  .=dialect    /=change edit line  ENTER     reprint screen
 0      HIT_THE_SPACE_BAR_TO_START
    v00V
 ;
 0
 1
 2
 3
 4
 5
 6
 7
 8
 9

# hit space bar repeatedly to get to a word to edit

 GRAPHEME 2 PHONEME FORGE             Copyright (C) D. M. Tan Creti 2009
 Input:in.p4j               h=help                      Output:patch.p4j

 space=next    -=back       speak ;=edit  0=festival  1-9=file  q  exits
 ui=vowel      o=p o speech p=insert blank      TAB ;*0-9 save patch.p4j
 jk=column     l=stress     ;=speak  edit line  BACKSPACE vim  patch.p4j
 m,=consonent  .=dialect    /=change edit line  ENTER     reprint screen
 5      abacterial
    v00V
 ;       ae   b  + ae   k  + t    ih   r  + iy % ax   l  %
 0       ae   b  + ae   k  + t    ih   r  + iy % ax   l  %
 1  0    ah   b    ae   k    t    ih   r    iy   ah   l
 2
 3
 4
 5
 6
 7
 8
 9

# hit the j key to select column 01 for editing

 GRAPHEME 2 PHONEME FORGE             Copyright (C) D. M. Tan Creti 2009
 Input:in.p4j               h=help                      Output:patch.p4j

 space=next    -=back       speak ;=edit  0=festival  1-9=file  q  exits
 ui=vowel      o=p o speech p=insert blank      TAB ;*0-9 save patch.p4j
 jk=column     l=stress     ;=speak  edit line  BACKSPACE vim  patch.p4j
 m,=consonent  .=dialect    /=change edit line  ENTER     reprint screen
 5      abacterial
         v01V
 ;       ae   b  + ae   k  + t    ih   r  + iy % ax   l  %
 0       ae   b  + ae   k  + t    ih   r  + iy % ax   l  %
 1  0    ah   b    ae   k    t    ih   r    iy   ah   l
 2
 3
 4
 5
 6
 7
 8
 9

# hit the u and i keys repeatedly to select an new vowel

 GRAPHEME 2 PHONEME FORGE             Copyright (C) D. M. Tan Creti 2009
 Input:in.p4j               h=help                      Output:patch.p4j

 space=next    -=back       speak ;=edit  0=festival  1-9=file  q  exits
 ui=vowel      o=p o speech p=insert blank      TAB ;*0-9 save patch.p4j
 jk=column     l=stress     ;=speak  edit line  BACKSPACE vim  patch.p4j
 m,=consonent  .=dialect    /=change edit line  ENTER     reprint screen
 5      abacterial
         v01V
 ;       ey   b  + ae   k  + t    ih   r  + iy % ax   l  %
 0       ae   b  + ae   k  + t    ih   r  + iy % ax   l  %
 1  0    ah   b    ae   k    t    ih   r    iy   ah   l
 2
 3
 4
 5
 6
 7
 8
 9

# hit ; key to hear the new phonemes spoken

 GRAPHEME 2 PHONEME FORGE             Copyright (C) D. M. Tan Creti 2009
 Input:in.p4j               h=help                      Output:patch.p4j

 space=next    -=back       speak ;=edit  0=festival  1-9=file  q  exits
 ui=vowel      o=p o speech p=insert blank      TAB ;*0-9 save patch.p4j
 jk=column     l=stress     ;=speak  edit line  BACKSPACE vim  patch.p4j
 m,=consonent  .=dialect    /=change edit line  ENTER     reprint screen
 5      abacterial
         v01V
 ;       ey   b  + ae   k  + t    ih   r  + iy % ax   l  %
 0       ae   b  + ae   k  + t    ih   r  + iy % ax   l  %
 1  0    ah   b    ae   k    t    ih   r    iy   ah   l
 2
 3
 4
 5
 6
 7
 8
 9

(SayPhones ( quote ( ey   b    ae   k    t    ih   r    iy   ax   l
                           )))
#
festival>

# hit TAB and ; to save your new entry to the patch file

 GRAPHEME 2 PHONEME FORGE             Copyright (C) D. M. Tan Creti 2009
 Input:in.p4j               h=help                      Output:patch.p4j

 space=next    -=back       speak ;=edit  0=festival  1-9=file  q  exits
 ui=vowel      o=p o speech p=insert blank      TAB ;*0-9 save patch.p4j
 jk=column     l=stress     ;=speak  edit line  BACKSPACE vim  patch.p4j
 m,=consonent  .=dialect    /=change edit line  ENTER     reprint screen
 5      abacterial
         v01V
 ;       ey   b  + ae   k  + t    ih   r  + iy % ax   l  %
 0       ae   b  + ae   k  + t    ih   r  + iy % ax   l  %
 1  0    ah   b    ae   k    t    ih   r    iy   ah   l
 2
 3
 4
 5
 6
 7
 8
 9

(SayPhones ( quote ( ey   b    ae   k    t    ih   r    iy   ax   l
                           )))
#
festival> HIT ; * 1 2 3 4 5 6 7 8  or 9 to add to patch.
 HIT ENTER   if you do not want to save a patch.
; added to the patch file.

# BACKSPACE shows the new entry in vim word processor

abacterial                    0    ey   b  + ae   k  + t    ih   r  + iy % ax   l  %
patch.p4j                                                                        1,1            Top
"patch.p4j" 27L, 2378C

# h to show a help screen, hit ENTER when done

 aa fAther, wAshington | ae fAt, bAd     | ah bUt, hUsh       | ao lAWn, mAll
 aw hOW, sOUth, brOWser| ax About, cAnoe | ay hIde, bIble     | eh gEt, fEAther
 er fERtile, makER     | ey gAte, Ate    | ih bIt, shIp       | iy bEAt, shEEp
 ow lOne, nOse         | oy tOY, OYster  | uh fUll, wOOd      | uw fOOl, fOOd
 b  Book, aBrupt       | ch CHart, larCH | d  Done, baD       | dh THat, faTHer
 f  Fat, lauGH         | g  Good, biGGer | hh Hello, loopHole | jh diGit, Jack
 k  Camera, jaCK, Kill | l  Late, fuLL   | m  Man, gaMe       | n  maN, New
 ng baNG, sittiNG      | p  Pat, camPer  | r  Reason, caR     | s  Sit, maSS
 sh SHip, claSH        | t  Tap, baT     | th THeatre, baTH   | v  Various, haVe
 w  Water, cobWeb      | y  Yellow, Yacht| z  Zero, quiZ, boyS| zh viSion, caSual
 -- pau short pause    | +  stressed     | %  unstress        | , secondary
 n=noun                | v=verb          | d=adverb           | j=adjective
 p=past                | i=interjection  | g=genative         | s=plural
 c=capitalized         | a=abbreviation                       | ## comment
 U1 U2 individual user | RP recieved pr. | GA general American| AU Australian
 ENTER to reset screen

# PROPOSED VIEWING FORMAT

###########DOCUMENT#########PROPOSED########VIEWING#####FORMAT###########
#   word             29 1-29     alpha    small case
#   blank separator   1 30       blank space no tabs
#   alternate num     1 31       numeric   0=single word, 1=first of more
#   alternate pos     1 32       part of speech effecting pronunciation
#   alternate type    2 33 34    alpha-numeric 1 or 2 
#   blank separator   1 35       space no tabs
#   phoneme           3 36,38    may be 1 or 2
#   blank separator   1 39       space no tabs
#   accent pause      1 40       +,;%`|    not alphanumeric '-# or _
#   blank separator   1 41       space no tabs
#   ... phonemes x 17                or set max_fields to more
#   flags comments    #          optional     comment or espeak flag
#                                or display in place of word      one [1]

# PATCH PROCESS and FILE CONVERSION UTILITIES

##########Options#########To#############Apply########Patch####################
#
# 1. in.p4j
#         place in this file a word list or portion of a dictionary to review
#         wordlist  or  word0phoneme1 ...
#         the "0" column will be renumbered later
#
# 2. g2p4j
#         check a word or dictionary, save one or more phoneme strings
#         modify and add to the patch file with input from in.p4j       --> patch.p4j
#
# 3. g2p4j -n patch.p4j
#         number any alternate word entries and make a sorted word list
#         column 2 starts with 0 or the alternate word number           --> patch.p4j
#         words with 0 and 1 are listed, make a unique list, sort       --> wlist.p4j
#
# 4. g2p4j -p in_dictionary
#         read in-dictionary and remove, purde, all words in wlist.p4j  --> purged.p4j
#
# 5. g2p4j -a patch.p4j
#         add patch.p4j to purged.p4j, sort and apply g2p4j format      --> new.p4j
#
###########Conversion#####Scripts#################################
#          input file     cv-in.p4j      output to     cv-out.p4j
#
# cv-fest-lookup    input list of words,  output festival phone list
# cv-lower          to lower case
# cv-make-paren     column 2, if 2-9 add (2) (3)  ... to the word
# cv-tab-0          convert word-tab phones   to    word 0 phones
# cv-upper          to upper case

#


#


#


#


#


#


#