Subversion Repositories wimsdev

Rev

Rev 13477 | Rev 13715 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 13477 Rev 13704
Line 2... Line 2...
2
textarea="data"
2
textarea="data"
3
 
3
 
4
:Classer tous les mots d'une phrase écrite selon un attribut (par exemple leur nature).
4
:Classify all words of a sentence according to an attribute (for example their nature).
5
Cet exercice diffère d'autres exercices de classification par la manière dont les données sont
5
This exercise differs from other classification exercises in the way the data is entered,
6
rentrées, la donnée étant une phrase et non une liste de mots.
6
 the data being a sentence and not a list of words.
7
<p class="wims_credits">
7
<p class="wims_credits">
8
Author of the model: Bernadette Perrin-Riou <bpr@math.u-psud.fr>
8
Author of the model: Bernadette Perrin-Riou <bpr@math.u-psud.fr>
9
</p>
9
</p>
10
:%%%%%%%%%%%%%%%%%      ATTENTION      %%%%%%%%%%%%%%%%%%%%
10
:%%%%%%%%%%%%%%%%%      ATTENTION      %%%%%%%%%%%%%%%%%%%%
11
 
11
 
12
Remove the above header if you destroy the model tags! (The lines starting
12
Remove the above header if you destroy the model tags! (The lines starting
13
with a ':'.) Otherwise the exercise might not be taken back by Createxo.
13
with a ':'.) Otherwise the exercise might not be taken back by Createxo.
14
 
14
 
