How to - force Agent to use terminal under Panel (Cmd+J) instead running in chat?

Hello, newbie here.

I am trying to ask Ai agent to compile a project for me and it will always either start a new session / compile inside the chat’s terminal. Is there any way I could force it use the terminal under the panel (cmd+J) or better yet, I can somehow use the “hammer/ tool” icon to manual compile it?