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 0b715c063a
commit 9380661ebd
2 changed files with 359 additions and 0 deletions

View file

@ -21,7 +21,11 @@
"info": { "info": {
"title": "[DRAFT] Llama Stack Specification", "title": "[DRAFT] Llama Stack Specification",
"version": "0.0.1", "version": "0.0.1",
<<<<<<< HEAD
"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-18 19:27:39.955190" "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-18 19:27:39.955190"
=======
"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 13:32:23.841908"
>>>>>>> 446914e (Add a special header per-client call to parser provider data)
}, },
"servers": [ "servers": [
{ {
@ -2584,7 +2588,187 @@
"$ref": "#/components/schemas/FunctionCallToolDefinition" "$ref": "#/components/schemas/FunctionCallToolDefinition"
}, },
{ {
<<<<<<< HEAD
"$ref": "#/components/schemas/MemoryToolDefinition" "$ref": "#/components/schemas/MemoryToolDefinition"
=======
"type": "object",
"properties": {
"input_shields": {
"type": "array",
"items": {
"$ref": "#/components/schemas/ShieldDefinition"
}
},
"output_shields": {
"type": "array",
"items": {
"$ref": "#/components/schemas/ShieldDefinition"
}
},
"type": {
"type": "string",
"const": "memory"
},
"memory_bank_configs": {
"type": "array",
"items": {
"oneOf": [
{
"type": "object",
"properties": {
"bank_id": {
"type": "string"
},
"type": {
"type": "string",
"const": "vector"
}
},
"additionalProperties": false,
"required": [
"bank_id",
"type"
]
},
{
"type": "object",
"properties": {
"bank_id": {
"type": "string"
},
"type": {
"type": "string",
"const": "keyvalue"
},
"keys": {
"type": "array",
"items": {
"type": "string"
}
}
},
"additionalProperties": false,
"required": [
"bank_id",
"type",
"keys"
]
},
{
"type": "object",
"properties": {
"bank_id": {
"type": "string"
},
"type": {
"type": "string",
"const": "keyword"
}
},
"additionalProperties": false,
"required": [
"bank_id",
"type"
]
},
{
"type": "object",
"properties": {
"bank_id": {
"type": "string"
},
"type": {
"type": "string",
"const": "graph"
},
"entities": {
"type": "array",
"items": {
"type": "string"
}
}
},
"additionalProperties": false,
"required": [
"bank_id",
"type",
"entities"
]
}
]
}
},
"query_generator_config": {
"oneOf": [
{
"type": "object",
"properties": {
"type": {
"type": "string",
"const": "default"
},
"sep": {
"type": "string"
}
},
"additionalProperties": false,
"required": [
"type",
"sep"
]
},
{
"type": "object",
"properties": {
"type": {
"type": "string",
"const": "llm"
},
"model": {
"type": "string"
},
"template": {
"type": "string"
}
},
"additionalProperties": false,
"required": [
"type",
"model",
"template"
]
},
{
"type": "object",
"properties": {
"type": {
"type": "string",
"const": "custom"
}
},
"additionalProperties": false,
"required": [
"type"
]
}
]
},
"max_tokens_in_context": {
"type": "integer"
},
"max_chunks": {
"type": "integer"
}
},
"additionalProperties": false,
"required": [
"type",
"memory_bank_configs",
"query_generator_config",
"max_tokens_in_context",
"max_chunks"
]
>>>>>>> 446914e (Add a special header per-client call to parser provider data)
} }
] ]
} }
@ -2693,6 +2877,7 @@
"parameters" "parameters"
] ]
}, },
<<<<<<< HEAD
"MemoryToolDefinition": { "MemoryToolDefinition": {
"type": "object", "type": "object",
"properties": { "properties": {
@ -2872,6 +3057,8 @@
"max_chunks" "max_chunks"
] ]
}, },
=======
>>>>>>> 446914e (Add a special header per-client call to parser provider data)
"OnViolationAction": { "OnViolationAction": {
"type": "integer", "type": "integer",
"enum": [ "enum": [
@ -5589,7 +5776,14 @@
], ],
"tags": [ "tags": [
{ {
<<<<<<< HEAD
"name": "Safety" "name": "Safety"
=======
"name": "BatchInference"
},
{
"name": "PostTraining"
>>>>>>> 446914e (Add a special header per-client call to parser provider data)
}, },
{ {
"name": "Memory" "name": "Memory"
@ -5598,6 +5792,7 @@
"name": "Evaluations" "name": "Evaluations"
}, },
{ {
<<<<<<< HEAD
"name": "RewardScoring" "name": "RewardScoring"
}, },
{ {
@ -5605,18 +5800,35 @@
}, },
{ {
"name": "Evaluations" "name": "Evaluations"
=======
"name": "Datasets"
>>>>>>> 446914e (Add a special header per-client call to parser provider data)
}, },
{ {
"name": "SyntheticDataGeneration" "name": "SyntheticDataGeneration"
}, },
{ {
<<<<<<< HEAD
"name": "Memory" "name": "Memory"
=======
"name": "RewardScoring"
},
{
"name": "Agents"
},
{
"name": "Safety"
>>>>>>> 446914e (Add a special header per-client call to parser provider data)
}, },
{ {
"name": "Inference" "name": "Inference"
}, },
{ {
<<<<<<< HEAD
"name": "Datasets" "name": "Datasets"
=======
"name": "Telemetry"
>>>>>>> 446914e (Add a special header per-client call to parser provider data)
}, },
{ {
"name": "BuiltinTool", "name": "BuiltinTool",
@ -5755,10 +5967,13 @@
"description": "<SchemaDefinition schemaRef=\"#/components/schemas/FunctionCallToolDefinition\" />" "description": "<SchemaDefinition schemaRef=\"#/components/schemas/FunctionCallToolDefinition\" />"
}, },
{ {
<<<<<<< HEAD
"name": "MemoryToolDefinition", "name": "MemoryToolDefinition",
"description": "<SchemaDefinition schemaRef=\"#/components/schemas/MemoryToolDefinition\" />" "description": "<SchemaDefinition schemaRef=\"#/components/schemas/MemoryToolDefinition\" />"
}, },
{ {
=======
>>>>>>> 446914e (Add a special header per-client call to parser provider data)
"name": "OnViolationAction", "name": "OnViolationAction",
"description": "<SchemaDefinition schemaRef=\"#/components/schemas/OnViolationAction\" />" "description": "<SchemaDefinition schemaRef=\"#/components/schemas/OnViolationAction\" />"
}, },
@ -6204,7 +6419,10 @@
"MemoryBank", "MemoryBank",
"MemoryBankDocument", "MemoryBankDocument",
"MemoryRetrievalStep", "MemoryRetrievalStep",
<<<<<<< HEAD
"MemoryToolDefinition", "MemoryToolDefinition",
=======
>>>>>>> 446914e (Add a special header per-client call to parser provider data)
"MetricEvent", "MetricEvent",
"OnViolationAction", "OnViolationAction",
"OptimizerConfig", "OptimizerConfig",

View file

@ -30,7 +30,127 @@ components:
- $ref: '#/components/schemas/PhotogenToolDefinition' - $ref: '#/components/schemas/PhotogenToolDefinition'
- $ref: '#/components/schemas/CodeInterpreterToolDefinition' - $ref: '#/components/schemas/CodeInterpreterToolDefinition'
- $ref: '#/components/schemas/FunctionCallToolDefinition' - $ref: '#/components/schemas/FunctionCallToolDefinition'
<<<<<<< HEAD
- $ref: '#/components/schemas/MemoryToolDefinition' - $ref: '#/components/schemas/MemoryToolDefinition'
=======
- additionalProperties: false
properties:
input_shields:
items:
$ref: '#/components/schemas/ShieldDefinition'
type: array
max_chunks:
type: integer
max_tokens_in_context:
type: integer
memory_bank_configs:
items:
oneOf:
- additionalProperties: false
properties:
bank_id:
type: string
type:
const: vector
type: string
required:
- bank_id
- type
type: object
- additionalProperties: false
properties:
bank_id:
type: string
keys:
items:
type: string
type: array
type:
const: keyvalue
type: string
required:
- bank_id
- type
- keys
type: object
- additionalProperties: false
properties:
bank_id:
type: string
type:
const: keyword
type: string
required:
- bank_id
- type
type: object
- additionalProperties: false
properties:
bank_id:
type: string
entities:
items:
type: string
type: array
type:
const: graph
type: string
required:
- bank_id
- type
- entities
type: object
type: array
output_shields:
items:
$ref: '#/components/schemas/ShieldDefinition'
type: array
query_generator_config:
oneOf:
- additionalProperties: false
properties:
sep:
type: string
type:
const: default
type: string
required:
- type
- sep
type: object
- additionalProperties: false
properties:
model:
type: string
template:
type: string
type:
const: llm
type: string
required:
- type
- model
- template
type: object
- additionalProperties: false
properties:
type:
const: custom
type: string
required:
- type
type: object
type:
const: memory
type: string
required:
- type
- memory_bank_configs
- query_generator_config
- max_tokens_in_context
- max_chunks
type: object
>>>>>>> 446914e (Add a special header per-client call to parser provider data)
type: array type: array
required: required:
- model - model
@ -1074,6 +1194,7 @@ components:
- memory_bank_ids - memory_bank_ids
- inserted_context - inserted_context
type: object type: object
<<<<<<< HEAD
MemoryToolDefinition: MemoryToolDefinition:
additionalProperties: false additionalProperties: false
properties: properties:
@ -1192,6 +1313,8 @@ components:
- max_tokens_in_context - max_tokens_in_context
- max_chunks - max_chunks
type: object type: object
=======
>>>>>>> 446914e (Add a special header per-client call to parser provider data)
MetricEvent: MetricEvent:
additionalProperties: false additionalProperties: false
properties: properties:
@ -3469,6 +3592,7 @@ servers:
tags: tags:
- name: BatchInference - name: BatchInference
- name: PostTraining - name: PostTraining
<<<<<<< HEAD
- name: Inference - name: Inference
- name: Safety - name: Safety
- name: RewardScoring - name: RewardScoring
@ -3478,6 +3602,17 @@ tags:
- name: Memory - name: Memory
- name: Agents - name: Agents
- name: Datasets - name: Datasets
=======
- name: Memory
- name: Evaluations
- name: Datasets
- name: SyntheticDataGeneration
- name: RewardScoring
- name: Agents
- name: Safety
- name: Inference
- name: Telemetry
>>>>>>> 446914e (Add a special header per-client call to parser provider data)
- description: <SchemaDefinition schemaRef="#/components/schemas/BuiltinTool" /> - description: <SchemaDefinition schemaRef="#/components/schemas/BuiltinTool" />
name: BuiltinTool name: BuiltinTool
- description: <SchemaDefinition schemaRef="#/components/schemas/CompletionMessage" - description: <SchemaDefinition schemaRef="#/components/schemas/CompletionMessage"
@ -3589,9 +3724,12 @@ tags:
- description: <SchemaDefinition schemaRef="#/components/schemas/FunctionCallToolDefinition" - description: <SchemaDefinition schemaRef="#/components/schemas/FunctionCallToolDefinition"
/> />
name: FunctionCallToolDefinition name: FunctionCallToolDefinition
<<<<<<< HEAD
- description: <SchemaDefinition schemaRef="#/components/schemas/MemoryToolDefinition" - description: <SchemaDefinition schemaRef="#/components/schemas/MemoryToolDefinition"
/> />
name: MemoryToolDefinition name: MemoryToolDefinition
=======
>>>>>>> 446914e (Add a special header per-client call to parser provider data)
- description: <SchemaDefinition schemaRef="#/components/schemas/OnViolationAction" - description: <SchemaDefinition schemaRef="#/components/schemas/OnViolationAction"
/> />
name: OnViolationAction name: OnViolationAction
@ -3954,7 +4092,10 @@ x-tagGroups:
- MemoryBank - MemoryBank
- MemoryBankDocument - MemoryBankDocument
- MemoryRetrievalStep - MemoryRetrievalStep
<<<<<<< HEAD
- MemoryToolDefinition - MemoryToolDefinition
=======
>>>>>>> 446914e (Add a special header per-client call to parser provider data)
- MetricEvent - MetricEvent
- OnViolationAction - OnViolationAction
- OptimizerConfig - OptimizerConfig