Twitter Inc. is working on a keyword-based tool that will let people filter the posts they see, giving users a more effective way to block out harassing and offensive tweets, according to people familiar with the matter.

The San Francisco-based company has been discussing how to implement the tool for about a year as it seeks to stem abuse on the site, said the people, who asked not to be identified because the initiative isn’t public. By using keywords, users could block swear words or racial slurs, for example, to screen out offenders.

For comparison, it took Twitter less than two weeks to identify a GIF from the Olympics posted by a sports journalist, and it took under three minutes for it to escalate from a removal demand to a permanent suspension, which was later reversed.

Twitter has known about harassment on its platform for years. It has only recently taken steps to combat it with the smallest of steps.