github.com/GuanceCloud/cliutils@v1.1.21/pipeline/ptinput/funcs/md/pt_kvs_set.en.md (about) 1 ### `pt_kvs_set()` {#fn_pt_kvs_set} 2 3 Function prototype: `fn pt_kvs_set(name: str, value: any, as_tag: bool = false) -> bool` 4 5 Function description: Add a key to a Point or modify the value of a key in a Point 6 7 Function parameters: 8 9 - `name`: The name of the field or label to be added or modified 10 - `value`: The value of a field or label 11 - `as_tag`: Set as tag or not 12 13 Example: 14 15 ```python 16 kvs = { 17 "a": 1, 18 "b": 2 19 } 20 21 for k in kvs { 22 pt_kvs_set(k, kvs[k]) 23 } 24 ```