package entity

type ResearchItem struct {
	Title   string `bson:"title,omitempty" json:"title,omitempty"`
	URL     string `bson:"url,omitempty" json:"url,omitempty"`
	Snippet string `bson:"snippet,omitempty" json:"snippet,omitempty"`
	Query   string `bson:"query,omitempty" json:"query,omitempty"`
}

type ResearchMap struct {
	AudienceSummary string         `bson:"audience_summary,omitempty" json:"audience_summary,omitempty"`
	ContentGoal     string         `bson:"content_goal,omitempty" json:"content_goal,omitempty"`
	Questions       []string       `bson:"questions,omitempty" json:"questions,omitempty"`
	Pillars         []string       `bson:"pillars,omitempty" json:"pillars,omitempty"`
	Exclusions      []string       `bson:"exclusions,omitempty" json:"exclusions,omitempty"`
	ResearchItems   []ResearchItem `bson:"research_items,omitempty" json:"research_items,omitempty"`
	ExpandStrategy  string         `bson:"expand_strategy,omitempty" json:"expand_strategy,omitempty"`
	PatrolKeywords  []string       `bson:"patrol_keywords,omitempty" json:"patrol_keywords,omitempty"`
}

func (m ResearchMap) IsEmpty() bool {
	return m.AudienceSummary == "" &&
		m.ContentGoal == "" &&
		len(m.Questions) == 0 &&
		len(m.Pillars) == 0 &&
		len(m.Exclusions) == 0 &&
		len(m.ResearchItems) == 0
}
