Skip to content

Analyzing a 79k Dataset of Misinformation and Fake News

License

Notifications You must be signed in to change notification settings

wiseaidev/truth-guard

Repository files navigation

Truth Guard

linting: pylint Code style: black Static typing: mypy Codeql

banner

banner.png

A Fully Async-based ML Fake news detection API.

NoteBook

Development Requirements

  • Make (GNU command)
  • Python (>= 3.9)
  • Poetry (1.2)

Project Structure

❯ tree app
.
├── model         # Package contains different config files for the `model` app.
│   ├── crud.py       # Module contains different CRUD operations performed on the database.
│   ├── models.py     # Module contains different data models for ODM to interact with database.
│   ├── router.py     # Module contains different routes for this api.
│   └── schemas.py    # Module contains different schemas for this api for validation purposes.
├── config.py     # Module contains the main configuration settings for project.
├── __init__.py
├── main.py       # Startup script. Starts uvicorn.
└── py.typed      # mypy related file.

Installation with Make

Having make installed and configured on your machine, you can now run make under the root directory of this project to explore different available commands to run:

make

Please use 'make <target>' where <target> is one of:

venv                     Create a virtual environment
install                  Install the package and all required core dependencies
run                      Running the app locally
deploy-deta              Deploy the app on a Deta Micro
clean                    Remove all build, test, coverage and Python artifacts
lint                     Check style with pre-commit
test                     Run tests quickly with pytest
test-all                 Run tests on every Python version with tox
coverage                 Check code coverage quickly with the default Python
build                    Build docker containers services
up                       Spin up the containers
down                     Stop all running containers

1. Create a virtualenv

make venv

2. Activate the virtualenv

source .venv/bin/activate

3. Install dependencies

make install

Note: This command will automatically generate a .env file from .env.example, uninstall the old version of poetry on your machine, then install latest version 1.2.2, and install the required main dependencies.

4. Run The Project Locally

make run

Note: You have to set DEBUG=info to access the docs.

Access Swagger Documentation

http://localhost:8000/docs

Access Redocs Documentation

http://localhost:8000/redocs

License

This project and the accompanying materials are made available under the terms and conditions of the Apache License Version 2.0.

Releases

No releases published

Packages

No packages published

Languages