mirror of
https://github.com/katanemo/plano.git
synced 2026-04-29 19:06:34 +02:00
Serialize tool calls for Arch FC (#131)
* Serialize tool calls * fix int tests
This commit is contained in:
parent
b43f687b85
commit
96686dc606
10 changed files with 166 additions and 57 deletions
|
|
@ -69,7 +69,8 @@ def process_state(arch_state, history: list[Message]):
|
|||
if hist.role == 'user':
|
||||
sha_history.append(hist.content)
|
||||
sha256_hash = hashlib.sha256()
|
||||
sha256_hash.update(json.dumps(sha_history).encode())
|
||||
joined_key_str = ('#.#').join(sha_history)
|
||||
sha256_hash.update(joined_key_str.encode())
|
||||
sha_key = sha256_hash.hexdigest()
|
||||
print(f"sha_key: {sha_key}")
|
||||
if sha_key in state_map:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue