Update environment.py
Browse files246 unmodified lines247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285246 unmodified linesif self._last_action_type in ("write_comment", "ask_question", "propose_fix"):author_response = self._test_results or ""else:author_response = ""return EnhancedObservation(code_snippet=self._current_code,last_tool_output=self._test_results or "",author_response=author_response, # ← fixedcurrent_test_score=self._current_test_score,current_lint_score=self._current_lint_score,negotiation_score=self._author.get_negotiation_score(),previous_test_score=self._previous_test_score,previous_lint_score=self._previous_lint_score,author_confidence=self._author._confidence,author_threshold=self._author.thresholds.get(self._author.personality, 0.5),step=self._step_count,max_steps=self.max_steps,progress_ratio=self._step_count / self.max_steps,tests_run=self._tests_run,linter_run=self._linter_run,docs_queried=self._docs_queried,last_action_type=self._last_action_type,action_history=self._action_history[-5:],done=self._done,bug_description=self._bug_description,comments_count=len(self._comments),)# ===================================================================def _compute_dense_reward(self,246 unmodified lines247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285246 unmodified linesif self._last_action_type in ("write_comment", "ask_question", "propose_fix"):author_response = self._test_results or ""else:author_response = ""return EnhancedObservation(code_snippet=self._current_code,last_tool_output=self._test_results or "",author_response=author_response, # ← fixedcurrent_test_score=self._current_test_score,current_lint_score=self._current_lint_score,negotiation_score=self._author.get_negotiation_score(),previous_test_score=self._previous_test_score,previous_lint_score=self._previous_lint_score,author_confidence=self._author._confidence,author_threshold=self._author.thresholds.get(self._author.personality, 0.5),step=self._step_count,max_steps=self.max_steps,progress_ratio=self._step_count / self.max_steps,tests_run=self._tests_run,linter_run=self._linter_run,docs_queried=self._docs_queried,last_action_type=self._last_action_type,action_history=self._action_history[-5:],done=self._done,bug_description=self._bug_description,comments_count=len(self._comments),)# ===================================================================def _compute_dense_reward(self,
environment.py+23-23