Skip to content

Commit

Permalink
bugfix: make sure batch values are all strings
Browse files Browse the repository at this point in the history
Else, this will break the `name=value` call to guidance
  • Loading branch information
parkervg committed Oct 22, 2024
1 parent 2c0e089 commit 61b63dc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion blendsql/ingredients/builtin/map/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ def make_predictions(lm, values, gen_f) -> guidance.models.Model:
for i in context_manager:
curr_batch_values = values[i : i + batch_size]
current_batch_example = copy.deepcopy(current_example)
current_batch_example.values = curr_batch_values
current_batch_example.values = [str(i) for i in curr_batch_values]
with guidance.user():
batch_lm = lm + current_example.to_string(
include_values=False, list_options=list_options_in_prompt
Expand Down

0 comments on commit 61b63dc

Please sign in to comment.