Skip to content

Commit

Permalink
format step log
Browse files Browse the repository at this point in the history
  • Loading branch information
SmartManoj committed Nov 21, 2024
1 parent bc2de6d commit cbcdf07
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions openhands/server/data_models/feedback.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,10 @@ def store_feedback(feedback: FeedbackDataModel) -> dict[str, str]:
},
}
feedback.trajectory = [config] + feedback.trajectory if feedback.trajectory else []
for idx, item in enumerate(feedback.trajectory):
if item.get('log'):
item = {'step': item['log'].split()[-1]}
feedback.trajectory[idx] = item
# Start actual request
response = requests.post(
FEEDBACK_URL,
Expand Down

0 comments on commit cbcdf07

Please sign in to comment.