Skip to content

Instantly share code, notes, and snippets.

@qtangs
Created May 19, 2023 08:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save qtangs/cc78f777424d00e2b4ee0e93b86a1240 to your computer and use it in GitHub Desktop.
Save qtangs/cc78f777424d00e2b4ee0e93b86a1240 to your computer and use it in GitHub Desktop.
{
"$schema": "http://json-schema.org/draft-06/schema#",
"$ref": "#/definitions/Flow",
"definitions": {
"Flow": {
"type": "object",
"additionalProperties": false,
"properties": {
"type": {
"type": "string"
},
"id": {
"type": "string"
},
"name": {
"type": "string"
},
"flow_type": {
"type": "string"
},
"input": {
"type": "array",
"items": {
"$ref": "#/definitions/InputElement"
}
},
"tasks": {
"type": "array",
"items": {
"$ref": "#/definitions/Task"
}
},
"output": {
"type": "array",
"items": {
"$ref": "#/definitions/Output"
}
}
},
"required": [
"flow_type",
"id",
"input",
"name",
"output",
"tasks",
"type"
],
"title": "Welcome3"
},
"InputElement": {
"type": "object",
"additionalProperties": false,
"properties": {
"name": {
"type": "string"
},
"description": {
"type": "string"
},
"type": {
"type": "string"
},
"required": {
"type": "boolean"
}
},
"required": [
"description",
"name",
"required",
"type"
],
"title": "InputElement"
},
"Output": {
"type": "object",
"additionalProperties": false,
"properties": {
"name": {
"type": "string"
},
"value": {
"type": "string"
}
},
"required": [
"name",
"value"
],
"title": "Output"
},
"Task": {
"type": "object",
"additionalProperties": false,
"properties": {
"name": {
"type": "string"
},
"description": {
"type": "string"
},
"type": {
"type": "string"
},
"input": {
"$ref": "#/definitions/TaskInput"
},
"taskConfig": {
"$ref": "#/definitions/TaskConfig"
}
},
"required": [
"description",
"input",
"name",
"taskConfig",
"type"
],
"title": "Task"
},
"TaskInput": {
"type": "object",
"additionalProperties": false,
"properties": {
"mode": {
"type": "string"
},
"query": {
"type": "string"
},
"path": {
"type": "string"
},
"collection_name": {
"type": "string"
},
"embedding": {
"type": "string"
},
"messages": {
"type": "array",
"items": {
"$ref": "#/definitions/Message"
}
},
"temperature": {
"type": "integer"
},
"max_tokens": {
"type": "integer"
}
},
"required": [],
"title": "TaskInput"
},
"Message": {
"type": "object",
"additionalProperties": false,
"properties": {
"type": {
"type": "string"
},
"content": {
"type": "string"
}
},
"required": [
"content",
"type"
],
"title": "Message"
},
"TaskConfig": {
"type": "object",
"additionalProperties": false,
"properties": {
"retries": {
"type": "integer"
},
"timeout_seconds": {
"type": "integer"
},
"persist_result": {
"type": "boolean"
},
"cache_result": {
"type": "boolean"
},
"cache_expiration": {
"type": "string"
}
},
"required": [
"cache_expiration",
"cache_result",
"persist_result",
"retries",
"timeout_seconds"
],
"title": "TaskConfig"
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment