2006-06-17 01:03:56 -04:00
IN: help
USING: namespaces ;
2006-08-16 21:55:53 -04:00
HELP: ignored-word?
2006-06-17 01:03:56 -04:00
{ $values { "string" "a string" } } { $description "Tests for English stop words." } ;
2006-08-16 21:55:53 -04:00
HELP: tokenize
2006-06-17 01:03:56 -04:00
{ $values { "string" "a string" } { "seq" "a sequence of strings" } }
2006-06-17 02:10:28 -04:00
{ $description "Split a string along whitespace boundaries, convert all tokens to lower case, stem all tokens, and discards one-letter words and stop words." } ;
2006-06-17 01:03:56 -04:00
2006-08-16 21:55:53 -04:00
HELP: index-text
2006-06-17 01:18:46 -04:00
{ $values { "topic" "a help article name or a word" } { "string" "a string" } }
{ $description "Tokenizes the string and adds each token to the term index." }
2006-06-17 01:03:56 -04:00
{ $notes "This word operates on the current namespace, and so must be wrapped in a " { $link bind } " to specify the term index hashtable." } ;
2006-08-16 21:55:53 -04:00
HELP: index-article
2006-06-17 01:03:56 -04:00
{ $values { "topic" "a help article name or a word" } }
2006-06-17 01:18:46 -04:00
{ $description "Adds the tokens making up the article to the term index." } ;
2006-06-17 01:03:56 -04:00
2006-08-16 21:55:53 -04:00
HELP: term-index
{ $var-description "A hashtable mapping stemmed search terms to hashtables mapping help topics to relevancy scores."
2006-06-17 01:03:56 -04:00
$terpri
"The " { $link search-help } " word searches the term index and the " { $link index-help } " word updates it." }
{ $see-also help } ;
2006-08-16 21:55:53 -04:00
HELP: count-occurrences
2006-06-17 01:03:56 -04:00
{ $values { "seq" "a sequence of hashtables" } { "hash" "a hashtable" } }
{ $description "Collates all keys from the hashtables in " { $snippet "seq" } " and sums their values, which must be numbers." } ;
2006-08-16 21:55:53 -04:00
HELP: search-help
2006-06-17 01:03:56 -04:00
{ $values { "phrase" "a string" } { "assoc" "a sequence of pairs" } }
{ $description "Performs a full-text search in the term index for help topics relating to " { $snippet "phrase" } ". The result is an association list of topic names paired with scores, sorted by decreasing score." } ;
2006-08-16 21:55:53 -04:00
HELP: index-help
2006-10-06 17:07:13 -04:00
{ $description "Updates the full-text search term index for use by " { $link search-help. } " and " { $link search-help } "." } ;
2006-06-17 01:03:56 -04:00
2006-08-16 21:55:53 -04:00
HELP: search-help.
2006-06-17 01:03:56 -04:00
{ $values { "phrase" "a string" } }
{ $description "Performs a full-text search in the term index for help topics relating to " { $snippet "phrase" } ", and prints an outliner with the results." } ;