Skip to content

Commit 38148d0

Browse files
committed
Update 2025-10-06 03:11:10
1 parent 4c348c9 commit 38148d0

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

43 files changed

+5118
-5211
lines changed

_sources/advanced_features/lora.ipynb

Lines changed: 161 additions & 156 deletions
Large diffs are not rendered by default.

_sources/advanced_features/separate_reasoning.ipynb

Lines changed: 122 additions & 96 deletions
Large diffs are not rendered by default.

_sources/advanced_features/speculative_decoding.ipynb

Lines changed: 401 additions & 363 deletions
Large diffs are not rendered by default.

_sources/advanced_features/structured_outputs.ipynb

Lines changed: 132 additions & 139 deletions
Large diffs are not rendered by default.

_sources/advanced_features/structured_outputs_for_reasoning_models.ipynb

Lines changed: 171 additions & 191 deletions
Large diffs are not rendered by default.

_sources/advanced_features/tool_parser.ipynb

Lines changed: 159 additions & 160 deletions
Large diffs are not rendered by default.

_sources/advanced_features/vlm_query.ipynb

Lines changed: 230 additions & 237 deletions
Large diffs are not rendered by default.

_sources/basic_usage/native_api.ipynb

Lines changed: 154 additions & 160 deletions
Large diffs are not rendered by default.

_sources/basic_usage/offline_engine_api.ipynb

Lines changed: 468 additions & 508 deletions
Large diffs are not rendered by default.

_sources/basic_usage/openai_api_completions.ipynb

