Skip to content

Instantly share code, notes, and snippets.

@ruvnet
Last active December 1, 2023 21:42
Show Gist options
  • Save ruvnet/666f3cbe43ddf8a52c607f98a61f46ed to your computer and use it in GitHub Desktop.
Save ruvnet/666f3cbe43ddf8a52c607f98a61f46ed to your computer and use it in GitHub Desktop.
AlignAPI x ruv Openapi.json
{
"openapi": "3.0.2",
"info": {
"title": "OpenAi API GPT",
"description": "API endpoints for OpenAi API GPT application",
"version": "0.0.1"
},
"paths": {
"/proxy_openai_api/completions/": {
"post": {
"tags": ["Chat"],
"summary": "Proxy Openai Api Completions",
"operationId": "proxy_openai_api_completions_proxy_openai_api_completions__post",
"requestBody": {
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/CompletionRequest"
}
}
},
"required": true
},
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/json": {
"schema": {}
}
}
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/HTTPValidationError"
}
}
}
}
}
}
},
"/align": {
"get": {
"summary": "Test Text Alignment",
"operationId": "test_text_alignment_align_get",
"parameters": [
{
"required": true,
"schema": {
"title": "Test Text",
"type": "string"
},
"name": "test_text",
"in": "query"
}
],
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/AlignAPIResponse"
}
}
}
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/HTTPValidationError"
}
}
}
}
}
}
},
"/conditional_completion/": {
"post": {
"tags": ["Conditional Completion"],
"summary": "Conditional Completion",
"operationId": "conditional_completion_conditional_completion__post",
"parameters": [
{
"required": false,
"schema": {
"title": "Threshold",
"type": "integer",
"default": 1
},
"name": "threshold",
"in": "query"
}
],
"requestBody": {
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/CompletionRequest"
}
}
},
"required": true
},
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/json": {
"schema": {}
}
}
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/HTTPValidationError"
}
}
}
}
}
}
}
},
"components": {
"schemas": {
}
},
"servers": [
{
"url": "yourserver.com",
"description": "Development server"
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment