Charly
Agentic coding guides for developers who ship with AI

Template · ai agent prompt for codebase

AI agent prompt for working in a codebase

Write a codebase prompt that tells an AI agent how to inspect files, respect architecture, edit safely and verify changes.

Quick answer

A good codebase prompt defines architecture rules, edit constraints, verification commands, security boundaries and how the agent should summarize work.

What to include

Include stack, folder rules, data boundaries, auth rules, formatting commands, test commands and rules for handling dirty git worktrees.

What to avoid

Avoid vague prompts like be careful. Give concrete constraints the agent can obey and verify.

FAQ

Should prompts include test commands?

Yes. The agent needs to know the exact local checks that prove a change is safe.

Build a project prompt