Examples: query, "exact match", wildcard*, wild?ard, wild*rd
Fuzzy search: cake~ (finds cakes, bake)
Term boost: "red velvet"^4, chocolate^2
Field grouping: tags:(+work -"fun-stuff")
Escaping: Escape characters +-&|!(){}[]^"~*?:\ with \, e.g. \+
Range search: properties.timestamp:[1587729413488 TO *] (inclusive), properties.title:{A TO Z}(excluding A and Z)
Combinations: chocolate AND vanilla, chocolate OR vanilla, (chocolate OR vanilla) NOT "vanilla pudding"
Field search: properties.title:"The Title" AND text
Answered
Hey, Can You Give An Example Of Api Post Request For Tasks.Clone Or Tasks.Edit_Hyper_Params I’Ve Tried:

Hey, can you give an example of API post request for
tasks.clone or tasks.edit_hyper_params

I’ve tried:
` resp = session.post(
API_SERVER + "/tasks.clone",
data={
"task": task_id,
"new_task_tags": ["api"],
"new_task_hyperparams": {"General": {"time_from": last_message_ts}}
}
).json()

or

resp = session.post(
API_SERVER + "/tasks.clone",
data={
"task": task_id,
"new_task_tags": ["api", "tmp"],
"new_task_hyperparams": {"General": {"time_from": {'section': 'General', 'name': 'time_from', 'value': '2022-09-12 00:00:00'}}}
}
).json() And i receive 2 errors: 'Validation error (error for field 'new_task_tags': ('value is wrong, expected type "list"', 'api').)' only when tags list length is less than 2 'Validation error (error for field 'new_task_hyperparams': ('value is wrong, expected type "dict"', 'general').)' `

  
  
Posted one year ago
Votes Newest

Answers 5


Hi NonchalantGiraffe17
You mean this documentation?
https://clear.ml/docs/latest/docs/references/api/tasks#post-tasksclone

  
  
Posted one year ago

BTW: any specific reason for going the RestAPI way and not using the python SDK ?

  
  
Posted one year ago

I saw documentation, but I can't make the proper dict object for hyperparams

  
  
Posted one year ago

And I want to use rest because we have a lightweight airflow dag

  
  
Posted one year ago

I saw documentation, but I can't make the proper dict object for hyperparams

I see, this is what you are after (I think)
https://github.com/allegroai/clearml/blob/fb644fe9ec6be36b8f2f70a34256fbdc593d663a/clearml/backend_api/services/v2_20/tasks.py#L3138

  
  
Posted one year ago
633 Views
5 Answers
one year ago
one year ago
Tags