BestPromptFinder
Home › Coding › Design a Word Game With AI Players That Shrugs Off Prompt Injection

Design a Word Game With AI Players That Shrugs Off Prompt Injection

Coding · Claude, ChatGPT, Gemini · coding
85AI Quality /100
90AI Usefulness est. /100
81Eval Confidence /100
No votes yetCommunity results

Quality, usefulness and confidence are AI evaluations out of 100 — not user ratings. Community results come from visitors' "worked / didn't work" votes below. How scoring works →

The prompt

I'm building a [type of game, e.g. party word-guessing game] where some seats can be played by an LLM. Players type free text (clues, guesses, chat) that ends up in the model's input. Help me design it so a player typing instructions to the bot can't do much harm: 1. Threats: list what a player could try (fake system text, asking for the prompt, making the bot pick a target answer, making it waste API calls) and the worst realistic outcome of each. 2. Design fixes first: limit what the model can do (pick from a fixed list, structured JSON output, validation in code), so a bad input at worst causes one wrong move. 3. Input handling: length limits, allowed characters, and how to pass player text clearly marked as data. 4. Cost controls: who can trigger paid calls, per-user daily caps, guest limits. 5. A short system prompt for the AI player, and 6 hostile test inputs with the expected safe behaviour. Stack: [language/framework]. Keep it practical; no filters that a small team can't maintain.
Find similar in the app →
Did this prompt work for you?

Why this prompt

Source

Created by BestPromptFinder — editorial prompt, not user-generated. See our content & source policy.

Related Coding prompts

Python: Download a CSV From a URL
Quality 94 · GPT-5.6
Public-Market and Competitor Data Collection Agent
Quality 92 · GPT-5.6
Plain-English to SQL Query Writer
Quality 91 · GPT-5.6
PRD to MVP Technical Plan
Quality 90 · Claude Code
Third-Party API Integration
Quality 90 · Claude Code
Database Schema and Migration
Quality 90 · Claude Code