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 2"
]
},
"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": 58258750,
"load_duration": 25899542,
"prompt_eval_count": 6,
"prompt_eval_duration": null,
"eval_count": null,
"eval_duration": null,
"embeddings": [
[
-0.028407024,
0.08176727,
-0.07856116,
0.027924549,
0.05008439,
-0.035268802,
-0.0040619136,
0.029315198,
-0.05775003,
0.013769637,
0.14610882,
-0.012019041,
-0.024392882,
-0.05509032,
-0.02661779,
-0.013253934,
-0.109151706,
-0.037233494,
-0.0036058167,
0.04766495,
0.06212885,
0.0070259646,
-0.015513743,
-0.008010851,
0.037648663,
0.01587603,
-0.041856695,
0.09732178,
-0.025641596,
-0.11368298,
0.03550726,
0.07043342,
0.016779423,
0.02220752,
0.123395406,
0.0077137193,
0.12550895,
0.008077936,
-0.026158499,
0.0028612812,
0.018155744,
-0.04666325,
0.041025575,
0.0013476727,
0.0019516364,
0.008663665,
0.016689047,
0.02200178,
0.0020768014,
-0.032861207,
-0.086455174,
0.008047145,
-0.07434091,
-0.016292974,
0.06051878,
0.005966867,
0.0160179,
0.021412006,
0.009540338,
0.03177335,
0.023032434,
0.03437097,
-0.04224765,
0.024748176,
0.116213955,
-0.024936162,
-0.03895259,
-0.024991278,
-0.020854436,
-0.08835937,
-0.15073228,
0.020921277,
-0.022518696,
0.0023868105,
0.0057663955,
-0.0015790414,
-0.11985628,
-0.0029912454,
0.0550998,
-0.11830636,
-0.058846988,
-0.15046737,
0.018624697,
-0.0093440395,
-0.028901154,
0.08400474,
0.0437436,
-0.0006745939,
-0.052540295,
0.00024754918,
0.040431518,
0.0066545215,
0.02609114,
0.051891107,
0.012606882,
0.061448827,
0.013889043,
0.038454182,
0.048222367,
0.104106456,
-0.026478294,
-0.021488149,
-0.020865437,
0.05061779,
-0.05171592,
-0.07573864,
0.057483904,
-0.049993664,
0.06528295,
-0.02875688,
0.038766492,
-0.062760465,
-0.0144796055,
-0.063462086,
0.06642258,
-0.014848135,
-0.03523116,
0.0774014,
-0.039893247,
0.032182425,
0.10171478,
-0.022525396,
-0.059299074,
0.00038746602,
-0.05779858,
-0.07034273,
0.06375495,
-4.088634e-33,
-0.021801252,
-0.07985834,
-0.013881648,
0.14923096,
0.02520313,
-0.042283125,
-0.0067697223,
0.054634638,
-0.09223034,
0.0081036305,
-0.03861765,
-0.117698364,
0.012977803,
0.034548674,
-0.01703291,
0.011910173,
0.012945288,
0.04277919,
-0.017591223,
-0.0184066,
0.06513148,
0.04050013,
-0.02252127,
-0.060939074,
-0.018603502,
0.011679816,
0.01410369,
-0.06763908,
0.08543174,
0.030138582,
0.010859261,
-0.054844614,
-0.024129191,
0.048327282,
0.00750549,
0.013356204,
0.024558878,
-0.005942624,
-0.045620095,
-0.00484637,
0.004418298,
-0.0023806267,
0.013590539,
-0.016870445,
0.06959721,
-0.07736302,
0.02058481,
0.0048155314,
0.055696823,
0.0131223425,
-0.011748222,
0.040935397,
0.007458848,
0.042072233,
0.010358565,
0.019406458,
0.011092792,
0.017259602,
0.018278012,
0.077335365,
0.019612921,
0.05268688,
-0.05863009,
0.039751627,
-0.050250556,
-0.048913844,
-0.05265637,
-0.09227304,
0.0755598,
0.08097828,
-0.022257954,
-0.042141132,
0.056546185,
0.023585746,
0.0015263582,
-0.049815144,
0.002336895,
0.028626408,
-0.06897293,
-0.04780049,
-0.048637427,
-0.076585636,
-0.03285766,
-0.046012525,
-0.0573021,
-0.080889866,
-0.008056378,
-0.0936112,
0.051229417,
-0.058302302,
-0.0005942833,
0.02222621,
-0.046907477,
-0.08964737,
0.1195762,
2.0452953e-33,
0.012159685,
0.086426094,
-0.023217503,
0.002771192,
-0.0010614472,
0.03487195,
0.07328719,
-0.049876485,
-0.041938163,
0.13486409,
-0.00690217,
0.006254477,
0.059122436,
-0.028893106,
0.09141587,
-0.018487127,
0.0077112317,
-0.044207573,
-0.0251735,
-0.014999972,
-0.035417248,
0.12413253,
0.13118097,
0.081015825,
-0.03327241,
0.003976432,
0.026454262,
0.026598025,
0.017349144,
-0.0036153824,
0.035460044,
0.05956128,
-0.124593176,
0.021954069,
0.025635097,
-0.11063109,
0.096061416,
-0.06731725,
-0.011819293,
0.042329434,
0.03790837,
0.10582649,
0.0073426333,
0.06629678,
0.022922922,
0.0494007,
0.14639522,
-0.0067070075,
0.004380622,
-0.029196544,
-0.009010303,
-0.08637028,
0.03588363,
0.0029887543,
-0.029351206,
0.07019312,
0.014898416,
0.028345235,
-0.040354595,
0.01916304,
0.015590835,
0.028637327,
-0.019529723,
-0.018309733,
-0.0054176697,
-0.093132764,
-0.06116049,
0.038816936,
0.02793884,
0.034137025,
-0.027511358,
0.010699668,
-0.05521562,
-0.07380209,
0.021521263,
-0.015450832,
-0.024988633,
-0.004755674,
0.030465573,
-0.024057997,
0.0341225,
-0.0103128245,
-0.012666524,
0.03628323,
-0.0044518244,
-0.014977736,
0.02790076,
0.0978009,
-0.026436698,
-0.005187212,
-0.019124882,
0.06205225,
0.052137945,
0.037870288,
0.012578256,
-1.705626e-08,
-0.05000592,
-0.08913878,
-0.0035273295,
-0.01577607,
-0.021846429,
0.07184407,
-0.050185654,
-0.010643527,
-0.030602882,
-0.01577121,
0.013220822,
-0.0025653532,
-0.04210823,
0.009286525,
-0.041129403,
-0.029615805,
0.002200794,
-0.032989334,
-0.05041253,
-0.021504797,
-0.0068345494,
0.0084738685,
0.03568697,
0.0252117,
-0.016504692,
0.04915123,
0.018349955,
0.049084183,
-0.058165494,
-0.015055481,
0.045743454,
0.049920842,
0.020444298,
-0.052004594,
-0.033592116,
0.061816722,
0.111411005,
0.07770497,
0.022457859,
0.0025742552,
-0.043929543,
0.008576763,
-0.036182683,
0.029673496,
-0.017278075,
-0.09458994,
-0.057882637,
-0.06579892,
-0.06124832,
-0.10455079,
-0.02925637,
0.0013624659,
0.0060532107,
0.04077331,
-0.036694046,
0.016800206,
0.005279432,
0.030968234,
-0.05446385,
0.0048696757,
0.070877954,
0.06684445,
0.017715273,
-0.029237686
]
]
}
},
"is_streaming": false
}
}