AI Features
JournalPHP integrates AI capabilities for automating moderation, enhancing content, and improving user interaction.
Setting Up AI
Admin Panel → AI Settings (/admin-panel/ai-settings):
| Setting | Purpose |
|---|---|
| API Key | Deepseek API Key |
| Model | Model to use (e.g., deepseek-chat) |
| Base URL | Deepseek API base URL |
| Enabled | Global enable/disable switch |
If AI is not configured — all AI features are silently disabled, no errors occur.
Post Summaries (AI Summary)
Users with the applicable subscription level (feature post_summaries) can request a concise summary of a long post — with one button click.
How it works:
- User clicks "Summary" on the post page
- The platform sends the post text to the Deepseek API
- The response is displayed below the post
The summary prompt is configurable in Admin Panel → Summary Prompt (/admin-panel/post-summary-prompt).
Route: POST /posts/{post}/summary
AI Comment Bot
The bot acts as a configured platform user and responds when mentioned via @slug in a comment.
Admin Panel → Comment Bot (/admin-panel/chat-gpt-bot):
| Setting | Purpose |
|---|---|
| Bot user | Account that publishes bot replies |
| Prompt | Instructions for generating responses |
Trigger: @slug mention of the bot in comment text (text after @slug is required).
Access requires a subscription with the chatgpt_comments feature. Without a subscription, the bot replies with a message linking to subscribe.
AI Text Moderation
When AI moderation is enabled, new posts and comments are automatically checked for policy violations.
Admin Panel → Content Moderation (/admin-panel/moderation-settings):
- Enable AI moderation for posts
- Enable AI moderation for comments
- Configure actions on violation detection (send to moderation queue / auto-delete)
Manual moderation run:
php artisan moderation:comments --syncImage Moderation (Yandex Vision)
Images uploaded by users can be automatically checked for NSFW content via the Yandex Vision API.
Admin Panel → Image Moderation (/admin-panel/image-moderation-settings):
| Setting | Purpose |
|---|---|
| Enabled | Activate image checking |
| Yandex Cloud API Key | Access key |
| Folder ID | Yandex Cloud folder identifier |
| Confidence threshold | Minimum score to block |