Skip to content

Commit 5d90644

Browse files
committed
Update 2025-10-06 07:42:06
1 parent 655080a commit 5d90644

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

+5060
-5134
lines changed

_sources/advanced_features/lora.ipynb

Lines changed: 143 additions & 155 deletions
Large diffs are not rendered by default.

_sources/advanced_features/separate_reasoning.ipynb

Lines changed: 112 additions & 101 deletions
Large diffs are not rendered by default.

_sources/advanced_features/speculative_decoding.ipynb

Lines changed: 350 additions & 354 deletions
Large diffs are not rendered by default.

_sources/advanced_features/structured_outputs.ipynb

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

_sources/advanced_features/structured_outputs_for_reasoning_models.ipynb

Lines changed: 174 additions & 185 deletions
Large diffs are not rendered by default.

_sources/advanced_features/tool_parser.ipynb

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

_sources/advanced_features/vlm_query.ipynb

Lines changed: 268 additions & 261 deletions
Large diffs are not rendered by default.

_sources/basic_usage/native_api.ipynb

Lines changed: 153 additions & 141 deletions
Large diffs are not rendered by default.

_sources/basic_usage/offline_engine_api.ipynb

Lines changed: 470 additions & 476 deletions
Large diffs are not rendered by default.

_sources/basic_usage/openai_api_completions.ipynb