15
:%%%%%%%% Sample parameters to be redefined %%%%%%%%%%%%%%%%%
15
:%%%%%%%% Sample parameters to be redefined %%%%%%%%%%%%%%%%%
16
:\title{Classer les mots d'une phrase}
16
:\title{Categorize the words of a sentence}
17
:\author{Bernadette, Perrin-Riou}
17
:\author{Bernadette, Perrin-Riou}
18
:\email{}
18
:\email{}
19
:\credits{}
19
:\credits{}
20
 
20
 
21
:Instructions
21
:Instructions
22
\text{instruction= Classer les mots selon leur nature ou des propriétés}
22
\text{instruction=Classify words of the sentence according to their nature or properties}
23
 
23
 
24
:File name
24
:File name
25
Ne remplissez que si vous vous désirez transférer le source de cet exercice dans un compte Modtool
25
Fill only if you want to transfer the source of this exercise
26
et utiliser un fichier de données (dans un module OEF)
26
 to a Modtool account and use a data file (in an OEF module) of the type
27
du type
-
 
28
<pre>
27
<pre>
29
 V,N,Art,Adj,Prep
28
 V,N,Art,Adj,Prep
30
 Verbe,Nom,Article,Adjectif,Préposition
29
 Verb, name, article, adjective, preposition
31
 &#58;Le|Art,petit|Adj,chat|N,boit|V,du|Art,lait.|N
30
 &#58;The|Art,little|Adj,cat|N,drinks|V,milk.|N
32
 &#58;Le|Art,chat|N,boit|V,du|Art,lait|N,dans|Prep,un|Art,bol.|N
31
 &#58;The|Art,cat|N,drinks|V,milk|N,in|Prep,a|Art,bowl.|N
33
</pre>
32
</pre>
34
Dans ce cas, les données principales ne seront pas prises en compte.
33
In this case, the main data will not be taken into account.
35
Sinon, remplissez les données principales.
34
Otherwise, fill in the main data.
36
 
35
 
37
\text{file=}
36
\text{file=}
38
 
37
 
39
:Nature des objets
38
:Nature of objects
40
\text{nom_nature=Verbe,Nom,Article,Adjectif,Préposition}
39
\text{nom_nature=verb, name, article, adjective, preposition}
41
 
40
 
42
:Nature des mots (code)
41
:Nature of words (code)
43
C'est ce code qui sera utilisé dans les données principales.
42
This code will be used in the main data.
44
\text{Nature=V,N,Art,Adj,Prep}
43
\text{Nature=V,N,Art,Adj,Prep}
45
 
44
 
46
:Main data
45
:Main data
47
Une phrase par ligne : les mots (ou groupes de mots) de la phrase sont séparés par des virgules. Après chaque mot,
46
One sentence per line: The words (or groups of words) in the sentence are separated by commas.
-
 
47
After each word, separated from the word by the vertical bar,
48
séparé du mot par la barre verticale <span class="tt">|</span>, est écrit la nature ou l'attribut du mot telle
48
 is written the nature or attribute of the word as it was written
49
qu'il a été écrit dans le champ <span class="tt">Nature des mots (code)</span>. Si le mot (ou groupe de mots)
49
 in the field <span class="tt">Nature of words (code)</span>.
50
n'est pas suivi d'une barre verticale
50
If the word (or group of words) is not followed by a vertical bar
51
et d'un attribut, il n'est pas proposé dans la liste des mots à placer,
51
 and an attribute, it is not proposed in the list of words to be placed,
52
mais est écrit dans la phrase d'introduction.
52
 but is written in the introductory sentence.
53
 
53
 
54
\text{data=Le|Art,petit|Adj,chat|N,boit|V,du|Art,lait|N
54
\text{data=The|Art,little|Adj,cat|N,drinks|V,milk.|N
55
Le|Art,chat|N,boit|V,du|Art,lait|N,dans|Prep,un|Art,bol|N
55
The|Art,cat|N,drinks|V,milk|N,in|Prep,a|Art,bowl.|N}
56
Le,chat|N,boit|V,du,lait|N,dans|Prep,un,bol|N}
-
 
57
 
56
 
58
:Embraced random items
57
:Embraced random items
59
$embraced_randitem
58
$embraced_randitem
60
\text{accolade=item(1,1 yes,
59
\text{accolade=item(1,1 yes,
61
2 no)}
60
2 no)}
62
 
61
 
63
:%%%%%%%%%%%%%% Nothing to modify until statement %%%%%%%%%%%%%%%%
62
:%%%%%%%%%%%%%% Nothing to modify until statement %%%%%%%%%%%%%%%%
64
\css{<style type="text/css">
63
\css{<style>
65
   .question {background-color: #FFFFCC;margin: 2% 2%;padding: 1%;}
64
   .question {background-color: #FFC;margin: 2% 2%;padding: 1%;}
66
   .reponse {background-color: #FFCC99;color: black;margin: 2% 2%;padding: 0%;}
65
   .reponse {background-color: #FC9;color: black;margin: 2% 2%;padding: 0;}
67
   .oefstatement{}
-
 
68
   ol li {list-style: upper-alpha; }
66
   ol li {list-style: upper-alpha;}
69
 </style>}
67
</style>}
70
 ##s'il y a un nom de fichier dans file, utilise le fichier, sinon utilise data
68
 ##if a file name exist, use the file, otherwise use data
71
\if{\file notsametext}{
69
\if{\file notsametext}{
72
  \text{data=wims(randrecord \file)}
70
  \text{data=wims(randrecord \file)}
73
  \text{Nature=wims(record 0 of \file)}
71
  \text{Nature=wims(record 0 of \file)}
74
  \text{nom_nature=row(2,\Nature)}
72
  \text{nom_nature=row(2,\Nature)}
75
  \text{Nature=row(1,\Nature)}
73
  \text{Nature=row(1,\Nature)}
76
  }{
74
}{
77
  \text{data=randomrow(\data)}
75
  \text{data=randomrow(\data)}
78
  }
76
}
79
\text{accolade=wims(word 1 of \accolade)}
77
\text{accolade=wims(word 1 of \accolade)}
80
 
78
 
81
\text{data=\accolade=1 ? wims(embraced randitem \data)}
79
\text{data=\accolade=1 ? wims(embraced randitem \data)}
82
\integer{cnt=items(\data)}
80
\integer{cnt=items(\data)}
83
\integer{Nat_cnt=items(\Nature)}
81
\integer{Nat_cnt=items(\Nature)}
Line 115... Line 113...
115
}
113
}
116
\integer{question_cnt=items(\question)}
114
\integer{question_cnt=items(\question)}
117
\steps{\Step}
115
\steps{\Step}
118
 
116
 
119
\statement{\instruction
117
\statement{\instruction
120
<div class="question">\phrase.</div>
118
<div class="question">\phrase</div>
121
<table class="wimsnoborder">
119
<table class="wimsnoborder">
122
\for{ s = 1 to \question_cnt}{
120
\for{ s = 1 to \question_cnt}{
123
  <tr><th>\nom_question[\s]</th><td>\embed{\Step[\s],80 x 30 x \cnt}</td></tr>
121
  <tr><th>\nom_question[\s]</th><td>\embed{\Step[\s],80 x 30 x \cnt}</td></tr>
124
}
122
}
125
</table>
123
</table>