<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def update_driver(self, prompt):
 """Update driver based on new prompt."""

        prompt = prompt.lstrip()
        self.chain.connection.log("({}): Prompt: '{}'".format(self.driver.platform, prompt))
        self.prompt = prompt
        driver_name = self.driver.update_driver(prompt)
        if driver_name is None:
            self.chain.connection.log("New driver not detected. Using existing {} driver.".format(self.driver.platform))
            return
        self.driver_name = driver_name