input: def classify_mnist_digits(dataset_name: str) -> LogisticRegression:
      """ Generate a machine learning model using scikit-learn to classify digits in the 
      specified dataset. The dataset is assumed to be in the format compatible with 
      fetch_openml method. The model used for classification is Logistic Regression.
      >>> model = classify_mnist_digits('mnist_784')
      >>> (X.shape, y.shape)
      ((70000, 784), (70000,))
      >>> print(type(model))
      <class 'sklearn.linear_model._logistic.LogisticRegression'>
      """
      from sklearn.datasets import fetch_openml
      import numpy as np
      from sklearn.linear_model import LogisticRegression
  
      # Load the dataset
      mnist = fetch_openml(dataset_name)
  
      # Split into features and labels
      X = mnist.data
      y = mnist.target
  
      # Reshape data to be valid
      X = X.reshape((X.shape[0], -1))
      print(X.shape, y.shape)
  
      # Create a Logistic Regression classifier
      clf = LogisticRegression()
  
      # Fit the model to the data
      clf.fit(X, y)
      return clf
output:     return clf