Integrate images in Google Slides at scale

Dear all,

I am setting up a workflow, to create a Google Slides presentation with replicable content. Here is how far I got:

  1. I generate all the relevant content with GPT
  2. I generate an image with DALL-E
  3. I have creates a template file and I am able to create new slides, map them and add text content at scale to the presentation, thanks to this guide: Google Slides - How to use "Create a Slide from a Template Slide"? - #5 by RobertAndrews
  4. However, I am struggling to integrate an image in every slide. And this is, where I am seeking help.

There are two ways to solve this.

a) Replace a text-field with a tag (e.g. {{image}}) with an image.
I have tried several ways (e.g. these: Insert Images and URL links in Google Slides - #2 by Benjamin_from_Make) but in the end I always run in an error that ‘text’ is expected as input, but since I am using the ‘Upload image to presentation’ module for Google Slides, that’s nothing I can manage.

b) Replace a image placeholder with an image.
I have tried many different ways (e.g. as described here: Upload an image by replacing an image google slides - #4 by Nicolas_Leblanc) but I am struggling with identifying the right image-placeholder object ID (at scale, so I can map it and it works with a new slide in the next run of the sequence) or the object I select is “of wrong type”. I am only able doing that with the first slide of a presentation but that’s not feasible for me.

I would be happy with any of both ways working at scale, after 4 hours without a solution I am seeking for help. To be clear once again: I am generating text and image in the same sequence and I need everything created before on one slide and once the sequence is running again, everything again on a new slide.

Does anyone know how I can achieve this?

Thanks!

You might need to upload the image to Google Drive and then take it from Google Drive to insert it into your Slides.

L

The field should be the publicly accessible URL for the image:

Hello!

I did a few tests and I see it’s complex to have it working. For the method I proposed, the image is always represented by its URL and thus has to always be accessible (shared with anyone with the link).
With “Upload an Image to a Presentation”, it makes a local copy of the file, making it not necessary to keep the original accessible.

What I noticed about the second option:

  • the image has to be accessible anonymously. When I tried with my Make Google account, it was impossible to have it work, since files can’t be shared outside of colleagues. When I tried with my personal gmail account, it worked.
  • don’t forget to add the tag you want to replace (without {{}} )
  • image has to be png, jpg or gif; it won’t work with any other format
  • image has to be less than 50Mb

If ever it still doesn’t work, can you please share the configuration of your module?

Benjamin

Hello!

@L_Duperval: I think that is not the issue. I am able to directly integrate images to the slides but only once or always on the first slide. My issue is to replace a text or image placeholder with the image.

@Anonymax It is public available with the DALL-E generated URL.

@Benjamin_from_Make: Thanking for looking into this. Let me explain further:

Test-Slide 1 with image placeholder:
Google Slide Template looks like this:

My sequence looks like this:

1. Module 11: Create a slide


→ A new slide is created and placeholders are filled with content in an Excel. Works well.

2. Module 10: Get a presentation: The updated version of the presentation is loaded (because a new slide was added).

3. Module 17: Get a page: Loading the last generated slide to access it via the module 11.

However, I am struggling with accessing the right image placeholder. As you can see below I am trying to access it via the Object-ID from the “Get a slide”-Module #17.

I simply want the image placeholder to be replaced with the image, via the URL that is shared below. This sequence outputs this error:

If you could simply help me to identify the right slide and object on the slide, this might already be the solution.

Option 2 with text tag below.

Test-Slide 2 with text placeholder:
Google Slide Template looks like this:

I am using the function like this:

This creates the following error:

In this scenario, I am unable to provide the image in the right format to replace a text-placeholder. If there is a way to do that, that would be great.

I am happy with a solution to either option 1 or 2. Any help highly appreciated :slight_smile:

Hello,

I will let the others to answer as well. But I would go to option 2 where everything is done internally (you won’t need to parse the doc).

Can you double check the Idea_Image that you map to the tag name? Make sure it has a value.

Benjamin

Hi @Benjamin_from_Make, I am not fully sure whether I understand what you mean. However, there was one mistake in the last screenshot:

Bildschirmfoto 2024-10-01 um 08.51.48

I accidentally added {{}} to the tag. Without those it works, but images are not added to the slide that was created by Module 11. Images are replaced on a new last slide in the presentation. I am still struggling here to identify the right place to add the image.

You should make sure the tag on the slide you want to replace content on is unique across the whole presentation. That will work better than focusing slide by slide. For example, {{Idea_Image}} should only appear once in the whole presentation, or if it’s used more than once, change it to something else.

The module that replaces the image tag with an image doesn’t really care about picking a slide or any changes you make to the presentation before it’s called. It’ll just do a search across all slides on that presentation ID, and replace the tag with the image.

Yes, the coloring of this tag was strange, and that explains why you had the error message from Google.

For your issue, “Upload an Image to a presentation” expect only an ID from a presentation, and won’t allow you to select the ID of a specific slide. Is it possible to give a unique name to the tag you want to replace? If “Idea_Image” appears only once in your generated document, you should be able to replace it with the image. You just need to map to ID of the presentation that was modified. You will normally not need to use Get a Presentation, etc.

Sorry if I misunderstood; just cheking:

  • You have a slideware that you want to make evolve (MAIN_ID)
  • In this document, you add a new slide from a Slide template, and fill the values with columns from a XLS doc
  • then, from this slideware, you have this new slide, that still has a tag {{idea_image}}
  • You want now to add the image generated via Dall-E to this new generated slide.
    If I got it right, you should be able to upload the image mapping MAIN_ID in “Upload an Image to a presentation”.

Kind regards,

benjamin

Thanks for the feedback guys and the input, that the image-tag must be unique. I came up with a solution and would like to share it. It’s quite complex but it works. If anybody finds an easier solution in the future, feel free to let me know :slight_smile:

  1. With every GPT run I create a random unique 8-digit ID and save it to my Excel file
  2. Using the “CONCATENATE” formula in Excel, I created one input_image_tag and one output_image_tag. See screenshot from Excel:

  1. Column I adds the ID behind my needed “Idea_Image_” tag without {{brackets}}.
  2. Column L does the same but adds {{brackets}}. (Concatenate from J, K and A (which is not in the screenshot but the ID).
  3. In module 11 (see sequence screenshots above) I write the value of column L to my Google Slide so I receive a unique placeholder. It is necessary to do this with the {{brackets}} because we need them in the placeholder on the slide.
  4. In module 13 where I add the image, I look up for the value from column I without the {{brackets}} because they are already part of the module.

Bildschirmfoto 2024-10-01 um 13.18.55

I hope that solutions helps anyone else as well in the future. I just made associates in consulting firms useless. Thank me later :smiley:

4 Likes