source: collections/documented-examples/trunk/gsarch-e/etc/collect.cfg@ 19285

Last change on this file since 19285 was 19285, checked in by kjdon, 15 years ago

updated for 2.82. descriptions, added some comments

  • Property svn:executable set to *
File size: 18.4 KB
Line 
1creator [email protected]
2maintainer [email protected]
3public true
4
5buildtype mg
6
7indexes document:text document:From document:Subject
8defaultindex document:text
9
10plugin GreenstoneXMLPlugin
11# process_exp tells EmailPlugin which files to process - in this case all files
12# starting with 'greenstone'. This is used as the email files in this
13# collection don't have a standard mbx/email extension.
14# OIDtype message_id tells the plugin to use the message identifier as the
15# Greenstone document identifier - this way we can use the InReplyTo metadata
16# to link to the original email.
17plugin EmailPlugin -process_exp greenstone.* -OIDtype message_id
18plugin MetadataXMLPlugin
19plugin ArchivesInfPlugin
20plugin DirectoryPlugin
21groupsize 200
22
23# note that [ and ] get turned into &#9x; before we remove the prefix!
24# mingroup 2 so that bookshelves are only generated when there is more than
25# one item with a common value.
26# removeprefix removes re: fwd: [greenstone-users] [greenstone-devel] from
27# the subject line before classifying, so that messages and their replies end
28# up in the same folder.
29classify AZCompactList -metadata Subject -mingroup 2 -removeprefix (\\s*(?i:re:|fw(d)?:|\[greenstone-(users|devel)\])\\s*)*
30classify AZCompactList -metadata FromName -mingroup 2 -buttonname From
31classify DateList -nogroup -bymonth
32
33format DocumentHeading ""
34format DocumentButtons ""
35format DocumentArrowsTop false
36format DocumentArrowsBottom false
37format DocumentGoTo false
38
39# removed from format strings to prevent listing email addresses - John:
40# &lt;<a href=\"mailto:[FromAddr]\">[FromAddr]</a>&gt;
41
42# for Subjects
43format CL1VList "
44<td valign=top>[link][icon][/link]</td>
45<td>{If}{[numleafdocs], <b>[Title]</b>,<b>[link][Subject][/link]</b><br>
46_From_: [FromName] &nbsp;&nbsp;(<a href=\"_httpquery_&q=[cgisafe:FromName]&h=dfr\">_SearchBySender_</a>) <br>
47_Date_: [DateText]}</td>
48"
49
50# for From
51format CL2VList "
52<td valign=top>[link][icon][/link]</td>
53<td>{If}{[numleafdocs],
54<strong>_From_:</strong> [Title] ([numleafdocs]),
55<strong>_From_: [FromName]</strong> &nbsp;&nbsp;(<a href=\"_httpquery_&q=[cgisafe:FromName]&h=dfr\">_SearchBySender_</a>) <br>
56<strong>_Subject_:</strong> [link][Subject][/link]<br>
57<strong>_Date_:</strong> [DateText]
58}</td>
59"
60
61# for Dates
62format CL3DateList "
63<td valign=top>[link][icon][/link]</td>
64<td><b>[link][Subject][/link]</b><br>
65_From_: [FromName] &nbsp;&nbsp;(<a href=\"_httpquery_&q=[cgisafe:FromName]&h=dfr\">_SearchBySender_</a>)<br>
66_Date_: [DateText]
67</td>
68"
69
70format SearchVList "
71<td valign=top>[link][icon][/link]</td>
72<td><b>[link][Subject][/link]</b><br>
73_From_: [FromName] &nbsp;&nbsp;(<a href=\"_httpquery_&q=[cgisafe:FromName]&h=dfr\">_SearchBySender_</a>)<br>
74_Date_: [DateText]
75</td>
76"
77
78format DocumentText "<center> <h2>[Subject]</h2>
79<p>
80<table width=\"90%\">
81<tr bgcolor=\"#DDDDEE\">
82<td align=\"right\">_From_</td>
83<td><b><a href=\"_httpquery_&q=[cgisafe:FromName]&h=dfr\">[FromName]</a></b>
84</td>
85</tr>
86<tr bgcolor=\"#DDDDEE\">
87<td align=\"right\">_Date_</td><td><b>[DateText]</b></td>
88</tr>
89<tr bgcolor=\"#DDDDEE\">
90<td align=\"right\">_Subject_</td>
91<td><b>[Subject]</b></td></tr>
92_If_([InReplyTo],<tr bgcolor=\"#DDDDEE\"><td align=\"right\">In-Reply-To</td><td>
93<a href=\"_httpdocument_&amp;d=[InReplyTo]\">([InReplyTo])</a></td></tr>)
94<tr><td colspan=\"2\">[Text]</td></tr>
95</table>
96</p>
97</center>"
98
99format VList "<td valign=\"top\">[link][icon][/link]</td>
100<td valign=\"top\">[ex.srclink]{Or}{[ex.thumbicon],[ex.srcicon]}[ex./srclink]</td>
101<td valign=\"top\">[highlight]
102{Or}{[dc.Title],[exp.Title],[ex.Title],Untitled}
103[/highlight]{If}{[ex.Source],<br><i>([ex.Source])</i>}</td>"
104
105format HList "[link][highlight][ex.Title][/highlight][/link]"
106
107format DateList "<td>[link][icon][/link]</td>
108<td>[highlight]{Or}{[dc.Title],[exp.Title],[ex.Title],Untitled}[/highlight]</td>
109<td>{Or}{[dc.Date],[exp.Date],[ex.Date]}</td>"
110
111
112# -- English strings ----------------
113collectionmeta collectionname [l=en] "Greenstone Archives collection"
114
115collectionmeta .document:text [l=en] "Messages"
116collectionmeta .document:From [l=en] "From fields"
117collectionmeta .document:Subject [l=en] "Subject lines"
118
119collectionmeta From [l=en] "From"
120collectionmeta Date [l=en] "Date"
121collectionmeta Subject [l=en] "Subject"
122collectionmeta SearchBySender [l=en] "search by sender"
123
124# -- French strings ----------------
125collectionmeta collectionname [l=fr] "Collection des Archives de Greenstone"
126
127collectionmeta .document:text [l=fr] "Messages"
128collectionmeta .document:From [l=fr] "Champs De"
129collectionmeta .document:Subject [l=fr] "Lignes de sujets"
130
131collectionmeta From [l=fr] "De"
132collectionmeta Date [l=fr] "Date"
133collectionmeta Subject [l=fr] "Sujet"
134collectionmeta SearchBySender [l=fr] "recherche par expéditeur"
135
136# -- Spanish strings ----------------
137collectionmeta collectionname [l=es] "Colección de Archivos Greenstone"
138
139collectionmeta .document:text [l=es] "Mensaje"
140collectionmeta .document:From [l=es] "Campos de origen"
141collectionmeta .document:Subject [l=es] "Líneas del asunto"
142
143collectionmeta From [l=es] "De"
144collectionmeta Date [l=es] "Fecha"
145collectionmeta Subject [l=es] "Asunto"
146collectionmeta SearchBySender [l=es] "buscar por emisor"
147
148# -- Russian strings ----------------
149collectionmeta collectionname [l=ru] "КПллекцОя арх
150ОвПв Greenstone"
151
152collectionmeta .document:text [l=ru] "СППбщеМОя"
153collectionmeta .document:From [l=ru] "Из пПлей"
154collectionmeta .document:Subject [l=ru] "СтрПкО преЎЌета"
155
156collectionmeta From [l=ru] "От"
157collectionmeta Date [l=ru] "Дата"
158collectionmeta Subject [l=ru] "ПреЎЌет"
159collectionmeta SearchBySender [l=ru] "ППОск пП ПтправОтелю"
160
161# -- English text ----------------
162collectionmeta collectionextra [l=en] "This is a collection of email messages
163from the Greenstone mailing list archives, from November/December, 2008.
164
165<h3>How the collection works</h3>
166
167<p>
168The Greenstone Archives collection
169uses the <i>Email</i> plugin, which parses files in email formats. In this case, there is a file per month per mailing list, and each file contains many email messages. The <i>Email</i>
170plugin splits these into individual documents, and produces <i>Title</i>,
171<i>Subject</i>, <i>From</i>, <i>FromName</i>, <i>FromAddr</i>,
172<i>Date</i>, <i>DateText</i>, <i>InReplyTo</i>, and optionally <i>Headers</i>, metadata.
173
174<p>
175The <a href=\"_httpcollection_/etc/collect.cfg\" target=collect.cfg>collection configuration file</a> begins with the specification
176<i>groupsize 200</i>. This groups documents together into groups of 200. Email
177collections typically have many small documents, and grouping them together
178prevents Greenstone\'s internal file structures from becoming bloated and
179occupying more disk space than necessary. Notice that the <i>Email</i> plugin first
180splits the input files up into individual Emails, then <i>groupsize</i> groups them
181together again. This allows the collection designer to control what is going on.
182
183<p>
184The <i>indexes</i> line specifies 3 searchable indexes, which can be seen by clicking
185beside the word \"Messages\" on the
186<a href=\"_gwcgi_?l=_cgiargl_&c=_cgiargc_&a=q\">search page</a> to reveal a drop-down menu.
187The first (called <i>Messages</i>) is created from the document
188text, while the others are formed from <i>From</i> and <i>Subject</i> metadata.
189
190<p>
191There are three classifiers, based on <i>Subject</i>, <i>FromName</i>, and
192<i>Date</i> metadata. The <i>AZCompactList</i> classifier used for the first
193two is like <i>AZList</i> but generates a bookshelf for duplicate items, as
194illustrated <a href=\"_gwcgi_?l=_cgiargl_&c=_cgiargc_&a=d&cl=CL1\">here</a>.
195This is represented by a tree structure whose nodes are either
196leaf nodes, representing documents, or internal nodes. A metadata item called
197numleafdocs gives the total number of documents below an internal node. The
198format statement for the first classifier, called <i>CL1Vlist</i>, checks
199whether this item exists. If so the node must be an internal one, in which case
200it is labeled by its <i>Title</i>. Otherwise the node\'s label starts with the
201<i>Subject</i> which links to the document, then gives <i>FromName</i> metadata, with a link to \"Search by Sender\", followed by the <i>DateText</i>.
202
203<p>
204The second classifier (<i>CL2Vlist</i>) is similar, but shows slightly
205different information -- the result can be seen
206<a href=\"_gwcgi_?l=_cgiargl_&c=_cgiargc_&a=d&cl=CL2\">here</a>.
207For internal nodes, the actual number of leaf documents
208(<i>numleafdocs</i>) is given in parentheses after the <i>Title</i>. For
209document nodes the <i>FromName</i>, with a link to \"Search By Sender\", <i>Subject</i> (linked to the document), and <i>DateText</i> metadata is
210shown.
211
212<p>
213The third classifier is a <i>DateList</i>, which allows selection by month and year.
214
215<p>
216Finally, the document text is formatted to show the header fields (<i>FromName</i>, <i>DateText</i>, <i>Subject</i>, <i>InReplyTo</i>), followed by
217the message text (written as <i>[Text]</i> in the format statement). <i>FromName</i> is linked to a search on that name, while <i>InReplyTo</i> links to the email message that it refers to.
218"
219
220# -- French text ----------------
221collectionmeta collectionextra [l=fr] "_text1_
222
223<h3>Comment fonctionne cette collection ?</h3>
224
225<p>
226La collection Greenstone Archive utilise le plugin \"<i>E-mail</i>\", qui traite les fichiers aux formats e-mail. _text2_
227_text3_
228
229<p>
230Le <a href=\"_httpcollection_/etc/collect.cfg\" target=collect.cfg>fichier de configuration</a> de la collection débute avec la spécification <i>groupsize 200</i>. Ceci regroupe les documents par groupes de 200. Les collections E-mail sont constituées habituellement de plusieurs documents de petite taille; leur regroupement évite l\'augmentation excessive des structures de fichier internes de Greenstone et l\'occupation de plus d\'espace disque que nécessaire. Notez que le plugin <i>E-mail</i> éclate d\'abord les fichiers d\'entrée à traiter en E-mail individuels, ensuite <i>groupsize</i> procÚde à leur regroupement. Ceci permet au créateur de la collection de contrÎler ce qui se passe.
231
232<p>
233La ligne des <i>indexes</i> précise trois indexes de recherche qui peuvent être vus en cliquant à cÎté du mot \"Message\" de la <a href=\"_gwcgi_?l=_cgiargl_&c=_cgiargc_&a=q\">page de recherche</a> pour révéler un menu déroulant. Le premier (appelé <i>Messages</i>) est créé à partir
234du texte du document, tandis que les autres sont formés à partir des méta-données <i>From</i> et <i>Subject</i>.
235
236<p>
237Il existe trois classificateurs basés sur les méta-données <i>Subject</i>, <i>FromName</i> et <i>Date</i>. Le classificateur <i>AZCompactList</i> utilisé pour les deux premiers est semblable
238à \"<i>AZList</i>\", mais en outre il génÚre un rayon de bibliothÚque pour les articles dupliqués, comme illustré <a href=\"_gwcgi_?l=_cgiargl_&c=_cgiargc_&a=d&cl=CL1\">ici</a>.
239Il est représenté par une structure arborescente dont les nœuds sont soit des nœuds de feuille
240représentant les documents, soit des nœuds internes. Une Méta-donnée appelée
241\"Numleafdocs\" donne le nombre total de documents sous un nœud interne. Les déclarations de format pour le premier classificateur, appelé <i>CL1VList</i>, vérifie si cette méta-donnée existe, auquel cas le nœud doit être d\'une part interne et d\'autre part libellé par son \"<i>Title</i>\" (<i>Titre</i>). _text4_
242
243<p>
244Le deuxiÚme classificateur (<i>CL2Vlist</i>) est similaire, mais fournit une
245information légÚrement différente --le résultat peut être vu
246<a href=\"_gwcgi_?l=_cgiargl_&c=_cgiargc_&a=d&cl=CL2\">ici</a>.
247Pour les nœuds internes, le nombre exact de documents en feuilles
248(<i>numleafdocs</i>) est donné entre parenthÚses aprÚs <i>Title</i>. _text5_
249
250<p>
251Le troisiÚme classificateur est un \"<i>DateList</i>\" qui permet une sélection par mois et par année.
252
253<p>
254_text6_
255"
256
257# -- Spanish text ----------------
258collectionmeta collectionextra [l=es] "
259_text1_
260
261<h3>Cómo trabaja esta colección</h3>
262<p>
263
264La colección de Archivos de Greenstone utiliza el plugin <i>Email</i>, el cual descompone y analiza los archivos que están en formato de correo electrónico. _text2_ _text3_
265<p>
266
267El <a href=\"_httpcollection_/etc/collect.cfg\" target=collect.cfg>archivo de configuración de la colección</a> empieza con la especificación <i>groupsize 200</i>, la cual reúne los documentos en grupos de 200. En términos generales las colecciones de correo electrónico tienen muchos documentos pequeños y al agruparlos se evita que las estructuras de archivos internos de Greenstone se inflen demasiado y ocupen más espacio del necesario. Recuerde que el plugin <i>Email</i> divide primero los archivos de entrada en correos individuales y luego <i>groupsize</i> los agrupa nuevamente. Esto le permite al diseñador de la colección controlar lo que está pasando.
268<p>
269
270La línea de índices especifica 3 índices de búsqueda, los cuales se pueden ver haciendo click a un lado de la palabra \"Mensajes\" en la <a href=\"_gwcgi_?l=_cgiargl_&c=_cgiargc_&a=q\">página de búsqueda</a> para que aparezca un menú descendente. El primero (llamado <i>Mensajes</i>) se crea a partir del texto del documento, mientras que los demás se forman a partir de los metadatos de <i>Remitente</i> y <i>Asunto</i>.
271<p>
272
273Existen tres clasificadores basados en los metadatos de <i>Asunto, Nombre del Remitente</i> y <i>Fecha</i>. El clasificador <i>AZCompactList</i> utilizado para los dos primeros es como <i>AZList</i>, pero además genera un estante para los ítems duplicados, tal como se puede ver <a href=\"_gwcgi_?l=_cgiargl_&c=_cgiargc_&a=d&cl=CL1\">aquí</a>. Éste se caracteriza por medio de una estructura de árbol cuyos nodos son hojas que representan documentos o nodos internos. Un ítem de metadato llamado <i>numleafdocs</i> proporciona el número total de documentos debajo de un nodo interno. Los enunciados de formato para el primer clasificador llamado <i>CL1Vlist</i> comprueban si existe dicho ítem. En caso afirmativo se trata de un nodo interno, en cuyo caso se etiquetará por su <i>Título</i>. _text4_
274<p>
275
276El segundo clasificador (CL2Vlist) es similar, sólo que muestra una información ligeramente diferente. El resultado se puede ver <a href=\"_gwcgi_?l=_cgiargl_&c=_cgiargc_&a=d&cl=CL2\">aquí</a>. Para nodos internos el número de documentos (<i>numleafdocs</i>) aparece entre paréntesis después del <i>Título</i>. _text5_
277<p>
278
279El tercer clasificador es una <i>Lista de Fechas (DateList)</i>, que permite hacer la selección por mes y año.
280<p>
281
282_text6_
283"
284
285# -- Russian strings ----------------
286collectionmeta collectionextra [l=ru] "
287_text1_
288
289
290<h3>Как рабПтает кПллекцОя</h3>
291
292КПллекцОя арх
293ОвПв Greenstone ОспПльзует плагОМ Еmail, кПтПрый аМалОзОрует файлы в фПрЌатах
294 электрПММПй пПчты. _text2_ _text3_
295<p>
296
297КПМфОгурацОПММый файл кПллекцОО МачОМается с ПпреЎелеМОя <i>groupsize</i> 200. ОМ сПбОрает ЎПкуЌеМты в группы пП 200 еЎОМОц. КПллекцОО электрПММПй пПчты ПбычМП сПстПят Оз бПльшПгП чОсла МебПльшОх
298 ЎПкуЌеМтПв, О группОрПвка Ох
299 вЌесте преЎПтвращает вМутреММОе файлПвые структуры Greenstone Пт разбух
300аМОя О заМятОя бПльшегП Ќеста Ма ЎОске, чеЌ МеПбх
301ПЎОЌП. ЗаЌетьте, чтП плагОМ Еmail вМачале разбОвает вх
302ПЎМые файлы Ма ОМЎОвОЎуальМые электрПММые пОсьЌа, а затеЌ <i>groupsize</i> сМПва сПбОрает Ох
303 вЌесте. ЭтП пПзвПляет прПектОрПвщОку кПллекцОО управлять теЌ, чтП слеЎует Ўальше.
304<p>
305
306СтрПка <i>ОМЎексПв (indexes)</i> ПпреЎеляет 3 ЎПступМых
307 Ўля пПОска ОМЎекса, кПтПрые ЌПгут быть вОЎМы, еслО щелкать ПкПлП слПва <i>СППбщеМОя (Messages)</i> Ма <a href=\"_gwcgi_?l=_cgiargl_&c=_cgiargc_&a=q\">пПОскПвПй страМОце</a> Ўля пПказа МОспаЎающегП ЌеМю. Первый, МазываеЌый <i>СППбщеМОяЌО</i>, сПзЎается Оз текста ЎПкуЌеМта, в тП вреЌя как ЎругОе сфПрЌОрПваМы пП ЌетаЎаММыЌ <i>От кПгП О ПреЎЌет</i>.
308<p>
309
310Существует трО классОфОкатПра, ПсМПваММые Ма ЌетаЎаММых
311 <i>ПреЎЌет</i>, <i>ИЌя ПтправОтеля</i> О <i>Дата</i>. КлассОфОкатПр <i>AZCompactList</i>, ОспПльзуеЌый Ўля первых
312 Ўвух
313, пПх
314Пж Ма <i>AZLIST</i>, МП ПМ фПрЌОрует кМОжМую пПлку Ўля ЎублОкатПв элеЌеМтПв, как пПказаМП <a href=\"_gwcgi_?l=_cgiargl_&c=_cgiargc_&a=d&cl=CL1\">зЎесь</a>. ОМа преЎставлеМа структурПй Ўерева, узлы кПтПрПй являются ОлО узлаЌО лОста, преЎставляя ЎПкуЌеМты, ОлО вМутреММОЌО узлаЌО. МетаЎаММые элеЌеМтПв, МазываеЌые numleafdocs, Ўают Пбщее кПлОчествП ЎПкуЌеМтПв, распПлПжеММых
315 МОже вМутреММегП узла. ОператПры фПрЌата Ўля первПгП классОфОкатПра, МазываеЌые <i>CL1Vlist</i>, прПверяют, существует лО этПт элеЌеМт. ЕслО этП так, тП узел ЎПлжеМ быть вМутреММОЌ, в случае чегП ПМ пПЌечается егП <i>НазваМОеЌ (Title)</i>. _text4_
316<p>
317
318ВтПрПй классОфОкатПр (<i>CL2Vlist</i>) пПЎПбеМ первПЌу, МП ПМ пПказывает ПтлОчающуюся ОМфПрЌацОю -- результат ЌПжМП вОЎеть <a href=\"_gwcgi_?l=_cgiargl_&c=_cgiargc_&a=d&cl=CL2\">зЎесь</a>. Для вМутреММОх
319 узлПв фактОческПе чОслП ЎПкуЌеМтПв в спОске (<i>numleafdocs</i>) Ўается в круглых
320 скПбках
321 пПсле <i>НазваМОя</i>. _text5_
322<p>
323
324ТретьОЌ классОфОкатПрПЌ является <i>DateList</i>, кПтПрый пПзвПляет прПОзвПЎОть выбПрку сППбщеМОй пП Ќесяцу О гПЎу.
325<p>
326
327_text6_
328"
329
330# use utf-8 as the default encoding
331cgiarg shortname=w argdefault=utf-8
332
Note: See TracBrowser for help on using the repository browser.