diff --git a/configs/zero3.yaml b/configs/zero3.yaml index 21ab374fb..5159780b0 100644 --- a/configs/zero3.yaml +++ b/configs/zero3.yaml @@ -7,6 +7,15 @@ deepspeed_config: zero3_init_flag: true zero3_save_16bit_model: true zero_stage: 3 + overlap_comm: true + contiguous_gradients: true + reduce_bucket_size: 5e8 + stage3_prefetch_bucket_size: 5e8 + stage3_param_persistence_threshold: 1e5 + sub_group_size: 1e5 + dump_state: false + gradient_clipping: auto + distributed_type: DEEPSPEED downcast_bf16: 'no' machine_rank: 0 @@ -19,4 +28,4 @@ same_network: true tpu_env: [] tpu_use_cluster: false tpu_use_sudo: false -use_cpu: false \ No newline at end of file +use_cpu: false diff --git a/pyproject.toml b/pyproject.toml index e147980ba..39962b1ba 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -6,7 +6,7 @@ authors = [ version = "0.1.0" description = "Verifiers for reinforcement learning with LLMs" license = {text = "MIT"} -requires-python = ">=3.11" +requires-python = "==3.12.2" dependencies = [ "huanzhi-utils", "scikit-learn", diff --git a/verifiers/tools/bfcl_tools.py b/verifiers/tools/bfcl_tools.py index bdc7a6a67..6391d0207 100644 --- a/verifiers/tools/bfcl_tools.py +++ b/verifiers/tools/bfcl_tools.py @@ -3,14 +3,14 @@ import json INVOLVED_CLASS_TO_FUNC_DOC_PATH = { - "GorillaFileSystem": "/root/richard/test/verifiers/verifiers/tools/bfcl_tools/gorilla_file_system.json", - "MathAPI": "/root/richard/test/verifiers/verifiers/tools/bfcl_tools/math_api.json", - "MessageAPI": "/root/richard/test/verifiers/verifiers/tools/bfcl_tools/message_api.json", - "TwitterAPI": "/root/richard/test/verifiers/verifiers/tools/bfcl_tools/posting_api.json", - "TicketAPI": "/root/richard/test/verifiers/verifiers/tools/bfcl_tools/ticket_api.json", - "TradingBot": "/root/richard/test/verifiers/verifiers/tools/bfcl_tools/trading_bot.json", - "TravelAPI": "/root/richard/test/verifiers/verifiers/tools/bfcl_tools/travel_booking.json", - "VehicleControlAPI": "/root/richard/test/verifiers/verifiers/tools/bfcl_tools/vehicle_control.json", + "GorillaFileSystem": "verifiers/tools/bfcl_tools/gorilla_file_system.json", + "MathAPI": "verifiers/tools/bfcl_tools/math_api.json", + "MessageAPI": "verifiers/tools/bfcl_tools/message_api.json", + "TwitterAPI": "verifiers/tools/bfcl_tools/posting_api.json", + "TicketAPI": "verifiers/tools/bfcl_tools/ticket_api.json", + "TradingBot": "verifiers/tools/bfcl_tools/trading_bot.json", + "TravelAPI": "verifiers/tools/bfcl_tools/travel_booking.json", + "VehicleControlAPI": "verifiers/tools/bfcl_tools/vehicle_control.json", } def construct_tools_from_involved_classes(involved_classes: List[str]) -> str: diff --git a/verifiers/utils/data_utils.py b/verifiers/utils/data_utils.py index 209a9ff58..9697a3b45 100644 --- a/verifiers/utils/data_utils.py +++ b/verifiers/utils/data_utils.py @@ -106,8 +106,8 @@ def format_bfcl_prompt(system_prompt: str | None = None, involved_classes: List[ def preprocess_bfcl_dataset(system_prompt: str | None = None, curriculum_learning: bool = False) -> Dataset: # TODO: Change to local path - multi_turn_base_data = load_file("/root/richard/test/verifiers/verifiers/berkeley-function-call-leaderboard/data/BFCL_v3_multi_turn_base.json") - multi_turn_base_answer = load_file("/root/richard/test/verifiers/verifiers/berkeley-function-call-leaderboard/data/possible_answer/BFCL_v3_multi_turn_base.json") + multi_turn_base_data = load_file("verifiers/berkeley-function-call-leaderboard/data/BFCL_v3_multi_turn_base.json") + multi_turn_base_answer = load_file("verifiers/berkeley-function-call-leaderboard/data/possible_answer/BFCL_v3_multi_turn_base.json") # Reprocess the columns into serializable format and add num_turns for i in range(len(multi_turn_base_data)):