barunsaha commited on
Commit
85a7fa9
1 Parent(s): 7bf36e8

Update description

Browse files
Files changed (3) hide show
  1. README.md +6 -4
  2. app.py +2 -3
  3. global_config.py +4 -2
README.md CHANGED
@@ -30,13 +30,14 @@ SlideDeck AI works in the following way:
30
 
31
  1. Given a topic description, it uses Mistral Nemo Instruct to generate the *initial* content of the slides.
32
  The output is generated as structured JSON data based on a pre-defined schema.
33
- 2. Subsequently, it uses the `python-pptx` library to generate the slides,
 
34
  based on the JSON data from the previous step.
35
  A user can choose from a set of three pre-defined presentation templates.
36
- 3. At this stage onward, a user can provide additional instructions to *refine* the content.
37
  For example, one can ask to add another slide or modify an existing slide.
38
  A history of instructions is maintained.
39
- 4. Every time SlideDeck AI generates a PowerPoint presentation, a download button is provided.
40
  Clicking on the button will download the file.
41
 
42
 
@@ -55,7 +56,8 @@ number of allowed characters in the textbox, pasting would not work.
55
  SlideDeck AI uses [Mistral-Nemo-Instruct-2407](https://huggingface.co/mistralai/Mistral-Nemo-Instruct-2407)
56
  via the Hugging Face Inference API.
57
  To run this project by yourself, you need to provide the `HUGGINGFACEHUB_API_TOKEN` API key,
58
- for example, in a `.env` file. Visit the respective websites to obtain the keys.
 
59
 
60
 
61
  # Live Demo
 
30
 
31
  1. Given a topic description, it uses Mistral Nemo Instruct to generate the *initial* content of the slides.
32
  The output is generated as structured JSON data based on a pre-defined schema.
33
+ 2. Next, it uses the keywords from the JSON output to search and download a few images with a certain probability.
34
+ 3. Subsequently, it uses the `python-pptx` library to generate the slides,
35
  based on the JSON data from the previous step.
36
  A user can choose from a set of three pre-defined presentation templates.
37
+ 4. At this stage onward, a user can provide additional instructions to *refine* the content.
38
  For example, one can ask to add another slide or modify an existing slide.
39
  A history of instructions is maintained.
40
+ 5. Every time SlideDeck AI generates a PowerPoint presentation, a download button is provided.
41
  Clicking on the button will download the file.
42
 
43
 
 
56
  SlideDeck AI uses [Mistral-Nemo-Instruct-2407](https://huggingface.co/mistralai/Mistral-Nemo-Instruct-2407)
57
  via the Hugging Face Inference API.
58
  To run this project by yourself, you need to provide the `HUGGINGFACEHUB_API_TOKEN` API key,
59
+ for example, in a `.env` file. For image search, the `PEXEL_API_KEY` should be added.
60
+ Visit the respective websites to obtain the keys.
61
 
62
 
63
  # Live Demo
app.py CHANGED
@@ -12,7 +12,6 @@ from langchain_community.chat_message_histories import (
12
  )
13
  from langchain_core.messages import HumanMessage
14
  from langchain_core.prompts import ChatPromptTemplate
15
- # from transformers import AutoTokenizer
16
 
17
  from global_config import GlobalConfig
18
  from helpers import llm_helper, pptx_helper, text_helper
@@ -123,8 +122,8 @@ def set_up_chat_ui():
123
  with st.expander('Usage Instructions'):
124
  st.markdown(GlobalConfig.CHAT_USAGE_INSTRUCTIONS)
125
  st.markdown(
126
- 'SlideDeck AI is powered by'
127
- ' [Mistral-7B-Instruct-v0.2](https://huggingface.co/mistralai/Mistral-7B-Instruct-v0.2)'
128
  )
129
 
130
  # view_messages = st.expander('View the messages in the session state')
 
12
  )
13
  from langchain_core.messages import HumanMessage
14
  from langchain_core.prompts import ChatPromptTemplate
 
15
 
16
  from global_config import GlobalConfig
17
  from helpers import llm_helper, pptx_helper, text_helper
 
122
  with st.expander('Usage Instructions'):
123
  st.markdown(GlobalConfig.CHAT_USAGE_INSTRUCTIONS)
124
  st.markdown(
125
+ 'SlideDeck AI is powered by' # noqa: E501
126
+ ' [Mistral-Nemo-Instruct-2407](https://huggingface.co/mistralai/Mistral-Nemo-Instruct-2407).'
127
  )
128
 
129
  # view_messages = st.expander('View the messages in the session state')
global_config.py CHANGED
@@ -62,8 +62,10 @@ class GlobalConfig:
62
  ' You can also ask it to refine any particular slide, e.g.:\n'
63
  '- Make the slide with title \'Examples of AI\' a bit more descriptive.'
64
  '\n\n'
65
- 'See this [demo video](https://youtu.be/QvAKzNKtk9k) for a brief walkthrough.'
66
- 'SlideDeck AI does not have access to the Web.'
 
 
67
  '\n\n'
68
  'If you like SlideDeck AI, please consider leaving a heart ❤️ on the'
69
  ' [Hugging Face Space](https://huggingface.co/spaces/barunsaha/slide-deck-ai/) or'
 
62
  ' You can also ask it to refine any particular slide, e.g.:\n'
63
  '- Make the slide with title \'Examples of AI\' a bit more descriptive.'
64
  '\n\n'
65
+ 'See this [demo video](https://youtu.be/QvAKzNKtk9k) for a brief walkthrough.\n\n'
66
+ ' SlideDeck AI does not have access to the Web, apart for searching for images relevant'
67
+ ' to the slides. Photos are added probabilistically; transparency needs to be changed'
68
+ ' manually, if required.'
69
  '\n\n'
70
  'If you like SlideDeck AI, please consider leaving a heart ❤️ on the'
71
  ' [Hugging Face Space](https://huggingface.co/spaces/barunsaha/slide-deck-ai/) or'