-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
- Loading branch information
whylabs
committed
Oct 24, 2023
1 parent
102ab8b
commit 426afa4
Showing
9 changed files
with
201 additions
and
36 deletions.
There are no files selected for viewing
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
{"openapi":"3.0.2","info":{"title":"FastAPI","version":"0.1.0"},"paths":{"/log":{"post":{"summary":"Log","operationId":"log_log_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/log-embeddings":{"post":{"summary":"Log Embeddings","operationId":"log_embeddings_log_embeddings_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/log-pubsub":{"post":{"summary":"Log Pubsub","operationId":"log_pubsub_log_pubsub_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/log-pubsub-embeddings":{"post":{"summary":"Log Pubsub Embeddings","operationId":"log_pubsub_embeddings_log_pubsub_embeddings_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/log_docs":{"post":{"summary":"Log Docs","description":"This endpoint is a bit silly. I can't find an easy way of manually controlling endpoint docs in the generated swagger\nand I can't declare /log's body as LogRequest because that has the side effect of also performing serde automatically,\nwhich performs far too poorly to keep in the server process. This endpoint is just for swagger docs on the body type\nfor convenience, but it shouldn't actually be used.","operationId":"log_docs_log_docs_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LogRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/chat/completions":{"post":{"summary":"Openai Proxy","operationId":"openai_proxy_v1_chat_completions_post","parameters":[{"required":false,"schema":{"title":"Whylabs Dataset Id","type":"string"},"name":"whylabs_dataset_id","in":"query"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/validations":{"post":{"summary":"Openai Validation","operationId":"openai_validation_v1_validations_post","parameters":[{"required":true,"schema":{"title":"Whylabs Dataset Id","type":"string"},"name":"whylabs_dataset_id","in":"query"},{"required":false,"schema":{"title":"Prompt Id","type":"string"},"name":"prompt_id","in":"query"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"title":"Response Openai Validation V1 Validations Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/publish":{"post":{"summary":"Publish Profiles","operationId":"publish_profiles_publish_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/health":{"post":{"summary":"Health","operationId":"health_health_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/logDebugInfo":{"post":{"summary":"Log Debug Info","operationId":"log_debug_info_logDebugInfo_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}}},"components":{"schemas":{"HTTPValidationError":{"title":"HTTPValidationError","type":"object","properties":{"detail":{"title":"Detail","type":"array","items":{"$ref":"#/components/schemas/ValidationError"}}}},"LogMultiple":{"title":"LogMultiple","required":["columns","data"],"type":"object","properties":{"columns":{"title":"Columns","type":"array","items":{"type":"string"}},"data":{"title":"Data","type":"array","items":{"type":"array","items":{"anyOf":[{"type":"string"},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"type":"array","items":{"type":"number"}},{"type":"array","items":{"type":"integer"}},{"type":"array","items":{"type":"string"}}]}}}}},"LogRequest":{"title":"LogRequest","required":["multiple"],"type":"object","properties":{"dataset_id":{"title":"Dataset Id","type":"string"},"timestamp":{"title":"Timestamp","type":"integer"},"multiple":{"$ref":"#/components/schemas/LogMultiple"}}},"ValidationError":{"title":"ValidationError","required":["loc","msg","type"],"type":"object","properties":{"loc":{"title":"Location","type":"array","items":{"anyOf":[{"type":"string"},{"type":"integer"}]}},"msg":{"title":"Message","type":"string"},"type":{"title":"Error Type","type":"string"}}}}}} | ||
{"openapi":"3.0.2","info":{"title":"FastAPI","version":"0.1.0"},"paths":{"/log":{"post":{"summary":"Log","description":"Profile tabular data. The Swagger UI isn't able to call this currently.\n\n## Sample curl request:\n\n```bash\ncurl -X 'POST' -H \"X-API-Key: <password>\" -H \"Content-Type: application/json\" 'http://localhost:8000/log' --data-raw '{\n \"datasetId\": \"model-62\",\n \"multiple\": {\n \"columns\": [ \"age\", \"workclass\", \"fnlwgt\", \"education\" ],\n \"data\": [\n [ 25, \"Private\", 226802, \"11th\" ]\n ]\n }\n}'\n```\n\n## Sample Python request:\n```python\nimport requests\n\n# Define your API key\napi_key = \"<password>\"\n\n# API endpoint\nurl = 'http://localhost:8000/log'\n\n# Sample data\ndata = {\n \"datasetId\": \"model-62\",\n \"multiple\": {\n \"columns\": [\"age\", \"workclass\", \"fnlwgt\", \"education\"],\n \"data\": [\n [25, \"Private\", 226802, \"11th\"]\n ]\n }\n}\n\n# Make the POST request\nheaders = {\"X-API-Key\": api_key}\nresponse = requests.post(url, json=data, headers=headers)\n```","operationId":"log_log_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/log/json":{"post":{"summary":"Log Json","description":"Use this endpoint for manually testing and experimenting. It shouldn't be used in production\nbecause it has a steep performance penalty compared to the normal /log endpoint.","operationId":"log_json_log_json_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LogRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/log-embeddings":{"post":{"summary":"Log Embeddings","description":"This endpoint requires a custom configuration to set up before hand. See https://docs.whylabs.ai/docs/integrations-whylogs-container/ \nfor setting up embeddings support.\n\nLog embeddings data. The Swagger UI isn't able to call this currently.\n\n## Sample curl request:\n\n```bash\ncurl -X 'POST' -H \"X-API-Key: <password>\" -H \"Content-Type: application/json\" 'http://localhost:8000/log-embeddings' --data-raw '{\n \"datasetId\": \"model-62\",\n \"timestamp\": 1634235000,\n \"embeddings\": {\n \"embeddings\": [[0.12, 0.45, 0.33, 0.92]]\n }\n}'\n```\n\n## Sample Python request:\n```python\nimport requests\n\n# Define your API key\napi_key = \"<password>\"\n\n# API endpoint\nurl = 'http://localhost:8000/log-embeddings'\n\n# Sample data\ndata = {\n \"datasetId\": \"model-62\",\n \"timestamp\": 1634235000, # an example timestamp\n \"embeddings\": {\n \"embeddings\": [[0.12, 0.45, 0.33, 0.92]]\n }\n}\n\n# Make the POST request\nheaders = {\"X-API-Key\": api_key, \"Content-Type\": \"application/json\"}\nresponse = requests.post(url, json=data, headers=headers)\n```","operationId":"log_embeddings_log_embeddings_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/log-embeddings/json":{"post":{"summary":"Log Embeddings Json","description":"Use this endpoint for manually testing and experimenting. It shouldn't be used in production\nbecause it has a steep performance penalty compared to the normal /log-embeddings endpoint.","operationId":"log_embeddings_json_log_embeddings_json_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LogEmbeddingRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/log-pubsub":{"post":{"summary":"Log Pubsub","operationId":"log_pubsub_log_pubsub_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/log-pubsub-embeddings":{"post":{"summary":"Log Pubsub Embeddings","operationId":"log_pubsub_embeddings_log_pubsub_embeddings_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/v1/chat/completions":{"post":{"summary":"Openai Proxy","operationId":"openai_proxy_v1_chat_completions_post","parameters":[{"required":false,"schema":{"title":"Whylabs Dataset Id","type":"string"},"name":"whylabs_dataset_id","in":"query"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/validations":{"post":{"summary":"Openai Validation","operationId":"openai_validation_v1_validations_post","parameters":[{"required":true,"schema":{"title":"Whylabs Dataset Id","type":"string"},"name":"whylabs_dataset_id","in":"query"},{"required":false,"schema":{"title":"Prompt Id","type":"string"},"name":"prompt_id","in":"query"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"title":"Response Openai Validation V1 Validations Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/publish":{"post":{"summary":"Publish Profiles","operationId":"publish_profiles_publish_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/health":{"post":{"summary":"Health","operationId":"health_health_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/logDebugInfo":{"post":{"summary":"Log Debug Info","operationId":"log_debug_info_logDebugInfo_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}}},"components":{"schemas":{"HTTPValidationError":{"title":"HTTPValidationError","type":"object","properties":{"detail":{"title":"Detail","type":"array","items":{"$ref":"#/components/schemas/ValidationError"}}}},"LogEmbeddingRequest":{"title":"LogEmbeddingRequest","required":["timestamp","embeddings"],"type":"object","properties":{"dataset_id":{"title":"Dataset Id","type":"string"},"timestamp":{"title":"Timestamp","type":"integer"},"embeddings":{"title":"Embeddings","type":"object","additionalProperties":{"anyOf":[{"type":"array","items":{"type":"array","items":{"type":"number"}}},{"type":"array","items":{"type":"array","items":{"type":"integer"}}},{"type":"array","items":{"type":"array","items":{"type":"string"}}}]}}}},"LogMultiple":{"title":"LogMultiple","required":["columns","data"],"type":"object","properties":{"columns":{"title":"Columns","type":"array","items":{"type":"string"}},"data":{"title":"Data","type":"array","items":{"type":"array","items":{"anyOf":[{"type":"string"},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"type":"array","items":{"type":"number"}},{"type":"array","items":{"type":"integer"}},{"type":"array","items":{"type":"string"}}]}}}}},"LogRequest":{"title":"LogRequest","required":["multiple"],"type":"object","properties":{"dataset_id":{"title":"Dataset Id","type":"string"},"timestamp":{"title":"Timestamp","type":"integer"},"multiple":{"$ref":"#/components/schemas/LogMultiple"}}},"ValidationError":{"title":"ValidationError","required":["loc","msg","type"],"type":"object","properties":{"loc":{"title":"Location","type":"array","items":{"anyOf":[{"type":"string"},{"type":"integer"}]}},"msg":{"title":"Message","type":"string"},"type":{"title":"Error Type","type":"string"}}}}}} |
Large diffs are not rendered by default.
Oops, something went wrong.
Oops, something went wrong.