LLM for a Python code debugger requires training a model or using an existing open-source LLM, such as GPT-2 or GPT-3 from Hugging Face's Transformers library.
Requirments
Ensure you have installed nbformat using
pip install nbformat
pip install torch==1.8.0+cu111 torchvision==0.9.0+cu111 torchaudio==0.8.0 -f https://download.pytorch.org/whl/torch_stable.html
Usage:
- To debug the code:
python debugger_vulnerability_suggestions.py debug <path_to_python_file>
- To check for vulnerabilities:
python debugger_vulnerability_suggestions.py check_vulnerabilities <path_to_python_file>
The input file can be in format of .py
or .ipnb