input: Write a function to extract the top 10 most frequent words from a given text using natural language processing in Python. The function should split the input text into individual words, count the frequency of each word, and then return the 10 most common words and their frequencies. If the text contains fewer than 10 words, the function should return all the word frequency pairs.
  assert top_10_frequent_words("Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.")==[('dolor', 1), ('Lorem', 1), ('ipsum', 1), ('amet', 1), ('consectetur', 1), ('adipiscing', 1), ('elit,', 1), ('sed', 1), ('do', 1), ('eiusmod', 1)]
  assert top_10_frequent_words("To be or not to be that is the question whether tis nobler in the mind to suffer the slings and arrows of outrageous fortune")==[('to', 2), ('be', 2), ('the', 2), ('or', 1), ('not', 1), ('that', 1), ('is', 1), ('question', 1), ('whether', 1), ('tis', 1)]
  assert top_10_frequent_words("")==[]
output: def top_10_frequent_words(text):
      from collections import Counter
      words = text.split()
      word_counts = Counter(words)
      return word_counts.most_common(10)