code: def prompt(self, msg):
          
          try:
              # prompt_toolkit v2
              prompt = prompt_toolkit.PromptSession(history=self.history).prompt
          except AttributeError:
              # prompt_toolkit v1
              prompt = partial(prompt_toolkit.prompt, history=self.history)
          return prompt(
              msg,
              multiline=self.multiline,
              vi_mode=self.vi_mode,
              wrap_lines=self.wrap_lines,
              enable_history_search=self.history_search,
              lexer=PygmentsLexer(CoconutLexer),
              style=style_from_pygments_cls(
                  pygments.styles.get_style_by_name(self.style),
              ),
          )
docs: Get input using prompt_toolkit.