Skip to content

Move first_comment_regex to instructions extractor

Jan Provaznik requested to merge jp-cs-ref2 into master

What does this MR do and why?

  • first_comment_regex method is used for parsing instruction, it fits into InstructionsExtractor class, instead of having it in TaskFactory and passing it as an additional parameter.
  • moves also "intent" logic into instruction extractor (if intent is set we want to take it into account for detecting generation/completion)
  • removes some duplicated tests from TaskFactory (as InstructionsExtractor is responsible for parsing prefix code it makes sense to cover all possible scenarios there)

Related to !134265 (comment 1608348539)

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.

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Jan Provaznik

Merge request reports