Skip to content

Commit 89b6110

Browse files
committed
added code docs to README.md
1 parent 3b06980 commit 89b6110

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

src/kbnlp/README.txt

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,4 +19,20 @@ $ sbcl
1919
* (defun test123 () (print (kbnlp:make-text-object "President Bill Clinton ran for president of the USA")))
2020
* (sb-ext:save-lisp-and-die "kbnlptest" :toplevel #'test123 :executable t)
2121

22+
## Function Documentation
2223

24+
### make-text-object (words &key (url "") (title ""))
25+
26+
This is the main entry point for the NLP library. It takes a string of words (or a list of words) and returns a `text` object. The `text` object contains the original text, part-of-speech tags, human names, place names, company names, category tags, and a summary.
27+
28+
### find-names-places (txt-object)
29+
30+
This function finds human and place names in a `text` object. It returns a list of two lists: the first list contains human names, and the second list contains place names.
31+
32+
### summarize (txt-obj)
33+
34+
This function generates a summary of the text in a `text` object. It ranks sentences based on word frequency and returns the most important ones.
35+
36+
### get-word-list-category (words)
37+
38+
This function assigns category tags to a list of words. It returns a list of categories with their scores.

0 commit comments

Comments
 (0)