Chapter 5. Using the command-line assistant powered by RHEL Lightspeed on RHEL systems


The command-line assistant powered by RHEL Lightspeed helps you to interact with and find information about RHEL by using the command-line interface. Use the command-line assistant to answer RHEL-related questions, troubleshoot, interpret log entries, and perform many other tasks.

Warning

Do not rely on the results from AI tools without human review. Always check the AI and LLM-generated responses for accuracy before using the generated suggestions.

5.1. Consulting the command-line assistant

To use the command-line assistant powered by RHEL Lightspeed, use the c command followed by your questions in quotation marks.

Warning

Do not enter the following types of data when using the command-line assistant, because the assistant is not intended to process data such as:

  • Personal information
  • Business-sensitive information
  • Confidential information
  • System data information

Prerequisites

Procedure

  • Use the c command, followed by your questions in quotation marks. The following are examples of prompts that you can use to interact with the command-line assistant when using your RHEL system:

    • Ask a data-based question:

      $ c "What is RHEL"
    • Request information on how to troubleshoot a problem with SSHD:

      $ c "how to troubleshoot sshd failing to start"
    • Request information on how to find files under /etc:

      $ c "how do I find all the files in the /etc/ that have been modified in the last hour"

You can attach a file to the command-line assistant powered by RHEL Lightspeed. In response, the assistant can provide a tailored answer based on that file.

Prerequisites

  • You have installed the command-line assistant powered by RHEL Lightspeed. See the Installing the command-line assistant powered by RHEL Lightspeed documentation.
  • You have created a readable file with the information that you want the command-line assistant to use. The following examples use the storage_info file, which contains information about the volume group, logical volumes and file systems on another system.

Procedure

  • To replicate the storage configuration on another system, save the layout of the volume group, logical volumes, and file systems to a <storage_info> file. Then, use the command-line assistant to read the file and incorporate the information into next steps.

    $ c --attachment <storage_info>
  • Optionally, use the short version of the attachment command:

    $ c -a <storage_info>
  • Combine the attachment with a question:

    $ c --attachment <storage_info> "how can I replicate the storage configuration in another system"

Access your conversation history to view previous answers from the command-line assistant powered by RHEL Lightspeed.

Prerequisites

Procedure

  • Use the c history command to parse your conversation history. For example:

    • Fetch all user history:

      $ c history --all
    • Access the first conversation from history:

      $ c history --first
    • Access the last conversation from history:

      $ c history --last
    • Filter your history conversation to search for a term to retrieve all questions and answers related to that word:

      $ c history --filter "podman"
    • Clear all the user history:

      $ c history --clear

To use the command-line assistant powered by RHEL Lightspeed to understand a command output, redirect the output of the command to the assistant.

Prerequisites

  • You have installed the command-line assistant powered by RHEL Lightspeed.

Procedure

  • Redirect the log file output containing information that you want to understand to the command-line assistant:

    $ cat <log_file.log> | c
  • If the error or log that you provided to the command-line assistant do not provide enough information, combine the redirect output with a question:

    $ cat <log_file_error.log> | c "how do I solve this?"
  • You can also redirect a question:

    $ echo "how do I solve this?" | c -a <log_file_error.log>"

You can use the command-line assistant powered by RHEL Lightspeed to reference commands that you previously ran.

Warning

If you add terminal context in a request and there are no previously captured commands, the command fails. You can only add context from the terminal while the capture mode is enabled.

Prerequisites

Procedure

  1. Enable the terminal capture for your current terminal session:

    $ c shell --enable-capture
  2. Run at least one command before you reference previous commands.
  3. Reference the output of a previously run command. For example, to reference the previous command, run:

    $ c -w 1 "what_is_this"
    • To reference the second to previous command, run:

      $ c -w 2 "what_is_this"
  4. To stop terminal capture, press Ctrl + D.

Help improve the quality of the responses that you receive when you interact with the command-line assistant powered by RHEL Lightspeed by submitting feedback on its responses.

Prerequisites

  • You have installed the command-line assistant powered by RHEL Lightspeed.

Procedure

  • Run the following command:

    $ c feedback
Red Hat logoGithubredditYoutubeTwitter

Learn

Try, buy, & sell

Communities

About Red Hat Documentation

We help Red Hat users innovate and achieve their goals with our products and services with content they can trust. Explore our recent updates.

Making open source more inclusive

Red Hat is committed to replacing problematic language in our code, documentation, and web properties. For more details, see the Red Hat Blog.

About Red Hat

We deliver hardened solutions that make it easier for enterprises to work across platforms and environments, from the core datacenter to the network edge.

Theme

© 2026 Red Hat
Back to top