Optimize Scenario from parse to Google Sheets

Hello!

I have a portion of my automation running. I am looking to optimize it to consume less credits. It is for lead enrichment for lead generation.

Currently it does the following:
-searches a row to find the data
-uses perplexity to classify the industry and if it fits the industry I am looking for

  • json parse tool to parse the two answers from perplexity
  • updates the row one by one with information

Would it be possible to do a bulk upload to sheets? Can it parse them all at once? Open to suggestions to cut down on the actions since I will be processing thousands of leads.

@Taylor_P, You can use a text aggregator just after perplexity to accumulate a big text to after generate an array of json objects. then parse whole text as one big json object with answers being in an array. With google sheet module (bulk advanced), you can directly input an array object and it pastes a 2D array your designated range.

Sooo for text aggregator this should work :

if( sheetBundlePosition = 1; { answers : [;emptystring)[perplexityOutput]if(sheetbundleposition!=sheetbundleamount;,;]}

And just parse the text aggregator. might need to work on perplexity output and some json syntax. Ask chatgpt to correct the syntax, shouldn’t be too hard. in the end, you’ll need to parse json from this text aggregate and get an ARRAY object. just one with all the rows and columns.

Let me know if you have some blockers

Ok I do not have any experience doing that unfortunately :sweat_smile:

This is the current outputs I have from Perplexity and how its being parsed. Is it possible for me to share the scenario and make a quick loom of what you mean?


@Taylor_P, Yeah, post your exported blueprint. It’s just 1 module to be added. This way you’ll consume 1 + 18 + 1 + 1 operations instead of 1 + 18 + 18 + 18. Perplexity wouldn’t be a problem either if it accepted long inputs. I believe it’s limited to like 50 words or something ? And output also. It can probably be optimized later too (go with batches of 10 rows per perplexity prompt at a time for example).

@kudracha Here it is. Perplexity can take long prompts which you can see from what I have been using, so maybe it can be done multiple at at time?
Apollo Scrape Blueprint (1).json (81.0 KB)

Welcome to the Make community!

Try using the Google Sheets “Bulk Update Rows (Advanced)” module:

Updates multiple rows.

For more information, see https://www.make.com/en/integrations/google-sheets, and https://www.make.com/en/help/app/google-sheets in the help centre.

Hope this helps! Let me know if there are any further questions or issues.

@samliew

P.S.: Investing some effort into the Make Academy will save you lots of time and frustration using Make.

To be honest, not much help at all since I dont’ have a technical background. It does not have an example of what it needs to look like

@Taylor_P, I modified your scenario, mainly added text aggregator with correct parameters, referenced the output in parse json. Might need to tweak prompt response and reference correct cells in add row (should be ok i think).

optimize parse aggreg 1.json (83.4 KB)
Apollo Scrape Blueprint (1).json (81.0 KB)

@kudracha i used your template and it gave these errors. Looks like some text is added that makes it not valid JSON


@Taylor_P, sorry the emptystring has to be native make function. The pink thing.

You can also type the special variables within {{ }} brackets, like this:

{{emptystring}}

{{newline}}

etc…

Or you could create keyboard shortcuts to quickly insert them.

Hope this helps! Let me know if there are any further questions or issues.

@samliew

P.S.: Investing some effort into the Make Academy will save you lots of time and frustration using Make.

@kudracha I got that fixed, but then i modified it to pull previous values from the google sheet so I could reference them. Everything works, except it doesn’t like using the row variable i pulled in the final google sheet update a row. I am so close! Just need it to accept the row variable, but its not playing nice.



Your JSON is incorrect, try removing these curly brackets in the middle, otherwise you are creating a new “answer” item:

If you need further assistance, please provide the following:

  • Screenshot of module [58]

Hope this helps! Let me know if there are any further questions or issues.

@samliew

P.S.: Investing some effort into the Make Academy will save you lots of time and frustration using Make.