Enhanced nonlinear characteristics with the assistance of a $$\mathscr{PT}$$𝒫𝒯-symmetric trimer system