Download examples/deploy-api.okt from OktoSeek/oktoscript: direct link, hf CLI and curl.
- Browser
- Download file 1.19 kB
-
https://huggingface.co/OktoSeek/oktoscript/resolve/main/examples/deploy-api.okt
- Command line
-
hf download hf://OktoSeek/oktoscript/examples/deploy-api.okt
-
curl -L -o deploy-api.okt https://huggingface.co/OktoSeek/oktoscript/resolve/main/examples/deploy-api.okt
1.19 kB
| PROJECT "DeployAPIExample" | |
| DESCRIPTION "Demonstrates DEPLOY block for API deployment" | |
| ENV { | |
| accelerator: "gpu" | |
| min_memory: "8GB" | |
| precision: "fp16" | |
| } | |
| DATASET { | |
| train: "examples/datasets/demo_train.jsonl" | |
| format: "jsonl" | |
| type: "chat" | |
| } | |
| MODEL { | |
| name: "api-deploy-model" | |
| base: "oktoseek/base-mini" | |
| device: "cuda" | |
| } | |
| TRAIN { | |
| epochs: 5 | |
| batch_size: 32 | |
| device: "cuda" | |
| } | |
| EXPORT { | |
| format: ["onnx", "okm"] | |
| path: "export/" | |
| } | |
| DEPLOY { | |
| target: "api" | |
| host: "0.0.0.0" | |
| endpoint: "/chatbot" | |
| requires_auth: true | |
| port: 9000 | |
| max_concurrent_requests: 100 | |
| protocol: "http" | |
| format: "onnx" | |
| } | |
| SECURITY { | |
| input_validation { | |
| max_length: 500 | |
| disallow_patterns: [ | |
| "<script>", | |
| "DROP TABLE", | |
| "rm -rf", | |
| "sudo" | |
| ] | |
| } | |
| output_validation { | |
| prevent_data_leak: true | |
| mask_personal_info: true | |
| } | |
| rate_limit { | |
| max_requests_per_minute: 60 | |
| } | |
| encryption { | |
| algorithm: "AES-256" | |
| } | |
| } | |
| BEHAVIOR { | |
| mode: "chat" | |
| personality: "assistant" | |
| verbosity: "medium" | |
| language: "en" | |
| fallback: "How can I help you?" | |
| } | |