Skip to content

Linger is An Open-Source Personal Agent That Runs Fully on Your PC. We aim to break Big Tech’s grip on AI by bringing powerful local AI to everyday computers through efficient model–harness co-design, so everyone can run their own.

391 B
Raw Blame
// Package ids generates TeamHub's random prefixed identifiers.
package ids

import (
	"crypto/rand"
	"encoding/hex"
)

// New returns prefix, an underscore, and 128 random bits as lowercase hex.
func New(prefix string) string {
	value := make([]byte, 16)
	// crypto/rand.Read never returns an error since Go 1.24.
	_, _ = rand.Read(value)
	return prefix + "_" + hex.EncodeToString(value)
}