changed prompt construction method