AttributeError: module ‘time’ has no attribute ‘clock’ ,please help me to solve

  chatbot, machine-learning, nlp, python-3.x, stanford-nlp

here my code

i dont know why pls help me to resolve it

from chatterbot import ChatBot
from chatterbot.trainers import ListTrainer

# Create a new chat bot named Charlie
chatbot = ChatBot('Charlie')

trainer = ListTrainer(chatbot)
Q_A = [  'Hi','How Can I help you?',
    '1.Need to Plan a Model n 2.Want to know more about planning n 3.Write to us',
    'Choose Your Planning',
    'INVESTMENT PLANNING n TAX PLANNINGnRETIREMENT PLANNINGnFINANCE PLANNINGnESTATE PLANNINGnWEALTH PLANNING',
    'How many dependant members in your family?',
    '0,1,2,3,4,5,6,7,8,9,10',
    'What is your Investment Horizon?',
    'Short,Medium,Long',
    'What is your Current age?',
    '15-20,21-25,26-30,31-35,36-40,41-45,46-50,51-55,55-60,61-65,66-70,71-75,76-80',
    'What is your expected Retirement Age?',
    '21-25,26-30,31-35,36-40,41-45,46-50,51-55,55-60,61-65,66-70,71-75,76-80',
    'What is your Life Expectancy?',
    '36-40,41-45,46-50,51-55,55-60,61-65,66-70,71-75,76-80',
    'What is your Risk Willingness?',
    'Low,Medium,High',
    'What is your Current Income?',
    '0-5lakhs,5-10 lakhs, 10-15 lakhs, 15-20 lakhs,20-30 lakhs, 30-40 lakhs,40-50 lakhs, 50 lakhs+(Enter Manually)',
    'What % can you put aside for Savings/Investments?',
    '0-5%,6-10%,11-15%,16-20%,21-25%,26-30%,31-35%,36-40%,41-45%,46-50%,51-55%,56-60%,61-65%,66-70%',
    'Mention some Future goals/Aspirations you have',
    "(Enter Manually)Just some examples: Children's Marriage, Children's Education, Vacation, Buying a Car, Buying a House, Paying off debt",
    'What is your Occupation?',
    'Student,Housewife, Working Professional'

]
trainer.train(Q_A)

# Get a response to the input text 'I would like to book a flight.'
for Q in Q_A[::2]:
    print(Q)
    response = chatbot.get_response(input('Q:'))

    print('Bot : ',response)

it shows folowing error i dont know why“`
here i didnt use any term as clock

AttributeError: module ‘time’ has no attribute ‘clock’

Source: Python-3x Questions

LEAVE A COMMENT