inspect-ai 0.3.55__py3-none-any.whl → 0.3.56__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- inspect_ai/__init__.py +1 -0
- inspect_ai/_cli/common.py +1 -1
- inspect_ai/_cli/trace.py +33 -20
- inspect_ai/_display/core/active.py +1 -1
- inspect_ai/_display/core/display.py +1 -1
- inspect_ai/_display/core/footer.py +1 -1
- inspect_ai/_display/core/progress.py +0 -6
- inspect_ai/_display/core/rich.py +1 -1
- inspect_ai/_display/rich/display.py +2 -2
- inspect_ai/_display/textual/app.py +15 -17
- inspect_ai/_display/textual/widgets/clock.py +3 -3
- inspect_ai/_display/textual/widgets/samples.py +6 -13
- inspect_ai/_eval/context.py +9 -1
- inspect_ai/_eval/score.py +4 -10
- inspect_ai/_eval/task/results.py +5 -4
- inspect_ai/_eval/task/run.py +6 -12
- inspect_ai/_eval/task/task.py +10 -0
- inspect_ai/_util/ansi.py +31 -0
- inspect_ai/_util/format.py +7 -0
- inspect_ai/_util/logger.py +12 -12
- inspect_ai/_util/throttle.py +10 -1
- inspect_ai/_util/trace.py +43 -47
- inspect_ai/_util/transcript.py +4 -0
- inspect_ai/_util/vscode.py +51 -0
- inspect_ai/_view/notify.py +2 -1
- inspect_ai/_view/www/App.css +22 -1
- inspect_ai/_view/www/dist/assets/index.css +2374 -2
- inspect_ai/_view/www/dist/assets/index.js +29622 -24424
- inspect_ai/_view/www/log-schema.json +138 -90
- inspect_ai/_view/www/package.json +1 -0
- inspect_ai/_view/www/src/App.mjs +1 -0
- inspect_ai/_view/www/src/appearance/Icons.mjs +2 -0
- inspect_ai/_view/www/src/components/AsciiCinemaPlayer.mjs +74 -0
- inspect_ai/_view/www/src/components/CopyButton.mjs +0 -1
- inspect_ai/_view/www/src/components/HumanBaselineView.mjs +168 -0
- inspect_ai/_view/www/src/components/LightboxCarousel.mjs +217 -0
- inspect_ai/_view/www/src/components/Tools.mjs +11 -3
- inspect_ai/_view/www/src/samples/transcript/ModelEventView.mjs +3 -2
- inspect_ai/_view/www/src/samples/transcript/TranscriptView.mjs +1 -0
- inspect_ai/_view/www/src/samples/transcript/state/StateEventRenderers.mjs +56 -0
- inspect_ai/_view/www/src/samples/transcript/state/StateEventView.mjs +17 -5
- inspect_ai/_view/www/src/types/asciicinema-player.d.ts +26 -0
- inspect_ai/_view/www/src/types/log.d.ts +26 -12
- inspect_ai/_view/www/yarn.lock +44 -0
- inspect_ai/approval/_apply.py +4 -0
- inspect_ai/approval/_human/panel.py +5 -8
- inspect_ai/dataset/_dataset.py +51 -10
- inspect_ai/dataset/_util.py +31 -3
- inspect_ai/log/__init__.py +2 -0
- inspect_ai/log/_log.py +5 -2
- inspect_ai/model/_call_tools.py +4 -2
- inspect_ai/model/_chat_message.py +3 -0
- inspect_ai/model/_model.py +42 -1
- inspect_ai/model/_providers/anthropic.py +4 -0
- inspect_ai/model/_render.py +9 -2
- inspect_ai/scorer/_metric.py +12 -1
- inspect_ai/solver/__init__.py +2 -0
- inspect_ai/solver/_human_agent/agent.py +83 -0
- inspect_ai/solver/_human_agent/commands/__init__.py +36 -0
- inspect_ai/solver/_human_agent/commands/clock.py +70 -0
- inspect_ai/solver/_human_agent/commands/command.py +59 -0
- inspect_ai/solver/_human_agent/commands/instructions.py +74 -0
- inspect_ai/solver/_human_agent/commands/note.py +42 -0
- inspect_ai/solver/_human_agent/commands/score.py +80 -0
- inspect_ai/solver/_human_agent/commands/status.py +62 -0
- inspect_ai/solver/_human_agent/commands/submit.py +151 -0
- inspect_ai/solver/_human_agent/install.py +222 -0
- inspect_ai/solver/_human_agent/panel.py +252 -0
- inspect_ai/solver/_human_agent/service.py +45 -0
- inspect_ai/solver/_human_agent/state.py +55 -0
- inspect_ai/solver/_human_agent/view.py +24 -0
- inspect_ai/solver/_task_state.py +28 -2
- inspect_ai/tool/_tool.py +10 -2
- inspect_ai/tool/_tools/_web_browser/_web_browser.py +13 -10
- inspect_ai/util/__init__.py +8 -4
- inspect_ai/{_util/display.py → util/_display.py} +6 -0
- inspect_ai/util/_panel.py +31 -9
- inspect_ai/util/_sandbox/__init__.py +0 -3
- inspect_ai/util/_sandbox/context.py +5 -1
- inspect_ai/util/_sandbox/docker/compose.py +16 -10
- inspect_ai/util/_sandbox/docker/docker.py +9 -6
- inspect_ai/util/_sandbox/docker/internal.py +1 -1
- inspect_ai/util/_sandbox/docker/util.py +2 -2
- inspect_ai/util/_sandbox/environment.py +6 -5
- inspect_ai/util/_sandbox/local.py +1 -1
- inspect_ai/util/_sandbox/service.py +22 -7
- inspect_ai/util/_store.py +5 -6
- inspect_ai/util/_store_model.py +110 -0
- inspect_ai/util/_throttle.py +32 -0
- {inspect_ai-0.3.55.dist-info → inspect_ai-0.3.56.dist-info}/METADATA +1 -1
- {inspect_ai-0.3.55.dist-info → inspect_ai-0.3.56.dist-info}/RECORD +95 -73
- {inspect_ai-0.3.55.dist-info → inspect_ai-0.3.56.dist-info}/LICENSE +0 -0
- {inspect_ai-0.3.55.dist-info → inspect_ai-0.3.56.dist-info}/WHEEL +0 -0
- {inspect_ai-0.3.55.dist-info → inspect_ai-0.3.56.dist-info}/entry_points.txt +0 -0
- {inspect_ai-0.3.55.dist-info → inspect_ai-0.3.56.dist-info}/top_level.txt +0 -0
@@ -23,9 +23,6 @@
|
|
23
23
|
"event": {
|
24
24
|
"const": "approval",
|
25
25
|
"default": "approval",
|
26
|
-
"enum": [
|
27
|
-
"approval"
|
28
|
-
],
|
29
26
|
"title": "Event",
|
30
27
|
"type": "string"
|
31
28
|
},
|
@@ -154,6 +151,11 @@
|
|
154
151
|
"title": "ApproverPolicyConfig",
|
155
152
|
"type": "object"
|
156
153
|
},
|
154
|
+
"BaseModel": {
|
155
|
+
"properties": {},
|
156
|
+
"title": "BaseModel",
|
157
|
+
"type": "object"
|
158
|
+
},
|
157
159
|
"ChatCompletionChoice": {
|
158
160
|
"properties": {
|
159
161
|
"message": {
|
@@ -235,9 +237,6 @@
|
|
235
237
|
"role": {
|
236
238
|
"const": "assistant",
|
237
239
|
"default": "assistant",
|
238
|
-
"enum": [
|
239
|
-
"assistant"
|
240
|
-
],
|
241
240
|
"title": "Role",
|
242
241
|
"type": "string"
|
243
242
|
},
|
@@ -309,9 +308,6 @@
|
|
309
308
|
"role": {
|
310
309
|
"const": "system",
|
311
310
|
"default": "system",
|
312
|
-
"enum": [
|
313
|
-
"system"
|
314
|
-
],
|
315
311
|
"title": "Role",
|
316
312
|
"type": "string"
|
317
313
|
}
|
@@ -367,9 +363,6 @@
|
|
367
363
|
"role": {
|
368
364
|
"const": "tool",
|
369
365
|
"default": "tool",
|
370
|
-
"enum": [
|
371
|
-
"tool"
|
372
|
-
],
|
373
366
|
"title": "Role",
|
374
367
|
"type": "string"
|
375
368
|
},
|
@@ -463,17 +456,27 @@
|
|
463
456
|
"role": {
|
464
457
|
"const": "user",
|
465
458
|
"default": "user",
|
466
|
-
"enum": [
|
467
|
-
"user"
|
468
|
-
],
|
469
459
|
"title": "Role",
|
470
460
|
"type": "string"
|
461
|
+
},
|
462
|
+
"tool_call_id": {
|
463
|
+
"anyOf": [
|
464
|
+
{
|
465
|
+
"type": "string"
|
466
|
+
},
|
467
|
+
{
|
468
|
+
"type": "null"
|
469
|
+
}
|
470
|
+
],
|
471
|
+
"default": null,
|
472
|
+
"title": "Tool Call Id"
|
471
473
|
}
|
472
474
|
},
|
473
475
|
"required": [
|
474
476
|
"content",
|
475
477
|
"source",
|
476
|
-
"role"
|
478
|
+
"role",
|
479
|
+
"tool_call_id"
|
477
480
|
],
|
478
481
|
"title": "ChatMessageUser",
|
479
482
|
"type": "object",
|
@@ -484,9 +487,6 @@
|
|
484
487
|
"type": {
|
485
488
|
"const": "image",
|
486
489
|
"default": "image",
|
487
|
-
"enum": [
|
488
|
-
"image"
|
489
|
-
],
|
490
490
|
"title": "Type",
|
491
491
|
"type": "string"
|
492
492
|
},
|
@@ -519,9 +519,6 @@
|
|
519
519
|
"type": {
|
520
520
|
"const": "text",
|
521
521
|
"default": "text",
|
522
|
-
"enum": [
|
523
|
-
"text"
|
524
|
-
],
|
525
522
|
"title": "Type",
|
526
523
|
"type": "string"
|
527
524
|
},
|
@@ -561,9 +558,6 @@
|
|
561
558
|
"event": {
|
562
559
|
"const": "error",
|
563
560
|
"default": "error",
|
564
|
-
"enum": [
|
565
|
-
"error"
|
566
|
-
],
|
567
561
|
"title": "Event",
|
568
562
|
"type": "string"
|
569
563
|
},
|
@@ -608,6 +602,34 @@
|
|
608
602
|
"default": null,
|
609
603
|
"title": "Limit"
|
610
604
|
},
|
605
|
+
"sample_id": {
|
606
|
+
"anyOf": [
|
607
|
+
{
|
608
|
+
"type": "string"
|
609
|
+
},
|
610
|
+
{
|
611
|
+
"type": "integer"
|
612
|
+
},
|
613
|
+
{
|
614
|
+
"items": {
|
615
|
+
"anyOf": [
|
616
|
+
{
|
617
|
+
"type": "string"
|
618
|
+
},
|
619
|
+
{
|
620
|
+
"type": "integer"
|
621
|
+
}
|
622
|
+
]
|
623
|
+
},
|
624
|
+
"type": "array"
|
625
|
+
},
|
626
|
+
{
|
627
|
+
"type": "null"
|
628
|
+
}
|
629
|
+
],
|
630
|
+
"default": null,
|
631
|
+
"title": "Sample Id"
|
632
|
+
},
|
611
633
|
"epochs": {
|
612
634
|
"anyOf": [
|
613
635
|
{
|
@@ -745,6 +767,18 @@
|
|
745
767
|
"default": null,
|
746
768
|
"title": "Max Subprocesses"
|
747
769
|
},
|
770
|
+
"max_sandboxes": {
|
771
|
+
"anyOf": [
|
772
|
+
{
|
773
|
+
"type": "integer"
|
774
|
+
},
|
775
|
+
{
|
776
|
+
"type": "null"
|
777
|
+
}
|
778
|
+
],
|
779
|
+
"default": null,
|
780
|
+
"title": "Max Sandboxes"
|
781
|
+
},
|
748
782
|
"sandbox_cleanup": {
|
749
783
|
"anyOf": [
|
750
784
|
{
|
@@ -792,12 +826,25 @@
|
|
792
826
|
],
|
793
827
|
"default": null,
|
794
828
|
"title": "Log Buffer"
|
829
|
+
},
|
830
|
+
"score_display": {
|
831
|
+
"anyOf": [
|
832
|
+
{
|
833
|
+
"type": "boolean"
|
834
|
+
},
|
835
|
+
{
|
836
|
+
"type": "null"
|
837
|
+
}
|
838
|
+
],
|
839
|
+
"default": null,
|
840
|
+
"title": "Score Display"
|
795
841
|
}
|
796
842
|
},
|
797
843
|
"title": "EvalConfig",
|
798
844
|
"type": "object",
|
799
845
|
"required": [
|
800
846
|
"limit",
|
847
|
+
"sample_id",
|
801
848
|
"epochs",
|
802
849
|
"epochs_reducer",
|
803
850
|
"trace",
|
@@ -809,10 +856,12 @@
|
|
809
856
|
"max_samples",
|
810
857
|
"max_tasks",
|
811
858
|
"max_subprocesses",
|
859
|
+
"max_sandboxes",
|
812
860
|
"sandbox_cleanup",
|
813
861
|
"log_samples",
|
814
862
|
"log_images",
|
815
|
-
"log_buffer"
|
863
|
+
"log_buffer",
|
864
|
+
"score_display"
|
816
865
|
],
|
817
866
|
"additionalProperties": false
|
818
867
|
},
|
@@ -1017,7 +1066,8 @@
|
|
1017
1066
|
"top_logprobs": null,
|
1018
1067
|
"parallel_tool_calls": null,
|
1019
1068
|
"max_tool_output": null,
|
1020
|
-
"cache_prompt": null
|
1069
|
+
"cache_prompt": null,
|
1070
|
+
"reasoning_effort": null
|
1021
1071
|
}
|
1022
1072
|
}
|
1023
1073
|
},
|
@@ -1097,9 +1147,6 @@
|
|
1097
1147
|
"properties": {
|
1098
1148
|
"type": {
|
1099
1149
|
"const": "git",
|
1100
|
-
"enum": [
|
1101
|
-
"git"
|
1102
|
-
],
|
1103
1150
|
"title": "Type",
|
1104
1151
|
"type": "string"
|
1105
1152
|
},
|
@@ -1964,9 +2011,6 @@
|
|
1964
2011
|
"anyOf": [
|
1965
2012
|
{
|
1966
2013
|
"const": "auto",
|
1967
|
-
"enum": [
|
1968
|
-
"auto"
|
1969
|
-
],
|
1970
2014
|
"type": "string"
|
1971
2015
|
},
|
1972
2016
|
{
|
@@ -1978,6 +2022,23 @@
|
|
1978
2022
|
],
|
1979
2023
|
"default": null,
|
1980
2024
|
"title": "Cache Prompt"
|
2025
|
+
},
|
2026
|
+
"reasoning_effort": {
|
2027
|
+
"anyOf": [
|
2028
|
+
{
|
2029
|
+
"enum": [
|
2030
|
+
"low",
|
2031
|
+
"medium",
|
2032
|
+
"high"
|
2033
|
+
],
|
2034
|
+
"type": "string"
|
2035
|
+
},
|
2036
|
+
{
|
2037
|
+
"type": "null"
|
2038
|
+
}
|
2039
|
+
],
|
2040
|
+
"default": null,
|
2041
|
+
"title": "Reasoning Effort"
|
1981
2042
|
}
|
1982
2043
|
},
|
1983
2044
|
"title": "GenerateConfig",
|
@@ -2003,7 +2064,8 @@
|
|
2003
2064
|
"top_logprobs",
|
2004
2065
|
"parallel_tool_calls",
|
2005
2066
|
"max_tool_output",
|
2006
|
-
"cache_prompt"
|
2067
|
+
"cache_prompt",
|
2068
|
+
"reasoning_effort"
|
2007
2069
|
],
|
2008
2070
|
"additionalProperties": false
|
2009
2071
|
},
|
@@ -2030,9 +2092,6 @@
|
|
2030
2092
|
"event": {
|
2031
2093
|
"const": "info",
|
2032
2094
|
"default": "info",
|
2033
|
-
"enum": [
|
2034
|
-
"info"
|
2035
|
-
],
|
2036
2095
|
"title": "Event",
|
2037
2096
|
"type": "string"
|
2038
2097
|
},
|
@@ -2073,9 +2132,6 @@
|
|
2073
2132
|
"event": {
|
2074
2133
|
"const": "input",
|
2075
2134
|
"default": "input",
|
2076
|
-
"enum": [
|
2077
|
-
"input"
|
2078
|
-
],
|
2079
2135
|
"title": "Event",
|
2080
2136
|
"type": "string"
|
2081
2137
|
},
|
@@ -2174,9 +2230,6 @@
|
|
2174
2230
|
"event": {
|
2175
2231
|
"const": "logger",
|
2176
2232
|
"default": "logger",
|
2177
|
-
"enum": [
|
2178
|
-
"logger"
|
2179
|
-
],
|
2180
2233
|
"title": "Event",
|
2181
2234
|
"type": "string"
|
2182
2235
|
},
|
@@ -2377,9 +2430,6 @@
|
|
2377
2430
|
"event": {
|
2378
2431
|
"const": "model",
|
2379
2432
|
"default": "model",
|
2380
|
-
"enum": [
|
2381
|
-
"model"
|
2382
|
-
],
|
2383
2433
|
"title": "Event",
|
2384
2434
|
"type": "string"
|
2385
2435
|
},
|
@@ -2769,9 +2819,6 @@
|
|
2769
2819
|
"event": {
|
2770
2820
|
"const": "sample_init",
|
2771
2821
|
"default": "sample_init",
|
2772
|
-
"enum": [
|
2773
|
-
"sample_init"
|
2774
|
-
],
|
2775
2822
|
"title": "Event",
|
2776
2823
|
"type": "string"
|
2777
2824
|
},
|
@@ -2816,9 +2863,6 @@
|
|
2816
2863
|
"event": {
|
2817
2864
|
"const": "sample_limit",
|
2818
2865
|
"default": "sample_limit",
|
2819
|
-
"enum": [
|
2820
|
-
"sample_limit"
|
2821
|
-
],
|
2822
2866
|
"title": "Event",
|
2823
2867
|
"type": "string"
|
2824
2868
|
},
|
@@ -2995,6 +3039,9 @@
|
|
2995
3039
|
},
|
2996
3040
|
{
|
2997
3041
|
"anyOf": [
|
3042
|
+
{
|
3043
|
+
"$ref": "#/$defs/BaseModel"
|
3044
|
+
},
|
2998
3045
|
{
|
2999
3046
|
"type": "string"
|
3000
3047
|
},
|
@@ -3139,9 +3186,6 @@
|
|
3139
3186
|
"event": {
|
3140
3187
|
"const": "score",
|
3141
3188
|
"default": "score",
|
3142
|
-
"enum": [
|
3143
|
-
"score"
|
3144
|
-
],
|
3145
3189
|
"title": "Event",
|
3146
3190
|
"type": "string"
|
3147
3191
|
},
|
@@ -3201,9 +3245,6 @@
|
|
3201
3245
|
"event": {
|
3202
3246
|
"const": "state",
|
3203
3247
|
"default": "state",
|
3204
|
-
"enum": [
|
3205
|
-
"state"
|
3206
|
-
],
|
3207
3248
|
"title": "Event",
|
3208
3249
|
"type": "string"
|
3209
3250
|
},
|
@@ -3248,9 +3289,6 @@
|
|
3248
3289
|
"event": {
|
3249
3290
|
"const": "step",
|
3250
3291
|
"default": "step",
|
3251
|
-
"enum": [
|
3252
|
-
"step"
|
3253
|
-
],
|
3254
3292
|
"title": "Event",
|
3255
3293
|
"type": "string"
|
3256
3294
|
},
|
@@ -3314,9 +3352,6 @@
|
|
3314
3352
|
"event": {
|
3315
3353
|
"const": "store",
|
3316
3354
|
"default": "store",
|
3317
|
-
"enum": [
|
3318
|
-
"store"
|
3319
|
-
],
|
3320
3355
|
"title": "Event",
|
3321
3356
|
"type": "string"
|
3322
3357
|
},
|
@@ -3361,9 +3396,6 @@
|
|
3361
3396
|
"event": {
|
3362
3397
|
"const": "subtask",
|
3363
3398
|
"default": "subtask",
|
3364
|
-
"enum": [
|
3365
|
-
"subtask"
|
3366
|
-
],
|
3367
3399
|
"title": "Event",
|
3368
3400
|
"type": "string"
|
3369
3401
|
},
|
@@ -3472,9 +3504,6 @@
|
|
3472
3504
|
},
|
3473
3505
|
"type": {
|
3474
3506
|
"const": "function",
|
3475
|
-
"enum": [
|
3476
|
-
"function"
|
3477
|
-
],
|
3478
3507
|
"title": "Type",
|
3479
3508
|
"type": "string"
|
3480
3509
|
},
|
@@ -3638,18 +3667,12 @@
|
|
3638
3667
|
"event": {
|
3639
3668
|
"const": "tool",
|
3640
3669
|
"default": "tool",
|
3641
|
-
"enum": [
|
3642
|
-
"tool"
|
3643
|
-
],
|
3644
3670
|
"title": "Event",
|
3645
3671
|
"type": "string"
|
3646
3672
|
},
|
3647
3673
|
"type": {
|
3648
3674
|
"const": "function",
|
3649
3675
|
"default": "function",
|
3650
|
-
"enum": [
|
3651
|
-
"function"
|
3652
|
-
],
|
3653
3676
|
"title": "Type",
|
3654
3677
|
"type": "string"
|
3655
3678
|
},
|
@@ -3693,6 +3716,12 @@
|
|
3693
3716
|
{
|
3694
3717
|
"type": "boolean"
|
3695
3718
|
},
|
3719
|
+
{
|
3720
|
+
"$ref": "#/$defs/ContentText"
|
3721
|
+
},
|
3722
|
+
{
|
3723
|
+
"$ref": "#/$defs/ContentImage"
|
3724
|
+
},
|
3696
3725
|
{
|
3697
3726
|
"items": {
|
3698
3727
|
"anyOf": [
|
@@ -3853,18 +3882,25 @@
|
|
3853
3882
|
"description": "Description of tool parameter in JSON Schema format.",
|
3854
3883
|
"properties": {
|
3855
3884
|
"type": {
|
3856
|
-
"
|
3857
|
-
|
3858
|
-
|
3859
|
-
|
3860
|
-
|
3861
|
-
|
3862
|
-
|
3863
|
-
|
3864
|
-
|
3885
|
+
"anyOf": [
|
3886
|
+
{
|
3887
|
+
"enum": [
|
3888
|
+
"string",
|
3889
|
+
"integer",
|
3890
|
+
"number",
|
3891
|
+
"boolean",
|
3892
|
+
"array",
|
3893
|
+
"object",
|
3894
|
+
"null"
|
3895
|
+
],
|
3896
|
+
"type": "string"
|
3897
|
+
},
|
3898
|
+
{
|
3899
|
+
"type": "null"
|
3900
|
+
}
|
3865
3901
|
],
|
3866
|
-
"
|
3867
|
-
"
|
3902
|
+
"default": null,
|
3903
|
+
"title": "Type"
|
3868
3904
|
},
|
3869
3905
|
"description": {
|
3870
3906
|
"anyOf": [
|
@@ -3882,6 +3918,19 @@
|
|
3882
3918
|
"default": null,
|
3883
3919
|
"title": "Default"
|
3884
3920
|
},
|
3921
|
+
"enum": {
|
3922
|
+
"anyOf": [
|
3923
|
+
{
|
3924
|
+
"items": {},
|
3925
|
+
"type": "array"
|
3926
|
+
},
|
3927
|
+
{
|
3928
|
+
"type": "null"
|
3929
|
+
}
|
3930
|
+
],
|
3931
|
+
"default": null,
|
3932
|
+
"title": "Enum"
|
3933
|
+
},
|
3885
3934
|
"items": {
|
3886
3935
|
"anyOf": [
|
3887
3936
|
{
|
@@ -3960,6 +4009,7 @@
|
|
3960
4009
|
"type",
|
3961
4010
|
"description",
|
3962
4011
|
"default",
|
4012
|
+
"enum",
|
3963
4013
|
"items",
|
3964
4014
|
"properties",
|
3965
4015
|
"additionalProperties",
|
@@ -3974,9 +4024,6 @@
|
|
3974
4024
|
"type": {
|
3975
4025
|
"const": "object",
|
3976
4026
|
"default": "object",
|
3977
|
-
"enum": [
|
3978
|
-
"object"
|
3979
|
-
],
|
3980
4027
|
"title": "Type",
|
3981
4028
|
"type": "string"
|
3982
4029
|
},
|
@@ -4086,6 +4133,7 @@
|
|
4086
4133
|
"num_choices": null,
|
4087
4134
|
"parallel_tool_calls": null,
|
4088
4135
|
"presence_penalty": null,
|
4136
|
+
"reasoning_effort": null,
|
4089
4137
|
"seed": null,
|
4090
4138
|
"stop_seqs": null,
|
4091
4139
|
"suffix": null,
|
inspect_ai/_view/www/src/App.mjs
CHANGED
@@ -123,6 +123,7 @@
|
|
123
123
|
* @property {string} toggle-right
|
124
124
|
* @property {string} more
|
125
125
|
* @property {string} next
|
126
|
+
* @property {string} play
|
126
127
|
* @property {string} previous
|
127
128
|
* @property {string} refresh
|
128
129
|
* @property {RoleIcons} role
|
@@ -209,6 +210,7 @@ export const ApplicationIcons = {
|
|
209
210
|
more: "bi bi-zoom-in",
|
210
211
|
"multiple-choice": "bi bi-card-list",
|
211
212
|
next: "bi bi-chevron-right",
|
213
|
+
play: "bi bi-play-fill",
|
212
214
|
previous: "bi bi-chevron-left",
|
213
215
|
refresh: "bi bi-arrow-clockwise",
|
214
216
|
role: {
|
@@ -0,0 +1,74 @@
|
|
1
|
+
// @ts-check
|
2
|
+
import { html } from "htm/preact";
|
3
|
+
import { useEffect, useRef } from "preact/hooks";
|
4
|
+
|
5
|
+
// Import the asciinema player library
|
6
|
+
import * as AsciinemaPlayer from "asciinema-player";
|
7
|
+
|
8
|
+
/**
|
9
|
+
* Renders the ChatView component.
|
10
|
+
*
|
11
|
+
* @param {Object} props - The properties passed to the component.
|
12
|
+
* @param {string} props.id - The ID for the chat view.
|
13
|
+
* @param {string} props.inputUrl - The input url for the player
|
14
|
+
* @param {string} props.outputUrl - The output url for the player
|
15
|
+
* @param {string} props.timingUrl - The timing url for the player
|
16
|
+
* @param {number} [props.rows] - The rows for the player's initial size
|
17
|
+
* @param {number} [props.cols] - The cols for the player's initial size
|
18
|
+
* @param {string} [props.fit] - how to fit the player
|
19
|
+
* @param {Object} [props.style] - Inline styles for the chat view.
|
20
|
+
* @param {number} [props.speed] - The speed to play (1 = 1x, 1.5 = 1.5x...)
|
21
|
+
* @param {boolean} [props.autoPlay] - Whether to autoplay
|
22
|
+
* @param {boolean} [props.loop] - Whether to loop
|
23
|
+
* @param {string} [props.theme] - The terminal theme (e.g. "solarized-dark")
|
24
|
+
* @param {number} [props.idleTimeLimit] - The amount to compress idle time to
|
25
|
+
* @returns {import("preact").JSX.Element} The component.
|
26
|
+
*/
|
27
|
+
export const AsciiCinemaPlayer = ({
|
28
|
+
id,
|
29
|
+
rows,
|
30
|
+
cols,
|
31
|
+
inputUrl,
|
32
|
+
outputUrl,
|
33
|
+
timingUrl,
|
34
|
+
fit,
|
35
|
+
speed,
|
36
|
+
autoPlay,
|
37
|
+
loop,
|
38
|
+
theme,
|
39
|
+
idleTimeLimit = 2,
|
40
|
+
style,
|
41
|
+
}) => {
|
42
|
+
const playerContainerRef = useRef();
|
43
|
+
useEffect(() => {
|
44
|
+
const player = AsciinemaPlayer.create(
|
45
|
+
{
|
46
|
+
url: [timingUrl, outputUrl, inputUrl],
|
47
|
+
parser: "typescript",
|
48
|
+
},
|
49
|
+
playerContainerRef.current,
|
50
|
+
{
|
51
|
+
rows: rows,
|
52
|
+
cols: cols,
|
53
|
+
autoPlay,
|
54
|
+
loop,
|
55
|
+
theme,
|
56
|
+
speed,
|
57
|
+
idleTimeLimit,
|
58
|
+
fit,
|
59
|
+
},
|
60
|
+
);
|
61
|
+
player.play();
|
62
|
+
return () => {
|
63
|
+
player.dispose();
|
64
|
+
};
|
65
|
+
}, []);
|
66
|
+
|
67
|
+
return html`
|
68
|
+
<div
|
69
|
+
id="asciinema-player-${id || "default"}"
|
70
|
+
ref=${playerContainerRef}
|
71
|
+
style=${{ ...style }}
|
72
|
+
></div>
|
73
|
+
`;
|
74
|
+
};
|