### Elasticsearch Version

master

### Installed Plugins

N/A

### Java Version

_bundled_

### OS Version

N/A

### Problem Description

@arteam [observed](https://github.com/elastic/elasticsearch/pull/83221/files#r795474431) that `static record` is redundant, records are apparently implicitly static. I think we should make sure that Checkstyle picks this up rather than needing human involvement.

### Steps to Reproduce

Mark a record declaration as `static` and observe that `./gradlew precommit` still passes.

### Logs (if relevant)

_No response_
x-pack/plugin/ml/src/main/java/org/elasticsearch/xpack/ml/inference/nlp/tokenizers/BpeTokenizer.java
private final CharTermAttribute termAtt = addAttribute(CharTermAttribute.class);
    private final OffsetAttribute offsetAtt = addAttribute(OffsetAttribute.class);
    private final PositionIncrementAttribute posIncAtt = addAttribute(PositionIncrementAttribute.class);
    private static final Pattern pattern = Pattern.compile(
        "'s|'t|'re|'ve|'m|'ll|'d| ?\\p{L}+| ?\\p{N}+| ?[^\\s\\p{L}\\p{N}]+|\\s+(?!\\S)|\\s+"
    );
    static char[] byteEncoder() {
        List<Integer> bytes = IntStream.concat(
            IntStream.range(Character.codePointAt("!", 0), Character.codePointAt("~", 0) + 1),
            IntStream.concat(
                IntStream.range(Character.codePointAt("¡", 0), Character.codePointAt("¬", 0) + 1),
                IntStream.range(Character.codePointAt("®", 0), Character.codePointAt("ÿ", 0) + 1)
            )
        ).boxed().collect(Collectors.toList());
        List<Integer> chars = new ArrayList<>(bytes);
        int n = 0;
        for (int i = 0; i < 256; i++) {
            if (bytes.contains(i)) {
                continue;
            }
            bytes.add(i);
            chars.add(256 + n);
            n++;
        }
        char[] charArray = new char[chars.size()];
        for (int j = 0; j < bytes.size(); j++) {
            charArray[bytes.get(j)] = Character.toChars(chars.get(j))[0];
        }
        return charArray;