feat(test): record agents, safety and vector_io integration tests (#2952)

Continue to build on top of
https://github.com/meta-llama/llama-stack/pull/2941

## Test Plan

Run server with `LLAMA_STACK_TEST_INFERENCE_MODE=record` and then run
the integration tests with `--stack-config=server:starter`. Then restart
the server with `LLAMA_STACK_TEST_INFERENCE_MODE=replay` and re-run the
tests. Verify that no request hit Ollama at any point.
This commit is contained in:
Ashwin Bharambe 2025-07-29 14:02:14 -07:00 committed by GitHub
parent 2d1ab3ca55
commit 072d20a124
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
59 changed files with 22727 additions and 9 deletions

View file

@ -0,0 +1,421 @@
{
"request": {
"method": "POST",
"url": "http://localhost:11434/api/embeddings",
"headers": {},
"body": {
"model": "all-minilm:l6-v2",
"input": [
"This is a test file"
]
},
"endpoint": "/api/embeddings",
"model": "all-minilm:l6-v2"
},
"response": {
"body": {
"__type__": "ollama._types.EmbedResponse",
"__data__": {
"model": "all-minilm:l6-v2",
"created_at": null,
"done": null,
"done_reason": null,
"total_duration": 54720667,
"load_duration": 26019750,
"prompt_eval_count": 5,
"prompt_eval_duration": null,
"eval_count": null,
"eval_duration": null,
"embeddings": [
[
-0.03427073,
0.090051405,
-0.11458989,
0.0021456745,
0.059038658,
-0.027524853,
-0.020602634,
0.03373726,
-0.038729247,
0.026002944,
0.11481002,
0.027119067,
-0.015927644,
-0.021832926,
-0.046713773,
-0.0463825,
-0.074167565,
-0.0528447,
-0.028117927,
0.06325688,
0.029135453,
0.047131006,
-0.052675154,
-0.005349263,
0.030659368,
0.017706472,
-0.01687267,
0.08681507,
-0.014155131,
-0.0838676,
0.020020565,
0.07115838,
0.08365558,
0.030919788,
0.11829893,
0.028751066,
0.069536895,
-0.017295403,
-0.005784813,
0.005809313,
0.0012009157,
-0.0653044,
0.0373506,
0.018565746,
-0.0034945607,
-0.0011305016,
-0.029752811,
-0.021266408,
0.0058016903,
-0.035597492,
-0.03722647,
0.012373253,
-0.066935256,
-0.023148224,
0.056864377,
0.0014741909,
0.014408296,
-0.017165763,
0.009236472,
0.06087921,
0.024628488,
0.03699286,
-0.050610077,
0.05173448,
0.10159555,
0.008507267,
-0.04803921,
-0.013024803,
0.03110457,
-0.16593884,
-0.1410075,
0.009813814,
-0.025974236,
0.05233053,
-0.0078903325,
0.00788491,
-0.08471812,
-0.044507448,
0.054161046,
-0.0704361,
-0.05769206,
-0.100796975,
0.02182441,
0.022125391,
0.0071617346,
0.13063926,
0.080232956,
-0.004421626,
-0.018768508,
0.0076132733,
-0.03163366,
0.031986494,
-0.022168567,
0.03073627,
-0.023798423,
0.06954045,
0.016659362,
0.009536805,
0.027459558,
0.102133445,
0.021457382,
-0.021377807,
0.015131543,
0.039423607,
-0.09434147,
-0.11544392,
0.09468138,
-0.011155598,
0.07266597,
-0.03601087,
-0.011743829,
-0.06654009,
-0.03470551,
-0.10300434,
0.03020924,
-0.06319472,
-0.0908424,
0.04116676,
-0.033686537,
0.045706224,
0.07134009,
-0.031778418,
-0.059655976,
-0.017215038,
-0.03229557,
-0.058579948,
0.06733934,
-5.023814e-33,
-0.0058283503,
-0.0719842,
-0.009296622,
0.09659216,
0.03709538,
-0.03478395,
-0.004713233,
0.016686605,
-0.09859812,
0.00547005,
-0.014113569,
-0.0840751,
0.0027168505,
0.04445616,
-0.012728728,
0.034566686,
-0.0006014651,
0.06319148,
-0.026799418,
-0.013500979,
0.024169419,
0.015417236,
-0.04135526,
-0.055208974,
-0.06455241,
0.03148543,
-0.0073052812,
-0.03945437,
0.059831504,
0.026674163,
0.01396753,
-0.038841277,
-0.048514687,
0.01756627,
0.020964677,
0.035239976,
0.0115498835,
-0.00846713,
-0.044673763,
0.014640657,
5.2045852e-05,
-0.04694704,
0.02703366,
0.006635295,
0.064396136,
-0.044757996,
-0.026173549,
-0.016282372,
0.05521396,
0.014104745,
-0.008479494,
0.04204778,
0.05049772,
0.021629427,
0.011260506,
0.04858872,
0.017662494,
-0.005005865,
0.0019118759,
0.06333162,
0.035875723,
0.03504778,
-0.06642375,
0.008791644,
-0.027326671,
-0.05987137,
-0.0272001,
-0.08728625,
0.112434424,
0.05879801,
-0.041698616,
-0.06924583,
0.06434144,
0.01583225,
-0.027750073,
-0.037574448,
-0.011715211,
0.0694801,
-0.07104981,
-0.039085716,
-0.043068763,
-0.11208956,
-0.030723054,
-0.063793585,
-0.03527373,
-0.06119042,
-0.01526633,
-0.10094421,
0.047486804,
-0.08320468,
-0.0029513796,
0.0131224785,
-0.056690685,
-0.057956036,
0.06140136,
2.7669969e-33,
0.0036719525,
0.06695694,
-0.05591421,
0.025166295,
0.014735592,
0.03381445,
0.09345791,
-0.01053347,
-0.046693947,
0.14254177,
-0.015430197,
0.0066938214,
0.07679359,
-0.045779705,
0.07989786,
0.0036165903,
0.023604553,
-0.06533708,
-0.04253485,
-0.025912313,
-0.0748119,
0.10020777,
0.12578633,
0.06409652,
-0.016682886,
0.01406972,
0.025274348,
0.0017218525,
-0.013340701,
0.01172295,
0.03772902,
0.040607873,
-0.120578945,
0.024344057,
0.03439985,
-0.10167353,
0.11863072,
-0.03571693,
-0.0126576,
0.022622129,
0.039235484,
0.10625315,
0.0106492825,
0.076503076,
0.02088746,
0.06468519,
0.08582322,
-0.032148413,
0.04359905,
0.011070053,
0.023209164,
-0.06709916,
0.055355705,
-0.008128262,
-0.026921155,
0.076995976,
-0.011614669,
0.044967294,
-0.02459807,
0.020910041,
-0.0016746842,
0.02905443,
-0.03898753,
-0.01360213,
-0.019878393,
-0.057056017,
-0.014543598,
0.010161744,
0.016893594,
0.011981163,
0.019902436,
0.019194229,
-0.06551642,
-0.050247267,
0.050837662,
-0.075614415,
-0.018767305,
-0.012229684,
0.0019464786,
-0.0035209567,
0.0699799,
-0.02925182,
-0.008455151,
0.04742619,
-0.0004527954,
-0.014011262,
-0.0035493495,
0.08439228,
-0.001586065,
0.0016962147,
-0.023180604,
0.059889086,
0.019616995,
0.05435093,
0.012301163,
-1.5289881e-08,
-0.038103975,
-0.084179275,
-0.013605872,
-0.03277629,
-0.020995136,
0.08924277,
0.005438667,
-0.07047066,
-0.03966912,
-0.018226335,
0.05716885,
-0.026391266,
-0.09881308,
0.017511,
-0.01952465,
-0.06237397,
-0.019553065,
-0.0112019945,
-0.030052405,
0.010624359,
-0.005598304,
0.05326868,
0.044162616,
0.025812192,
0.0059228353,
0.059632093,
0.06885661,
0.08894283,
-0.06225795,
-0.038893122,
0.028817136,
0.08772772,
0.017759481,
-0.050048865,
-0.0009810333,
0.1297453,
0.083138496,
0.08161095,
0.011747931,
0.006871316,
-0.07277484,
-0.0020051182,
-0.018357608,
0.008882652,
-0.03823878,
-0.09057624,
-0.06433315,
-0.04256367,
-0.030856675,
-0.09314087,
-0.043470908,
0.012043298,
-9.8401986e-05,
0.040246293,
-0.04912119,
0.014575804,
0.017479645,
-0.00515073,
-0.033331197,
0.0075505474,
0.07488009,
0.06460031,
0.044803377,
-0.028485151
]
]
}
},
"is_streaming": false
}
}