Add explain slash command
What does this MR do and why?
Related to #431575 (closed)
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.
Example below:
Feature.enable(:slash_commands)
- In one browser tab open Duo Chat UI, in second tab open graphql-explorer
- Send the following request from graphql explorer and check the result in Duo Chat UI:
mutation {
aiAction(input: {chat: {content: "/explain", currentFile: {
fileName: "test.rb",
selectedText: "
def extract(content)
lines = content.to_s.lines
comment_block = []
trimmed_lines = 0
end
",
}}}) {
clientMutationId
errors
}
}
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Edited by Gosia Ksionek