Giter Site home page Giter Site logo

Comments (2)

jo3-l avatar jo3-l commented on July 28, 2024

Thank you for raising this and offering to submit a PR; I appreciate it. That said, I admit I am rather hesitant to add 'official' support for languages other than English to Obscenity for two primary reasons:

  • The library was designed with English in mind, and I am not sure how nicely some of its foundations generalize to other languages. In particular, I am skeptical as to whether the current system (character-based transformations, plus a carefully curated set of patterns) for detecting variants of terms will remain effective. For your request in particular, this is less of an issue because English and French are somewhat closely related. But the more pressing issue is:

  • I only personally speak English fluently, which means I can only attest to the quality of patterns for profanity in English. So while I could in theory accept an initial PR for a new French preset based on an existing dataset, it would be difficult to maintain that myself going forward. If, for instance, I later receive a bug report that phrase X is being erroneously marked as profanity by pattern Y in French, it would be exceedingly difficult to evaluate this report and to release a satisfactory fix on my own.

If you are a native French speaker and are able to both confirm that Obscenity works well for French and maintain the relevant code in the long-term, I would be willing to accept a PR. If you are not, though -- which is perfectly reasonable -- I would prefer to leave support for other languages out of the official project. You can still of course develop such support in your own project, perhaps even released separately on npm if you think it is something others would find useful.

from obscenity.

jo3-l avatar jo3-l commented on July 28, 2024

Closing for now, but happy to re-open if you (or anyone else) address my previous comment.

from obscenity.

Related Issues (15)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.