<commit_before>package actor

type Decider func(child *PID, cause interface{}) Directive

type SupervisorStrategy interface {
	HandleFailure(supervisor Supervisor, child *PID, crs *ChildRestartStats, cause interface{})
}

type Supervisor interface {
	Children() []*PID
	EscalateFailure(who *PID, reason interface{})
}

func logFailure(child *PID, reason interface{}, directive Directive) {
	event := &SupervisorEvent{
		Child:     child,
		Reason:    reason,
		Directive: directive,
	}
	EventStream.Publish(event)
}

func DefaultDecider(child *PID, reason interface{}) Directive {
	return RestartDirective
}

var defaultSupervisionStrategy = NewOneForOneStrategy(10, 3000, DefaultDecider)

func DefaultSupervisionStrategy() SupervisorStrategy {
	return defaultSupervisionStrategy
}<commit_msg>rename default supervisor strategy<commit_after>package actor

type Decider func(child *PID, cause interface{}) Directive

type SupervisorStrategy interface {
	HandleFailure(supervisor Supervisor, child *PID, crs *ChildRestartStats, cause interface{})
}

type Supervisor interface {
	Children() []*PID
	EscalateFailure(who *PID, reason interface{})
}

func logFailure(child *PID, reason interface{}, directive Directive) {
	event := &SupervisorEvent{
		Child:     child,
		Reason:    reason,
		Directive: directive,
	}
	EventStream.Publish(event)
}

func DefaultDecider(child *PID, reason interface{}) Directive {
	return RestartDirective
}

var defaultSupervisionStrategy = NewOneForOneStrategy(10, 3000, DefaultDecider)

func DefaultSupervisorStrategy() SupervisorStrategy {
	return defaultSupervisionStrategy
}
{'fraction_non_alphanumeric': 0.09090909090909091, 'fraction_numerical': 0.007471980074719801, 'mean_word_length': 6.580188679245283, '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': '1735973', 'n_tokens_mistral': 483, 'n_tokens_neox': 449, 'n_words': 129}