{"id":18657289,"url":"https://github.com/thealoneprogrammer/bad-words-filtering","last_synced_at":"2025-11-05T21:30:32.317Z","repository":{"id":118150791,"uuid":"174371665","full_name":"thealoneprogrammer/Bad-words-filtering","owner":"thealoneprogrammer","description":null,"archived":false,"fork":false,"pushed_at":"2019-03-08T18:58:56.000Z","size":15366,"stargazers_count":0,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2024-12-27T15:11:03.735Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/thealoneprogrammer.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-03-07T15:32:51.000Z","updated_at":"2019-03-08T18:58:58.000Z","dependencies_parsed_at":null,"dependency_job_id":"d31c3eee-c3a2-49cb-b317-df972d5a5cef","html_url":"https://github.com/thealoneprogrammer/Bad-words-filtering","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thealoneprogrammer%2FBad-words-filtering","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thealoneprogrammer%2FBad-words-filtering/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thealoneprogrammer%2FBad-words-filtering/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thealoneprogrammer%2FBad-words-filtering/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/thealoneprogrammer","download_url":"https://codeload.github.com/thealoneprogrammer/Bad-words-filtering/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239474820,"owners_count":19645000,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-07T07:27:27.292Z","updated_at":"2025-11-05T21:30:32.285Z","avatar_url":"https://github.com/thealoneprogrammer.png","language":"Python","readme":"This project basically filters the swear words by appending '*' at the respected position\n\nThis project is built on top of django.\n\n**Some main parts to note**\n\n**filter.py**\n\n```python\n\nimport os\n\ndef process_string(string,):\n    result = \"\"\n    str_list = string.split()\n    strn_list = [i.lower() for i in str_list]\n\n    with open(os.path.dirname(__file__)+'/badwords.txt','r') as file:\n        for word in file:\n           word = word.split(', ')\n\n    for i in strn_list:\n        if i in word:\n            result += '*'*len(i)+\" \"\n        else:\n             result+=i+\" \"\n    return result\n```\n\n**views.py**\n\n```python\n\nfrom django.shortcuts import render\nfrom django.shortcuts import render\nfrom django.views.decorators.csrf import csrf_exempt\nfrom badApp import filter\n\n@csrf_exempt\ndef getResult(request):\n    if request.method == 'GET':\n        return render(request, 'index.html')\n    if request.method == 'POST':\n        # getting values from post\n        string = request.POST.get('string')\n        response = filter.process_string(string)\n        print(response)\n        return render(request, 'response.html', {\"r\": response})\n        \n```\n\n**urls.py**\n\n```python\n\nfrom django.contrib import admin\nfrom django.urls import path\nfrom badApp import views\n\nurlpatterns = [\n    path('admin/', admin.site.urls),\n    path('',views.getResult)\n]\n```\n![screenshot 90](https://user-images.githubusercontent.com/38497682/54049215-eb348900-4201-11e9-967e-e08745a70396.png)\n\n\n![screenshot 91](https://user-images.githubusercontent.com/38497682/54049218-eec81000-4201-11e9-91cc-d4667441b774.png)\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthealoneprogrammer%2Fbad-words-filtering","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fthealoneprogrammer%2Fbad-words-filtering","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthealoneprogrammer%2Fbad-words-filtering/lists"}