Auto generating pptx from json format file(include prompt) using gpt3.5-turbo model.
- Python version > 3.6
- python-pptx
- openai
First install requirment packages:
pip3 install -r requirements.txt
Run the following command in your terminal, replacing yourkey with your API key.
echo "export OPENAI_API_KEY='yourkey'" >> ~/.bashrc
python app.py
positional arguments:
options: [input_file] path/to/input_json_file.
optional arguments:
-o, --outputFile destination for output pptx.
-m, --maximum maximum words generated by LLM.
For inserting slide or content conviently, annotation can be used in .json file.
@title
Add new slide and set title for page.@prompt
insert prompt into content, format:Topic:@prompt
Raw json file:
Generated pptx: