From 2ecb1a73f41aa23378999c3f6bdbc9f3ec64c170 Mon Sep 17 00:00:00 2001 From: Lysanne Pinto <lpinto@gitlab.com> Date: Wed, 24 Jul 2024 02:04:36 +0000 Subject: [PATCH] Docs for RCA in Duo Chat --- doc/ci/jobs/index.md | 4 +++ doc/subscriptions/subscription-add-ons.md | 2 +- doc/user/gitlab_duo/experiments.md | 24 ------------------ doc/user/gitlab_duo/index.md | 15 ++++++++++- doc/user/gitlab_duo/use_cases.md | 4 +-- doc/user/gitlab_duo_chat/examples.md | 31 ++++++++++++++++++++++- 6 files changed, 51 insertions(+), 29 deletions(-) diff --git a/doc/ci/jobs/index.md b/doc/ci/jobs/index.md index 4eb94a219ee67..0b63ed429841e 100644 --- a/doc/ci/jobs/index.md +++ b/doc/ci/jobs/index.md @@ -73,6 +73,10 @@ In each place, if you hover over the failed job you can see the reason it failed You can also see the reason it failed on the Job detail page. +### Troubleshoot a failed job with root cause analysis + +You can use root cause analysis in GitLab Duo Chat to [troubleshoot failed CI/CD jobs](../../user/gitlab_duo_chat/examples.md#troubleshoot-failed-cicd-jobs-with-root-cause-analysis). + ## The order of jobs in a pipeline The order of jobs in a pipeline depends on the type of pipeline graph. diff --git a/doc/subscriptions/subscription-add-ons.md b/doc/subscriptions/subscription-add-ons.md index d285848fc496b..b196177c0f8be 100644 --- a/doc/subscriptions/subscription-add-ons.md +++ b/doc/subscriptions/subscription-add-ons.md @@ -116,7 +116,7 @@ Prerequisites: - You must be an administrator. 1. Sign in to the [GitLab Customers Portal](https://customers.gitlab.com/). -1. On the **GitLab Duo Pro** section of your subscription card click **Add seats** button. +1. On the **GitLab Duo Pro** section of your subscription card select **Add seats**. 1. Enter the number of seats. The amount cannot be higher than the number of seats in the subscription. 1. Review the **Purchase summary** section. 1. From the **Payment method** dropdown list, select your payment method. diff --git a/doc/user/gitlab_duo/experiments.md b/doc/user/gitlab_duo/experiments.md index e90d312b8c4a5..71f36326dcf53 100644 --- a/doc/user/gitlab_duo/experiments.md +++ b/doc/user/gitlab_duo/experiments.md @@ -74,30 +74,6 @@ is displayed. Provide feedback on this experimental feature in [issue 416833](https://gitlab.com/gitlab-org/gitlab/-/issues/416833). -## Troubleshoot failed CI/CD jobs with Root cause analysis - -DETAILS: -**Tier:** For a limited time, Ultimate. In the future, [GitLab Duo Enterprise](../../subscriptions/subscription-add-ons.md). -**Offering:** GitLab.com -**Status:** Experiment - -> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/123692) in GitLab 16.2 as an [experiment](../../policy/experiment-beta-support.md#experiment). - -Determine the root cause of a CI/CD job failure by analyzing the logs. - -Prerequisites: - -- You must belong to at least one group with the [experiment and beta features setting](turn_on_off.md#turn-on-beta-and-experimental-features) enabled. -- You must have permission to view the CI/CD job. - -To view root cause analysis: - -1. Open a merge request. -1. On the **Pipelines** tab, select the failed CI/CD job. -1. Above the job output, select **Troubleshoot**. - -An analysis of the reasons for the failure is displayed. - ## Summarize an issue with Issue description generation DETAILS: diff --git a/doc/user/gitlab_duo/index.md b/doc/user/gitlab_duo/index.md index b373536f0796c..f71957602488f 100644 --- a/doc/user/gitlab_duo/index.md +++ b/doc/user/gitlab_duo/index.md @@ -43,6 +43,19 @@ the [Duo Chat examples](../gitlab_duo_chat_examples.md). For self-managed, the models also depend on your GitLab version. For the most benefit, use the latest GitLab version whenever possible. +#### Root cause analysis + +DETAILS: +**Tier:** Ultimate with [GitLab Duo Enterprise](../../subscriptions/subscription-add-ons.md). +**Offering:** GitLab.com, Self-managed, GitLab Dedicated + +> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/123692) in GitLab 16.2 as an [experiment](../../policy/experiment-beta-support.md#experiment) on GitLab.com. +> - [Generally available](https://gitlab.com/gitlab-org/gitlab/-/issues/441681) and moved to GitLab Duo Chat in GitLab 17.3. + +- Helps you determine the root cause for a CI/CD job failure by analyzing the logs. +- LLM: Anthropic's [Claude 3.5 Sonnet](https://console.cloud.google.com/vertex-ai/publishers/anthropic/model-garden/claude-3-5-sonnet) +- [View documentation](../gitlab_duo_chat/examples.md#troubleshoot-failed-cicd-jobs-with-root-cause-analysis) + ### Code Suggestions DETAILS: @@ -201,7 +214,7 @@ DETAILS: - Helps you determine the root cause for a CI/CD job failure by analyzing the logs. - LLM: Vertex AI Codey [`text-bison`](https://console.cloud.google.com/vertex-ai/publishers/google/model-garden/text-bison) -- [View documentation](experiments.md#troubleshoot-failed-cicd-jobs-with-root-cause-analysis). +- [View documentation](../gitlab_duo_chat/examples.md#troubleshoot-failed-cicd-jobs-with-root-cause-analysis). ### Vulnerability resolution diff --git a/doc/user/gitlab_duo/use_cases.md b/doc/user/gitlab_duo/use_cases.md index ced85d7004454..db74902c93f50 100644 --- a/doc/user/gitlab_duo/use_cases.md +++ b/doc/user/gitlab_duo/use_cases.md @@ -55,8 +55,8 @@ you need to configure CI/CD. Please show a .gitignore and .gitlab-ci.yml configuration for a C# project. ``` -- If your CI/CD job fails, [Root Cause Analysis](../../user/gitlab_duo/experiments.md#troubleshoot-failed-cicd-jobs-with-root-cause-analysis) - can help understand the problem. Alternatively, you can copy the error message into +- If your CI/CD job fails, use root cause analysis to [troubleshoot failed CI/CD jobs](../gitlab_duo_chat/examples.md#troubleshoot-failed-cicd-jobs-with-root-cause-analysis). + Alternatively, you can copy the error message into GitLab Duo Chat, and ask for help: ```markdown diff --git a/doc/user/gitlab_duo_chat/examples.md b/doc/user/gitlab_duo_chat/examples.md index 700b94e1d4f14..3ecee5c63f4de 100644 --- a/doc/user/gitlab_duo_chat/examples.md +++ b/doc/user/gitlab_duo_chat/examples.md @@ -80,7 +80,35 @@ You can also ask to explain specific job errors by copy-pasting the error messag - `Please explain this CI/CD job error message in the context of a Go project: build.sh: line 14: go command not found` -Alternatively, you can use [root cause analysis in CI/CD](../gitlab_duo/experiments.md#troubleshoot-failed-cicd-jobs-with-root-cause-analysis). +Alternatively, you can use root cause analysis to [troubleshoot failed CI/CD jobs](#troubleshoot-failed-cicd-jobs-with-root-cause-analysis). + +## Troubleshoot failed CI/CD jobs with root cause analysis + +DETAILS: +**Tier:** Ultimate with [GitLab Duo Enterprise](../../subscriptions/subscription-add-ons.md). +**Offering:** GitLab.com, Self-managed, GitLab Dedicated + +> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/123692) in GitLab 16.2 as an [experiment](../../policy/experiment-beta-support.md#experiment) on GitLab.com. +> - [Generally available](https://gitlab.com/gitlab-org/gitlab/-/issues/441681) and moved to GitLab Duo Chat in GitLab 17.3. + +You can ask GitLab Duo Chat to determine the root cause of a CI/CD job failure by analyzing the logs. + +Prerequisites: + +- Have permission to view the CI/CD job. +- Have a paid GitLab Duo Enterprise seat. + +To troubleshoot a failed CI/CD job: + +1. On the left sidebar, select **Search or go to** and find your project. +1. Select **Build > Jobs**. +1. Select the failed CI/CD job. +1. From the job log page, do one of the following: + + - Above the job log, select **Troubleshoot**. + - Open GitLab Duo Chat and type `/troubleshoot`. + +An analysis of the reasons for the failure and an example fix is displayed. ## Explain a vulnerability @@ -276,4 +304,5 @@ Use the following commands to quickly accomplish specific tasks. | /explain | [Explain code](../gitlab_duo_chat/examples.md#explain-code-in-the-ide) | | /vulnerability_explain | [Explain current vulnerability](../gitlab_duo/index.md#vulnerability-explanation) | | /refactor | [Refactor the code](../gitlab_duo_chat/examples.md#refactor-code-in-the-ide) | +| /troubleshoot | [Troubleshoot failed CI/CD jobs with root cause analysis](#troubleshoot-failed-cicd-jobs-with-root-cause-analysis) | | /fix | [Fix the code](../gitlab_duo_chat/examples.md#fix-code-in-the-ide) | -- GitLab