Fix error print in dataset

This commit is contained in:
2025-04-18 12:42:24 +00:00
parent 5e47200ece
commit 64fc621d44

View File

@@ -120,12 +120,12 @@ class Dataset(torch.utils.data.Dataset):
# Check system prompt hash # Check system prompt hash
file_system_hash = root.get('system_prompt_hash') file_system_hash = root.get('system_prompt_hash')
if file_system_hash != self.system_prompt_hash: if file_system_hash != self.system_prompt_hash:
print(f"WARNING: System prompt hash mismatch in {file_path}") print(f"WARNING: System prompt hash mismatch in {file}")
# Check action schema hash # Check action schema hash
file_schema_hash = root.get('action_schema_hash') file_schema_hash = root.get('action_schema_hash')
if file_schema_hash != self.action_schema_hash: if file_schema_hash != self.action_schema_hash:
print(f"WARNING: Action schema hash mismatch in {file_path}") print(f"WARNING: Action schema hash mismatch in {file}")
# Check for required elements # Check for required elements
context_elem = root.find('context') context_elem = root.find('context')