File size: 2,541 Bytes
31c9f7d | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 | {
"name": "write_file",
"description": "Write string content as a file to a Hugging Face bucket, model, dataset, or Space.",
"inputSchema": {
"type": "object",
"properties": {
"content": {
"type": "string",
"description": "String content to write to the Hub."
},
"repo_id": {
"type": "string",
"description": "Hub repo id, or bucket id when repo_type is bucket."
},
"path_in_repo": {
"type": "string",
"description": "File path to create in the repo, or object path in the bucket."
},
"repo_type": {
"type": "string",
"enum": [
"model",
"dataset",
"space",
"bucket"
],
"description": "Repository type: model, dataset, space, or bucket.",
"default": "model"
},
"create_if_missing": {
"type": "boolean",
"description": "Create the repo or bucket if it does not already exist.\nThis matches the default behavior of `hf upload` for repos.",
"default": true
},
"private": {
"type": [
"boolean",
"null"
],
"description": "Optional privacy setting when creating the repo or bucket."
},
"space_sdk": {
"type": "string",
"enum": [
"static",
"gradio",
"streamlit",
"docker"
],
"description": "Space SDK to use when creating a Space.",
"default": "static"
},
"revision": {
"type": [
"string",
"null"
],
"description": "Branch or revision for repo uploads."
},
"create_pr": {
"type": "boolean",
"description": "Open repo uploads as a pull request instead of committing directly.",
"default": false
},
"commit_message": {
"type": [
"string",
"null"
],
"description": "Optional commit message for repo uploads."
},
"commit_description": {
"type": [
"string",
"null"
],
"description": "Optional commit description for repo uploads."
},
"encoding": {
"type": "string",
"description": "Text encoding used to convert the string to bytes.",
"default": "utf-8"
}
},
"required": [
"content",
"repo_id",
"path_in_repo"
],
"additionalProperties": false,
"$schema": "http://json-schema.org/draft-07/schema#"
}
} |