Skip to content

Antigravity CLI ​

Here is a quick-reference cheatsheet of the most useful commands, shortcuts, and features to help you get started with Antigravity CLI (agy).

1. Essential Slash Commands (Within agy) ​

Type these directly into the prompt box inside an active session:

CommandActionWhen to use it
/help or ?Show all commandsWhen you forget a command or want to check options.
/clearClear conversationResets the conversation context to start fresh.
/undo or /rewindRewind last stepIf the agent went down the wrong path and you want to step back.
/forkFork workspaceCreates an isolated branch workspace for experimenting.
/resumeResume past chatsLists previous conversations to pick up where you left off.
/config or /settingsConfig screenCustomizes agent model settings and permissions.
/exitExit the CLIEnds the session and returns to your main bash shell.

2. Typing & Navigation Shortcuts ​

  • @ (File Completion): Type @ in the prompt to trigger interactive auto-completion of files in your workspace directory.
  • ! (Direct Shell Execution): Prefix a line with ! to run a shell command on your local system immediately without involving the agent (e.g., !git status or !npm install).
  • Esc then Esc: Press the Escape key twice to quickly clear whatever you've typed in the active prompt box.

3. CLI Launch Commands (From your terminal) ​

  • agy — Starts a session using the default settings in your current directory.
  • agy --model <model-name> — Launches the session with a specific AI model.
  • agy update — Upgrades your CLI tool to the latest version.
  • agy changelog — Lists the latest release updates and patches.

4. Pro-Tips for Beginners ​

  1. Always open from the Workspace Root: Run agy from the root directory of your repository. This ensures it understands the full context of your codebase and avoids workspace state conflicts.
  2. Use /goal for complex tasks: If you have a large refactoring job or a task that might take a long time (e.g., migrating tests), use the /goal command. This instructs the agent to run in a thorough, multi-step background loop until the job is completed.

5. Slash Command Reference ​

CommandDescription
/add-dirAdd a directory to the workspace
/agentsList available custom agents
/artifactView and review artifacts
/btwAsk a side question without interrupting the current task
/changelogShow release notes and changes
/clear (new)Clear conversation and start a new one
/config (settings)Open settings panel
/contextVisualize current context usage
/copyCopy the last planner response to the clipboard (may require allowing clipboard access in your terminal)
/creditsShow remaining G1 credits and purchase link
/diffView uncommitted changes and per-turn diffs
/exit (quit)Exit the CLI
/fastAgent will execute tasks directly. Use for simple tasks that can be completed faster
/feedbackSubmit qualitative feedback to improve the agent
/fork (branch)Create a branch of the current conversation at this point
/helpShow available commands and keybindings
/hooksManage hook configurations for tool events
/keybindingsSet custom keybindings
/logoutLog out
/mcpManage MCP servers
/modelSet a model
/openOpen a file or view opened/edited files
/permissionsManage tool permissions
/planningAgent can plan before executing tasks. Use for deep research, complex tasks, or collaborative work
/renameRename the current conversation
/resume (switch, conversation)Browse and resume past conversations
/rewind (undo)Rewind conversation to a previous message
/skillsList available skills
/statuslineToggle the statusline
/tasksView background tasks
/titleToggle custom terminal window title
/usage (quota)View model quota usage
/goalRun until the specified goal is completely finished
/scheduleRun an instruction on a recurring schedule or as a one-time timer
/grill-meInterview me to align on a plan
/teamwork-previewInvoke a team of agents to autonomously tackle large projects

6. Shortcuts Reference ​

Shortcut / KeybindingAction
/Open slash commands
\ + enterInsert newline fallback
alt+enter, ctrl+j, shift+enterInsert newline
alt+jManage subagent
ctrl+_, ctrl+shift+-Undo
ctrl+c, escGo back / dismiss
ctrl+dExit
ctrl+endGo to bottom
ctrl+gOpen prompt in $EDITOR
ctrl+homeGo to top
ctrl+kApprove subagent fast
ctrl+lClear CLI screen
ctrl+oToggle trajectory view
ctrl+rReview artifact
ctrl+shift+zRedo
ctrl+vPaste image/video
ctrl+yYank (paste from kill ring)
ctrl+zSuspend CLI
downMove down
eEdit command
enterSend message or confirm
leftMove left / Prev tab
pgdown, shift+downPage down
pgup, shift+upPage up
rightMove right / Next tab
shift/alt+clickSelect and copy text
tabTab
upMove up