Comments (2)
I think this should do the trick:
{
'queries': [
['This is document 1', 'document 1', 8],
['This is document 2', '2', 17],
....
]
}
The relevant part of the api is here - you could probably refactor this to be less awful if you wanted! Basically ctxts
, ans
, ans_pos
are all lists of documents, answers, and answer character offsets.
from question-generation.
perfect thanks, to anyone else looking for a quick minimal code
import requests
data = {"queries": [
["The Normans were the people who in the 10th and 11th centuries gave their name to Normandy, a region in France.", "Normans", 4],
]}
r = requests.post("http://<IP>:5004/api/generate_batch", json=data)
print(r.json())
>>> {'status': 'OK', 'results': [{'q': "what were the people who 's name to normandy ? </Sent>", 'a': 'Normans'}]}
from question-generation.
Related Issues (20)
- Unable to use tensorflow_hub HOT 4
- Does this support parallel execution ? HOT 18
- Fine-tuning the hyperparameters HOT 2
- Unable to find the Discriminator Instance & the saved disc_path HOT 3
- Replicate the RL paper parameters and to run HOT 4
- Debugging the code in VSC
- Do you have a graph_def file for the models ? HOT 4
- Can i train the model with my own data ?
- What is the model trained on ? HOT 4
- How do i get the .ckpt file for the model ? HOT 4
- Input shape for the tensors HOT 3
- Answer selection for question gneration HOT 1
- TypeError : Nonetype object not iterable HOT 3
- List Index Out of Range HOT 1
- how disable qa, lm and discriminator rewards? HOT 16
- Model dropping out the Phrase/words while generating the questions HOT 3
- What does the below hyperparameters indicates? HOT 2
- What is the RL-S2S-1544356761.zip model trained on? HOT 1
- Which tokenizer does this model use? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from question-generation.