Lines changed: 64 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -31,10 +31,10 @@
3131
"execution_count": 1,
3232
"metadata": {
3333
"execution": {
34-
"iopub.execute_input": "2025-10-06T02:09:58.606964Z",
35-
"iopub.status.busy": "2025-10-06T02:09:58.606839Z",
36-
"iopub.status.idle": "2025-10-06T02:10:37.396079Z",
37-
"shell.execute_reply": "2025-10-06T02:10:37.395176Z"
34+
"iopub.execute_input": "2025-10-06T03:00:32.007007Z",
35+
"iopub.status.busy": "2025-10-06T03:00:32.006876Z",
36+
"iopub.status.idle": "2025-10-06T03:01:13.019849Z",
37+
"shell.execute_reply": "2025-10-06T03:01:13.019316Z"
3838
}
3939
},
4040
"outputs": [
@@ -76,7 +76,13 @@
7676
"output_type": "stream",
7777
"text": [
7878
"/usr/local/lib/python3.10/dist-packages/torch/cuda/__init__.py:63: FutureWarning: The pynvml package is deprecated. Please install nvidia-ml-py instead. If you did not install pynvml directly, please report this to the maintainers of the package that installed pynvml for you.\n",
79-
" import pynvml # type: ignore[import]\n",
79+
" import pynvml # type: ignore[import]\n"
80+
]
81+
},
82+
{
83+
"name": "stdout",
84+
"output_type": "stream",
85+
"text": [
8086
"/usr/local/lib/python3.10/dist-packages/torch/cuda/__init__.py:63: FutureWarning: The pynvml package is deprecated. Please install nvidia-ml-py instead. If you did not install pynvml directly, please report this to the maintainers of the package that installed pynvml for you.\n",
8187
" import pynvml # type: ignore[import]\n"
8288
]
@@ -86,7 +92,7 @@
8692
"output_type": "stream",
8793
"text": [
8894
"`torch_dtype` is deprecated! Use `dtype` instead!\n",
89-
"[2025-10-06 02:10:25] `torch_dtype` is deprecated! Use `dtype` instead!\n"
95+
"[2025-10-06 03:01:01] `torch_dtype` is deprecated! Use `dtype` instead!\n"
9096
]
9197
},
9298
{
@@ -96,20 +102,32 @@
96102
"[Gloo] Rank 0 is connected to 0 peer ranks. Expected number of connected peer ranks is : 0\n",
97103
"[Gloo] Rank 0 is connected to 0 peer ranks. Expected number of connected peer ranks is : 0\n",
98104
"[Gloo] Rank 0 is connected to 0 peer ranks. Expected number of connected peer ranks is : 0\n",
99-
"[Gloo] Rank 0 is connected to 0 peer ranks. Expected number of connected peer ranks is : 0\n",
100-
"[2025-10-06 02:10:27] MOE_RUNNER_BACKEND is not initialized, using triton backend\n"
105+
"[Gloo] Rank 0 is connected to 0 peer ranks. Expected number of connected peer ranks is : 0\n"
106+
]
107+
},
108+
{
109+
"name": "stdout",
110+
"output_type": "stream",
111+
"text": [
112+
"[2025-10-06 03:01:02] MOE_RUNNER_BACKEND is not initialized, using triton backend\n"
101113
]
102114
},
103115
{
104116
"name": "stdout",
105117
"output_type": "stream",
106118
"text": [
107119
"\r",
108-
"Loading safetensors checkpoint shards: 0% Completed | 0/1 [00:00<?, ?it/s]\n",
120+
"Loading safetensors checkpoint shards: 0% Completed | 0/1 [00:00<?, ?it/s]\n"
121+
]
122+
},
123+
{
124+
"name": "stdout",
125+
"output_type": "stream",
126+
"text": [
109127
"\r",
110-
"Loading safetensors checkpoint shards: 100% Completed | 1/1 [00:00<00:00, 5.47it/s]\n",
128+
"Loading safetensors checkpoint shards: 100% Completed | 1/1 [00:00<00:00, 4.20it/s]\n",
111129
"\r",
112-
"Loading safetensors checkpoint shards: 100% Completed | 1/1 [00:00<00:00, 5.46it/s]\n",
130+
"Loading safetensors checkpoint shards: 100% Completed | 1/1 [00:00<00:00, 4.20it/s]\n",
113131
"\n"
114132
]
115133
},
@@ -119,18 +137,18 @@
119137
"text": [
120138
"\r",
121139
" 0%| | 0/3 [00:00<?, ?it/s]\r",
122-
"Capturing batches (bs=4 avail_mem=67.93 GB): 0%| | 0/3 [00:00<?, ?it/s]"
140+
"Capturing batches (bs=4 avail_mem=77.03 GB): 0%| | 0/3 [00:00<?, ?it/s]"
123141
]
124142
},
125143
{
126144
"name": "stdout",
127145
"output_type": "stream",
128146
"text": [
129147
"\r",
130-
"Capturing batches (bs=4 avail_mem=67.93 GB): 33%|███▎ | 1/3 [00:00<00:00, 3.74it/s]\r",
131-
"Capturing batches (bs=2 avail_mem=67.87 GB): 33%|███▎ | 1/3 [00:00<00:00, 3.74it/s]\r",
132-
"Capturing batches (bs=1 avail_mem=67.86 GB): 33%|███▎ | 1/3 [00:00<00:00, 3.74it/s]\r",
133-
"Capturing batches (bs=1 avail_mem=67.86 GB): 100%|██████████| 3/3 [00:00<00:00, 8.74it/s]\n"
148+
"Capturing batches (bs=4 avail_mem=77.03 GB): 33%|███▎ | 1/3 [00:00<00:01, 1.53it/s]\r",
149+
"Capturing batches (bs=2 avail_mem=76.97 GB): 33%|███▎ | 1/3 [00:00<00:01, 1.53it/s]\r",
150+
"Capturing batches (bs=1 avail_mem=76.96 GB): 33%|███▎ | 1/3 [00:00<00:01, 1.53it/s]\r",
151+
"Capturing batches (bs=1 avail_mem=76.96 GB): 100%|██████████| 3/3 [00:00<00:00, 4.17it/s]\n"
134152
]
135153
},
136154
{
@@ -149,7 +167,7 @@
149167
"name": "stdout",
150168
"output_type": "stream",
151169
"text": [
152-
"Server started on http://localhost:39399\n"
170+
"Server started on http://localhost:31747\n"
153171
]
154172
}
155173
],
@@ -183,17 +201,17 @@
183201
"execution_count": 2,
184202
"metadata": {
185203
"execution": {
186-
"iopub.execute_input": "2025-10-06T02:10:37.398656Z",
187-
"iopub.status.busy": "2025-10-06T02:10:37.398258Z",
188-
"iopub.status.idle": "2025-10-06T02:10:37.661630Z",
189-
"shell.execute_reply": "2025-10-06T02:10:37.661051Z"
204+
"iopub.execute_input": "2025-10-06T03:01:13.024173Z",
205+
"iopub.status.busy": "2025-10-06T03:01:13.023033Z",
206+
"iopub.status.idle": "2025-10-06T03:01:13.307561Z",
207+
"shell.execute_reply": "2025-10-06T03:01:13.307079Z"
190208
}
191209
},
192210
"outputs": [
193211
{
194212
"data": {
195213
"text/html": [
196-
"<strong style='color: #00008B;'>Response: ChatCompletion(id='375f25746b1e45be92cdf750444e14b7', choices=[Choice(finish_reason='stop', index=0, logprobs=None, message=ChatCompletionMessage(content='Sure, here are three countries and their respective capitals:\\n\\n1. **United States** - Washington, D.C.\\n2. **Canada** - Ottawa\\n3. **Australia** - Canberra', refusal=None, role='assistant', annotations=None, audio=None, function_call=None, tool_calls=None, reasoning_content=None), matched_stop=151645)], created=1759716637, model='qwen/qwen2.5-0.5b-instruct', object='chat.completion', service_tier=None, system_fingerprint=None, usage=CompletionUsage(completion_tokens=39, prompt_tokens=37, total_tokens=76, completion_tokens_details=None, prompt_tokens_details=None, reasoning_tokens=0), metadata={'weight_version': 'default'})</strong>"
214+
"<strong style='color: #00008B;'>Response: ChatCompletion(id='22b3d25954cb404ca70949629f098753', choices=[Choice(finish_reason='stop', index=0, logprobs=None, message=ChatCompletionMessage(content='Sure, here are three countries and their respective capitals:\\n\\n1. **United States** - Washington, D.C.\\n2. **Canada** - Ottawa\\n3. **Australia** - Canberra', refusal=None, role='assistant', annotations=None, audio=None, function_call=None, tool_calls=None, reasoning_content=None), matched_stop=151645)], created=1759719673, model='qwen/qwen2.5-0.5b-instruct', object='chat.completion', service_tier=None, system_fingerprint=None, usage=CompletionUsage(completion_tokens=39, prompt_tokens=37, total_tokens=76, completion_tokens_details=None, prompt_tokens_details=None, reasoning_tokens=0), metadata={'weight_version': 'default'})</strong>"
197215
],
198216
"text/plain": [
199217
"<IPython.core.display.HTML object>"
@@ -383,17 +401,17 @@
383401
"execution_count": 3,
384402
"metadata": {
385403
"execution": {
386-
"iopub.execute_input": "2025-10-06T02:10:37.663358Z",
387-
"iopub.status.busy": "2025-10-06T02:10:37.663203Z",
388-
"iopub.status.idle": "2025-10-06T02:10:37.885552Z",
389-
"shell.execute_reply": "2025-10-06T02:10:37.884986Z"
404+
"iopub.execute_input": "2025-10-06T03:01:13.309570Z",
405+
"iopub.status.busy": "2025-10-06T03:01:13.309423Z",
406+
"iopub.status.idle": "2025-10-06T03:01:13.543919Z",
407+
"shell.execute_reply": "2025-10-06T03:01:13.543474Z"
390408
}
391409
},
392410
"outputs": [
393411
{
394412
"data": {
395413
"text/html": [
396-
"<strong style='color: #00008B;'>The major achievements of ancient Rome include the construction of the Colosseum, the Pantheon, and the aqueducts that brought water to the city. They also developed a complex system of governance, including the Roman Republic and the Roman Empire. The Romans were known for their military prowess, particularly in their campaigns against the Carthaginians and the Gauls. They are also famous for their art, architecture, and philosophy, which influenced later cultures.</strong>"
414+
"<strong style='color: #00008B;'>The ancient Romans made significant contributions to various fields, including law, philosophy, science, and literature. They were known for their engineering skills, particularly in the construction of monumental architecture like the Colosseum and the Pantheon. The Roman Empire was one of the largest and most powerful empires in history, spanning across Europe, Asia Minor, and North Africa. Their cultural achievements included the development of Roman law and the spread of Christianity. Additionally, they were skilled in agriculture and had a sophisticated system of governance.</strong>"
397415
],
398416
"text/plain": [
399417
"<IPython.core.display.HTML object>"
@@ -442,18 +460,18 @@
442460
"execution_count": 4,
443461
"metadata": {
444462
"execution": {
445-
"iopub.execute_input": "2025-10-06T02:10:37.886984Z",
446-
"iopub.status.busy": "2025-10-06T02:10:37.886831Z",
447-
"iopub.status.idle": "2025-10-06T02:10:37.997297Z",
448-
"shell.execute_reply": "2025-10-06T02:10:37.996755Z"
463+
"iopub.execute_input": "2025-10-06T03:01:13.545307Z",
464+
"iopub.status.busy": "2025-10-06T03:01:13.545169Z",
465+
"iopub.status.idle": "2025-10-06T03:01:13.655547Z",
466+
"shell.execute_reply": "2025-10-06T03:01:13.654789Z"
449467
}
450468
},
451469
"outputs": [
452470
{
453471
"name": "stdout",
454472
"output_type": "stream",
455473
"text": [
456-
"I apologize, but I need more context to understand what you mean by \"a test.\" Could you please provide more details or clarify your question? Whether it's a specific technical question, a question about a specific language, or something else, I could help you with the information you need."
474+
"Yes, \"test\" is a code word for a survey or a sample in various contexts. It's common to use \"test\" to refer to a small group of people or a particular population whose opinions or behaviors will be surveyed in a testing or evaluation activity."
457475
]
458476
}
459477
],
@@ -483,17 +501,17 @@
483501
"execution_count": 5,
484502
"metadata": {
485503
"execution": {
486-
"iopub.execute_input": "2025-10-06T02:10:37.998642Z",
487-
"iopub.status.busy": "2025-10-06T02:10:37.998497Z",
488-
"iopub.status.idle": "2025-10-06T02:10:38.148945Z",
489-
"shell.execute_reply": "2025-10-06T02:10:38.148459Z"
504+
"iopub.execute_input": "2025-10-06T03:01:13.657280Z",
505+
"iopub.status.busy": "2025-10-06T03:01:13.656894Z",
506+
"iopub.status.idle": "2025-10-06T03:01:13.822803Z",
507+
"shell.execute_reply": "2025-10-06T03:01:13.822237Z"
490508
}
491509
},
492510
"outputs": [
493511
{
494512
"data": {
495513
"text/html": [
496-
"<strong style='color: #00008B;'>Response: Completion(id='b15c911e50ec48bb915fc8a641dd052c', choices=[CompletionChoice(finish_reason='length', index=0, logprobs=None, text=' 1. United States - Washington D.C.\\n2. Canada - Ottawa\\n3. France - Paris\\n4. Germany - Berlin\\n5. Japan - Tokyo\\n6. Italy - Rome\\n7. Spain - Madrid\\n8. United Kingdom - London\\n9. Australia - Canberra\\n10. New Zealand', matched_stop=None)], created=1759716638, model='qwen/qwen2.5-0.5b-instruct', object='text_completion', system_fingerprint=None, usage=CompletionUsage(completion_tokens=64, prompt_tokens=8, total_tokens=72, completion_tokens_details=None, prompt_tokens_details=None, reasoning_tokens=0), metadata={'weight_version': 'default'})</strong>"
514+
"<strong style='color: #00008B;'>Response: Completion(id='0a9bef63fc134f77b60a8501ba5d912d', choices=[CompletionChoice(finish_reason='length', index=0, logprobs=None, text=' 1. United States - Washington D.C.\\n2. Canada - Ottawa\\n3. France - Paris\\n4. Germany - Berlin\\n5. Japan - Tokyo\\n6. Italy - Rome\\n7. Spain - Madrid\\n8. United Kingdom - London\\n9. Australia - Canberra\\n10. New Zealand', matched_stop=None)], created=1759719673, model='qwen/qwen2.5-0.5b-instruct', object='text_completion', system_fingerprint=None, usage=CompletionUsage(completion_tokens=64, prompt_tokens=8, total_tokens=72, completion_tokens_details=None, prompt_tokens_details=None, reasoning_tokens=0), metadata={'weight_version': 'default'})</strong>"
497515
],
498516
"text/plain": [
499517
"<IPython.core.display.HTML object>"
@@ -532,17 +550,17 @@
532550
"execution_count": 6,
533551
"metadata": {
534552
"execution": {
535-
"iopub.execute_input": "2025-10-06T02:10:38.150455Z",
536-
"iopub.status.busy": "2025-10-06T02:10:38.150314Z",
537-
"iopub.status.idle": "2025-10-06T02:10:38.246197Z",
538-
"shell.execute_reply": "2025-10-06T02:10:38.245724Z"
553+
"iopub.execute_input": "2025-10-06T03:01:13.824422Z",
554+
"iopub.status.busy": "2025-10-06T03:01:13.824267Z",
555+
"iopub.status.idle": "2025-10-06T03:01:13.902031Z",
556+
"shell.execute_reply": "2025-10-06T03:01:13.901479Z"
539557
}
540558
},
541559
"outputs": [
542560
{
543561
"data": {
544562
"text/html": [
545-
"<strong style='color: #00008B;'>Response: Completion(id='addc2fde8786458da18724887320bc9c', choices=[CompletionChoice(finish_reason='stop', index=0, logprobs=None, text=' Once upon a time, there was a space explorer named Captain Alex. He had always dreamed of exploring the stars and uncovering the mysteries of the universe. One day, he received an invitation to join a team of scientists on a mission to explore a new planet.', matched_stop='\\n\\n')], created=1759716638, model='qwen/qwen2.5-0.5b-instruct', object='text_completion', system_fingerprint=None, usage=CompletionUsage(completion_tokens=53, prompt_tokens=9, total_tokens=62, completion_tokens_details=None, prompt_tokens_details=None, reasoning_tokens=0), metadata={'weight_version': 'default'})</strong>"
563+
"<strong style='color: #00008B;'>Response: Completion(id='b96d15fb328c43c8afb3db6bf8ab7023', choices=[CompletionChoice(finish_reason='stop', index=0, logprobs=None, text=' As an AI language model, I do not have personal experiences or emotions, but I can generate a fictional story based on common themes and events that people might encounter in space travel.', matched_stop='\\n\\n')], created=1759719673, model='qwen/qwen2.5-0.5b-instruct', object='text_completion', system_fingerprint=None, usage=CompletionUsage(completion_tokens=36, prompt_tokens=9, total_tokens=45, completion_tokens_details=None, prompt_tokens_details=None, reasoning_tokens=0), metadata={'weight_version': 'default'})</strong>"
546564
],
547565
"text/plain": [
548566
"<IPython.core.display.HTML object>"
@@ -583,10 +601,10 @@
583601
"execution_count": 7,
584602
"metadata": {
585603
"execution": {
586-
"iopub.execute_input": "2025-10-06T02:10:38.247645Z",
587-
"iopub.status.busy": "2025-10-06T02:10:38.247506Z",
588-
"iopub.status.idle": "2025-10-06T02:10:38.296314Z",
589-
"shell.execute_reply": "2025-10-06T02:10:38.294678Z"
604+
"iopub.execute_input": "2025-10-06T03:01:13.903616Z",
605+
"iopub.status.busy": "2025-10-06T03:01:13.903457Z",
606+
"iopub.status.idle": "2025-10-06T03:01:13.943927Z",
607+
"shell.execute_reply": "2025-10-06T03:01:13.943243Z"
590608
}
591609
},
592610
"outputs": [],

0 commit comments

Comments
 (0)