Deleted some redundant code from agent.py
Improved validation messaging