import { AlertTriangle, ExternalLink } from "lucide-react"; import type { AgentPermissions } from "@paperclipai/shared"; import { getTrustPreset } from "@/lib/trust-policy-ui"; import { Button } from "@/components/ui/button"; export const LOW_TRUST_AGENT_GUIDE = "https://docs.paperclip.ing/administration/trust-and-low-trust-review/"; export function GitHubAgentTrustWarning({ agent, onChangeToLowTrust, disabled, }: { agent: { name: string; permissions: Partial } | null | undefined; onChangeToLowTrust?: () => void; disabled?: boolean; }) { if (!agent || getTrustPreset(agent.permissions) === "low_trust_review") return null; return (

{agent.name} is not configured for low-trust review

GitHub comments and pull requests can contain malicious instructions. We recommend a low-trust agent with a scoped work boundary and an isolated sandbox runtime.

Continuing keeps this agent’s current permissions. A restricted guest profile does not replace the agent’s trust and runtime settings.

{onChangeToLowTrust && ( )} Learn about low-trust agents
); }