Using Linguistic Analysis Techniques we could determine the personality and influence of someone based on text, the steps towards determining influence involves word frequency usually a person of bad influence would perhaps do unhealthy things or depending on your definition of bad influence, they probably wouldn't be able to curse a lot either. If we apply the non-cursing rule(which they can curse but excessive amounts of cursing would be added to "bad influence" category, the steps you could take in this case is:
1. Blacklist file
2. Frequency count towards blacklisted words.
So if they said let's go to that censored house and pop censored using the frequency count of blacklisted words we would know that they said a blacklisted word 2 times. Does this make them bad influence? No but let's say that they increased the frequency count within a short amount of time. Usually a person that curses a lot rely on a lot of impulsiveness which they have a higher chance of being bad influence, in python we could implement:
x = input("Insert word: ") blacklist = ["punk","kill","drugs"] y = x.count(blacklist) print(y)
^NOTE: This example isn't necessarily recommended, it is suggested that you don't allow user input, but rather user data in a file.
And what you could do to make it better is by converting the input into a list using list() and split it by spaces using split() or vice versa and then check if any of the strings are in the blacklist, if so get the index of the blacklisted word and put it within x.count(blacklist[index]) and then compare it with the user inputted list and see how many times it occurred, and then based on the occurrences, tag it as either negative or positive and using this small intel we could try to determine the personality even further.
Also using datasets of positive, negative and multiple phrases used by people with certain disorders you could even take this a bit further. e.g. determining if someone is psychotic based on common usage of words that other psychopaths have used, like most psychopathic serial killers are philosophical for example. This of course could be inaccurate at times but it's also more good clues. also it's a recommended step for the potential to spot possible malicious activities and people.