<commit_before>package gmx

import (
	"sync/atomic"
)

type counter struct {
	value uint64
}

func (c *counter) Inc() {
	atomic.AddUint64(&c.value, 1)
}

func NewCounter(name string) *counter {
	c := new(counter)
	Publish(name, func() interface{} {
		return c.value
	})
	return c
}

type gauge struct {
	value int64
}

func (g *gauge) Inc() {
	atomic.AddInt64(&g.value, 1)
}

func (g *gauge) Dec() {
	atomic.AddInt64(&g.value, -1)
}

func NewGauge(name string) *gauge {
	g := new(gauge)
	Publish(name, func() interface{} {
		return g.value
	})
	return g
}<commit_msg>Export Counter and Gauge types<commit_after>package gmx

import (
	"sync/atomic"
)

type Counter struct {
	value uint64
}

func (c *Counter) Inc() {
	atomic.AddUint64(&c.value, 1)
}

func NewCounter(name string) *Counter {
	c := new(Counter)
	Publish(name, func() interface{} {
		return c.value
	})
	return c
}

type Gauge struct {
	value int64
}

func (g *Gauge) Inc() {
	atomic.AddInt64(&g.value, 1)
}

func (g *Gauge) Dec() {
	atomic.AddInt64(&g.value, -1)
}

func NewGauge(name string) *Gauge {
	g := new(Gauge)
	Publish(name, func() interface{} {
		return g.value
	})
	return g
}
{'fraction_non_alphanumeric': 0.15638575152041703, 'fraction_numerical': 0.022589052997393572, 'mean_word_length': 3.902127659574468, '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': '4350218', 'n_tokens_mistral': 489, 'n_tokens_neox': 463, 'n_words': 120}