text_plain_output_1.png
import pandas as pd

import re

data_meta = pd.read_csv('/kaggle/input/content-based/meta_full_csv')
data_meta = data_meta.sample(50000)
data_meta['summaryRev'] = data_meta['summary'] + ' ' + data_meta['reviewText']

data_meta.query("asin == 'B00GIDADP0'")

data_meta.query("asin == 'B002Q46RDW'")

data_meta_1 = data_meta[['asin', 'overall', 'unixReviewTime']]
data_meta_1
data_meta_2 = data_meta[['asin', 'overall', 'summaryRev']]

data_meta_2
regEx = re.compile('[^a-z]+')
def cleanReviews(reviewText):
    reviewText = reviewText.lower()
    reviewText = regEx.sub(' ', reviewText).strip()
    return reviewText
data_meta_2['summaryClean'] = data_meta_2['summaryRev'].apply(cleanReviews)
data_meta_2 = data_meta_2.reset_index()