Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/gavin-black-dsu/securePrompts
https://github.com/gavin-black-dsu/securePrompts
Last synced: 16 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/gavin-black-dsu/securePrompts
- Owner: gavin-black-dsu
- Created: 2023-06-20T01:24:39.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-04-29T23:48:12.000Z (8 months ago)
- Last Synced: 2024-08-08T05:07:05.120Z (4 months ago)
- Language: Jupyter Notebook
- Size: 1 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- awesome_gpt_super_prompting - gavin-black-dsu/securePrompts - Repository with secure GPT prompts. (🔐 Secure Prompting / Hall Of Fame:)
README
# ChatGPT Security Focused Prompts and Code Correctness
## Setup
Install the requirements in **requirements.txt**, e.g.
pip3 install -r requirements.txt
OpenAI Secret key must be in **.key** file, or the file passed in as an argument.
## Running
```
usage: ./prompts.py [-h] [-k KEY] [-m MODEL] [-x MAX_TOKENS] [-b BACKOFF] [-d DELAY] [-n TRIALS] [-t TEMPERATURE] outputSend prompts to ChatGPT and analyze the resulting code
positional arguments:
output Location to write resultsoptional arguments:
-h, --help show this help message and exit
-k KEY, --key KEY File containing OpenAI API secret key
-m MODEL, --model MODEL
ChatGPT model to use
-x MAX_TOKENS, --max_tokens MAX_TOKENS
Maximum number of tokens from ChatGPT
-b BACKOFF, --backoff BACKOFF
Seconds to wait until retrying ChatGPT request
-d DELAY, --delay DELAY
Seconds to wait for Flask server to start
-n TRIALS, --trials TRIALS
Number of times to repeat testing
-t TEMPERATURE, --temperature TEMPERATURE
Temperature to use for randomness
```