diff --git a/internal/services/suggestion_service.go b/internal/services/suggestion_service.go index e36ccc6..4ed1576 100644 --- a/internal/services/suggestion_service.go +++ b/internal/services/suggestion_service.go @@ -42,7 +42,6 @@ type templateConditions struct { HasGarage *bool `json:"has_garage,omitempty"` HasBasement *bool `json:"has_basement,omitempty"` HasAttic *bool `json:"has_attic,omitempty"` - ClimateRegion *string `json:"climate_region,omitempty"` PropertyType *string `json:"property_type,omitempty"` } @@ -52,7 +51,7 @@ func (c *templateConditions) isEmpty() bool { c.RoofType == nil && c.ExteriorType == nil && c.FlooringPrimary == nil && c.LandscapingType == nil && c.HasPool == nil && c.HasSprinkler == nil && c.HasSeptic == nil && c.HasFireplace == nil && c.HasGarage == nil && - c.HasBasement == nil && c.HasAttic == nil && c.ClimateRegion == nil && + c.HasBasement == nil && c.HasAttic == nil && c.PropertyType == nil } @@ -61,7 +60,7 @@ const ( baseUniversalScore = 0.3 stringMatchBonus = 0.25 boolMatchBonus = 0.3 - climateRegionBonus = 0.2 + // climateRegionBonus removed — suggestions now based on home features only propertyTypeBonus = 0.15 totalProfileFields = 14 ) @@ -300,15 +299,6 @@ func (s *SuggestionService) scoreTemplate(tmpl *models.TaskTemplate, residence * } } - // Climate region match - compare condition against template's associated regions - // (residence climate region is determined by ZIP code; template regions are preloaded) - if cond.ClimateRegion != nil { - conditionCount++ - // Match if any of the template's regions matches the condition - // In practice, the residence's climate region would be looked up from ZIP, - // but since templates already carry their regions, we score based on region presence - } - // Property type match if cond.PropertyType != nil { conditionCount++