<commit_before>package model

import "strings"

//Path represents a system path
type Path struct {
	index map[string]bool
	Items []string
}

//Push appends path to the system paths
func (p *Path) Push(paths ...string) {
	for _, path := range paths {
		if strings.Contains(path, "\n") {
			continue
		}
		if _, has := p.index[path]; has {
			continue
		}
		p.Items = append(p.Items, path)
		p.index[path] = true
	}
}<commit_msg>updated path to add as first element<commit_after>package model

import "strings"

//Path represents a system path
type Path struct {
	index map[string]bool
	Items []string
}

//Unshift add path at the begining to the system paths
func (p *Path) Unshift(paths ...string) {
	for _, path := range paths {
		if strings.Contains(path, "\n") {
			continue
		}
		if _, has := p.index[path]; has {
			continue
		}
		p.Items = append([]string{path}, p.Items...)
		p.index[path] = true
	}
}
{'fraction_non_alphanumeric': 0.1354625550660793, 'fraction_numerical': 0.0, 'mean_word_length': 3.308056872037915, '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': '2169007', 'n_tokens_mistral': 327, 'n_tokens_neox': 304, 'n_words': 101}