Addressed missing lines bug in repeated word script and functors update