<commit_before>package main

import (
	"strings"
)

type (
	RetryableError interface {
		Retryable() bool
	}
)

type (
	InvalidJobError struct {
		msg string
	}
)

func (e InvalidJobError) Error() string {
	return e.msg
}

func (e InvalidJobError) Retryable() bool {
	return false
}

type (
	CompositeError struct {
		errors []error
	}
)

func (e *CompositeError) Error() string {
	msgs := []string{}
	for _, err := range e.errors {
		msgs = append(msgs, err.Error())
	}
	return strings.Join(msgs, "\n")
}

func (e CompositeError) Retryable() bool {
	for _, err := range e.errors {
		switch err.(type) {
		case RetryableError:
			e := err.(RetryableError)
			if !e.Retryable() {
				return false
			}
		}
	}
	return true
}<commit_msg>:bug: Fix the method definitions<commit_after>package main

import (
	"strings"
)

type (
	RetryableError interface {
		Retryable() bool
	}
)

type (
	InvalidJobError struct {
		msg string
	}
)

func (e *InvalidJobError) Error() string {
	return e.msg
}

func (e *InvalidJobError) Retryable() bool {
	return false
}

type (
	CompositeError struct {
		errors []error
	}
)

func (e *CompositeError) Error() string {
	msgs := []string{}
	for _, err := range e.errors {
		msgs = append(msgs, err.Error())
	}
	return strings.Join(msgs, "\n")
}

func (e *CompositeError) Retryable() bool {
	for _, err := range e.errors {
		switch err.(type) {
		case RetryableError:
			e := err.(RetryableError)
			if !e.Retryable() {
				return false
			}
		}
	}
	return true
}

func (e *CompositeError) Any(f func(error) bool) bool {
	for _, err := range e.errors {
		if f(err) {
			return true
		}
	}
	return false
}
{'fraction_non_alphanumeric': 0.134886572654813, 'fraction_numerical': 0.0, 'mean_word_length': 3.3404255319148937, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6973221', 'n_tokens_mistral': 645, 'n_tokens_neox': 615, 'n_words': 163}