返回提示词库
文本 · 通用大模型AI沙箱安全代码执行环境配置生成器PW
创作者Prompt2 编辑部PromptWhisper 收录
文本通用大模型开发与工程

AI沙箱安全代码执行环境配置生成器

为AI Agent生成安全的沙箱代码执行环境配置,支持Docker、microVM等多种隔离方案,确保AI代码执行的安全性

12浏览
完整提示词可替换花括号中的变量后直接使用

You are an expert in secure sandbox environments for AI agent code execution. Help me design and configure a sandboxed execution environment. ## Context I need to set up a secure environment where an AI agent can execute code safely, with proper isolation, resource limits, and security controls. ## Requirements Analysis Please ask me about: 1. **Use case**: What type of code will the AI execute? (Python scripts, shell commands, web scraping, data analysis, etc.) 2. **Isolation level**: How strict should isolation be? (Container, microVM, process-level) 3. **Resource constraints**: CPU, memory, disk, network limits 4. **Network policy**: Should the sandbox have internet access? Which domains? 5. **Persistence**: Should file changes persist between executions? 6. **Platform**: Where will this run? (Local machine, cloud, Kubernetes) ## Output Based on my answers, generate: ### 1. Architecture Diagram (Mermaid) A clear diagram showing the sandbox architecture. ### 2. Configuration Files - Dockerfile or microVM config - Security policy (AppArmor/seccomp profile) - Network policy - Resource limit configuration ### 3. Setup Script A complete setup script that installs dependencies, configures the sandbox runtime, sets up security policies, creates the execution environment, and includes health checks. ### 4. Security Checklist - Filesystem isolation verified - Network restrictions tested - Resource limits enforced - No privilege escalation possible - Secrets/credentials not accessible - Audit logging enabled ### 5. Usage Examples Show how to execute code in the sandbox, pass input/output safely, handle timeouts and failures, and clean up after execution. Start by asking me the requirements questions above.

2026/4/28

如何使用这条提示词

  1. 1复制上方完整提示词。
  2. 2在对应模型中替换主题、人物或风格变量。
  3. 3生成后记录有效调整,形成自己的版本。