Add a special header per-client call to parser provider data

This commit is contained in:
Ashwin Bharambe 2024-09-18 09:17:59 -07:00 committed by Xi Yan
parent 8e757ed274
commit 0b715c063a
2 changed files with 838 additions and 89 deletions

View file

@ -2364,7 +2364,7 @@ info:
description: "This is the specification of the llama stack that provides\n \
\ a set of endpoints and their corresponding interfaces that are tailored\
\ to\n best leverage Llama Models. The specification is still in\
\ draft and subject to change.\n Generated at 2024-09-20 17:50:36.257743"
\ draft and subject to change.\n Generated at 2024-09-20 13:32:23.841908"
title: '[DRAFT] Llama Stack Specification'
version: 0.0.1
jsonSchemaDialect: https://json-schema.org/draft/2020-12/schema
@ -2372,7 +2372,14 @@ openapi: 3.1.0
paths:
/agents/create:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -2390,7 +2397,14 @@ paths:
- Agents
/agents/delete:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -2404,7 +2418,14 @@ paths:
- Agents
/agents/session/create:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -2422,7 +2443,14 @@ paths:
- Agents
/agents/session/delete:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -2447,6 +2475,13 @@ paths:
required: true
schema:
type: string
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -2480,6 +2515,13 @@ paths:
required: true
schema:
type: string
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
responses:
'200':
content:
@ -2491,7 +2533,14 @@ paths:
- Agents
/agents/turn/create:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -2520,6 +2569,13 @@ paths:
required: true
schema:
type: string
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
responses:
'200':
content:
@ -2531,7 +2587,14 @@ paths:
- Agents
/batch_inference/chat_completion:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -2549,7 +2612,14 @@ paths:
- BatchInference
/batch_inference/completion:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -2567,7 +2637,14 @@ paths:
- BatchInference
/datasets/create:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -2581,7 +2658,14 @@ paths:
- Datasets
/datasets/delete:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -2601,6 +2685,13 @@ paths:
required: true
schema:
type: string
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
responses:
'200':
content:
@ -2618,6 +2709,13 @@ paths:
required: true
schema:
type: string
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
responses:
'200':
content:
@ -2629,7 +2727,14 @@ paths:
- Evaluations
/evaluate/job/cancel:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -2649,6 +2754,13 @@ paths:
required: true
schema:
type: string
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
responses:
'200':
content:
@ -2666,6 +2778,13 @@ paths:
required: true
schema:
type: string
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
responses:
'200':
content:
@ -2677,7 +2796,14 @@ paths:
- Evaluations
/evaluate/jobs:
get:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
responses:
'200':
content:
@ -2689,7 +2815,14 @@ paths:
- Evaluations
/evaluate/question_answering/:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -2707,7 +2840,14 @@ paths:
- Evaluations
/evaluate/summarization/:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -2725,7 +2865,14 @@ paths:
- Evaluations
/evaluate/text_generation/:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -2743,7 +2890,14 @@ paths:
- Evaluations
/inference/chat_completion:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -2763,7 +2917,14 @@ paths:
- Inference
/inference/completion:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -2783,7 +2944,14 @@ paths:
- Inference
/inference/embeddings:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -2801,7 +2969,14 @@ paths:
- Inference
/memory_bank/documents/delete:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -2821,6 +2996,13 @@ paths:
required: true
schema:
type: string
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -2838,7 +3020,14 @@ paths:
- Memory
/memory_bank/insert:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -2852,7 +3041,14 @@ paths:
- Memory
/memory_bank/query:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -2870,7 +3066,14 @@ paths:
- Memory
/memory_bank/update:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -2884,7 +3087,14 @@ paths:
- Memory
/memory_banks/create:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -2902,7 +3112,14 @@ paths:
- Memory
/memory_banks/drop:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -2926,6 +3143,13 @@ paths:
required: true
schema:
type: string
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
responses:
'200':
content:
@ -2939,7 +3163,14 @@ paths:
- Memory
/memory_banks/list:
get:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
responses:
'200':
content:
@ -2957,6 +3188,13 @@ paths:
required: true
schema:
type: string
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
responses:
'200':
content:
@ -2968,7 +3206,14 @@ paths:
- PostTraining
/post_training/job/cancel:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -2988,6 +3233,13 @@ paths:
required: true
schema:
type: string
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
responses:
'200':
content:
@ -3005,6 +3257,13 @@ paths:
required: true
schema:
type: string
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
responses:
'200':
content:
@ -3016,7 +3275,14 @@ paths:
- PostTraining
/post_training/jobs:
get:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
responses:
'200':
content:
@ -3028,7 +3294,14 @@ paths:
- PostTraining
/post_training/preference_optimize:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -3046,7 +3319,14 @@ paths:
- PostTraining
/post_training/supervised_fine_tune:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -3064,7 +3344,14 @@ paths:
- PostTraining
/reward_scoring/score:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -3082,7 +3369,14 @@ paths:
- RewardScoring
/safety/run_shields:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -3100,7 +3394,14 @@ paths:
- Safety
/synthetic_data_generation/generate:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -3124,6 +3425,13 @@ paths:
required: true
schema:
type: string
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
responses:
'200':
content:
@ -3135,7 +3443,14 @@ paths:
- Telemetry
/telemetry/log_event:
post:
parameters: []
parameters:
- description: JSON-encoded provider data which will be made available to the
adapter servicing the API
in: header
name: X-LlamaStack-ProviderData
required: false
schema:
type: string
requestBody:
content:
application/json:
@ -3152,17 +3467,17 @@ security:
servers:
- url: http://any-hosted-llama-stack.com
tags:
- name: Safety
- name: Inference
- name: Evaluations
- name: PostTraining
- name: BatchInference
- name: Memory
- name: Datasets
- name: PostTraining
- name: Inference
- name: Safety
- name: RewardScoring
- name: Agents
- name: Telemetry
- name: Evaluations
- name: SyntheticDataGeneration
- name: Memory
- name: Agents
- name: Datasets
- description: <SchemaDefinition schemaRef="#/components/schemas/BuiltinTool" />
name: BuiltinTool
- description: <SchemaDefinition schemaRef="#/components/schemas/CompletionMessage"