Back to Rivet

System Prompt

website/src/content/docs/agent-os/system-prompt.mdx

2.2.1644 B
Original Source

agentOS automatically injects a system prompt into every agent session that describes the VM environment and available tools. The prompt is additive and never replaces the agent's own instructions (CLAUDE.md, AGENTS.md, etc.).

The base prompt lives at /etc/agentos/instructions.md inside the VM.

Customization

ts
const session = await vm.createSession("pi", {
  env: { ANTHROPIC_API_KEY: process.env.ANTHROPIC_API_KEY! },
  // Append custom instructions
  additionalInstructions: "Always write tests before implementation.",
  // Suppress the base OS prompt (tool docs are still injected)
  skipOsInstructions: true,
});