« All posts

Building a Basic AI Agent: Security II

Learn about using Docker sandbox and prompt-injection defenses to close security gaps in your AI agent.

This section focuses on closing security gaps in the AI agent. By utilizing a Docker sandbox, we ensure that commands can only access the project directory. Additionally, prompt-injection defenses are added to prevent the model from treating tool output as instructions, and every tool input will be validated against its schema before execution.