Commit | Line | Data |
---|---|---|
8bbc3c98 KT |
1 | .th SPEAK VI 4/26/75 |
2 | .if t .ds A \o"a\(ga" | |
3 | .if n .ds A a\b` | |
4 | .if t .ds v \|\(bv | |
5 | .sh NAME | |
6 | speak \*- word to voice translator | |
7 | .sh SYNOPSIS | |
8 | .bd speak | |
9 | [ | |
10 | .bd \*-efpsv | |
11 | ] [ vocabulary | |
12 | [ | |
13 | output ] | |
14 | ] | |
15 | .sh DESCRIPTION | |
16 | .it Speak | |
17 | turns a stream of words | |
18 | into utterances and outputs them to a voice synthesizer, | |
19 | or to the specified | |
20 | .it output. | |
21 | It has facilities for maintaining a vocabulary. | |
22 | It receives, from the standard input | |
23 | .s3 | |
24 | .lp +5 3 | |
25 | \*- working lines: text of words separated by blanks | |
26 | .lp +5 3 | |
27 | \*- phonetic lines: strings of phonemes for one word preceded | |
28 | and separated by commas. | |
29 | The phonemes may be followed by comma-percent then a `replacement | |
30 | part' \*- an ASCII string with no spaces. | |
31 | The phonetic code is given in | |
32 | .it vs | |
33 | (V). | |
34 | .lp +5 3 | |
35 | \*- empty lines | |
36 | .lp +5 3 | |
37 | \*- command lines: beginning with | |
38 | .bd !. | |
39 | The following command lines | |
40 | are recognized: | |
41 | .s3 | |
42 | .lp +15 10 | |
43 | \fB!r\fR file replace coded vocabulary from file | |
44 | .lp +15 10 | |
45 | \fB!w\fR file write coded vocabulary on file | |
46 | .lp +15 10 | |
47 | \fB!p\fR print phonetics for working word | |
48 | .lp +15 10 | |
49 | \fB!l\fR list vocabulary on standard output with phonetics | |
50 | .lp +15 10 | |
51 | \fB!c\fR word copy phonetics from working word to | |
52 | specified word | |
53 | .lp +15 10 | |
54 | \fB!d\fR print decomposition of working word into substrings | |
55 | .lp +15 10 | |
56 | \fB!f\fI n\fR turn off (or on) English preprocessing rule number | |
57 | .it n | |
58 | (see listing for meaning of | |
59 | .it n) | |
60 | .s3 | |
61 | .i0 | |
62 | Each working line replaces its predecessor. | |
63 | Its first word is the `working word'. | |
64 | Each phonetic line replaces the phonetics stored for the | |
65 | working word. | |
66 | In particular, a phonetic line of comma only deletes the | |
67 | entry for the working word. | |
68 | Each working line, phonetic line or empty line | |
69 | causes the working line to be uttered. | |
70 | The process terminates at the end of input. | |
71 | .s3 | |
72 | Unknown words are pronounced by rules, and failing that, | |
73 | are spelled. | |
74 | For the builtin part of | |
75 | the rules, see the reference. | |
76 | Spelling is done by taking each character of | |
77 | the word, prefixing it with `*', and looking it up. | |
78 | Unspellable words burp. | |
79 | .s3 | |
80 | Words not found verbatim in the vocabulary | |
81 | are pronounced piecewise. | |
82 | First the word is bracketed by sharps: | |
83 | `#...#'. | |
84 | The vocabulary is then searched for | |
85 | the longest fragment that matches the | |
86 | beginning of the word. | |
87 | The phonetic part of the phonetic string is uttered, | |
88 | and the matched fragment is replaced by the replacement | |
89 | part of the phonetic string, if any. | |
90 | The process is repeated until the word is exhausted. | |
91 | A fragment is entered into the vocabulary as a working | |
92 | word prefixed by `%'. | |
93 | .s3 | |
94 | .it Speak | |
95 | is initialized with a coded vocabulary stored in file | |
96 | .it /usr/lib/speak.m. | |
97 | The vocabulary option substitutes a different file for | |
98 | .it /usr/lib/speak.m. | |
99 | Other vocabularies, to be used with | |
100 | option | |
101 | \fB\*-e\fR, | |
102 | exist in /usr/vs/latin.m and /usr/vs/polish.m. | |
103 | .s3 | |
104 | A set of single letter options may | |
105 | appear in any order preceded by | |
106 | .bd \*-. | |
107 | Their meanings are: | |
108 | .s3 | |
109 | .lp +8 4 | |
110 | \fBe\fR suppress English preprocessing | |
111 | .lp +8 4 | |
112 | \fBf\fR equivalent to `f1, f2,...' | |
113 | .lp +8 4 | |
114 | \fBp\fR suppress pronunciation by rule | |
115 | .lp +8 4 | |
116 | \fBs\fR suppress spelling | |
117 | .lp +8 4 | |
118 | \fBv\fR suppress voice output | |
119 | .s3 | |
120 | .i0 | |
121 | The following input will reconstitute a | |
122 | coded vocabulary, `speak.m', from an ascii listing, `speak.v', that | |
123 | was created using \fB!l\fR. | |
124 | .s3 | |
125 | .lp +8 0 | |
126 | (cat speak.v; echo !w speak.m) \*v speak \*-v /dev/null | |
127 | .s3 | |
128 | .i0 | |
129 | .sh FILES | |
130 | /usr/lib/speak.m | |
131 | .sh "SEE ALSO" | |
132 | M. D. McIlroy, ``Synthetic English Speech by Rule,'' | |
133 | Computing Science Technical Report #14, | |
134 | Bell Laboratories, 1973 | |
135 | .br | |
136 | vs (V), vs (IV) | |
137 | .sh BUGS | |
138 | Excessively long words cause dumps. | |
139 | .br | |
140 | Space is not reclaimed from changed entries; | |
141 | use \fB!w\fR and \fB!r\fR to effect reclamation. | |
142 | .br | |
143 | \fB!p\fR doesn't always work as advertised. |