text updated
Browse files15 unmodified lines16171819202122232415 unmodified lines@app.get("/generate")def generate(text: str):"""Using the text2text-generation pipeline from `transformers`, generate textfrom the given input text. The model used is `google/flan-t5-small`, whichcan be found [here](<https://huggingface.co/google/flan-t5-small>)."""# Use the pipeline to generate text from the given input textoutput = summarizer(conversation)15 unmodified lines16171819202122232415 unmodified lines@app.get("/generate")def generate(text: str):"""Using the text2text-generation pipeline from `transformers`, summerize textfrom the given input text. The model used is `philschmid/bart-large-cnn-samsum`, whichcan be found [here](<https://huggingface.co/philschmid/bart-large-cnn-samsum>)."""# Use the pipeline to generate text from the given input textoutput = summarizer(conversation)
app.py+3-3