Wolfram Function Repository
Instant-use add-on functions for the Wolfram Language
Function Repository Resource:
Generate a set of questions from the given sentence
ResourceFunction["GenerateQuestionsFromSentence"][string] attempts to create quiz-type questions from the information present in string. |
Generate questions from a sentence:
In[1]:= |
|
Out[1]= |
|
See the first question in textual format:
In[2]:= |
|
Out[2]= |
|
List at most 2 questions:
In[3]:= |
|
Out[3]= |
|
Number of questions generated can be bounded:
In[4]:= |
|
Out[4]= |
|
Though the function can take in multiple sentences, extracting sentences using TextCases would give better (and shorter) questions:
In[5]:= |
|
In[6]:= |
|
Out[6]= |
|
In[7]:= |
|
Out[7]= |
|
The function might fail to find questions due to absence of any entities, dates, quantities and other content-related elements:
In[8]:= |
|
Out[8]= |
|
TextContents does not find any elements:
In[9]:= |
|
Out[9]= |
|
This work is licensed under a Creative Commons Attribution 4.0 International License