Crystal Skull (0)

Download OpenAPI specification:Download

Generates an entire quiz in English with just a topic name, or even nothing at all for a random one. You can also generate a quiz off of text you supply.

You can view the documentation for previous versions here.

search

searchTopics

Searches for topics to generate a quiz on.

query Parameters
query
required
string (TopicQuery)
Example: query=appl

Topics to search for

Responses

200

Topic names and descriptions

get /search

You'll have to set up the server yourself.

http://localhost:80/search

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "topics":
    [
    ]
}

searchTrendingTopics

Searches for topics trending locally and internationally in the last day to generate a quiz on.

Search results are returned from Wikipedia. It has been found that for random long periods of time, zero search results are returned regardless of the input. Only this endpoint is affected (i.e., other searches work fine).

query Parameters
max
number (TrendingTopic)
Default: 5
Example: max=3

Maximum number of topics to retrieve

Responses

200

Topic names and descriptions

get /search_trending

You'll have to set up the server yourself.

http://localhost:80/search_trending

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "topics":
    [
    ]
}

quiz

generateQuiz

Generate a quiz containing fill-in-the-blank questions on a topic or off of the supplied text.

You may send either the "topic" or the "text" key, but not both. If neither of them are provided, a popular topic from the previous day will be chosen (e.g., if the movie Batman released recently, the movie will be taken as the topic). The random topic is taken from Wikipedia's most popular pages the previous day. It has been found that Wikipedia returns zero search results for trending topics for random long periods of time. During such periods, a completely random (i.e., possibly boring and irrelevant) topic will be chosen instead.

Request Body schema: application/json

Configures how the quiz will be generated

topic
string

Generate a quiz for this topic. You must get the topic name by performing an HTTP GET request to the /search endpoint.

text
Array of strings

Generate a quiz off of this text. You can enhance the accuray of the generated questions by splitting the text into its respective subtopics. For example, if the text is on the topic of Bill Gates, you can split it into multiple strings such as for "Early Life", "Career", etc.

max
integer >= 0

The maximum number of questions to return. Quizzes may contain hundreds of questions. If you only need a certain number, specifying a maximum number to send back will reduce the download size.

allow_sans_years
boolean
Default: false

Questions on dates may contain options lacking years (e.g., June 7 instead of June 7, 2000). Since such questions may be unnecessarily difficult and/or irrelevant to a person's study, options lacking years are disallowed by default.

duplicate_answers
boolean
Default: false

This states whether the quiz may include more than one question having the same answer. For example, one question may be Apple Computer Company was founded by Steve Jobs., and another would be Apple purchased NeXT for its NeXTSTEP operating system and to bring Steve Jobs back.. Although both the questions are different (and would have different options), both their answers are Steve Jobs.

duplicate_sentences
boolean
Default: false

This states whether to include multiple questions from the same sentence. Take the sentence Apple was founded by Steve Jobs in April 1976. for example. Two questions may be generated from this, one being Apple was founded by Steve Jobs in April 1976. (where the answer is Steve Jobs), and another might be Apple was founded by Steve Jobs in April 1976. (where the answer is April 1976). Although the questions and answers (and hence, options) are different, they are based on the same sentence. This has the potential of making the quiz slightly boring, or having certain questions too easy since the user already knows the answer to the next duplicate sentence because they have read the rest of the same sentence in a previous question.

Responses

200

Generated quiz

post /quiz

You'll have to set up the server yourself.

http://localhost:80/quiz

Request samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "topic": "Apple Inc."
}

Response samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "quiz":
    [
    ],
  • "metadata":
    {},
  • "related":
    [
    ]
}

status

healthCheck

Check if all systems are operational

Responses

200

All systems are operational

get /health_check

You'll have to set up the server yourself.

http://localhost:80/health_check

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "quiz": true,
  • "nlp": true
}