mirror of
https://github.com/meta-llama/llama-stack.git
synced 2025-08-15 22:18:00 +00:00
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:
parent
2d1ab3ca55
commit
072d20a124
59 changed files with 22727 additions and 9 deletions
421
tests/integration/recordings/responses/477f8946bf7d.json
Normal file
421
tests/integration/recordings/responses/477f8946bf7d.json
Normal file
|
@ -0,0 +1,421 @@
|
|||
{
|
||||
"request": {
|
||||
"method": "POST",
|
||||
"url": "http://localhost:11434/api/embeddings",
|
||||
"headers": {},
|
||||
"body": {
|
||||
"model": "all-minilm:l6-v2",
|
||||
"input": [
|
||||
"Python is a high-level programming language with code readability and fewer lines than C++ or Java"
|
||||
]
|
||||
},
|
||||
"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": 32336042,
|
||||
"load_duration": 24852000,
|
||||
"prompt_eval_count": 21,
|
||||
"prompt_eval_duration": null,
|
||||
"eval_count": null,
|
||||
"eval_duration": null,
|
||||
"embeddings": [
|
||||
[
|
||||
-0.07642644,
|
||||
0.0213101,
|
||||
-0.03612849,
|
||||
-0.0012144424,
|
||||
-0.048599217,
|
||||
-0.13194773,
|
||||
-0.084226094,
|
||||
0.059389386,
|
||||
-0.0617182,
|
||||
-0.009323243,
|
||||
-0.08099486,
|
||||
0.055514984,
|
||||
0.052610602,
|
||||
0.026061919,
|
||||
0.063071534,
|
||||
-0.062316332,
|
||||
-0.065115415,
|
||||
-0.022351492,
|
||||
0.017378356,
|
||||
-0.11605584,
|
||||
-0.036349725,
|
||||
0.0404155,
|
||||
-0.0325302,
|
||||
-0.01770141,
|
||||
0.05722761,
|
||||
0.012393438,
|
||||
-0.018529164,
|
||||
-0.030017126,
|
||||
0.002365914,
|
||||
0.0066701965,
|
||||
-0.08862459,
|
||||
0.0779319,
|
||||
0.03702611,
|
||||
0.029523117,
|
||||
-0.01977821,
|
||||
0.05424799,
|
||||
-0.00074063655,
|
||||
-0.08949148,
|
||||
-0.05312112,
|
||||
-0.012703181,
|
||||
-0.08622611,
|
||||
0.07689996,
|
||||
-0.038602136,
|
||||
-0.011616902,
|
||||
-0.03234132,
|
||||
-0.0073969415,
|
||||
-0.024779495,
|
||||
-0.067999884,
|
||||
-0.03039565,
|
||||
-0.025974417,
|
||||
-0.09690519,
|
||||
0.009931951,
|
||||
-0.05362519,
|
||||
-0.09107193,
|
||||
-0.009222061,
|
||||
-0.008804084,
|
||||
0.048185978,
|
||||
-0.003329437,
|
||||
-0.0058579347,
|
||||
-0.13306528,
|
||||
-0.09721703,
|
||||
0.013474277,
|
||||
0.047286008,
|
||||
0.06279936,
|
||||
-0.01582815,
|
||||
-0.03771013,
|
||||
-0.01651892,
|
||||
0.029905442,
|
||||
0.09326656,
|
||||
-0.06746783,
|
||||
-0.13385954,
|
||||
-0.020873511,
|
||||
-0.02586237,
|
||||
0.11623731,
|
||||
0.030632136,
|
||||
-0.10494776,
|
||||
0.03905967,
|
||||
-0.010701787,
|
||||
-0.0014734551,
|
||||
0.020711906,
|
||||
0.0017687598,
|
||||
0.027797814,
|
||||
-0.078500465,
|
||||
0.10791581,
|
||||
0.02910256,
|
||||
-0.05398749,
|
||||
0.030513834,
|
||||
0.07001416,
|
||||
-0.034323946,
|
||||
0.00986597,
|
||||
0.034644563,
|
||||
-0.04232179,
|
||||
0.065106474,
|
||||
0.026648693,
|
||||
-0.032122962,
|
||||
0.07616709,
|
||||
0.020026332,
|
||||
-0.030642457,
|
||||
-0.07188906,
|
||||
0.027189687,
|
||||
-0.018678213,
|
||||
-0.05416582,
|
||||
0.07488992,
|
||||
0.017753933,
|
||||
0.03386007,
|
||||
0.02414506,
|
||||
0.09077034,
|
||||
-0.052096054,
|
||||
0.040722203,
|
||||
-0.018450806,
|
||||
-0.012474094,
|
||||
-0.06403705,
|
||||
-0.023205942,
|
||||
-0.061878704,
|
||||
0.053436812,
|
||||
0.047876816,
|
||||
-0.010608645,
|
||||
0.07852118,
|
||||
0.03579911,
|
||||
0.027097313,
|
||||
0.022424318,
|
||||
-0.004912598,
|
||||
-0.02455264,
|
||||
0.003700777,
|
||||
0.00039888592,
|
||||
-0.008842094,
|
||||
0.009365857,
|
||||
2.05052e-34,
|
||||
-0.03236592,
|
||||
-0.024301885,
|
||||
0.027186498,
|
||||
0.021633558,
|
||||
0.06519107,
|
||||
-0.019539308,
|
||||
0.05306087,
|
||||
0.007985293,
|
||||
-0.03927361,
|
||||
-0.020062907,
|
||||
0.008070545,
|
||||
0.02382429,
|
||||
0.015006528,
|
||||
0.1128094,
|
||||
0.06113956,
|
||||
-0.011911169,
|
||||
0.016901307,
|
||||
0.045509744,
|
||||
0.0013988831,
|
||||
0.00907712,
|
||||
0.01314859,
|
||||
-0.012022324,
|
||||
0.027043821,
|
||||
0.0071581583,
|
||||
0.022573117,
|
||||
-0.013721936,
|
||||
-0.004378743,
|
||||
-0.0007087661,
|
||||
0.033585846,
|
||||
0.011227843,
|
||||
-0.05136015,
|
||||
-0.0739591,
|
||||
-0.03094639,
|
||||
0.01957863,
|
||||
-0.010360539,
|
||||
-0.0029881562,
|
||||
-0.00480912,
|
||||
-0.10446798,
|
||||
0.034694213,
|
||||
-0.02424012,
|
||||
-0.047155295,
|
||||
0.035451673,
|
||||
0.037169226,
|
||||
-0.016986743,
|
||||
0.0056092087,
|
||||
0.05057555,
|
||||
-0.008601115,
|
||||
0.0060349177,
|
||||
-0.12273999,
|
||||
0.036871877,
|
||||
-0.022267655,
|
||||
-0.009739047,
|
||||
0.075974636,
|
||||
0.08902226,
|
||||
0.01647873,
|
||||
0.044345584,
|
||||
0.06792565,
|
||||
0.06456903,
|
||||
-0.050189856,
|
||||
-0.0016995457,
|
||||
-0.00090498856,
|
||||
0.09925942,
|
||||
0.09253569,
|
||||
-0.011321612,
|
||||
0.050309792,
|
||||
0.07697773,
|
||||
0.0100068,
|
||||
0.101032645,
|
||||
0.03268899,
|
||||
0.06433435,
|
||||
-0.044524822,
|
||||
0.03860177,
|
||||
-0.019314477,
|
||||
0.037440598,
|
||||
-0.0017394378,
|
||||
0.011816814,
|
||||
0.011359969,
|
||||
-0.1040215,
|
||||
0.06984421,
|
||||
0.01910163,
|
||||
-0.028409261,
|
||||
-0.013704911,
|
||||
0.048502754,
|
||||
-0.015429918,
|
||||
-0.03423058,
|
||||
-0.055616368,
|
||||
0.005001686,
|
||||
0.026054256,
|
||||
-0.0007700968,
|
||||
-0.0041726283,
|
||||
-0.0640977,
|
||||
-0.05985385,
|
||||
0.0813829,
|
||||
0.014288322,
|
||||
-0.038147252,
|
||||
-2.1576616e-33,
|
||||
-0.027279941,
|
||||
-0.034765568,
|
||||
-0.02465107,
|
||||
0.026859807,
|
||||
-0.090699576,
|
||||
-0.045698144,
|
||||
0.013666582,
|
||||
0.002109106,
|
||||
0.054007426,
|
||||
0.032838397,
|
||||
-0.029939773,
|
||||
-0.058843046,
|
||||
0.09825693,
|
||||
0.03251322,
|
||||
0.109977886,
|
||||
0.020682266,
|
||||
-0.0958973,
|
||||
0.0005566991,
|
||||
0.0018037638,
|
||||
0.017544486,
|
||||
-0.06843023,
|
||||
0.06435102,
|
||||
-0.050149646,
|
||||
-0.048880838,
|
||||
-0.027535524,
|
||||
-0.014993001,
|
||||
-0.1210176,
|
||||
-0.04412877,
|
||||
-0.011025324,
|
||||
0.058610573,
|
||||
-0.007498303,
|
||||
0.038722932,
|
||||
-0.07025986,
|
||||
0.030281536,
|
||||
0.055707317,
|
||||
-0.001162887,
|
||||
0.01707519,
|
||||
-0.042081844,
|
||||
-0.016578361,
|
||||
-0.025714336,
|
||||
0.117893435,
|
||||
0.04196084,
|
||||
0.064787276,
|
||||
0.046081997,
|
||||
0.014950138,
|
||||
0.030026693,
|
||||
-0.039077066,
|
||||
0.087156676,
|
||||
-0.012328571,
|
||||
-0.035646956,
|
||||
-0.048145168,
|
||||
0.041394625,
|
||||
0.038984135,
|
||||
-0.025188481,
|
||||
-0.028836856,
|
||||
-0.02917782,
|
||||
0.029690607,
|
||||
0.051454436,
|
||||
-0.08629761,
|
||||
-0.06921346,
|
||||
-0.07273269,
|
||||
-0.05952071,
|
||||
0.0050034616,
|
||||
0.025693603,
|
||||
-0.022103382,
|
||||
0.024972659,
|
||||
-0.09724792,
|
||||
0.0062089814,
|
||||
-0.04963219,
|
||||
-0.13054384,
|
||||
0.124669954,
|
||||
-0.01361085,
|
||||
-0.022798477,
|
||||
0.039057832,
|
||||
-0.07550591,
|
||||
0.049364913,
|
||||
0.0007779102,
|
||||
0.004692535,
|
||||
-0.040757872,
|
||||
0.06355995,
|
||||
0.110190175,
|
||||
0.02015945,
|
||||
-0.048807338,
|
||||
0.05842704,
|
||||
-0.066375315,
|
||||
0.026938869,
|
||||
-0.062775925,
|
||||
-0.014049011,
|
||||
0.023343485,
|
||||
0.02358394,
|
||||
-0.002172394,
|
||||
0.07766165,
|
||||
0.031056313,
|
||||
0.020171564,
|
||||
-0.020073414,
|
||||
-2.4317085e-08,
|
||||
0.020261949,
|
||||
-0.008623839,
|
||||
0.0621209,
|
||||
-0.008334477,
|
||||
0.02526615,
|
||||
0.08902315,
|
||||
-0.007958188,
|
||||
-0.018911751,
|
||||
-0.035572145,
|
||||
0.06189234,
|
||||
-0.017249323,
|
||||
-0.030186126,
|
||||
-0.10225455,
|
||||
-0.06522741,
|
||||
-0.004033112,
|
||||
0.10897627,
|
||||
-0.02168822,
|
||||
-0.053784374,
|
||||
0.011841631,
|
||||
0.052263785,
|
||||
0.058334205,
|
||||
0.0052479547,
|
||||
-0.06017166,
|
||||
0.08723854,
|
||||
-0.08275336,
|
||||
-0.040676847,
|
||||
0.065786876,
|
||||
0.028317772,
|
||||
-0.012168614,
|
||||
-0.07196286,
|
||||
0.014588226,
|
||||
-0.03231537,
|
||||
0.0028357722,
|
||||
0.03868031,
|
||||
0.055439528,
|
||||
-0.015238348,
|
||||
0.05482384,
|
||||
-0.025080629,
|
||||
-0.033771332,
|
||||
0.0030752022,
|
||||
-0.037511814,
|
||||
0.015122315,
|
||||
0.02292684,
|
||||
0.012024873,
|
||||
0.03559873,
|
||||
0.006865039,
|
||||
-0.04049267,
|
||||
-0.049685854,
|
||||
-0.05455341,
|
||||
-0.073071465,
|
||||
-0.024902396,
|
||||
-0.002133957,
|
||||
-0.013212662,
|
||||
-0.06657236,
|
||||
0.023245512,
|
||||
0.046919,
|
||||
-0.13278763,
|
||||
-0.011092663,
|
||||
-0.023939205,
|
||||
0.043182902,
|
||||
0.024406029,
|
||||
0.06922961,
|
||||
0.15658055,
|
||||
0.017658537
|
||||
]
|
||||
]
|
||||
}
|
||||
},
|
||||
"is_streaming": false
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue