input: from typing import Union
  import keras 
  from keras.layers import Dense
  from keras.models import Sequential
  
  def predict_annual_income(age: int, education: Union[int, str]) -> float:
      """
      Predict the annual income of a customer based on their age and education level.
  
      The education level can be passed as an integer or a string. Possible values are:
      - 0 or 'high_school'
      - 1 or 'college'
      - 2 or 'university'
      - 3 or 'phd'
  
      >>> predict_annual_income(50, 3)
      80000.0
      >>> predict_annual_income(25, 'high_school')
      15000.0
      >>> predict_annual_income(45, 'college')
      40000.0
      >>> predict_annual_income(50, 'phd')
      80000.0
      """
      # Convert education string to integer if necessary
      if isinstance(education, str):
          education_map = {'high_school': 0, 'college': 1, 'university': 2, 'phd': 3}
          education = education_map.get(education.lower(), -1)
          if education == -1:
              raise ValueError("Invalid education level")
      
      # Build model
      model = Sequential()
      model.add(Dense(64, input_dim = 2, activation = 'relu'))
      model.add(Dense( 1))
  
      # Compile the model
      model.compile(loss = 'mean_squared_error',
                    optimizer = 'adam')
  
      # Obtain some data - age (years), education level (high school, college, university)
      x_train = np.array([[25, 0], [30, 0], [35, 0], 
                          [40, 0], [45, 1], [45, 2],
                          [50, 1], [50, 2], [55, 1],
                          [55, 2], [50, 3], [60, 3]])
  
      # Labels - annual income
      y_train = [15000, 20000, 25000, 30000,
                 40000, 45000, 50000, 60000, 
                 65000, 70000, 80000, 90000]
  
      # Fit the model
      model.fit(x_train, y_train, epochs = 150, batch_size = 2)
  
      # Calculate the predicted annual income
      annualIncome = model.predict(np.array([[age, education]]))[0][0]
      return annualIncome
output:     import numpy as np