Lines changed: 42 additions & 74 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-06T04:19:36.335708Z",
35-
"iopub.status.busy": "2025-10-06T04:19:36.335583Z",
36-
"iopub.status.idle": "2025-10-06T04:20:09.614838Z",
37-
"shell.execute_reply": "2025-10-06T04:20:09.614374Z"
34+
"iopub.execute_input": "2025-10-06T07:31:01.579123Z",
35+
"iopub.status.busy": "2025-10-06T07:31:01.578995Z",
36+
"iopub.status.idle": "2025-10-06T07:31:34.179280Z",
37+
"shell.execute_reply": "2025-10-06T07:31:34.178753Z"
3838
}
3939
},
4040
"outputs": [
@@ -86,7 +86,7 @@
8686
"output_type": "stream",
8787
"text": [
8888
"`torch_dtype` is deprecated! Use `dtype` instead!\n",
89-
"[2025-10-06 04:19:58] `torch_dtype` is deprecated! Use `dtype` instead!\n"
89+
"[2025-10-06 07:31:23] `torch_dtype` is deprecated! Use `dtype` instead!\n"
9090
]
9191
},
9292
{
@@ -97,7 +97,7 @@
9797
"[Gloo] Rank 0 is connected to 0 peer ranks. Expected number of connected peer ranks is : 0\n",
9898
"[Gloo] Rank 0 is connected to 0 peer ranks. Expected number of connected peer ranks is : 0\n",
9999
"[Gloo] Rank 0 is connected to 0 peer ranks. Expected number of connected peer ranks is : 0\n",
100-
"[2025-10-06 04:20:00] MOE_RUNNER_BACKEND is not initialized, using triton backend\n"
100+
"[2025-10-06 07:31:24] MOE_RUNNER_BACKEND is not initialized, using triton backend\n"
101101
]
102102
},
103103
{
@@ -107,9 +107,9 @@
107107
"\r",
108108
"Loading safetensors checkpoint shards: 0% Completed | 0/1 [00:00<?, ?it/s]\n",
109109
"\r",
110-
"Loading safetensors checkpoint shards: 100% Completed | 1/1 [00:00<00:00, 5.92it/s]\n",
110+
"Loading safetensors checkpoint shards: 100% Completed | 1/1 [00:00<00:00, 5.09it/s]\n",
111111
"\r",
112-
"Loading safetensors checkpoint shards: 100% Completed | 1/1 [00:00<00:00, 5.91it/s]\n",
112+
"Loading safetensors checkpoint shards: 100% Completed | 1/1 [00:00<00:00, 5.08it/s]\n",
113113
"\n"
114114
]
115115
},
@@ -127,10 +127,10 @@
127127
"output_type": "stream",
128128
"text": [
129129
"\r",
130-
"Capturing batches (bs=4 avail_mem=77.03 GB): 33%|███▎ | 1/3 [00:00<00:00, 4.52it/s]\r",
131-
"Capturing batches (bs=2 avail_mem=76.97 GB): 33%|███▎ | 1/3 [00:00<00:00, 4.52it/s]\r",
132-
"Capturing batches (bs=1 avail_mem=76.96 GB): 33%|███▎ | 1/3 [00:00<00:00, 4.52it/s]\r",
133-
"Capturing batches (bs=1 avail_mem=76.96 GB): 100%|██████████| 3/3 [00:00<00:00, 10.68it/s]\n"
130+
"Capturing batches (bs=4 avail_mem=77.03 GB): 33%|███▎ | 1/3 [00:00<00:00, 4.42it/s]\r",
131+
"Capturing batches (bs=2 avail_mem=76.97 GB): 33%|███▎ | 1/3 [00:00<00:00, 4.42it/s]\r",
132+
"Capturing batches (bs=1 avail_mem=76.96 GB): 33%|███▎ | 1/3 [00:00<00:00, 4.42it/s]\r",
133+
"Capturing batches (bs=1 avail_mem=76.96 GB): 100%|██████████| 3/3 [00:00<00:00, 10.47it/s]\n"
134134
]
135135
},
136136
{
@@ -149,7 +149,7 @@
149149
"name": "stdout",
150150
"output_type": "stream",
151151
"text": [
152-
"Server started on http://localhost:38621\n"
152+
"Server started on http://localhost:32309\n"
153153
]
154154
}
155155
],
@@ -183,17 +183,17 @@
183183
"execution_count": 2,
184184
"metadata": {
185185
"execution": {
186-
"iopub.execute_input": "2025-10-06T04:20:09.616535Z",
187-
"iopub.status.busy": "2025-10-06T04:20:09.616213Z",
188-
"iopub.status.idle": "2025-10-06T04:20:09.879343Z",
189-
"shell.execute_reply": "2025-10-06T04:20:09.878902Z"
186+
"iopub.execute_input": "2025-10-06T07:31:34.182290Z",
187+
"iopub.status.busy": "2025-10-06T07:31:34.181961Z",
188+
"iopub.status.idle": "2025-10-06T07:31:34.440017Z",
189+
"shell.execute_reply": "2025-10-06T07:31:34.439531Z"
190190
}
191191
},
192192
"outputs": [
193193
{
194194
"data": {
195195
"text/html": [
196-
"<strong style='color: #00008B;'>Response: ChatCompletion(id='0d37bf86176342649a990e275a02c638', 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=1759724409, 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>"
196+
"<strong style='color: #00008B;'>Response: ChatCompletion(id='39856b570e2e446592053194f80ee394', 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=1759735894, 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>"
197197
],
198198
"text/plain": [
199199
"<IPython.core.display.HTML object>"
@@ -383,17 +383,17 @@
383383
"execution_count": 3,
384384
"metadata": {
385385
"execution": {
386-
"iopub.execute_input": "2025-10-06T04:20:09.880978Z",
387-
"iopub.status.busy": "2025-10-06T04:20:09.880826Z",
388-
"iopub.status.idle": "2025-10-06T04:20:10.096277Z",
389-
"shell.execute_reply": "2025-10-06T04:20:10.095847Z"
386+
"iopub.execute_input": "2025-10-06T07:31:34.441639Z",
387+
"iopub.status.busy": "2025-10-06T07:31:34.441487Z",
388+
"iopub.status.idle": "2025-10-06T07:31:34.690251Z",
389+
"shell.execute_reply": "2025-10-06T07:31:34.689779Z"
390390
}
391391
},
392392
"outputs": [
393393
{
394394
"data": {
395395
"text/html": [
396-
"<strong style='color: #00008B;'>The ancient Romans made significant contributions to various fields, including law, philosophy, science, and literature. They are known for their extensive use of the Latin language and their innovative approach to governance. Rome's achievements include the construction of the Colosseum, which was a massive amphitheater that hosted gladiatorial contests and other public spectacles. The Roman Empire, which lasted from the 3rd century BCE to the 4th century CE, is considered one of the most influential empires in history.</strong>"
396+
"<strong style='color: #00008B;'>Ancient Rome was a major civilization that played a significant role in the history of Western civilization. Some of their major achievements include:<br><br>1. **Gothic Architecture**: Roman architecture is known for its grandeur and symmetry, with iconic examples like the Colosseum and the Pantheon.<br><br>2. **Roman Law**: The Roman legal system, codified in the Twelve Tables, was one of the earliest forms of written law in the world. It laid the foundation for modern legal systems.<br><br>3. **Roman Literature**: The Romans are credited with inventing Latin, which became the primary language of literature and education in Europe.<br><br>4.</strong>"
397397
],
398398
"text/plain": [
399399
"<IPython.core.display.HTML object>"
@@ -442,50 +442,18 @@
442442
"execution_count": 4,
443443
"metadata": {
444444
"execution": {
445-
"iopub.execute_input": "2025-10-06T04:20:10.097679Z",
446-
"iopub.status.busy": "2025-10-06T04:20:10.097535Z",
447-
"iopub.status.idle": "2025-10-06T04:20:10.540590Z",
448-
"shell.execute_reply": "2025-10-06T04:20:10.540114Z"
445+
"iopub.execute_input": "2025-10-06T07:31:34.691725Z",
446+
"iopub.status.busy": "2025-10-06T07:31:34.691577Z",
447+
"iopub.status.idle": "2025-10-06T07:31:34.773202Z",
448+
"shell.execute_reply": "2025-10-06T07:31:34.772684Z"
449449
}
450450
},
451451
"outputs": [
452452
{
453453
"name": "stdout",
454454
"output_type": "stream",
455455
"text": [
456-
"Yes, \"test\" is a common term used in various contexts to refer to a simulated situation, a set of instructions, or an evaluation of performance. Here are some examples of how \"test\" might be used:\n",
457-
"\n",
458-
"1. In software testing, \"test\" refers to a program that checks for defects in a software system.\n",
459-
"\n",
460-
"2. In a chemistry test, \"test\" refers to the procedure used to determine whether a sample of a compound has reacted with another substance.\n",
461-
"\n",
462-
"3. In a coding test, \"test\" refers to an automated program that runs a program and checks its correctness.\n",
463-
"\n",
464-
"4. In a language learning test, \"test\" refers to a computer program that evaluates a learner's progress in"
465-
]
466-
},
467-
{
468-
"name": "stdout",
469-
"output_type": "stream",
470-
"text": [
471-
" understanding a particular language.\n",
472-
"\n",
473-
"5. In a physical test, \"test\" refers to the process of measuring or assessing something, such as a physical property or performance.\n",
474-
"\n",
475-
"6. In a sports test, \"test\" refers to an official event where athletes compete against each other.\n",
476-
"\n",
477-
"7. In a scientific test, \"test\" refers to a method used to investigate a particular phenomenon or determine the effectiveness of a treatment.\n",
478-
"\n",
479-
"8. In a medical test, \"test\" refers to the examination or diagnostic process to determine the medical condition of a patient.\n",
480-
"\n",
481-
"All of these uses of \"test\" indicate a scenario where a specified action or set of actions is carried out to evaluate or assess"
482-
]
483-
},
484-
{
485-
"name": "stdout",
486-
"output_type": "stream",
487-
"text": [
488-
" a performance or outcome."
456+
"Yes, it is a test. I'm here to assist you with any questions or tasks you may have. Please feel free to ask me anything and I'll do my best to help."
489457
]
490458
}
491459
],
@@ -515,17 +483,17 @@
515483
"execution_count": 5,
516484
"metadata": {
517485
"execution": {
518-
"iopub.execute_input": "2025-10-06T04:20:10.542027Z",
519-
"iopub.status.busy": "2025-10-06T04:20:10.541882Z",
520-
"iopub.status.idle": "2025-10-06T04:20:10.698366Z",
521-
"shell.execute_reply": "2025-10-06T04:20:10.697945Z"
486+
"iopub.execute_input": "2025-10-06T07:31:34.774615Z",
487+
"iopub.status.busy": "2025-10-06T07:31:34.774467Z",
488+
"iopub.status.idle": "2025-10-06T07:31:34.924107Z",
489+
"shell.execute_reply": "2025-10-06T07:31:34.923640Z"
522490
}
523491
},
524492
"outputs": [
525493
{
526494
"data": {
527495
"text/html": [
528-
"<strong style='color: #00008B;'>Response: Completion(id='6f88b33ba1bc4d8d82b9a15ee30e156b', 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=1759724410, 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>"
496+
"<strong style='color: #00008B;'>Response: Completion(id='40011f7a27204aa587e9b040e21d38a4', 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=1759735894, 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>"
529497
],
530498
"text/plain": [
531499
"<IPython.core.display.HTML object>"
@@ -564,17 +532,17 @@
564532
"execution_count": 6,
565533
"metadata": {
566534
"execution": {
567-
"iopub.execute_input": "2025-10-06T04:20:10.700748Z",
568-
"iopub.status.busy": "2025-10-06T04:20:10.700605Z",
569-
"iopub.status.idle": "2025-10-06T04:20:10.786008Z",
570-
"shell.execute_reply": "2025-10-06T04:20:10.785601Z"
535+
"iopub.execute_input": "2025-10-06T07:31:34.925516Z",
536+
"iopub.status.busy": "2025-10-06T07:31:34.925366Z",
537+
"iopub.status.idle": "2025-10-06T07:31:35.035841Z",
538+
"shell.execute_reply": "2025-10-06T07:31:35.035391Z"
571539
}
572540
},
573541
"outputs": [
574542
{
575543
"data": {
576544
"text/html": [
577-
"<strong style='color: #00008B;'>Response: Completion(id='721840baf7824385a71fc9221d73e24e', choices=[CompletionChoice(finish_reason='stop', index=0, logprobs=None, text=' Once upon a time, there was a space explorer named Jack who had always dreamed of exploring the stars. He had heard tales of the vastness of the universe and how it was filled with strange and beautiful wonders.', matched_stop='\\n\\n')], created=1759724410, model='qwen/qwen2.5-0.5b-instruct', object='text_completion', system_fingerprint=None, usage=CompletionUsage(completion_tokens=43, prompt_tokens=9, total_tokens=52, completion_tokens_details=None, prompt_tokens_details=None, reasoning_tokens=0), metadata={'weight_version': 'default'})</strong>"
545+
"<strong style='color: #00008B;'>Response: Completion(id='f0ec46a6083f4f849bd26d2d653ad505', choices=[CompletionChoice(finish_reason='stop', index=0, logprobs=None, text=' Once upon a time, there was a space explorer named James. He was a man who loved nothing more than exploring the stars and making new discoveries. One day, he decided to venture out into space with his spaceship and set out on a mission to explore the far reaches of the universe.', matched_stop='\\n\\n')], created=1759735895, model='qwen/qwen2.5-0.5b-instruct', object='text_completion', system_fingerprint=None, usage=CompletionUsage(completion_tokens=58, prompt_tokens=9, total_tokens=67, completion_tokens_details=None, prompt_tokens_details=None, reasoning_tokens=0), metadata={'weight_version': 'default'})</strong>"
578546
],
579547
"text/plain": [
580548
"<IPython.core.display.HTML object>"
@@ -615,10 +583,10 @@
615583
"execution_count": 7,
616584
"metadata": {
617585
"execution": {
618-
"iopub.execute_input": "2025-10-06T04:20:10.787486Z",
619-
"iopub.status.busy": "2025-10-06T04:20:10.787351Z",
620-
"iopub.status.idle": "2025-10-06T04:20:10.820339Z",
621-
"shell.execute_reply": "2025-10-06T04:20:10.819713Z"
586+
"iopub.execute_input": "2025-10-06T07:31:35.037313Z",
587+
"iopub.status.busy": "2025-10-06T07:31:35.037091Z",
588+
"iopub.status.idle": "2025-10-06T07:31:35.143880Z",
589+
"shell.execute_reply": "2025-10-06T07:31:35.143316Z"
622590
}
623591
},
624592
"outputs": [],

0 commit comments

Comments
 (0)