text_plain_output_1.png
from sklearn.metrics import accuracy_score,confusion_matrix

transformer = ct(transformers=[('review_counts', cv(), 'verified_reviews'), ('variation_dummies', ohe(), ['variation'])], remainder='passthrough')

pipe = mp(transformer, dtc(random_state=42))
pipe

(x_train.shape, y_train.shape)

pipe.fit(x_train, y_train)

pred = pipe.predict(x_test)

pipe = mp(transformer, rfc(n_estimators=150, random_state=42))

pipe.fit(x_train, y_train)

pred = pipe.predict(x_test)

accuracy_score(y_test, pred)