Skip to content

Commit

Permalink
feat: 타입 오류 해결
Browse files Browse the repository at this point in the history
  • Loading branch information
hin6150 committed Nov 6, 2024
1 parent 3293bae commit 4e584c8
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions main.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,9 @@ def recommend_outfit(user_data: UserData):
user_data.gender,
user_data.activity_style,
user_data.activity_type,
f"온도 {user_data.weather['temperature']}도",
f"체감온도 {user_data.weather['feels_like']}도",
f"바람 {user_data.weather['wind_speed']}m/s",
f"온도 {user_data.weather.temperature}도",
f"체감온도 {user_data.weather.feels_like}도",
f"바람 {user_data.weather.wind_speed}m/s",
user_data.time,
user_data.location
]
Expand Down Expand Up @@ -121,11 +121,11 @@ def create_dynamic_prompt(user_data):
gender=user_data.gender,
activity_style=user_data.activity_style,
activity_type=user_data.activity_type,
temperature=user_data.weather["temperature"],
feels_like=user_data.weather["feels_like"],
precipitation_chance=user_data.weather["precipitation_chance"],
humidity=user_data.weather["humidity"],
wind_speed=user_data.weather["wind_speed"],
temperature=user_data.weather.temperature,
feels_like=user_data.weather.feels_like,
precipitation_chance=user_data.weather.precipitation_chance,
humidity=user_data.weather.humidity,
wind_speed=user_data.weather.wind_speed,
time=user_data.time,
location=user_data.location,
retrieved_items=retrieved_items,
Expand All @@ -142,7 +142,7 @@ def create_dynamic_prompt(user_data):
try:
import json
result = json.loads(response)
feels_like_temp = user_data.weather['feels_like']
feels_like_temp = user_data.weather.feels_like

if feels_like_temp > 21:
result['OUTER'] = None
Expand Down

0 comments on commit 4e584c8

Please sign in to comment.