projects:mai:algorithms
Differences
This shows you the differences between two versions of the page.
| Next revision | Previous revision | ||
| projects:mai:algorithms [2023/01/12 11:05] – created jhagstrand | projects:mai:algorithms [2023/01/12 11:11] (current) – jhagstrand | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| - | [[projects: | + | [[projects: |
| ====== Algorithms ====== | ====== Algorithms ====== | ||
| Line 11: | Line 11: | ||
| ===== parse string ===== | ===== parse string ===== | ||
| + | Scans a string, separating into dictionary words. | ||
| + | |||
| + | Longest words first. | ||
| + | |||
| + | === ToDo === | ||
| + | |||
| + | repeat symbol ๆ is sometimes missed. | ||
| ===== parse syllable ===== | ===== parse syllable ===== | ||
| + | |||
| + | === ToDo === | ||
| + | |||
| + | * identify rules | ||
| + | * ccredup | ||
| + | * cciva | ||
| + | * ccive (are cciva and ccive the same?) | ||
| + | * cct | ||
| + | * ccf | ||
| + | * test dict | ||
| + | * load test suite from dict pf=true | ||
| ===== leveling ===== | ===== leveling ===== | ||
| + | |||
| + | ==== Recommendation ==== | ||
| + | |||
| + | A typical recommendation engine would choose stories with similar content. | ||
| + | We leave that to the student to judge by reading the story titles. | ||
| + | |||
| + | Leveling is one of the tools we use. | ||
| + | |||
| + | student: vocabulary size, average level \\ | ||
| + | each story: average level, number of mastered words, number of new words, ratio, total number of words | ||
| + | |||
| + | find stories with words that the student should know by now to be at this level. | ||
| + | |||
| + | |||
| + | Goal. Introduce vocabulary to the student gradually, more common words first, more advanced words later. \\ | ||
| + | Always reinforcing and building upon what the student already knows. | ||
| + | |||
| + | totally wrong. | ||
| + | |||
| + | leveling is a vague way of sorting stories and words and students and choosing what to offer to the student next. | ||
| + | |||
| + | the level of a student can be used to as motivational, | ||
| + | |||
| + | controlled vocabulary. | ||
| + | |||
| + | |||
| + | The goal of leveling is to recommend appropriate stories to a student depending on his vocabulary. | ||
| + | |||
| + | The " | ||
| + | A lower level indicates a more common word. \\ | ||
| + | A higher level is more advanced, rarely-used word. | ||
| + | |||
| + | The level of a story is the weighted average of the levels of all the words used in the story. | ||
| + | |||
| + | The levels of words and stories are re-calculated on the server once each day. | ||
| + | |||
| + | The level of a student is the average level of all the mastered words in his vocabulary. | ||
| + | |||
| + | ==== Calculate level of all words in the dictionary ==== | ||
| + | |||
| + | - Make the mean-table in memory with an entry for every word/mean in the dictionary. | ||
| + | - Read all the stories. | ||
| + | * open the consolidated words field into an array | ||
| + | * (the number of loc items in the array is the use-count for that word/mean) | ||
| + | * add the use-count to the new-count in the master word table | ||
| + | - Loop thru the mean table saving lowest and highest use-count. | ||
| + | - Loop thru the mean table again. | ||
| + | * calculate and set the level for the mean, by interpolating an index from 1 to 100 as follows: | ||
| + | * level = 100 - (use-count * (high-low)/ | ||
| + | * max/min : 1/100 | ||
| + | * freq/ | ||
| + | * 100 * (freq/ | ||
| + | * level + (100 * (freq/ | ||
| + | * level = 100 - (100 * (freq/ | ||
| + | * Update mean table record setting count and level if changed. | ||
| + | |||
| + | ==== Calculate level of all stories ==== | ||
| + | |||
| + | - Read all stories. | ||
| + | * open the consolidated words field into an array | ||
| + | * get the level of each word from the dictionary | ||
| + | * save total-use-count | ||
| + | * save total-level as level*use-count | ||
| + | - Calculate average-level. | ||
| + | * average-level = total-level / total-use-count | ||
| + | * update the story record, setting level | ||
| + | |||
| + | |||
| + | For each story | ||
| + | * Num words | ||
| + | * Num uniques | ||
| + | * Avg level | ||
| + | |||
| + | For each story per student | ||
| + | * Num mastered | ||
| + | * Num new words | ||
| + | * Num working | ||
| + | * % new / uniques | ||
| + | |||
| + | Calc avg level for each user | ||
| + | |||
| + | New table, story-user | ||
| + | |||
| ===== loggen ===== | ===== loggen ===== | ||
| + | |||
| + | Curiosity, exploration, | ||
| + | |||
| + | * Name | ||
| + | * Age | ||
| + | * Sex | ||
| + | * Associates - | ||
| + | * IQ | ||
| + | * Education | ||
| + | * Job | ||
| + | |||
| + | * Hobbies | ||
| + | * Countries visited | ||
| + | * Books read | ||
| + | * Authors favorite | ||
| + | * Movies favorite, recent | ||
| + | * Movie stars favorite | ||
| + | |||
| + | * Wealth | ||
| + | * Income | ||
| + | * Bank accounts | ||
| + | |||
| + | Links to proper names | ||
| + | |||
| + | Sleep period to organize data | ||
| + | |||
| + | Blockages to action, like denying sex or flying a helicopter. | ||
projects/mai/algorithms.1673539535.txt.gz · Last modified: 2023/01/12 11:05 by jhagstrand