Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FillerDetector ¶
type FillerDetector struct {
// contains filtered or unexported fields
}
func NewFillerDetector ¶
func NewFillerDetector() *FillerDetector
func (*FillerDetector) Detect ¶
func (d *FillerDetector) Detect(input string) []WasteFinding
type OutputUtilizationTracker ¶
type OutputUtilizationTracker struct {
}
func NewOutputUtilizationTracker ¶
func NewOutputUtilizationTracker() *OutputUtilizationTracker
func (*OutputUtilizationTracker) Track ¶
func (t *OutputUtilizationTracker) Track(inputTokens int, outputTokens int) WasteFinding
type RedundantInstructionDetector ¶
type RedundantInstructionDetector struct{}
func NewRedundantInstructionDetector ¶
func NewRedundantInstructionDetector() *RedundantInstructionDetector
func (*RedundantInstructionDetector) Detect ¶
func (d *RedundantInstructionDetector) Detect(input string) []WasteFinding
type WasteAnalyzer ¶
type WasteAnalyzer struct {
// contains filtered or unexported fields
}
func NewWasteAnalyzer ¶
func NewWasteAnalyzer() *WasteAnalyzer
func (*WasteAnalyzer) Analyze ¶
func (a *WasteAnalyzer) Analyze(input string) *WasteReport
type WasteFinding ¶
type WasteRecord ¶
type WasteReport ¶
type WasteReport struct {
TotalTokens int `json:"total_tokens"`
WasteTokens int `json:"waste_tokens"`
WasteScore float64 `json:"waste_score"`
Findings []WasteFinding `json:"findings"`
Recommendations []string `json:"recommendations"`
}
type WasteScoreCalculator ¶
type WasteScoreCalculator struct{}
func NewWasteScoreCalculator ¶
func NewWasteScoreCalculator() *WasteScoreCalculator
func (*WasteScoreCalculator) Calculate ¶
func (c *WasteScoreCalculator) Calculate(totalTokens int, findings []WasteFinding) float64
type WasteStore ¶
type WasteStore struct {
// contains filtered or unexported fields
}
func NewWasteStore ¶
func NewWasteStore(db *sql.DB) *WasteStore
func (*WasteStore) GetAverageScore ¶
func (s *WasteStore) GetAverageScore(days int) (float64, error)
func (*WasteStore) GetTrend ¶
func (s *WasteStore) GetTrend(days int) ([]WasteRecord, error)
func (*WasteStore) Init ¶
func (s *WasteStore) Init() error
func (*WasteStore) Record ¶
func (s *WasteStore) Record(command string, report *WasteReport) error
type WhitespaceBloatDetector ¶
type WhitespaceBloatDetector struct {
// contains filtered or unexported fields
}
func NewWhitespaceBloatDetector ¶
func NewWhitespaceBloatDetector() *WhitespaceBloatDetector
func (*WhitespaceBloatDetector) Detect ¶
func (d *WhitespaceBloatDetector) Detect(input string) []WasteFinding
Click to show internal directories.
Click to hide internal directories.