<commit_before>package resource

import "github.com/google/go-github/github"

func metadataFromRelease(release *github.RepositoryRelease) []MetadataPair {
	metadata := []MetadataPair{}

	if release.Name != nil {
		nameMeta := MetadataPair{
			Name:  "name",
			Value: *release.Name,
		}

		if release.HTMLURL != nil {
			nameMeta.URL = *release.HTMLURL
		}

		metadata = append(metadata, nameMeta)
	}

	if release.HTMLURL != nil {
		metadata = append(metadata, MetadataPair{
			Name:  "url",
			Value: *release.HTMLURL,
		})
	}

	if release.Body != nil {
		metadata = append(metadata, MetadataPair{
			Name:     "body",
			Value:    *release.Body,
			Markdown: true,
		})
	}

	if release.TagName != nil {
		metadata = append(metadata, MetadataPair{
			Name:  "tag",
			Value: *release.TagName,
		})
	}

	if *release.Draft {
		metadata = append(metadata, MetadataPair{
			Name:  "draft",
			Value: "true",
		})
	}

	return metadata
}<commit_msg>Let us know if its a prerelease in the metadata<commit_after>package resource

import "github.com/google/go-github/github"

func metadataFromRelease(release *github.RepositoryRelease) []MetadataPair {
	metadata := []MetadataPair{}

	if release.Name != nil {
		nameMeta := MetadataPair{
			Name:  "name",
			Value: *release.Name,
		}

		if release.HTMLURL != nil {
			nameMeta.URL = *release.HTMLURL
		}

		metadata = append(metadata, nameMeta)
	}

	if release.HTMLURL != nil {
		metadata = append(metadata, MetadataPair{
			Name:  "url",
			Value: *release.HTMLURL,
		})
	}

	if release.Body != nil {
		metadata = append(metadata, MetadataPair{
			Name:     "body",
			Value:    *release.Body,
			Markdown: true,
		})
	}

	if release.TagName != nil {
		metadata = append(metadata, MetadataPair{
			Name:  "tag",
			Value: *release.TagName,
		})
	}

	if *release.Draft {
		metadata = append(metadata, MetadataPair{
			Name:  "draft",
			Value: "true",
		})
	}


	if *release.Prerelease {
		metadata = append(metadata, MetadataPair{
			Name:  "pre-release",
			Value: "true",
		})
	}
	return metadata
}
{'fraction_non_alphanumeric': 0.13747553816046967, 'fraction_numerical': 0.0, 'mean_word_length': 3.379014989293362, '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': '5340781', 'n_tokens_mistral': 796, 'n_tokens_neox': 695, 'n_words': 158}