def METHOD_NAME(self, code: str) -> ActionResultDict:
    self._check_process_alive()
    if self._waiting_input:
        self.server_process.stdin.write(code.encode("utf-8", errors="replace"))
        if not code.endswith(("\r", "\n")):
            self.server_process.stdin.write(b"\n")
        self.server_process.stdin.flush()
        return {"success": True, "message": None, "result": None}
    msg_id = self.next_id()
    return self._unpack_result_as_action_result_dict(
        self.request(
            {
                "jsonrpc": "2.0",
                "id": msg_id,
                "method": "interpreter/evaluate",
                "params": {"code": code},
            },
            timeout=None,
        )
    )