Unverified Commit 3a6cbf16 authored by Taneem Ibrahim's avatar Taneem Ibrahim Committed by GitHub
Browse files

[MISC] Removed unused function find_all_indices() from tool_parsers/utils.py (#35683)


Signed-off-by: default avatarTaneem Ibrahim <taneem.ibrahim@gmail.com>
parent f44d1ddc
......@@ -93,21 +93,6 @@ def extract_intermediate_diff(curr: str, old: str) -> str:
return diff
def find_all_indices(string: str, substring: str) -> list[int]:
"""
Find all (starting) indices of a substring in a given string. Useful for
tool call extraction
"""
indices = []
index = -1
while True:
index = string.find(substring, index + 1)
if index == -1:
break
indices.append(index)
return indices
# partial_json_parser doesn't support extra data and
# JSONDecoder.raw_decode doesn't support partial JSON
def partial_json_loads(input_str: str, flags: Allow) -> tuple[Any, int]:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment