DawnC commited on
Commit
7466dd7
·
verified ·
1 Parent(s): 25d1488

Update score_integration_manager.py

Browse files
Files changed (1) hide show
  1. score_integration_manager.py +8 -5
score_integration_manager.py CHANGED
@@ -317,25 +317,28 @@ class ScoreIntegrationManager:
317
  temperament = breed_info.get('Temperament', '').lower()
318
  description = breed_info.get('Description', '').lower()
319
 
320
- # 重新定義空間需求矩陣,降低對大型犬的懲罰
321
  space_requirements = {
322
  'apartment': {
323
  'Small': 1.0,
324
  'Medium': 0.8,
325
  'Large': 0.7,
326
- 'Giant': 0.6
 
327
  },
328
  'house_small': {
329
  'Small': 0.9,
330
  'Medium': 1.0,
331
  'Large': 0.8,
332
- 'Giant': 0.7
 
333
  },
334
  'house_large': {
335
  'Small': 0.8,
336
  'Medium': 0.9,
337
  'Large': 1.0,
338
- 'Giant': 1.0
 
339
  }
340
  }
341
 
@@ -802,4 +805,4 @@ class ScoreIntegrationManager:
802
  if user_prefs.climate in description or user_prefs.climate in temperament:
803
  adaptability_score += 0.05
804
 
805
- return min(0.2, adaptability_score)
 
317
  temperament = breed_info.get('Temperament', '').lower()
318
  description = breed_info.get('Description', '').lower()
319
 
320
+ # 降低對大型犬的懲罰
321
  space_requirements = {
322
  'apartment': {
323
  'Small': 1.0,
324
  'Medium': 0.8,
325
  'Large': 0.7,
326
+ 'Giant': 0.6,
327
+ 'Varies': 0.8
328
  },
329
  'house_small': {
330
  'Small': 0.9,
331
  'Medium': 1.0,
332
  'Large': 0.8,
333
+ 'Giant': 0.7,
334
+ 'Varies': 1.0
335
  },
336
  'house_large': {
337
  'Small': 0.8,
338
  'Medium': 0.9,
339
  'Large': 1.0,
340
+ 'Giant': 1.0,
341
+ 'Varies': 0.9
342
  }
343
  }
344
 
 
805
  if user_prefs.climate in description or user_prefs.climate in temperament:
806
  adaptability_score += 0.05
807
 
808
+ return min(0.2, adaptability_score)