some cleanup, and added source, company, and subject validation