11# AI Spam Guard
22
33An AI-powered GitHub Action that automatically detects and moderates spam in
4- issues and comments using GitHub Models language models .
4+ issues and comments using LLMs .
55
6- ## Usage
6+ Each new issue and comment is passed through a series of prompts: by default
7+ checking for link spam, regular spam, and AI-generated content, but you can
8+ write your own custom prompt if you've got more specific requirements.
79
8- ### Basic Setup
10+ ## Usage
911
1012Add this action to your repository's workflow file (e.g.,
1113` .github/workflows/spam-guard.yml ` ):
5658| ` enable-link-spam-detection ` | Enable built-in link spam detection prompt | ` true ` | No |
5759| ` enable-ai-detection ` | Enable built-in AI-generated content detection prompt | ` true ` | No |
5860
59- ### Inference
61+ ## Inference
6062
6163The action does not require any external API keys for inference - it uses the
6264built-in GitHub token with ` models: read ` permission to access GitHub Models.
@@ -65,7 +67,7 @@ Every GitHub user has Github Models inference for free, but if you're running
6567into rate limiting issues you can choose to
6668[ opt in to paid usage] ( https://docs.github.com/en/billing/managing-billing-for-your-products/about-billing-for-github-models ) .
6769
68- ## Detection Prompts
70+ ### Default prompts
6971
7072The action uses built-in YAML prompts located in the ` prompts/ ` directory. Each
7173prompt can be individually enabled or disabled using the configuration options:
@@ -94,7 +96,7 @@ You can iterate on or tweak these prompts via the
9496If you want to push an update to this prompt, please also include updated test
9597data so we can see the effect of the prompt update.
9698
97- ### Custom Prompts
99+ ### Custom prompts
98100
99101You can also provide your own custom prompt file in your repository using the
100102` custom-prompt-path` input:
0 commit comments