Skip to content

Commit 8d989dd

Browse files
committed
more flexible TrainablePolicyModel
1 parent 069f04d commit 8d989dd

File tree

16 files changed

+1554
-1504
lines changed

16 files changed

+1554
-1504
lines changed

dev/yes-no-maybe.ipynb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -41,12 +41,12 @@
4141
"load_dotenv()\n",
4242
"\n",
4343
"\n",
44-
"api = art.LocalAPI()\n",
45-
"model = await api.get_or_create_model(\n",
44+
"model = art.TrainableModel(\n",
4645
" name=\"001\",\n",
4746
" project=\"yes-no-maybe\",\n",
4847
" base_model=\"Qwen/Qwen2.5-7B-Instruct\",\n",
4948
")\n",
49+
"await model.register_for_training(art.LocalAPI())\n",
5050
"\n",
5151
"\n",
5252
"async def rollout(client: openai.AsyncOpenAI, prompt: str) -> art.Trajectory:\n",
@@ -90,7 +90,7 @@
9090
" ]\n",
9191
"]\n",
9292
"\n",
93-
"openai_client = await model.openai_client()\n",
93+
"openai_client = model.openai_client()\n",
9494
"for _ in range(await model.get_step(), 1_000):\n",
9595
" train_groups = await art.gather_trajectory_groups(\n",
9696
" (\n",

0 commit comments

Comments
 (0)