AI / GitHub Copilot CLI Fundamentals Interview Questions
What is the AGENTS.md file and how does it differ from copilot-instructions.md?
Both files customise how Copilot behaves in a repository, but they serve different purposes and have different scopes.
| Feature | AGENTS.md | copilot-instructions.md |
|---|---|---|
| Purpose | Define custom instructions and tool access for agentic sessions - used by Copilot when working autonomously | Provide project context: build commands, architecture, conventions for all Copilot interactions |
| Scope | Agentic/autonomous sessions (Plan, Autopilot, /fleet) | All Copilot CLI sessions including chat |
| Contents | Agent behaviour rules, which skills/tools are permitted, task-specific instructions | Build commands, test commands, architecture overview, coding style |
| Cross-session consistency | Ensures behaviour stays consistent across models, sessions, and delegated work | Ensures Copilot has project context on every session |
| Generated by | Created manually or by /init for agent-specific needs | Generated or updated by /init |
When to use each:
- Use copilot-instructions.md to give Copilot general project knowledge that applies to all interactions (how to build, test, understand the codebase)
- Use AGENTS.md to define the rules and constraints for autonomous agent sessions specifically - what tools an agent can use, what actions it should or shouldn't take, task-specific behavioural guidelines
Invest now in Acorns!!! 🚀
Join Acorns and get your $5 bonus!
Acorns is a micro-investing app that automatically invests your "spare change" from daily purchases into diversified, expert-built portfolios of ETFs. It is designed for beginners, allowing you to start investing with as little as $5. The service automates saving and investing. Disclosure: I may receive a referral bonus.
Invest now!!! Get Free equity stock (US, UK only)!
Use Robinhood app to invest in stocks. It is safe and secure. Use the Referral link to claim your free stock when you sign up!.
The Robinhood app makes it easy to trade stocks, crypto and more.
Webull! Receive free stock by signing up using the link: Webull signup.
More Related questions...
