---
title: "Create a meta review site"
video_id: S5DLMvlzx5E
url: https://www.youtube.com/watch?v=S5DLMvlzx5E
workflow_page: https://workflows-of-ai.com/workflow/create-meta-review-site
language: en
captions: generated
---

0:00 hey there Marcus here um today we're
0:02 going to do a little bit more complex
0:04 workflow than usual so what we're going
0:07 to do is we're going to try to recreate
0:09 Metacritic and how how it works but
0:11 we're just going to use druple nii to do
0:14 it very
0:16 quickly uh first of all I'm I'm just
0:19 going to create the data structure and
0:21 how to fill the data in this case so I'm
0:23 not going to show you how to style it
0:25 how to create the views and so on uh the
0:28 loog logic for aggre ating values
0:31 together you can use views agregate for
0:33 that and so on I'm not going to show
0:34 that part there's a lot of videos
0:37 showing how Drupal Works in general so
0:40 you can look at those uh for this use
0:43 case I'm just going to show you how you
0:44 can use Drupal to
0:46 basically uh fill all the data that you
0:49 need so for people that don't know
0:51 Metacritic it's a awesome website for
0:54 basically figuring out if a game is good
0:57 or great or worthless and so on
1:00 uh same for movies TV show music and I
1:03 don't know they might have other stuff
1:04 as well that's not here in the menu so
1:06 how it works is compared to a normal
1:10 reviewing website it Aggregates all the
1:13 reviews and normalizes so if if one
1:17 review site might have one to five as
1:19 the rating and another might not even
1:21 have actual numeric rating they kind of
1:24 normalized that to 0 to 100 and then uh
1:29 as a aage of those so you can figure out
1:31 if something is really great depend uh
1:35 depending on a lot of reviews and not
1:37 just one single reviewer right um and
1:41 this of course means if something gets
1:43 like close to 100 I think Salk Arena
1:45 time has 100 for instance which makes
1:47 sense it's one of the greatest games
1:49 ever right that means it's awesome uh
1:53 while if something has a low rating or a
1:57 average rating it might have been that
1:59 one reviewer gave it a very good rating
2:01 but the others didn't
2:04 right um and for this workflow we're
2:07 going to use um well I will say first of
2:11 all so I said Drupal in the beginning
2:13 we're going to build this in Drupal
2:15 using the AI interpolator that's what
2:17 all my videos are about if you don't
2:18 know drol aw some CMS cmf uh it gets you
2:22 started very quickly to set up a website
2:25 especially data heavy website uh data
2:28 structure heavy website
2:31 uh it's open source it's free you
2:33 anything I show you you can just start
2:35 doing after I showed it and you can set
2:37 up a copy of exactly what I do so the
2:40 modules we're going to do uh use sorry
2:43 and that I already installed is then the
2:45 AI inator open AI uh so we're going to
2:48 use that basically to
2:51 um get a summarization of uh oh I forgot
2:55 to say what I'm going to do I'm not
2:56 going to do this on games and so on I
2:58 have some uh Berlin restaurants here
3:01 that I'm going to do it on so uh say
3:03 that I want to create Metacritic for but
3:05 for restaurants in this case right so
3:07 we're going to use it to summarize uh a
3:09 short couple of sentences about the
3:13 restaurant uh then uh yeah what it's
3:17 also going to do what's more important
3:18 then it's going to normalize the rating
3:20 so do semantic
3:22 analysis uh we're going to use AI
3:24 interpolator Ser so that creates search
3:27 results from a search word um
3:30 in this case uh what it's going to do
3:32 it's just going to create a search uh
3:35 result uh for the general search term so
3:39 I can create a summary uh like I was
3:42 talking about without actually having to
3:45 copy and paste or write something myself
3:48 then we're going to use scraping bot
3:49 scraping bot is for scraping websites uh
3:52 what's unique with scraping bot compared
3:55 to using curl or guzzle or something uh
3:58 is that it's can run headless so it it
4:02 or sorry it can run a browser that can
4:04 run against headless websites which
4:06 means that a website that requires
4:08 JavaScript so if it's written on react
4:10 or angular or something it can actually
4:13 render this so there is a simple crawler
4:15 if you don't want to pay scraping butt
4:17 but that um it has advantages because it
4:20 can run locally and it's a lot faster of
4:22 course but it also has a lot of uh or
4:26 has this big disadvantage that it's not
4:28 an actual browser and you can't run it
4:30 from different countries and so on
4:32 unless you set up Proxes
4:35 yourself uh the last one is a inor
4:38 screenshot so we're going to take a
4:39 screenshot also of the websites we
4:42 review and this could be good for uh
4:45 proving that they actually wrote what
4:47 they did because maybe the article goes
4:49 down maybe they change the article right
4:52 so you have a screenshot of how it
4:54 looked exactly when you did the the
4:57 normalization of the rating
5:00 uh just to Showcase it I'm going to use
5:02 the address module so you don't have to
5:05 type in address for every restaurant
5:07 it's going to find that by itself uh
5:10 there is another uh video where you can
5:13 see how to actually map this on Google
5:15 Maps and so on but in this case we're
5:17 just going to create the address
5:19 structured token module is needed to
5:22 have have token for advanced prompting
5:25 uh
5:26 in in druple I'm not actually sure if
5:30 we're goingon to need that but it's good
5:32 that you're aware of it as well so you
5:34 can do a lot more advanced prompting
5:36 where you can use many fields together
5:39 in a prompt instead of just using one
5:41 field as the
5:44 context so let's get started I'm just
5:47 going to log in then uh so as I said uh
5:52 so this is running locally it's just a
5:54 base druple setup with these
5:56 modules uh I have the admin tool bar
5:59 here to make the toolbar nice as well
6:01 I've also set up all the API keys so
6:03 that you do on the configuration web
6:05 services all the scraping bot Ser
6:07 screenshot one except for open AI
6:09 because it's using the open AI module so
6:11 it's open AI settings to set that
6:13 up um and that's it basically so this is
6:17 the only thing I have done got in the
6:19 modules using
6:21 composer and um then set up the API keys
6:26 so let's get started then so we're going
6:28 to add two different typee of context
6:31 content types in this case we're going
6:32 to use uh we're going to have a content
6:35 type that's the restaurant and that's
6:36 the overall restaurant and then this
6:40 will have different reviews connected to
6:42 it right so we start with the
6:44 restaurants uh rounds and this will have
6:48 a title field that's called
6:51 name wait
6:54 name um and here you there's a lot of
6:58 settings that you
7:00 would normally care about if you were
7:01 setting up the website end to endend how
7:04 to do that in druple there's multiple
7:06 there's thousands of videos on YouTube
7:09 you can search so I remove the body
7:11 field because I'm not going to create
7:12 that General article what I will add
7:15 first is basically uh search field so
7:21 this is going to be a formated text um
7:26 formatted uh oh we have to give it a
7:28 label we call it search word so this is
7:32 basically what we need to search for to
7:34 find it the address and also to find
7:37 some about text
7:39 right uh and we just set the full HTML
7:43 oh sorry I forgot one thing there as
7:45 well I'm going to set this required
7:47 because that's one of two field that you
7:48 will have to fill out and the rest you
7:50 should not really have to fill out so
7:52 the next thing we want to do is uh add a
7:56 address
7:58 field uh sorry I forget this restront
8:02 address so this is going to get filled
8:04 out automatically now so we're going to
8:08 use uh we're going to turn off that we
8:11 need first name middle name last name
8:13 because these are not people instead
8:15 organization name the restaurant name is
8:18 required right and then we're going to
8:19 use enable Ai interpolator and we're
8:21 going to use the rule that's called text
8:23 address finder and this uses base mode
8:26 and it uses the search word and I'm just
8:29 going copy this so basically what this
8:31 is uh saying is from the search word uh
8:35 oh sorry there I copy too much just this
8:40 uh from the search word that is the
8:42 search word that we add find up place in
8:47 um using Google places so that's why we
8:51 add the API key and get the address and
8:53 store it basically uh we're going to use
8:56 batch mode in this case we use GPT 4 so
8:59 batch mode is basically so you can
9:02 see uh the different AI jobs running one
9:06 and after another so if you just have
9:08 one job that's very fast this is not
9:10 required because you can use direct so
9:12 it's just when you click save on the
9:15 saving the entity it's just going to
9:17 happen but you might have time out and
9:19 so on on server so you want to split it
9:21 up into a queue where you see it
9:23 happening right gp4 is just because it's
9:26 better at understanding stuff which is
9:28 important in this
9:30 case um so we do search for
9:33 right um and then we're going to create
9:36 the next field which is going to be uh
9:39 links and this is going to be search
9:42 links so we're going just going to take
9:43 the first three
9:46 uh uh links that we
9:49 find and we're going to scrape those and
9:52 we're going to use that as context to
9:54 create a summary right so we enable AI
9:57 interpolator in this case as well we do
9:59 Ser to link this has a lot of settings
10:03 uh but the most important is what do you
10:06 use as the base field so that's search
10:07 word and what is important uh otherwise
10:12 is of course if you're on a specific
10:13 Market you should maybe not search from
10:16 us or in English so you can set all that
10:19 up but that's not so important in this
10:21 case once again we do uh
10:24 batch set 100 so in this case the weight
10:28 is going to be important because we need
10:29 to do this in three steps basically
10:32 first we need to find the links right uh
10:36 oh there's one thing I forgot there
10:37 search result okay no that's set
10:39 automatically right um so we're going to
10:41 find the links second step is that we're
10:43 going to scrape it third step is we're
10:45 going to use the scrape data to write a
10:48 summary so because of this weight is
10:51 important so the next step is that we're
10:52 going to scrape it right so to do this
10:55 we use formatted text text format long
10:58 and the these are uh basically HTML
11:02 bodies we can call
11:04 it and this is important that we have uh
11:08 at least three I mean I just said
11:10 unlimited now so because there's going
11:12 to be three links uh we have to have as
11:16 many um bodies to scrape from right set
11:20 this to full HTML enable Ai interpolator
11:24 and we're using scraping bot crawler in
11:26 this case base Mode still and we're
11:28 going to use the search link as the uh
11:31 as the base field so that's what we're
11:32 using to scrape we're going to use
11:35 Chrome in this case that's important
11:36 right um that we're using a browser can
11:40 set weight for Network maybe someone set
11:43 it up in react really poorly or so on
11:45 and it takes time before it actually
11:47 renders this of course takes longer to
11:50 run but that's okay in this case what's
11:52 important is that we use uh article
11:54 segmentation as calller mode so you can
11:56 do raw dump to get the whole web website
11:59 but we don't care about the menus and
12:00 stuff you can use HTML selector like
12:03 jQuery to just select a specific part
12:05 but in this case we're using the Firefox
12:08 readability Library so that's the um
12:11 thing in Firefox if you ever went to
12:13 article and you just wanted to see the
12:15 text of the article this can figure it
12:18 out so in this case this has to happen
12:20 after we have the linked right uh and
12:23 we're going to use batch mode again so
12:25 we're using 101 a little bit higher than
12:29 100 so it happens later and then we're
12:32 going to have the last thing which is
12:34 the
12:36 description um and we're going to use
12:40 text format long for this as well and
12:44 this can be
12:45 one uh and we're going to enable so we
12:48 set this to full HTML we're going to
12:50 enable H AI interpolator we're going to
12:52 use the open AI text long in this
12:55 case uh we're going to use bace mode
12:59 and no in this case I think we use token
13:03 actually because we don't want to run
13:05 through them one and one we want all of
13:07 them right so this is the advanced mode
13:10 then so we're going to go to nodes and
13:12 find our uh HTML bodies field and we're
13:16 just going to copy the whole thing oh I
13:19 have to press here first before I copy
13:21 it and this is going to be the context
13:24 then right so this is going to be a um
13:28 this is going to be all the bodies
13:29 together in one Big Blob and then we
13:32 just write here based on the
13:35 following data generate a one
13:41 paragraph
13:42 three sentence uh
13:46 description of the rest restaurant and
13:51 then we're just going to copy the title
13:53 in here because that's the restaurant
13:54 title
13:56 right uh
14:01 uh let's write context actually based on
14:04 the following
14:06 context and then it's going to create
14:08 this right uh for
14:11 this we're going to use turo 16k I think
14:14 to save some money because that's
14:16 usually kind of good at writing small
14:19 descriptions it hopefully has the
14:21 context links that's that you're is
14:23 needed for reading these three articles
14:25 it depends on how long they are of
14:27 course worst case you have to use um
14:30 like gp4 turbo preview for instance
14:33 that's I think is 32k or we can use
14:36 stupid it4 just so I don't get stuck on
14:39 this and it's too I get a warning
14:41 message that the context L stays too
14:42 long right so we're going to set batch
14:45 mode and this has to be 102 because this
14:47 is the last thing that happens right
14:49 then and we're going to save
14:52 this and we can start by trying a
14:55 restaurant now then so I'm going to add
14:56 a restaurant
14:59 uh and what we're going to do is use
15:01 mustafa's Kus Kebab so it's one of the
15:05 most popular derer places in the world
15:10 uh it's for I I think personally a
15:13 little bit overrated but if you're a
15:16 tourist it might make sense to visit it
15:19 if you go to Berlin so you see there's a
15:21 lot of fields here that's just empty I'm
15:23 just not going to fill those out those
15:25 are going to be filled out now then by
15:28 AI so get that description in the end
15:30 and we get the address basically so if I
15:33 click save now you see it's going to
15:35 start working here nicely what I can do
15:38 in a new tab while we're doing this I'm
15:40 just going to set the manage display of
15:42 the restaurant so we don't have to see
15:45 the
15:46 HTML we don't care about the search
15:48 links or the search word not this links
15:51 as well so we're just going to show the
15:53 restaurant address and the description
15:55 on the output of it right
15:59 so this is going to take some time
16:02 now
16:04 um especially finding out the address
16:07 can take some time for
16:10 sure um so now it's finished with the
16:13 first the
16:15 second then the third one is uh should
16:18 be scraping of course uh which will take
16:21 some time because it's actually going to
16:22 the website make sure that they have
16:24 finished rendering scrapes it and stores
16:27 it and then uh last thing now it's going
16:29 to write a description then of one
16:31 paragraph if everything works out as it
16:33 should
16:34 be uh okay so this output was not
16:39 perfect so um what you can do here
16:42 basically is that
16:45 you remove the description here and
16:47 resave then it's going to run this job
16:50 again so this um is one of the reasons
16:55 why it's still in beta I'm trying to uh
16:59 basically get better stability so I'm I
17:01 I'm not going to stop this uh worklow
17:06 here so it is a little bit realistic to
17:09 the current status of it so this could
17:11 happen to you and then you know what you
17:12 can do as
17:14 well
17:16 uh so it got a description it got the
17:21 restaurant address right uh and this I
17:24 know miring them 32 it's the correct
17:26 address so what we're going to do now is
17:29 to create the second thing then which is
17:31 the
17:34 reviews uh
17:37 and yeah what we need to do in this case
17:42 is so because we use content types title
17:46 is required so I I'm just going to keep
17:49 it there we going to have to manually
17:51 fill out something basically so we
17:54 remove the body once again so in this
17:57 case what we basically we need to give
17:59 is a
18:00 link so this is the link that we're
18:03 going to get the review from it just
18:05 needs to be one it's a required field
18:07 because it needs to be filled
18:10 out and then this is going to scrape of
18:13 course so we take um formatted text text
18:18 formatted long and HTML body in this
18:22 case we call it because it's only
18:26 one enable the an
18:28 scraping bot and it's using the
18:31 link same thing as before we use batch
18:35 mode get the art actual article and
18:38 nothing
18:40 else uh and now then we're going to set
18:43 a number on this we're going to set a
18:45 rating so we just set rating so it's
18:48 going to read through uh this re view
18:51 now and set a rating on it right there's
18:54 of course a lot of other stuff we could
18:56 get here that I'm not going to show show
18:58 you using the anle layer so you could
19:00 get the
19:01 title uh of the
19:04 actual uh URL we going to um you could
19:09 get the host name so you
19:11 know which place it is that reviewing it
19:14 so you could group those together so you
19:16 could see a view like what's what's the
19:18 typical review of this web page and so
19:21 on uh but I'm not going to show in this
19:24 case so we're do minimum maximum 0 to
19:28 100
19:29 we're going to use open AI
19:31 integer uh base mode is okay in this
19:33 case we're going to use the a h HTML
19:37 body and what we can do here is we can
19:39 just copy
19:41 this because this is basically the
19:44 example placeholder is pretty okay here
19:46 based on the content text add a
19:47 sentiment rating between Min and Max so
19:50 you can see here Min and Max is the
19:51 numeric value basically uh of the
19:55 minimum that we set here so this is just
19:56 going to be replaced by 0 and 100 where
19:59 zero means really negative sentiment and
20:01 Max means really great sentiment answer
20:03 with a full number and context is then
20:06 this HDM
20:08 body this is of course not a perfect
20:10 prompt because if you want it
20:12 to all respond
20:16 similarly um you need to give a longer
20:20 prompt with a lot more context like
20:23 maybe give some background who this
20:25 person that actually sets the center
20:28 senent is what give examples on what
20:31 good and bad sentiment is in this
20:35 context and so on but I'm not going to
20:36 do that I'm just going to do the
20:37 simplest
20:39 here this case we definitely need gptt 4
20:42 because it's a lot better at semantic uh
20:45 anal analysis we need to set 1001
20:49 because this has to happen after we
20:50 scraped it in this case we can give an
20:53 open AI role as well so you have seen
20:55 this as well you are a an editor of a
21:02 restant meta view website that tries to
21:08 normalize reviews into a rating of 0 to
21:13 100 right so this is this is also
21:17 important to give some background who
21:18 the person is right in this case it's
21:21 important when you write a summary and
21:23 so on is probably not that important
21:25 unless you want it in a specific
21:26 language I can also say open AI
21:28 moderation I made it possible to turn
21:32 this off there's never a reason to turn
21:34 this off what this does is it checks
21:36 against the moderation endpoint that
21:38 open AI has uh beforehand to check that
21:42 what you're going to send is actually
21:43 not against their
21:45 policies uh because what could happen
21:47 when we automate everything so there's
21:49 stuff one after another so take the
21:51 description part right it searches for M
21:54 Mustafa Gus about Berlin but somehow by
21:58 mistake it might
22:01 um find I don't know something about
22:04 that what's happening in Israel right
22:07 now which might write something that
22:11 goes against the policy of what you're
22:13 allowed to prompt into open Ai and if
22:15 you do this often enough you actually
22:17 lose your your uh access to it so just
22:22 keep this on because this will basically
22:23 if that happens their moderation end
22:26 point will say that this is not the you
22:28 will get a warning message in druple
22:29 that this got stuck on the moderation
22:31 queue and you don't get the result
22:34 basically because of
22:36 this I will show as well that I will
22:39 create a image in this
22:42 case um because so it's file upload
22:47 images we want to take a screenshot as
22:49 well so we have a screenshot saved of it
22:52 right um so there's once again a lot of
22:56 CMS settings not Import in our case we
22:59 don't want the alt field we enable the
23:01 AI inator take the rule screenshot one
23:07 image uh and we can say width and height
23:10 here of it uh but in this case we're
23:14 just going to care about width so we can
23:16 take one 1280 is enough we don't have to
23:18 make it bigger but we're going to do
23:20 full
23:21 page uh so this is going to take a full
23:23 page
23:24 screenshot what's cool with screenshot
23:26 one and the reason I'm using using them
23:28 instead of a lot of other services and
23:30 why I create a module for it is that
23:32 they remove the cookie banners which is
23:35 super important because otherwise you
23:37 just get a screenshot of a cookie Banner
23:39 basically it's using the link based
23:41 field in this case we don't have to set
23:44 a wait but we set batch mode
23:46 anyway save it and then we're going to
23:50 be able to create a review as well so
23:53 we're just going to take uh this we have
23:56 to set the title so I just copy this and
23:59 that's basically what we need to fill in
24:01 the rest is going to be filled in
24:03 automatically it's going to set a rating
24:04 it's going to create a screen sh
24:06 right um okay one field I forgot now is
24:10 this has to be connected to the
24:11 restaurant of course so you have to use
24:13 a reference field in druple but once
24:15 again that has nothing to do with the AI
24:17 interpolator that's something you can
24:18 figure out yourself by watching other
24:21 videos how how Drupal Works
24:24 basically uh if we wanted a
24:26 representative image of the restaurant
24:30 as well we could use open AI
24:33 or or dream Studio plugin to create
24:36 stuff as well so now you see it's
24:38 showing the HTML body that's what I
24:40 removed the last time that's not
24:42 something we actually care
24:45 about so I'm just going to remove this
24:48 and I'm going to show you by the way or
24:50 I did show you uh that it was scraping
24:54 scraping stuff right from the Sur
24:56 results so um I will just show rating
25:00 and screenshot right so we just remove
25:02 the
25:04 links we can just we don't have to show
25:08 oh
25:10 sorry this is what I'm looking for so we
25:12 just going to show a thumbnail and this
25:14 if you click on it we can see the file
25:17 so let's reload so it got rating 85
25:21 because Berlin's best k out this is a
25:23 very positive review then there's a
25:26 screenshot here you can click on and you
25:27 see you have the screenshot of the
25:29 website we can take another one just to
25:32 show you that this is working I found
25:34 another one that is far far away from
25:38 my H list so this is similar to what I
25:41 said it's kind of
25:44 overrated so we're just oh sorry I
25:47 copied the title first which is what I
25:49 wanted to do just copy that and then
25:52 copy the URL and we're going to save
25:55 this and hopefully the rating should be
25:58 well under 50 I guess at least it's it's
26:01 not a super critical review but it's
26:03 definitely not saying that it's Berlin's
26:05 best Don know that is what some people
26:08 says about it
26:10 right yeah so you see rating 25 pretty
26:13 low uh and a
26:16 screenshot that you have and then you
26:18 can I just can show you in edit you can
26:20 see that it also store the actual review
26:23 completely as it is
26:24 right
26:26 um
26:28 and now of course there's a lot of steps
26:30 in druple you need to connect this to
26:32 the restaurant you need to create views
26:34 you need to design it
26:36 but you already have the grounds for
26:39 creating your restaurant meta critic
26:42 website in this case without a lot of
26:46 editorial
26:47 work so yeah that's
26:51 it um yeah just feel free to start using
26:55 it and happy usage thank you for
26:57 watching
