This project is a machine-generated text detector that uses multiple existing MGT detection models through the Hugging Face API and text statistics to determine if text is machine-generated or not. It combines the power of various models and statistical analysis to make more accurate predictions regarding the origin of the text.
To analyse the dataset and generate statistics required for the graphs , please follow these steps:
- Go to the
analysis
folder
cd src/analysis
- Run
analysis.py
to generatecombined_analysis.json
python3 analysis.py
- Run
graph.py
to verify that the results look valid (Optional)
python3 graph.py
- Move
combined_analysis.json
to thepublic
folder if updated.
To run the user interface, please follow these steps:
- Install the dependencies.
pnpm install
-
Copy
.env.local.example
to a new file.env.local
and add your Hugging Face API key. -
Run the development server.
pnpm run dev
- Open http://localhost:3000 with your browser to see the UI.