Starting an interactive session

Interactive sessions provide a conversational interface to Bob directly in your terminal, allowing real-time assistance with your development tasks.

Bobshell interactive session

To start an interactive session:

Open a new terminal window.

Note:

When you start Bob Shell for the first time, you must login with your IBMid and accept the license agreement.

Navigate to the main directory of your project.

To start a Bob Shell interactive session, run:

bob

Basic usage

Interact with Bob Shell

  • Type your instructions or questions directly in the terminal
  • Press Enter to send your message to Bob
  • Bob Shell will respond with its analysis and suggestions
  • For tool usage (like reading or writing files), you'll be prompted to approve or decline each action

Reference files

Use the @ symbol to reference files in your project:

Explain the functionality in @src/main.js

This tells Bob Shell to read and analyze the specified file before responding.

Use slash commands

Type / to access a menu of available commands:

  • Built-in commands like /help for assistance
  • Mode-switching commands like /code or /ask
  • Custom commands you've created

For a complete list of available commands, see Slash commands in Bob Shell.

View file changes

When Bob Shell needs to modify files, it will show you the proposed changes:

  • By default, changes are displayed in the terminal with a CLI diff view.
  • To use an external editor for reviewing changes, configure your preferred editor with the /editor command. Then select the "Show diff in editor" option when prompted to review changes.

Advanced features

Tool approvals

For security, Bob Shell requires your approval before:

  • Reading files.
  • Writing or modifying files.
  • Executing commands.

You can approve or decline each action individually when prompted.

Multi-turn conversations

Bob Shell maintains context throughout your conversation, allowing you to:

  • Ask follow-up questions.
  • Refine previous requests.
  • Build on earlier responses.

Tips for effective use

  • Be specific in your requests to get more targeted responses.
  • Use @ references to provide code context when needed.
  • For complex tasks, break them down into smaller steps.
  • Use slash commands to quickly access common functionality.
  • When working with large codebases, direct Bob Shell to the most relevant files.

When to use interactive session

Interactive session works best for:

  • Exploratory coding sessions.
  • Debugging and troubleshooting.
  • Learning new concepts or technologies.
  • Tasks that require multiple back-and-forth exchanges.
  • Projects where you need to review changes before they're applied.
How is this topic?