llama-stack-mirror/tests/integration/recordings/responses/80311f244b55.json
Ashwin Bharambe ef0736527d
feat(tools)!: substantial clean up of "Tool" related datatypes (#3627)
This is a sweeping change to clean up some gunk around our "Tool"
definitions.

First, we had two types `Tool` and `ToolDef`. The first of these was a
"Resource" type for the registry but we had stopped registering tools
inside the Registry long back (and only registered ToolGroups.) The
latter was for specifying tools for the Agents API. This PR removes the
former and adds an optional `toolgroup_id` field to the latter.

Secondly, as pointed out by @bbrowning in
https://github.com/llamastack/llama-stack/pull/3003#issuecomment-3245270132,
we were doing a lossy conversion from a full JSON schema from the MCP
tool specification into our ToolDefinition to send it to the model.
There is no necessity to do this -- we ourselves aren't doing any
execution at all but merely passing it to the chat completions API which
supports this. By doing this (and by doing it poorly), we encountered
limitations like not supporting array items, or not resolving $refs,
etc.

To fix this, we replaced the `parameters` field by `{ input_schema,
output_schema }` which can be full blown JSON schemas.

Finally, there were some types in our llama-related chat format
conversion which needed some cleanup. We are taking this opportunity to
clean those up.

This PR is a substantial breaking change to the API. However, given our
window for introducing breaking changes, this suits us just fine. I will
be landing a concurrent `llama-stack-client` change as well since API
shapes are changing.
2025-10-02 15:12:03 -07:00

1204 lines
32 KiB
JSON

{
"request": {
"method": "POST",
"url": "http://0.0.0.0:11434/v1/v1/embeddings",
"headers": {},
"body": {
"model": "all-minilm:l6-v2",
"input": [
"Hello, world!",
"How are you today?",
"This is a test."
],
"encoding_format": "float"
},
"endpoint": "/v1/embeddings",
"model": "all-minilm:l6-v2"
},
"response": {
"body": {
"__type__": "openai.types.create_embedding_response.CreateEmbeddingResponse",
"__data__": {
"data": [
{
"embedding": [
-0.038168654,
0.032873917,
-0.0055947267,
0.014366432,
-0.040310103,
-0.116643615,
0.031721067,
0.0019260457,
-0.04255802,
0.029198613,
0.04252229,
0.032184314,
0.029838374,
0.010959321,
-0.053805783,
-0.05028783,
-0.023449864,
0.0107550435,
-0.13774979,
0.0039929547,
0.029302042,
0.066712305,
-0.015410682,
0.048422653,
-0.08814465,
-0.012715775,
0.041334823,
0.040851083,
-0.050064698,
-0.05804616,
0.048728727,
0.06888658,
0.058795262,
0.008804153,
-0.016073612,
0.08514259,
-0.078146815,
-0.07741974,
0.020842256,
0.016201088,
0.032518543,
-0.05346469,
-0.062197812,
-0.024271712,
0.007416788,
0.024103774,
0.006469804,
0.051166162,
0.07284196,
0.034627657,
-0.05475476,
-0.059386417,
-0.0071934434,
0.020163197,
0.035816014,
0.0055927313,
0.010762318,
-0.05274177,
0.010083032,
-0.008742163,
-0.06284565,
0.038426206,
-0.013933317,
0.07342759,
0.09004579,
-0.07995627,
-0.016420787,
0.044767782,
-0.06886435,
-0.03303916,
-0.015482072,
0.011322529,
0.036461752,
0.066346884,
-0.05434455,
0.008740993,
0.012066104,
-0.038101126,
0.0069316486,
0.051146947,
0.07740579,
-0.122950904,
0.016380342,
0.049568996,
0.031634904,
-0.039637603,
0.0016715266,
0.009577405,
-0.032646418,
-0.033988595,
-0.13329837,
0.0072566303,
-0.010266605,
0.038557075,
-0.09338859,
-0.041706774,
0.069941126,
-0.026323376,
-0.14971305,
0.13445398,
0.03748492,
0.052825302,
0.0450506,
0.018712776,
0.05444322,
0.017282845,
-0.032480195,
0.04614526,
-0.046711974,
-0.030566413,
-0.01820007,
-0.04869831,
0.033051647,
-0.0038142777,
0.04999665,
-0.058270358,
-0.010011706,
0.010643473,
-0.040113144,
-0.0015507729,
0.060854245,
-0.045562096,
0.049257778,
0.02612153,
0.01981428,
-0.001660993,
0.059509434,
-6.525298e-33,
0.063519135,
0.0030875143,
0.028961418,
0.1733713,
0.0029763067,
0.027727291,
-0.0951315,
-0.031186627,
0.026689058,
-0.010807322,
0.023850724,
0.023777472,
-0.031174092,
0.049501278,
-0.025049716,
0.10175924,
-0.07919064,
-0.0032249284,
0.042915843,
0.09483459,
-0.06652636,
0.006303593,
0.02220902,
0.06999181,
-0.0074810013,
-0.0017734945,
0.027008688,
-0.07534615,
0.114036545,
0.008552313,
-0.023737878,
-0.04694563,
0.014472103,
0.019855395,
-0.0046694353,
0.0013555645,
-0.034298304,
-0.054142635,
-0.09419824,
-0.028909719,
-0.018876282,
0.0457315,
0.04761082,
-0.0030971593,
-0.033264168,
-0.013539523,
0.051041685,
0.031110944,
0.015244497,
0.054158635,
-0.08499706,
0.013360703,
-0.04759633,
0.07101136,
-0.0131114535,
-0.0023818254,
0.050331973,
-0.041642286,
-0.01419894,
0.032463223,
0.0053973934,
0.091275506,
0.0044798073,
-0.018260129,
-0.015278888,
-0.046306957,
0.038750377,
0.014729783,
0.05204642,
0.0017938613,
-0.014963651,
0.027101943,
0.031203475,
0.023725478,
-0.004601222,
0.03617344,
0.06679477,
-0.0018401983,
0.021265576,
-0.057589985,
0.019155758,
0.031437635,
-0.018444614,
-0.04085069,
0.10393101,
0.011960795,
-0.014898805,
-0.10520497,
-0.012302656,
-0.00043837292,
-0.09508398,
0.058318105,
0.042576887,
-0.025066672,
-0.094555676,
4.0072287e-33,
0.1322281,
0.0053512393,
-0.03312536,
-0.09096454,
-0.031562407,
-0.033949774,
-0.07205118,
0.1259232,
-0.08333555,
0.052797858,
0.001077506,
0.022004265,
0.10402767,
0.013034249,
0.04091762,
0.018705815,
0.11424037,
0.024799824,
0.014582492,
0.006205516,
-0.011202356,
-0.035756435,
-0.03800272,
0.011251353,
-0.0512988,
0.007890417,
0.06736164,
0.0033359542,
-0.09285096,
0.03704081,
-0.022326592,
0.039967872,
-0.030748183,
-0.011446819,
-0.014453254,
0.02498229,
-0.097532175,
-0.035378877,
-0.03757795,
-0.010181498,
-0.06392041,
0.025538994,
0.02061816,
0.03757256,
-0.1043548,
-0.028326731,
-0.05209465,
0.0128473425,
-0.051238894,
-0.029034877,
-0.09633617,
-0.042309195,
0.067165054,
-0.030870603,
-0.010357507,
0.027381465,
-0.028105576,
0.010302046,
0.04306986,
0.022315372,
0.007954779,
0.056068663,
0.04071972,
0.09293905,
0.016536433,
-0.053764775,
0.00047211433,
0.050708972,
0.042510226,
-0.029195962,
0.009274875,
-0.010647389,
-0.037209682,
0.002267011,
-0.030304702,
0.0745741,
0.0026207205,
-0.017582772,
0.0028797672,
0.038404796,
0.00723137,
0.045613218,
0.03998252,
0.014209623,
-0.0142997475,
0.05850862,
0.03630791,
0.055294298,
-0.020075988,
-0.08041808,
-0.030250112,
-0.014920701,
0.022349516,
0.011911506,
-0.06903851,
-1.8806734e-08,
-0.078480355,
0.046674173,
-0.023920896,
0.0634942,
0.02396477,
0.0014517035,
-0.090798445,
-0.06684978,
-0.0801405,
0.005503192,
0.053675175,
0.104841895,
-0.066848256,
0.015522683,
0.067097165,
0.070832625,
-0.03197915,
0.020843629,
-0.0219202,
-0.0073016756,
-0.010645817,
0.0040983153,
0.03313765,
-0.0790081,
0.03878132,
-0.075230986,
-0.015732396,
0.0060099233,
0.0051297406,
-0.061492138,
0.04202211,
0.09544608,
-0.04318599,
0.014424486,
-0.10617826,
-0.027963417,
0.011034413,
0.069576606,
0.06689785,
-0.07479674,
-0.07851099,
0.042766396,
-0.034639932,
-0.10607304,
-0.03577663,
0.051540814,
0.068673156,
-0.049959548,
0.015460458,
-0.064520314,
-0.076010585,
0.026035817,
0.07440218,
-0.012396022,
0.13329679,
0.074770845,
0.05134284,
0.020977058,
-0.026776016,
0.08894323,
0.039937407,
-0.04102053,
0.03194075,
0.018113315
],
"index": 0,
"object": "embedding"
},
{
"embedding": [
-0.009833591,
0.0668779,
0.08488449,
0.038122248,
0.032220595,
-0.03433386,
0.10730999,
-0.046878964,
-0.10266935,
-0.00370671,
-0.0023427065,
0.0121665625,
-0.046939347,
0.08200702,
0.042902183,
-0.0269985,
0.0070130927,
-0.10432514,
-0.12179822,
0.07268025,
-0.07978419,
-0.0036544742,
-0.004423966,
0.06783815,
-0.020906046,
0.05779926,
-0.008492945,
-0.013392021,
0.0052612307,
-0.09833074,
-0.13072163,
0.0089445235,
-0.05787279,
-0.05804388,
-0.056277692,
-0.04266197,
0.00011274022,
-0.14460878,
0.007978511,
0.022490304,
0.048143692,
-0.039113734,
-0.012775274,
0.00774044,
0.057925634,
-0.0277638,
-0.019801306,
0.09388109,
0.14315501,
-0.023440128,
-0.10622172,
0.026852824,
-0.05544247,
0.017898263,
0.021249173,
0.041583873,
0.0032883594,
0.01606716,
0.08307148,
-0.014618173,
0.027187122,
0.014263773,
-0.006215441,
0.060580455,
0.038631216,
0.00601958,
-0.10086374,
-0.052872147,
-0.07970713,
0.016736085,
-0.054666266,
-0.07301758,
0.045461986,
-0.009579665,
-0.010393855,
-0.06414482,
0.0011229888,
-0.03685241,
0.06301278,
-0.0016175678,
0.057848454,
-0.02605763,
-0.0005511475,
0.021425176,
-0.05001372,
-0.011338819,
-0.008776912,
0.093425095,
0.010633341,
-0.00062553474,
-0.056090016,
0.043499533,
0.0037617732,
0.028000852,
0.020929853,
-0.03870579,
0.019406682,
0.023135182,
-0.050996922,
0.13818857,
0.022762392,
0.13101754,
0.042277776,
0.012446188,
0.02232269,
0.01416872,
-0.09036148,
0.07457381,
-0.062656924,
-0.08921229,
0.005476475,
0.03847988,
-0.036277156,
-0.009225353,
0.091821924,
-0.012585263,
0.026147954,
0.08752217,
-0.010917677,
0.09249038,
0.020964727,
0.052522942,
0.02889203,
0.03941557,
-0.010532948,
0.077333786,
0.071537115,
-7.666136e-33,
0.1007941,
0.0006832776,
0.057265434,
0.11700236,
-0.060210142,
-0.027968848,
-0.041750107,
-0.018907221,
0.050820086,
-0.06298854,
0.03686846,
-0.04519097,
-0.005230235,
0.0064626867,
-0.032001205,
0.029013716,
-0.09601744,
0.057358947,
0.008101205,
0.12529038,
-0.021971641,
-0.04753891,
-0.043775026,
0.022004716,
0.051121656,
-0.014482441,
-0.021044016,
-0.06673008,
-0.026052782,
-0.008716248,
-0.03660495,
-0.008708152,
0.115699895,
-0.0028488566,
0.025259791,
-0.0076865884,
-0.00857807,
-0.003692314,
-0.0425788,
-0.03768598,
0.03309143,
-0.024962988,
0.05863119,
-0.061788555,
-0.04672501,
-0.02788036,
-0.03501338,
0.05530872,
-0.0020685238,
-0.022395074,
-0.10156128,
0.029757096,
-0.06324917,
-0.0055847103,
-0.04842867,
-0.0406527,
-0.07527831,
0.03743154,
0.016060246,
0.084336765,
0.012059259,
0.05541269,
0.009253656,
-0.07830337,
-0.10507807,
-0.023997093,
-0.017076802,
-0.018283347,
0.04169534,
-0.006048637,
0.012450259,
-0.03500919,
0.024494508,
0.06315759,
0.06566752,
0.052477088,
0.038372934,
-0.07515921,
-0.012239953,
-0.006440479,
0.049801994,
0.057076473,
-0.0019500607,
-0.04908919,
0.05485639,
0.052818075,
0.007574656,
-0.009921382,
0.0022724136,
0.022785993,
-0.06867227,
0.060549237,
0.070556775,
-0.041930214,
-0.02491663,
5.211892e-33,
0.09750541,
0.015079458,
-0.095042065,
0.0515883,
-0.0994903,
-0.046793085,
-0.04579176,
0.04599562,
-0.021065598,
0.04897981,
0.085892305,
0.031818043,
0.010482406,
-0.011647838,
0.023812337,
-0.0036415062,
0.053783026,
0.005232672,
-0.02077592,
0.011894891,
-0.097780555,
0.060238954,
-0.027633231,
0.06742237,
2.5952173e-05,
0.06254275,
0.024719816,
0.053590305,
-0.037180737,
-0.015468933,
-0.015324857,
-0.021314861,
-0.039786287,
0.049943436,
0.019945512,
0.05842415,
0.0017712337,
-0.07452784,
-0.015759895,
-0.10015912,
-0.104994535,
0.03002228,
0.0038714884,
0.06567684,
0.05313137,
0.009852781,
-0.023740485,
-0.025747454,
-0.009146766,
0.06444407,
0.008365104,
-0.032752022,
-0.0017309446,
0.017398946,
0.027344245,
-0.0039835107,
-0.07793314,
-0.06111028,
-0.018392045,
0.019161185,
-0.10229173,
0.004820445,
-0.03923746,
-0.009809605,
0.02428856,
-0.02256144,
-0.016944531,
-0.03403803,
-0.05211972,
-0.031824537,
-0.034718003,
0.008275027,
0.0013583767,
-0.06358826,
-0.028270705,
0.050367188,
0.023883171,
0.0058828085,
-0.011626739,
-0.00044805612,
-0.071661964,
0.041463517,
0.054404654,
-0.10819901,
-0.08137075,
-0.06927182,
0.08611682,
-0.0035160778,
0.030999359,
0.08360334,
-0.028444909,
0.008868503,
-0.027930394,
0.04986546,
0.011590262,
-1.5343216e-08,
0.054317594,
0.045336407,
-0.07639679,
0.052074224,
-0.012374757,
0.060316578,
-0.0041594645,
-0.017367603,
-0.014107863,
-0.017071113,
0.075814135,
0.0079101855,
-0.0653045,
-0.047504168,
0.038116574,
-0.050272573,
0.021948416,
0.0685364,
-0.037221905,
-0.04937101,
0.057309754,
0.008049557,
-0.042899966,
0.09778022,
0.058175605,
0.05289681,
0.024736015,
0.032797,
-0.0062358975,
0.08241506,
0.03714261,
0.10870123,
-0.05776473,
0.036651433,
-0.018998465,
-0.08551218,
0.05913097,
-0.04569603,
0.025227055,
0.022481369,
-0.007972968,
0.0031193425,
-0.047840066,
-0.01866631,
0.048634782,
-0.032800686,
0.05455027,
-0.03739758,
-0.07470992,
-0.019272048,
0.0060886056,
0.042403262,
0.067405015,
0.044566732,
0.033157814,
0.033654317,
0.0012653307,
0.0331767,
-0.04841697,
-0.005587956,
-0.008498534,
-0.016844513,
-0.075615294,
0.003522267
],
"index": 1,
"object": "embedding"
},
{
"embedding": [
0.033608936,
0.010398442,
-0.017553993,
0.029364064,
-0.009464617,
-0.037002508,
-0.025546908,
0.008652466,
0.019171866,
0.03954904,
-0.024698786,
-0.012698567,
-0.006575828,
0.043791965,
-0.035994604,
-0.05671484,
0.0056701135,
-0.048562843,
-0.019397723,
0.05104105,
0.063669115,
0.045695283,
-0.025647452,
0.020920323,
0.023776716,
-0.011002659,
-0.06972687,
0.008664046,
-0.010030623,
-0.004339591,
-0.013750908,
0.060781404,
0.054188438,
0.030624274,
0.032462284,
0.023917627,
0.09566426,
0.041960694,
0.00087254023,
0.04337981,
0.033683162,
-0.08997299,
0.021594081,
0.040572572,
-0.002699973,
0.03181515,
-0.04552366,
0.047550924,
-0.07038101,
-0.013632569,
-0.010259558,
-0.016508883,
-0.07213799,
-0.055489477,
0.03312745,
-0.0075917933,
0.050809033,
-0.04651997,
0.064730175,
0.080775,
-0.053802576,
-0.01303103,
-0.023942273,
0.07259772,
0.07427843,
0.050371367,
-0.034895457,
-0.10131592,
-0.01694396,
-0.054186717,
0.0054757623,
0.0064777075,
0.055816714,
0.04833513,
0.040297274,
0.005629578,
-0.024119677,
-0.10035926,
0.07866524,
0.047488276,
-0.08309364,
-0.056954693,
-0.007104401,
0.03495975,
0.013019207,
0.047803633,
0.0777118,
-0.00509941,
-0.08840243,
0.0034689775,
-0.023245867,
0.04557207,
-0.04230277,
-0.024225675,
0.017693503,
-0.024583058,
-0.032045294,
-0.009174721,
-0.06059988,
0.07893847,
-0.00714072,
-0.0018742199,
-0.024142431,
0.03558561,
-0.097880565,
-0.07468488,
0.036415916,
-0.06168905,
0.06755602,
0.0037724776,
-0.05098253,
-0.023584208,
0.043991886,
0.042738363,
0.020495268,
-0.0098619405,
-0.107808046,
0.041273866,
0.02920404,
0.04561137,
0.095207445,
-0.020896124,
0.00023096669,
-0.057968765,
0.022850417,
-0.043668177,
0.021688405,
-8.720441e-33,
-0.0012058292,
-0.03802704,
0.042444937,
0.08773871,
-0.004220456,
0.00012147395,
-0.06457608,
0.061607473,
-0.0035593824,
-0.0057741986,
-0.010743548,
-0.065433994,
0.002658555,
0.006107435,
0.07180735,
0.099667646,
-0.028398223,
0.08866949,
-0.06581663,
0.057735924,
-0.057161212,
0.036086526,
-0.02094693,
-0.091624826,
-0.07255717,
-0.07521124,
-0.0064620934,
0.010381977,
-0.0037112501,
0.020337056,
-0.0396202,
0.04863623,
-0.057977367,
0.045799762,
-0.0028102288,
-0.026413642,
0.011332779,
-0.008787543,
-0.01246847,
0.003016415,
-0.050528,
-0.043582138,
-0.024329135,
0.06542502,
0.050448198,
-0.031531323,
-0.0007779434,
-0.04532696,
0.058871463,
0.0012682271,
-0.019152224,
0.01258753,
0.03999562,
-0.022376174,
-0.030803563,
0.04760751,
0.036079545,
-0.0076535675,
-0.04203372,
0.097275354,
0.011409953,
0.027754916,
-0.0835048,
0.019380422,
-0.05416042,
0.014054438,
-0.04266347,
-0.007908375,
0.029723784,
0.0761083,
0.03139675,
-0.041797075,
0.0016033188,
0.038726415,
-0.059795942,
-0.07054141,
-0.05157118,
0.0684149,
-0.003766908,
-0.012878277,
0.035064787,
-0.11262972,
0.053968824,
-0.1140537,
-0.033282436,
-0.011386638,
-0.022939742,
-0.08745513,
0.0009942602,
-0.07038481,
-0.034342457,
0.028354177,
-0.003912724,
-0.0654399,
0.056719452,
4.401956e-33,
-0.06759265,
0.07454906,
-0.046297893,
0.11055107,
0.08249596,
-0.035986293,
0.11225011,
-0.010407374,
-0.09363792,
0.15916187,
0.0057810647,
0.041591797,
0.041856647,
-0.022185486,
0.018102126,
0.017321726,
0.031456053,
-0.076545484,
0.011582533,
-0.04284016,
-0.07789234,
0.12440625,
0.03617526,
0.09730373,
-0.06544067,
0.051156454,
0.030499168,
-0.06475215,
0.003401952,
-0.006514968,
0.002070544,
0.005759038,
-0.07172358,
0.0145481,
0.011155189,
-0.012380945,
0.098492086,
-0.053324275,
-0.05958665,
0.027893873,
0.01397341,
0.09733979,
0.14172351,
0.09822425,
-0.000753543,
0.036323734,
0.013357258,
-0.11347022,
0.01546052,
0.045483384,
-0.05844928,
-0.011548025,
0.026313214,
0.055244267,
-0.050127964,
0.014079803,
-0.04502139,
0.005556844,
0.017963082,
0.01945956,
-0.08633155,
0.08159404,
-0.012574804,
0.034080163,
-0.017839924,
-0.031354588,
-0.084478684,
0.073620565,
0.030523231,
0.014402138,
0.08548794,
-0.0014136349,
-0.117235936,
-0.071074195,
0.083228014,
-0.07779257,
-0.044802953,
-0.009106513,
0.0316612,
-0.03717584,
-0.05652208,
-0.07973565,
0.003353578,
0.03982252,
-0.05883056,
0.097288825,
-0.01612578,
0.0277682,
-0.06547234,
0.040883925,
0.009703006,
-0.012041616,
-0.008719466,
-0.05062296,
-0.024210127,
-1.8977037e-08,
-0.024204005,
-0.055027,
-0.014531686,
0.017793229,
-0.014444479,
0.06776621,
0.032021433,
-0.04271159,
-0.056421917,
0.008902811,
0.0965939,
0.069501095,
-0.09060633,
0.018546907,
0.06365827,
-0.0715206,
-0.0047898116,
-0.008457558,
-0.01603862,
0.083756834,
-0.081861764,
0.050247736,
0.020439949,
0.027903674,
-0.02344807,
0.074611686,
0.036804173,
0.08724397,
0.013292644,
0.02741063,
0.0673842,
0.039584856,
-0.044136506,
-0.051336076,
-0.013291427,
0.06607191,
0.043135997,
-0.036887288,
0.024783924,
0.040656343,
-0.11329909,
0.027977955,
0.0070782495,
0.039789386,
-0.027414937,
-0.055913515,
-0.085740864,
-0.025473714,
-0.021161858,
-0.05823863,
-0.025728453,
0.017994676,
0.04891479,
-0.03684745,
0.012969448,
-0.063004315,
-0.039539963,
-0.0036127788,
-0.069469534,
0.042392787,
0.11249585,
-0.0015041318,
0.087654695,
-0.041728426
],
"index": 2,
"object": "embedding"
}
],
"model": "all-minilm:l6-v2",
"object": "list",
"usage": {
"prompt_tokens": 14,
"total_tokens": 14
}
}
},
"is_streaming": false
}
}