You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A Julia package for using Princeton's [WordNet](https://wordnet.princeton.edu/)®, heavily inspired by [Douches](https://github.com/doches)' [rwordnet](https://github.com/doches/rwordnet).
7
+
A Julia package for using Princeton's [WordNet](https://wordnet.princeton.edu/)®, heavily inspired by [Doches](https://github.com/doches)' [rwordnet](https://github.com/doches/rwordnet).
8
8
9
9
## Simple Demo
10
10
@@ -22,34 +22,34 @@ lemma = db['a', "glad"]
22
22
```julia
23
23
ss =synsets(db, lemma)
24
24
```
25
-
> 4-element Array{WordNet.Synset,1}:
26
-
> (a) glad (showing or causing joy and pleasure; especially made happy; "glad you are here"; "glad that they succeeded"; "gave a glad shout"; "a glad smile"; "heard the glad news"; "a glad occasion")
27
-
> (s) happy, glad (eagerly disposed to act or to be of service; "glad to help")
28
-
> (s) glad (feeling happy appreciation; "glad of the fire's warmth")
29
-
> (s) glad, beaming (cheerful and bright; "a beaming smile"; "a glad May morning")
25
+
> 4-element Array{WordNet.Synset,1}:
26
+
> (a) glad (showing or causing joy and pleasure; especially made happy; "glad you are here"; "glad that they succeeded"; "gave a glad shout"; "a glad smile"; "heard the glad news"; "a glad occasion")
27
+
> (s) happy, glad (eagerly disposed to act or to be of service; "glad to help")
28
+
> (s) glad (feeling happy appreciation; "glad of the fire's warmth")
29
+
> (s) glad, beaming (cheerful and bright; "a beaming smile"; "a glad May morning")
30
30
31
31
```julia
32
32
antonyms(db, ss[1])
33
33
```
34
-
> 1-element Array{WordNet.Synset,1}:
34
+
> 1-element Array{WordNet.Synset,1}:
35
35
> (a) sad (experiencing or showing sorrow or unhappiness; "feeling sad because his dog had died"; "Better by far that you should forget and smile / Than that you should remember and be sad"- Christina Rossetti)
> (n) canine, canid (any of various fissiped mammals with nonretractile claws and typically long muzzles)
42
-
> (n) carnivore (a terrestrial or aquatic flesh-eating mammal; "terrestrial carnivores have four or five clawed digits on each limb")
43
-
> (n) eutherian mammal, placental, placental mammal, eutherian (mammals having a placenta; all mammals except monotremes and marsupials)
44
-
> (n) mammalian, mammal (any warm-blooded vertebrate having the skin more or less covered with hair; young are born alive except for the small subclass of monotremes and nourished with milk)
45
-
> (n) vertebrate, craniate (animals having a bony or cartilaginous skeleton with a segmented spinal column and a large brain enclosed in a skull or cranium)
46
-
> (n) chordate (any animal of the phylum Chordata having a notochord or spinal column)
47
-
> (n) animal, creature, animate being, brute, beast, fauna (a living organism characterized by voluntary movement)
48
-
> (n) organism, being (a living thing that has (or can develop) the ability to act or function independently)
49
-
> (n) living thing, animate thing (a living (or once living) entity)
50
-
> (n) unit, whole (an assemblage of parts that is regarded as a single entity; "how big is that part compared to the whole?"; "the team is a unit")
51
-
> (n) physical object, object (a tangible and visible entity; an entity that can cast a shadow; "it was full of rackets, balls and other objects")
52
-
> (n) physical entity (an entity that has physical existence)
40
+
> 13-element Array{WordNet.Synset,1}:
41
+
> (n) canine, canid (any of various fissiped mammals with nonretractile claws and typically long muzzles)
42
+
> (n) carnivore (a terrestrial or aquatic flesh-eating mammal; "terrestrial carnivores have four or five clawed digits on each limb")
43
+
> (n) eutherian mammal, placental, placental mammal, eutherian (mammals having a placenta; all mammals except monotremes and marsupials)
44
+
> (n) mammalian, mammal (any warm-blooded vertebrate having the skin more or less covered with hair; young are born alive except for the small subclass of monotremes and nourished with milk)
45
+
> (n) vertebrate, craniate (animals having a bony or cartilaginous skeleton with a segmented spinal column and a large brain enclosed in a skull or cranium)
46
+
> (n) chordate (any animal of the phylum Chordata having a notochord or spinal column)
47
+
> (n) animal, creature, animate being, brute, beast, fauna (a living organism characterized by voluntary movement)
48
+
> (n) organism, being (a living thing that has (or can develop) the ability to act or function independently)
49
+
> (n) living thing, animate thing (a living (or once living) entity)
50
+
> (n) unit, whole (an assemblage of parts that is regarded as a single entity; "how big is that part compared to the whole?"; "the team is a unit")
51
+
> (n) physical object, object (a tangible and visible entity; an entity that can cast a shadow; "it was full of rackets, balls and other objects")
52
+
> (n) physical entity (an entity that has physical existence)
53
53
> (n) entity (that which is perceived or known or inferred to have its own distinct existence (living or nonliving))
54
54
55
55
```julia
@@ -72,7 +72,7 @@ sensekeys(db, db['n', "cat"])
72
72
73
73
74
74
## Design consideration
75
-
This package loads all of WordNet into memory. It's not terribly expensive, but it may not be suitable for all developers.
75
+
This package loads all of WordNet into memory. It's not terribly expensive, but it may not be suitable for all developers.
76
76
77
77
## Wordnet Data
78
78
The constructor `DB` can optionally take a path to a WordNet directory, containing a `dict` folder.
@@ -81,5 +81,5 @@ If you do not specify such a path, WordNet 3.0 will automatically be downloaded
81
81
It will only be downloaded once.
82
82
See [DataDeps.jl's readme for more information](https://github.com/oxinabox/DataDeps.jl).
83
83
84
-
> George A. Miller (1995). WordNet: A Lexical Database for English.
85
-
> Communications of the ACM Vol. 38, No. 11: 39-41.
84
+
> George A. Miller (1995). WordNet: A Lexical Database for English.
85
+
> Communications of the ACM Vol. 38, No. 11: 39-41.
0 commit comments