Skip to content

Commit

Permalink
Update prompt_based.py to fix the trailing space PR issues
Browse files Browse the repository at this point in the history
  • Loading branch information
VanyaBK authored Dec 5, 2023
1 parent d0cd15c commit 58038d9
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions prompt2model/dataset_generator/prompt_based.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,14 +40,14 @@ class Example:

def __eq__(self, other) -> bool:
"""Example equality."""
return (self.input_col == other.input_col and
self.output_col == other.output_col and
return (self.input_col == other.input_col and
self.output_col == other.output_col and
self.explain_col == other.explain_col)

def __lt__(self, other) -> bool:
"""Example less than."""
return (self.input_col < other.input_col
or self.output_col < other.output_col
return (self.input_col < other.input_col
or self.output_col < other.output_col
or self.explain_col < other.explain_col)


Expand Down Expand Up @@ -263,8 +263,8 @@ def apply_multi_vote_filtering(

filtered_examples.append(
Example(
input_str,
random.choice(output_explain_map[final_output]),
input_str,
random.choice(output_explain_map[final_output]),
final_output
)
)
Expand Down

0 comments on commit 58038d9

Please sign in to comment.