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 0"
]
},
"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": 44225125,
"load_duration": 36913875,
"prompt_eval_count": 6,
"prompt_eval_duration": null,
"eval_count": null,
"eval_duration": null,
"embeddings": [
[
-0.021802,
0.088129535,
-0.10867403,
0.0027561262,
0.04917365,
-0.030165128,
-0.0155558735,
0.027549915,
-0.025064131,
0.016137881,
0.124836035,
0.0027821937,
-0.033310093,
-0.0071708336,
-0.07004796,
-0.027996853,
-0.09748515,
-0.091607764,
0.013367206,
0.08752305,
0.013990884,
0.03663788,
-0.036330026,
-0.019752761,
0.04456914,
-0.009629443,
-0.01832647,
0.048832405,
-0.015315298,
-0.07147843,
0.04094573,
0.082709365,
0.063961774,
0.01448001,
0.13194442,
0.0303949,
0.101027474,
-0.030359762,
-0.047630757,
0.044637363,
0.027034018,
-0.029368822,
0.038537122,
0.0053882804,
0.01478374,
0.025617138,
0.0041860593,
0.0034900715,
0.029765956,
-0.036669906,
-0.04589116,
0.031120853,
-0.07786974,
-0.019517597,
0.053876307,
-0.0152282175,
-0.0016955235,
0.016938528,
0.019939963,
0.07106882,
0.009938938,
0.03114348,
-0.010335175,
0.029952966,
0.115054145,
0.025746102,
-0.052842245,
-0.042447682,
0.0053093657,
-0.09987591,
-0.12741813,
-0.012022532,
-0.013787561,
0.05265948,
-0.01723935,
0.009638554,
-0.0775266,
0.0014047497,
0.06974368,
-0.08465856,
-0.061480872,
-0.14244927,
0.0096944375,
-0.008611519,
-0.0318523,
0.12823504,
0.053257603,
0.021978743,
0.0026468195,
0.015444479,
-0.042528655,
0.031551417,
-0.06209267,
0.044017885,
-0.0060390937,
0.06959196,
0.0050514904,
0.059341036,
0.00658094,
0.08397857,
-0.0067914296,
-0.041901726,
0.027081704,
0.106456675,
-0.039408114,
-0.053899165,
0.09689717,
-0.0084604705,
0.03398384,
-0.033843804,
0.002225838,
-0.08180734,
-0.008216738,
-0.11271415,
0.0058824755,
-0.095151186,
-0.07958445,
0.052868627,
-0.08120183,
0.034291897,
0.07903789,
-0.02675632,
-0.04391073,
0.0067707864,
-0.05438546,
-0.021719433,
0.080597855,
-3.9388086e-33,
-0.0072714644,
-0.079664536,
0.024838887,
0.115598045,
0.03591746,
-0.07254434,
0.012642099,
0.050809097,
-0.100082524,
0.019521356,
0.0035883472,
-0.07001022,
0.007977421,
0.029305879,
-0.017785804,
0.02702277,
0.016827941,
0.035956737,
-0.0209356,
-0.032321777,
0.056705642,
-0.009747762,
-0.059722506,
-0.053817417,
-0.055837773,
0.06526892,
-0.024752634,
-0.07778206,
0.038636208,
0.008998632,
0.009699391,
-0.02798574,
-0.024878206,
-0.0017547129,
0.025541965,
0.034623418,
-8.975541e-06,
0.0034556785,
-0.04525613,
0.03461154,
-0.025307115,
-0.02981576,
-0.019071916,
-0.023184983,
0.049324982,
-0.061433185,
0.00038017757,
0.0028894164,
0.027610173,
0.0069347974,
-0.020659719,
0.060771395,
0.015200205,
0.038918514,
-0.025353896,
-0.0017897633,
-0.019378036,
-0.0056970986,
-0.017806012,
0.038060427,
0.0320353,
0.03998783,
-0.09612384,
0.0006942505,
-0.018478483,
-0.06866618,
-0.0077035497,
-0.083554305,
0.10223985,
0.05141575,
-0.033018276,
-0.05033401,
0.043923385,
0.017748218,
-0.006601344,
-0.018691983,
0.012763011,
0.016694913,
-0.095070764,
-0.023533016,
0.006879241,
-0.07225332,
-0.0029991802,
-0.06930797,
-0.027289826,
-0.0672911,
-0.006683099,
-0.06801406,
0.04452207,
-0.09788058,
0.050909285,
0.010051549,
-0.04617998,
-0.067622505,
0.04447288,
2.5643933e-33,
0.014783131,
0.071710624,
-0.05237768,
0.011041238,
-0.013921518,
0.07072471,
0.091977395,
-0.01916791,
-0.015780058,
0.14812021,
0.031904023,
0.022344623,
0.07071857,
-0.037060503,
0.08806883,
-0.018145561,
-0.013254877,
-0.041782882,
-0.052317847,
-0.00279131,
-0.024807084,
0.13974102,
0.074973755,
0.056424167,
-0.029412953,
0.017093861,
0.03373144,
0.06874087,
0.020454561,
-0.018965451,
0.081238694,
0.06527906,
-0.09342225,
0.0037720343,
0.06347132,
-0.08775714,
0.09286548,
-0.024266576,
0.029101077,
0.0034162905,
0.05528427,
0.102037616,
-0.023588225,
0.065829135,
0.01520327,
0.034344077,
0.10559419,
0.011605323,
0.0409873,
-0.056635953,
0.037730522,
-0.04976337,
0.047961522,
0.0042118295,
-0.014172872,
0.07564937,
-0.009671058,
0.05520304,
-0.031121492,
0.019924358,
-0.024975697,
0.031822197,
-0.019536836,
-0.009870229,
-0.020225972,
-0.03319855,
-0.026266782,
0.038882248,
0.012940086,
-0.041266225,
0.012833021,
0.028703777,
-0.054075323,
-0.07628176,
0.021953572,
-0.023357453,
-0.026714878,
-0.029401133,
0.005280363,
0.012325193,
0.05232579,
0.0054451786,
-0.0063759633,
0.04604998,
0.042399842,
-0.018433316,
0.01260558,
0.09300185,
-0.005949781,
-0.015193224,
-0.011673769,
0.048114438,
0.02588804,
0.050943956,
0.005536351,
-1.5059804e-08,
-0.03100338,
-0.07003323,
-0.032613333,
-0.008732137,
-0.0045523546,
0.0759239,
-0.032725554,
-0.08790561,
-0.032228027,
-0.02459868,
0.051224917,
-0.034561895,
-0.08266327,
0.013319846,
-0.020541467,
-0.056271035,
-0.009450659,
-0.015903467,
-0.036625408,
0.010096497,
-0.03440534,
0.0315293,
-0.00013937108,
0.010463861,
0.017065981,
0.015492903,
0.074808784,
0.07079003,
-0.050000764,
-0.047017526,
0.01375958,
0.060757488,
-0.009361379,
-0.01570009,
-0.01836736,
0.12301148,
0.1185397,
0.12366319,
0.022782512,
-0.020027133,
-0.07401259,
-0.0047104736,
-0.024872223,
0.006070436,
-0.06660639,
-0.08130306,
-0.0873992,
-0.0634906,
-0.039198957,
-0.11274462,
-0.030654918,
0.026607778,
-0.063220546,
0.042023618,
-0.039010853,
-0.009214424,
0.005044682,
0.0015641748,
-0.058640927,
0.043107104,
0.06682025,
0.062172387,
0.021147223,
-0.041068073
]
]
}
},
"is_streaming": false
}
}