<commit_before>package analysis

import (
	"encoding/json"
	"time"
)

// Analysis is a representation of an Ion Channel Analysis within the system
type Analysis struct {
	ID            string            `json:"id" xml:"id"`
	TeamID        string            `json:"team_id" xml:"team_id"`
	ProjectID     string            `json:"project_id" xml:"project_id"`
	BuildNumber   string            `json:"build_number" xml:"build_number"`
	Name          string            `json:"name" xml:"name"`
	Text          string            `json:"text" xml:"text"`
	Type          string            `json:"type" xml:"type"`
	Source        string            `json:"source" xml:"source"`
	Branch        string            `json:"branch" xml:"branch"`
	Description   string            `json:"description" xml:"description"`
	Status        string            `json:"status" xml:"status"`
	RulesetID     string            `json:"ruleset_id" xml:"ruleset_id"`
	CreatedAt     time.Time         `json:"created_at" xml:"created_at"`
	UpdatedAt     time.Time         `json:"updated_at" xml:"updated_at"`
	Duration      float64           `json:"duration" xml:"duration"`
	TriggerHash   string            `json:"trigger_hash" xml:"trigger_hash"`
	TriggerText   string            `json:"trigger_text" xml:"trigger_text"`
	TriggerAuthor string            `json:"trigger_author" xml:"trigger_author"`
	ScanSummaries []json.RawMessage `json:"scan_summaries" xml:"scan_summaries"`
}

// Summary is a representation of a summarized Ion Channel Analysis
// within the system
type Summary struct {
	ID            string    `json:"id"`
	AnalysisID    string    `json:"analysis_id"`
	TeamID        string    `json:"team_id"`
	BuildNumber   string    `json:"build_number"`<commit_msg>analysis needs to get the joke<commit_after>package analysis

import (
	"time"

	"github.com/ion-channel/ionic/scans"
)

// Analysis is a representation of an Ion Channel Analysis within the system
type Analysis struct {
	ID            string              `json:"id" xml:"id"`
	TeamID        string              `json:"team_id" xml:"team_id"`
	ProjectID     string              `json:"project_id" xml:"project_id"`
	BuildNumber   string              `json:"build_number" xml:"build_number"`
	Name          string              `json:"name" xml:"name"`
	Text          string              `json:"text" xml:"text"`
	Type          string              `json:"type" xml:"type"`
	Source        string              `json:"source" xml:"source"`
	Branch        string              `json:"branch" xml:"branch"`
	Description   string              `json:"description" xml:"description"`
	Status        string              `json:"status" xml:"status"`
	RulesetID     string              `json:"ruleset_id" xml:"ruleset_id"`
	CreatedAt     time.Time           `json:"created_at" xml:"created_at"`
	UpdatedAt     time.Time           `json:"updated_at" xml:"updated_at"`
	Duration      float64             `json:"duration" xml:"duration"`
	TriggerHash   string              `json:"trigger_hash" xml:"trigger_hash"`
	TriggerText   string              `json:"trigger_text" xml:"trigger_text"`
	TriggerAuthor string              `json:"trigger_author" xml:"trigger_author"`
	ScanSummaries []scans.ScanSummary `json:"scan_summaries" xml:"scan_summaries"`
}

// Summary is a representation of a summarized Ion Channel Analysis
// within the system
type Summary struct {
	ID            string    `json:"id"`
	AnalysisID    string    `json:"analysis_id"`
	TeamID        string    `json:"team_id"`
	BuildNumber   string    `json:"build_number"`
{'fraction_non_alphanumeric': 0.11126720989041866, 'fraction_numerical': 0.00112391121101433, 'mean_word_length': 2.466407010710808, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 38}, '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': '6302539', 'n_tokens_mistral': 978, 'n_tokens_neox': 969, 'n_words': 252}