@@ -73,35 +73,35 @@ impl ClaimExtractor {
7373 // Must contain a file extension or path separator to be a valid file path
7474 file_created_pattern : Regex :: new (
7575 r#"(?i)(?:I\s+)?(?:created|made|added)\s+(?:the\s+)?file\s+[`"']?([^\s`"']+\.[a-zA-Z0-9]+)[`"']?"#
76- ) . expect ( "TODO: handle error " ) ,
76+ ) . expect ( "invariant: regex pattern is syntactically valid " ) ,
7777 file_wrote_pattern : Regex :: new (
7878 r#"(?i)(?:I\s+)?(?:wrote|written)\s+(?:to\s+)?(?:the\s+)?file\s+[`"']?([^\s`"']+\.[a-zA-Z0-9]+)[`"']?"#
79- ) . expect ( "TODO: handle error " ) ,
79+ ) . expect ( "invariant: regex pattern is syntactically valid " ) ,
8080 file_modified_pattern : Regex :: new (
8181 r#"(?i)(?:I\s+)?(?:modified|updated|edited|changed)\s+(?:the\s+)?(?:file\s+)?[`"']?([^\s`"']+\.[a-zA-Z0-9]+)[`"']?"#
82- ) . expect ( "TODO: handle error " ) ,
82+ ) . expect ( "invariant: regex pattern is syntactically valid " ) ,
8383 file_deleted_pattern : Regex :: new (
8484 r#"(?i)(?:I\s+)?(?:deleted|removed)\s+(?:the\s+)?file\s+[`"']?([^\s`"']+\.[a-zA-Z0-9]+)[`"']?"#
85- ) . expect ( "TODO: handle error " ) ,
85+ ) . expect ( "invariant: regex pattern is syntactically valid " ) ,
8686 // Command execution
8787 command_ran_pattern : Regex :: new (
8888 r#"(?i)(?:I\s+)?(?:ran|executed)\s+(?:the\s+)?command\s+[`"']([^`"']+)[`"']"#
89- ) . expect ( "TODO: handle error " ) ,
89+ ) . expect ( "invariant: regex pattern is syntactically valid " ) ,
9090 // Git operations - require hash to be present for commit detection
9191 git_commit_pattern : Regex :: new (
9292 r#"(?i)(?:committed|commit)\s+(?:with\s+)?(?:hash\s+)?([a-f0-9]{7,40})"#
93- ) . expect ( "TODO: handle error " ) ,
93+ ) . expect ( "invariant: regex pattern is syntactically valid " ) ,
9494 git_push_pattern : Regex :: new (
9595 r#"(?i)(?:I\s+)?pushed\s+(?:to\s+)?(?:the\s+)?branch\s+[`"']?([^\s`"']+)[`"']?"#
96- ) . expect ( "TODO: handle error " ) ,
96+ ) . expect ( "invariant: regex pattern is syntactically valid " ) ,
9797 // Git branch - require "branch" keyword to avoid false positives
9898 git_branch_pattern : Regex :: new (
9999 r#"(?i)(?:I\s+)?(?:created|switched\s+to)\s+(?:the\s+)?branch\s+[`"']?([^\s`"']+)[`"']?"#
100- ) . expect ( "TODO: handle error " ) ,
100+ ) . expect ( "invariant: regex pattern is syntactically valid " ) ,
101101 // Directory operations - require "directory" or "folder" keyword
102102 directory_created_pattern : Regex :: new (
103103 r#"(?i)(?:I\s+)?(?:created|made)\s+(?:the\s+)?(?:directory|folder|dir)\s+[`"']?([^\s`"']+)[`"']?"#
104- ) . expect ( "TODO: handle error " ) ,
104+ ) . expect ( "invariant: regex pattern is syntactically valid " ) ,
105105 }
106106 }
107107
0 commit comments