Maintain consistency in syntax highlighting patterns by using appropriate, specific scopes and avoiding overly complex or noisy patterns. Follow Helix-specific conventions rather than generic tree-sitter patterns.

Key guidelines:

Example of good pattern specificity:

; Good - specific scopes
[
  "for"
  "while"
] @keyword.control.repeat

[
  "if" 
  "else"
] @keyword.control.conditional

; Avoid - overly generic
[
  "for"
  "while" 
  "if"
  "else"
] @keyword

Example of proper precedence:

; Specific pattern first
((comment) @comment.block.documentation
  (#match? @comment.block.documentation "^//!"))

; Generic pattern second  
(comment) @comment.line

This approach ensures highlighting is consistent, follows project conventions, and provides clear visual feedback without being distracting or overly complex.