telemetry

package
v1.9.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 27, 2026 License: MIT Imports: 6 Imported by: 0

Documentation

Overview

Package telemetry provides measurement tools for engram's belief revision system.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type SimilaritySnapshot

type SimilaritySnapshot struct {
	TotalPairs       int     `json:"total_pairs"`
	HighSimPairs     int     `json:"high_sim_pairs"`      // cosine > 0.85
	VeryHighSimPairs int     `json:"very_high_sim_pairs"` // cosine > 0.90
	HighSimPercent   float64 `json:"high_sim_percent"`
	VeryHighPercent  float64 `json:"very_high_sim_percent"`
	SampleSize       int     `json:"sample_size"`
}

SimilaritySnapshot holds the results of a similarity analysis run.

type SimilarityTelemetry

type SimilarityTelemetry struct {
	// contains filtered or unexported fields
}

SimilarityTelemetry measures pairwise similarity overlap among observations.

func NewSimilarityTelemetry

func NewSimilarityTelemetry(
	store *gorm.Store,
	observationStore *gorm.ObservationStore,
	vectorClient vector.Client,
	log zerolog.Logger,
) *SimilarityTelemetry

NewSimilarityTelemetry creates a new SimilarityTelemetry instance.

func (*SimilarityTelemetry) GetAllLatestSnapshots

func (st *SimilarityTelemetry) GetAllLatestSnapshots(ctx context.Context) (map[string]*SimilaritySnapshot, error)

GetAllLatestSnapshots returns the most recent snapshot per project.

func (*SimilarityTelemetry) GetLatestSnapshot

func (st *SimilarityTelemetry) GetLatestSnapshot(ctx context.Context, project string) (*SimilaritySnapshot, error)

GetLatestSnapshot returns the most recent similarity snapshot for a project.

func (*SimilarityTelemetry) Run

func (st *SimilarityTelemetry) Run(ctx context.Context)

Run executes the similarity telemetry analysis for all projects.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL