Skip to content

Add duo_workflow_extended_logging feature flag

What does this MR do and why?

The Duo Workflow feature in GitLab has the ability to collect prompts and AI responses related to running a workflow. These are sent to Langchain. We want this to be off by default but allow team members to enable this data collection for our own users. This MR is the GitLab part of that work. It introduces a new feature flag that can be turned on per user to collect this data. With the intention that this would only be used for internal team members for now. In future if it will be used by customers it would be based on them opting in directly and would likely require new disclaimers and legal input before we can do that.

The Duo Workflow Service is the one that is sending this data to Langchain so we need to send the setting to the Duo Workflow Service. This is accomplished by passing the data through the following programs:

  1. LSP ->(http request)-> GitLab: to create a workflow and get token and other details
  2. LSP ->(shell out)->Duo Workflow Executor: to start the workflow
  3. Duo Workflow Executor ->(grpc)-> Duo Workflow Service: to start running the workflow

This MR introduces a new generic workflowMetadata JSON payload for sending this kind of insignificant data all the way through these 4 systems without having to update all 4 of them every time we need new data. The idea will be that we'll put more fields into this JSON payload in future. We do not intend to use this new JSON field for critical data that is necessary for the application to function as this creates more challenges for backwards compatibility.

This MR is 1 of 4 MRs needed to accomplish this:

  1. GitLab !167571 (merged) 👈 (you are here)
  2. LSP gitlab-org/editor-extensions/gitlab-lsp!881 (merged)
  3. Executor gitlab-org/duo-workflow/duo-workflow-executor!54 (merged)
  4. Service gitlab-org/duo-workflow/duo-workflow-service!101 (merged)

MR acceptance checklist

Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Screenshots or screen recordings

Screenshots are required for UI changes, and strongly recommended for all other merge requests.

Before After

How to set up and validate locally

Numbered steps to set up and validate the change are strongly suggested.

Related to https://gitlab.com/gitlab-org/duo-workflow/duo-workflow-service/-/issues/80

Edited by Dylan Griffith

Merge request reports

Loading