https://api.imagineville.org/word/random
| Parameter | Required/optional | Description | Valid values | Default |
|---|---|---|---|---|
num |
Optional | Number of results | 1-100 | 5 |
vocab |
Optional | Vocabulary size to draw words from | 1k, 5k, 10k, 20k, 40k, 100k, 500k | 100k |
sort |
Optional | Sorting of result words |
alpha = sort alphabetically A-Z rev-alpha = sort reverse alphabetically Z-A |
(none) |
safe |
Optional | Safe mode, filters obscene words. | on | off |
https://api.imagineville.org/word/random?num=3&vocab=1k&sort=alpha&safe=on
{
"words": [
"amazing",
"news",
"not"
]
}
https://api.imagineville.org/word/predict
| Parameter | Required/optional | Description | Valid values | Default |
|---|---|---|---|---|
left |
Optional | Left text context | One or more words separated by spaces | (none) |
right |
Optional | Right text context | One or more words separated by spaces | (none) |
prefix |
Optional | Prefix of current word | Sequence of one or more characters | (none) |
num |
Optional | Number of results | 1-100 | 5 |
vocab |
Optional | Filter to words in this vocabulary size | 1k, 5k, 10k, 20k, 40k, 100k, 500k | 100k |
sort |
Optional | Sorting of result words |
alpha = sort alphabetically A-Z rev-alpha = sort reverse alphabetically Z-A |
most likely first |
safe |
Optional | Safe mode, filters obscene words. | on | off |
https://api.imagineville.org/word/predict?left=this is a&prefix=t&right=message
{
"words": [
"text",
"test",
"total",
"terrible",
"true"
]
}
https://api.imagineville.org/sentence/likely
| Parameter | Required/optional | Description | Valid values | Default |
|---|---|---|---|---|
text |
Required | Sentence text | Sequence of words separated by spaces | (none) |
num |
Optional | Number of results | 1-100 | 5 |
vocab |
Optional | Filter to words in this vocabulary size | 1k, 5k, 10k, 20k, 40k, 100k, 500k | 100k |
sort |
Optional | Sorting of result words |
alpha = sort alphabetically A-Z rev-alpha = sort reverse alphabetically Z-A |
most likely first |
safe |
Optional | Safe mode, filters obscene words. | on | off |
https://api.imagineville.org/sentence/likely?text=i do not like neon zebras or others animals
{
"words": [
"not",
"i",
"like",
"do",
"or"
]
}
https://api.imagineville.org/sentence/unlikely
| Parameter | Required/optional | Description | Valid values | Default |
|---|---|---|---|---|
text |
Required | Sentence text | Sequence of words separated by spaces | (none) |
num |
Optional | Number of results | 1-100 | 5 |
vocab |
Optional | Filter to words in this vocabulary size | 1k, 5k, 10k, 20k, 40k, 100k, 500k | 100k |
sort |
Optional | Sorting of result words |
alpha = sort alphabetically A-Z rev-alpha = sort reverse alphabetically Z-A |
least likely first |
safe |
Optional | Safe mode, filters obscene words. | on | off |
https://api.imagineville.org/sentence/unlikely?text=i do not like neon zebras or others animals
{
"words": [
"zebras",
"neon",
"animals",
"others",
"or"
]
}
https://api.imagineville.org/sentence/oov
| Parameter | Required/optional | Description | Valid values | Default |
|---|---|---|---|---|
text |
Required | Sentence text | Sequence of words separated by spaces | (none) |
num |
Optional | Number of results | 1-100 | 5 |
vocab |
Optional | Vocabulary used to determine out-of-vocabulary words | 1k, 5k, 10k, 20k, 40k, 100k, 500k | 100k |
sort |
Optional | Sorting of result words |
alpha = sort alphabetically A-Z rev-alpha = sort reverse alphabetically Z-A |
(none) |
safe |
Optional | Safe mode, filters obscene words. | on | off |
https://api.imagineville.org/sentence/oov?vocab=1k&text=it was the epoch of belief it was the epoch of incredulity
{
"words": [
"epoch",
"belief",
"incredulity"
]
}
https://api.imagineville.org/sentence/perplexity
| Parameter | Required/optional | Description | Valid values | Default |
|---|---|---|---|---|
text |
Required | Sentence text | Sequence of words separated by spaces | (none) |
https://api.imagineville.org/sentence/perplexity?text=i like neon zebras
2181.753470691329