ai2_kit.workflow.cll_mlp module#

pydantic model ai2_kit.workflow.cll_mlp.CllWorkflowConfig[source]#

Bases: BaseModel

Show JSON schema
{
   "title": "CllWorkflowConfig",
   "type": "object",
   "properties": {
      "executors": {
         "additionalProperties": {
            "$ref": "#/$defs/CllWorkflowExecutorConfig"
         },
         "title": "Executors",
         "type": "object"
      },
      "artifacts": {
         "additionalProperties": {
            "$ref": "#/$defs/Artifact"
         },
         "title": "Artifacts",
         "type": "object"
      },
      "workflow": {
         "title": "Workflow"
      }
   },
   "$defs": {
      "AnywareContextConfig": {
         "additionalProperties": false,
         "properties": {
            "script_template": {
               "$ref": "#/$defs/BashTemplate"
            },
            "concurrency": {
               "default": 5,
               "title": "Concurrency",
               "type": "integer"
            }
         },
         "required": [
            "script_template"
         ],
         "title": "AnywareContextConfig",
         "type": "object"
      },
      "Artifact": {
         "additionalProperties": false,
         "properties": {
            "key": {
               "anyOf": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Key"
            },
            "executor": {
               "anyOf": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Executor"
            },
            "url": {
               "title": "Url",
               "type": "string"
            },
            "format": {
               "anyOf": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Format"
            },
            "includes": {
               "anyOf": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Includes"
            },
            "attrs": {
               "default": {},
               "title": "Attrs",
               "type": "object"
            }
         },
         "required": [
            "url"
         ],
         "title": "Artifact",
         "type": "object"
      },
      "BashTemplate": {
         "additionalProperties": false,
         "properties": {
            "shebang": {
               "default": "#!/bin/bash",
               "title": "Shebang",
               "type": "string"
            },
            "header": {
               "default": "",
               "title": "Header",
               "type": "string"
            },
            "setup": {
               "default": "",
               "title": "Setup",
               "type": "string"
            },
            "teardown": {
               "default": "",
               "title": "Teardown",
               "type": "string"
            }
         },
         "title": "BashTemplate",
         "type": "object"
      },
      "CllCp2kContextConfig": {
         "additionalProperties": false,
         "properties": {
            "script_template": {
               "$ref": "#/$defs/BashTemplate"
            },
            "cp2k_cmd": {
               "default": "cp2k",
               "title": "Cp2K Cmd",
               "type": "string"
            },
            "post_cp2k_cmd": {
               "default": "echo \"no post_cp2k_cmd\"",
               "title": "Post Cp2K Cmd",
               "type": "string"
            },
            "concurrency": {
               "default": 5,
               "title": "Concurrency",
               "type": "integer"
            }
         },
         "required": [
            "script_template"
         ],
         "title": "CllCp2kContextConfig",
         "type": "object"
      },
      "CllDeepmdContextConfig": {
         "additionalProperties": false,
         "properties": {
            "script_template": {
               "$ref": "#/$defs/BashTemplate"
            },
            "dp_cmd": {
               "default": "dp",
               "title": "Dp Cmd",
               "type": "string"
            },
            "concurrency": {
               "default": 5,
               "title": "Concurrency",
               "type": "integer"
            },
            "multi_gpus_per_job": {
               "default": false,
               "title": "Multi Gpus Per Job",
               "type": "boolean"
            }
         },
         "required": [
            "script_template"
         ],
         "title": "CllDeepmdContextConfig",
         "type": "object"
      },
      "CllLammpsContextConfig": {
         "additionalProperties": false,
         "properties": {
            "script_template": {
               "$ref": "#/$defs/BashTemplate"
            },
            "lammps_cmd": {
               "default": "lmp",
               "title": "Lammps Cmd",
               "type": "string"
            },
            "concurrency": {
               "default": 5,
               "title": "Concurrency",
               "type": "integer"
            },
            "multi_gpus_per_job": {
               "default": false,
               "title": "Multi Gpus Per Job",
               "type": "boolean"
            }
         },
         "required": [
            "script_template"
         ],
         "title": "CllLammpsContextConfig",
         "type": "object"
      },
      "CllLaspContextConfig": {
         "additionalProperties": false,
         "properties": {
            "lasp_cmd": {
               "default": "lasp",
               "title": "Lasp Cmd",
               "type": "string"
            },
            "script_template": {
               "$ref": "#/$defs/BashTemplate"
            },
            "concurrency": {
               "default": 5,
               "title": "Concurrency",
               "type": "integer"
            }
         },
         "required": [
            "script_template"
         ],
         "title": "CllLaspContextConfig",
         "type": "object"
      },
      "CllVaspContextConfig": {
         "additionalProperties": false,
         "properties": {
            "script_template": {
               "$ref": "#/$defs/BashTemplate"
            },
            "vasp_cmd": {
               "default": "vasp_std",
               "title": "Vasp Cmd",
               "type": "string"
            },
            "post_vasp_cmd": {
               "default": "echo \"no post_vasp_cmd\"",
               "title": "Post Vasp Cmd",
               "type": "string"
            },
            "concurrency": {
               "default": 5,
               "title": "Concurrency",
               "type": "integer"
            }
         },
         "required": [
            "script_template"
         ],
         "title": "CllVaspContextConfig",
         "type": "object"
      },
      "CllWorkflowExecutorConfig": {
         "additionalProperties": false,
         "properties": {
            "ssh": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/SshConfig"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            },
            "queue_system": {
               "$ref": "#/$defs/QueueSystemConfig"
            },
            "work_dir": {
               "title": "Work Dir",
               "type": "string"
            },
            "python_cmd": {
               "default": "python",
               "title": "Python Cmd",
               "type": "string"
            },
            "context": {
               "$ref": "#/$defs/Context"
            }
         },
         "required": [
            "queue_system",
            "work_dir",
            "context"
         ],
         "title": "CllWorkflowExecutorConfig",
         "type": "object"
      },
      "Context": {
         "additionalProperties": false,
         "properties": {
            "train": {
               "$ref": "#/$defs/Train"
            },
            "explore": {
               "$ref": "#/$defs/Explore"
            },
            "label": {
               "$ref": "#/$defs/Label"
            }
         },
         "required": [
            "train",
            "explore",
            "label"
         ],
         "title": "Context",
         "type": "object"
      },
      "Explore": {
         "additionalProperties": false,
         "properties": {
            "lammps": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/CllLammpsContextConfig"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            },
            "lasp": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/CllLaspContextConfig"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            },
            "anyware": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/AnywareContextConfig"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            }
         },
         "title": "Explore",
         "type": "object"
      },
      "LSF": {
         "additionalProperties": false,
         "properties": {
            "bsub_bin": {
               "default": "bsub",
               "title": "Bsub Bin",
               "type": "string"
            },
            "bjobs_bin": {
               "default": "bjobs",
               "title": "Bjobs Bin",
               "type": "string"
            },
            "polling_interval": {
               "default": 10,
               "title": "Polling Interval",
               "type": "integer"
            }
         },
         "title": "LSF",
         "type": "object"
      },
      "Label": {
         "additionalProperties": false,
         "properties": {
            "cp2k": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/CllCp2kContextConfig"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            },
            "vasp": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/CllVaspContextConfig"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            }
         },
         "title": "Label",
         "type": "object"
      },
      "PBS": {
         "additionalProperties": false,
         "properties": {
            "qsub_bin": {
               "default": "qsub",
               "title": "Qsub Bin",
               "type": "string"
            },
            "qstat_bin": {
               "default": "qstat",
               "title": "Qstat Bin",
               "type": "string"
            },
            "qdel_bin": {
               "default": "qdel",
               "title": "Qdel Bin",
               "type": "string"
            }
         },
         "title": "PBS",
         "type": "object"
      },
      "QueueSystemConfig": {
         "additionalProperties": false,
         "properties": {
            "slurm": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/Slurm"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            },
            "lsf": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/LSF"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            },
            "pbs": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/PBS"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            }
         },
         "title": "QueueSystemConfig",
         "type": "object"
      },
      "Slurm": {
         "additionalProperties": false,
         "properties": {
            "sbatch_bin": {
               "default": "sbatch",
               "title": "Sbatch Bin",
               "type": "string"
            },
            "squeue_bin": {
               "default": "squeue",
               "title": "Squeue Bin",
               "type": "string"
            },
            "scancel_bin": {
               "default": "scancel",
               "title": "Scancel Bin",
               "type": "string"
            },
            "polling_interval": {
               "default": 10,
               "title": "Polling Interval",
               "type": "integer"
            }
         },
         "title": "Slurm",
         "type": "object"
      },
      "SshConfig": {
         "additionalProperties": false,
         "properties": {
            "host": {
               "title": "Host",
               "type": "string"
            },
            "gateway": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/SshConfig"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            }
         },
         "required": [
            "host"
         ],
         "title": "SshConfig",
         "type": "object"
      },
      "Train": {
         "additionalProperties": false,
         "properties": {
            "deepmd": {
               "$ref": "#/$defs/CllDeepmdContextConfig"
            }
         },
         "required": [
            "deepmd"
         ],
         "title": "Train",
         "type": "object"
      }
   },
   "additionalProperties": false,
   "required": [
      "executors",
      "artifacts",
      "workflow"
   ]
}

Config:
  • extra: str = forbid

Fields:
field artifacts: Mapping[str, Artifact] [Required]#
field executors: Dict[str, CllWorkflowExecutorConfig] [Required]#
field workflow: Any [Required]#
pydantic model ai2_kit.workflow.cll_mlp.CllWorkflowExecutorConfig[source]#

Bases: BaseExecutorConfig

Show JSON schema
{
   "title": "CllWorkflowExecutorConfig",
   "type": "object",
   "properties": {
      "ssh": {
         "anyOf": [
            {
               "$ref": "#/$defs/SshConfig"
            },
            {
               "type": "null"
            }
         ],
         "default": null
      },
      "queue_system": {
         "$ref": "#/$defs/QueueSystemConfig"
      },
      "work_dir": {
         "title": "Work Dir",
         "type": "string"
      },
      "python_cmd": {
         "default": "python",
         "title": "Python Cmd",
         "type": "string"
      },
      "context": {
         "$ref": "#/$defs/Context"
      }
   },
   "$defs": {
      "AnywareContextConfig": {
         "additionalProperties": false,
         "properties": {
            "script_template": {
               "$ref": "#/$defs/BashTemplate"
            },
            "concurrency": {
               "default": 5,
               "title": "Concurrency",
               "type": "integer"
            }
         },
         "required": [
            "script_template"
         ],
         "title": "AnywareContextConfig",
         "type": "object"
      },
      "BashTemplate": {
         "additionalProperties": false,
         "properties": {
            "shebang": {
               "default": "#!/bin/bash",
               "title": "Shebang",
               "type": "string"
            },
            "header": {
               "default": "",
               "title": "Header",
               "type": "string"
            },
            "setup": {
               "default": "",
               "title": "Setup",
               "type": "string"
            },
            "teardown": {
               "default": "",
               "title": "Teardown",
               "type": "string"
            }
         },
         "title": "BashTemplate",
         "type": "object"
      },
      "CllCp2kContextConfig": {
         "additionalProperties": false,
         "properties": {
            "script_template": {
               "$ref": "#/$defs/BashTemplate"
            },
            "cp2k_cmd": {
               "default": "cp2k",
               "title": "Cp2K Cmd",
               "type": "string"
            },
            "post_cp2k_cmd": {
               "default": "echo \"no post_cp2k_cmd\"",
               "title": "Post Cp2K Cmd",
               "type": "string"
            },
            "concurrency": {
               "default": 5,
               "title": "Concurrency",
               "type": "integer"
            }
         },
         "required": [
            "script_template"
         ],
         "title": "CllCp2kContextConfig",
         "type": "object"
      },
      "CllDeepmdContextConfig": {
         "additionalProperties": false,
         "properties": {
            "script_template": {
               "$ref": "#/$defs/BashTemplate"
            },
            "dp_cmd": {
               "default": "dp",
               "title": "Dp Cmd",
               "type": "string"
            },
            "concurrency": {
               "default": 5,
               "title": "Concurrency",
               "type": "integer"
            },
            "multi_gpus_per_job": {
               "default": false,
               "title": "Multi Gpus Per Job",
               "type": "boolean"
            }
         },
         "required": [
            "script_template"
         ],
         "title": "CllDeepmdContextConfig",
         "type": "object"
      },
      "CllLammpsContextConfig": {
         "additionalProperties": false,
         "properties": {
            "script_template": {
               "$ref": "#/$defs/BashTemplate"
            },
            "lammps_cmd": {
               "default": "lmp",
               "title": "Lammps Cmd",
               "type": "string"
            },
            "concurrency": {
               "default": 5,
               "title": "Concurrency",
               "type": "integer"
            },
            "multi_gpus_per_job": {
               "default": false,
               "title": "Multi Gpus Per Job",
               "type": "boolean"
            }
         },
         "required": [
            "script_template"
         ],
         "title": "CllLammpsContextConfig",
         "type": "object"
      },
      "CllLaspContextConfig": {
         "additionalProperties": false,
         "properties": {
            "lasp_cmd": {
               "default": "lasp",
               "title": "Lasp Cmd",
               "type": "string"
            },
            "script_template": {
               "$ref": "#/$defs/BashTemplate"
            },
            "concurrency": {
               "default": 5,
               "title": "Concurrency",
               "type": "integer"
            }
         },
         "required": [
            "script_template"
         ],
         "title": "CllLaspContextConfig",
         "type": "object"
      },
      "CllVaspContextConfig": {
         "additionalProperties": false,
         "properties": {
            "script_template": {
               "$ref": "#/$defs/BashTemplate"
            },
            "vasp_cmd": {
               "default": "vasp_std",
               "title": "Vasp Cmd",
               "type": "string"
            },
            "post_vasp_cmd": {
               "default": "echo \"no post_vasp_cmd\"",
               "title": "Post Vasp Cmd",
               "type": "string"
            },
            "concurrency": {
               "default": 5,
               "title": "Concurrency",
               "type": "integer"
            }
         },
         "required": [
            "script_template"
         ],
         "title": "CllVaspContextConfig",
         "type": "object"
      },
      "Context": {
         "additionalProperties": false,
         "properties": {
            "train": {
               "$ref": "#/$defs/Train"
            },
            "explore": {
               "$ref": "#/$defs/Explore"
            },
            "label": {
               "$ref": "#/$defs/Label"
            }
         },
         "required": [
            "train",
            "explore",
            "label"
         ],
         "title": "Context",
         "type": "object"
      },
      "Explore": {
         "additionalProperties": false,
         "properties": {
            "lammps": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/CllLammpsContextConfig"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            },
            "lasp": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/CllLaspContextConfig"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            },
            "anyware": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/AnywareContextConfig"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            }
         },
         "title": "Explore",
         "type": "object"
      },
      "LSF": {
         "additionalProperties": false,
         "properties": {
            "bsub_bin": {
               "default": "bsub",
               "title": "Bsub Bin",
               "type": "string"
            },
            "bjobs_bin": {
               "default": "bjobs",
               "title": "Bjobs Bin",
               "type": "string"
            },
            "polling_interval": {
               "default": 10,
               "title": "Polling Interval",
               "type": "integer"
            }
         },
         "title": "LSF",
         "type": "object"
      },
      "Label": {
         "additionalProperties": false,
         "properties": {
            "cp2k": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/CllCp2kContextConfig"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            },
            "vasp": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/CllVaspContextConfig"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            }
         },
         "title": "Label",
         "type": "object"
      },
      "PBS": {
         "additionalProperties": false,
         "properties": {
            "qsub_bin": {
               "default": "qsub",
               "title": "Qsub Bin",
               "type": "string"
            },
            "qstat_bin": {
               "default": "qstat",
               "title": "Qstat Bin",
               "type": "string"
            },
            "qdel_bin": {
               "default": "qdel",
               "title": "Qdel Bin",
               "type": "string"
            }
         },
         "title": "PBS",
         "type": "object"
      },
      "QueueSystemConfig": {
         "additionalProperties": false,
         "properties": {
            "slurm": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/Slurm"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            },
            "lsf": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/LSF"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            },
            "pbs": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/PBS"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            }
         },
         "title": "QueueSystemConfig",
         "type": "object"
      },
      "Slurm": {
         "additionalProperties": false,
         "properties": {
            "sbatch_bin": {
               "default": "sbatch",
               "title": "Sbatch Bin",
               "type": "string"
            },
            "squeue_bin": {
               "default": "squeue",
               "title": "Squeue Bin",
               "type": "string"
            },
            "scancel_bin": {
               "default": "scancel",
               "title": "Scancel Bin",
               "type": "string"
            },
            "polling_interval": {
               "default": 10,
               "title": "Polling Interval",
               "type": "integer"
            }
         },
         "title": "Slurm",
         "type": "object"
      },
      "SshConfig": {
         "additionalProperties": false,
         "properties": {
            "host": {
               "title": "Host",
               "type": "string"
            },
            "gateway": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/SshConfig"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            }
         },
         "required": [
            "host"
         ],
         "title": "SshConfig",
         "type": "object"
      },
      "Train": {
         "additionalProperties": false,
         "properties": {
            "deepmd": {
               "$ref": "#/$defs/CllDeepmdContextConfig"
            }
         },
         "required": [
            "deepmd"
         ],
         "title": "Train",
         "type": "object"
      }
   },
   "additionalProperties": false,
   "required": [
      "queue_system",
      "work_dir",
      "context"
   ]
}

Config:
  • extra: str = forbid

Fields:
field context: Context [Required]#
pydantic model Context[source]#

Bases: BaseModel

Show JSON schema
{
   "title": "Context",
   "type": "object",
   "properties": {
      "train": {
         "$ref": "#/$defs/Train"
      },
      "explore": {
         "$ref": "#/$defs/Explore"
      },
      "label": {
         "$ref": "#/$defs/Label"
      }
   },
   "$defs": {
      "AnywareContextConfig": {
         "additionalProperties": false,
         "properties": {
            "script_template": {
               "$ref": "#/$defs/BashTemplate"
            },
            "concurrency": {
               "default": 5,
               "title": "Concurrency",
               "type": "integer"
            }
         },
         "required": [
            "script_template"
         ],
         "title": "AnywareContextConfig",
         "type": "object"
      },
      "BashTemplate": {
         "additionalProperties": false,
         "properties": {
            "shebang": {
               "default": "#!/bin/bash",
               "title": "Shebang",
               "type": "string"
            },
            "header": {
               "default": "",
               "title": "Header",
               "type": "string"
            },
            "setup": {
               "default": "",
               "title": "Setup",
               "type": "string"
            },
            "teardown": {
               "default": "",
               "title": "Teardown",
               "type": "string"
            }
         },
         "title": "BashTemplate",
         "type": "object"
      },
      "CllCp2kContextConfig": {
         "additionalProperties": false,
         "properties": {
            "script_template": {
               "$ref": "#/$defs/BashTemplate"
            },
            "cp2k_cmd": {
               "default": "cp2k",
               "title": "Cp2K Cmd",
               "type": "string"
            },
            "post_cp2k_cmd": {
               "default": "echo \"no post_cp2k_cmd\"",
               "title": "Post Cp2K Cmd",
               "type": "string"
            },
            "concurrency": {
               "default": 5,
               "title": "Concurrency",
               "type": "integer"
            }
         },
         "required": [
            "script_template"
         ],
         "title": "CllCp2kContextConfig",
         "type": "object"
      },
      "CllDeepmdContextConfig": {
         "additionalProperties": false,
         "properties": {
            "script_template": {
               "$ref": "#/$defs/BashTemplate"
            },
            "dp_cmd": {
               "default": "dp",
               "title": "Dp Cmd",
               "type": "string"
            },
            "concurrency": {
               "default": 5,
               "title": "Concurrency",
               "type": "integer"
            },
            "multi_gpus_per_job": {
               "default": false,
               "title": "Multi Gpus Per Job",
               "type": "boolean"
            }
         },
         "required": [
            "script_template"
         ],
         "title": "CllDeepmdContextConfig",
         "type": "object"
      },
      "CllLammpsContextConfig": {
         "additionalProperties": false,
         "properties": {
            "script_template": {
               "$ref": "#/$defs/BashTemplate"
            },
            "lammps_cmd": {
               "default": "lmp",
               "title": "Lammps Cmd",
               "type": "string"
            },
            "concurrency": {
               "default": 5,
               "title": "Concurrency",
               "type": "integer"
            },
            "multi_gpus_per_job": {
               "default": false,
               "title": "Multi Gpus Per Job",
               "type": "boolean"
            }
         },
         "required": [
            "script_template"
         ],
         "title": "CllLammpsContextConfig",
         "type": "object"
      },
      "CllLaspContextConfig": {
         "additionalProperties": false,
         "properties": {
            "lasp_cmd": {
               "default": "lasp",
               "title": "Lasp Cmd",
               "type": "string"
            },
            "script_template": {
               "$ref": "#/$defs/BashTemplate"
            },
            "concurrency": {
               "default": 5,
               "title": "Concurrency",
               "type": "integer"
            }
         },
         "required": [
            "script_template"
         ],
         "title": "CllLaspContextConfig",
         "type": "object"
      },
      "CllVaspContextConfig": {
         "additionalProperties": false,
         "properties": {
            "script_template": {
               "$ref": "#/$defs/BashTemplate"
            },
            "vasp_cmd": {
               "default": "vasp_std",
               "title": "Vasp Cmd",
               "type": "string"
            },
            "post_vasp_cmd": {
               "default": "echo \"no post_vasp_cmd\"",
               "title": "Post Vasp Cmd",
               "type": "string"
            },
            "concurrency": {
               "default": 5,
               "title": "Concurrency",
               "type": "integer"
            }
         },
         "required": [
            "script_template"
         ],
         "title": "CllVaspContextConfig",
         "type": "object"
      },
      "Explore": {
         "additionalProperties": false,
         "properties": {
            "lammps": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/CllLammpsContextConfig"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            },
            "lasp": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/CllLaspContextConfig"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            },
            "anyware": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/AnywareContextConfig"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            }
         },
         "title": "Explore",
         "type": "object"
      },
      "Label": {
         "additionalProperties": false,
         "properties": {
            "cp2k": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/CllCp2kContextConfig"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            },
            "vasp": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/CllVaspContextConfig"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            }
         },
         "title": "Label",
         "type": "object"
      },
      "Train": {
         "additionalProperties": false,
         "properties": {
            "deepmd": {
               "$ref": "#/$defs/CllDeepmdContextConfig"
            }
         },
         "required": [
            "deepmd"
         ],
         "title": "Train",
         "type": "object"
      }
   },
   "additionalProperties": false,
   "required": [
      "train",
      "explore",
      "label"
   ]
}

Config:
  • extra: str = forbid

Fields:
  • explore (ai2_kit.workflow.cll_mlp.CllWorkflowExecutorConfig.Context.Explore)

  • label (ai2_kit.workflow.cll_mlp.CllWorkflowExecutorConfig.Context.Label)

  • train (ai2_kit.workflow.cll_mlp.CllWorkflowExecutorConfig.Context.Train)

field explore: Explore [Required]#
field label: Label [Required]#
field train: Train [Required]#
pydantic model Explore[source]#

Bases: BaseModel

Show JSON schema
{
   "title": "Explore",
   "type": "object",
   "properties": {
      "lammps": {
         "anyOf": [
            {
               "$ref": "#/$defs/CllLammpsContextConfig"
            },
            {
               "type": "null"
            }
         ],
         "default": null
      },
      "lasp": {
         "anyOf": [
            {
               "$ref": "#/$defs/CllLaspContextConfig"
            },
            {
               "type": "null"
            }
         ],
         "default": null
      },
      "anyware": {
         "anyOf": [
            {
               "$ref": "#/$defs/AnywareContextConfig"
            },
            {
               "type": "null"
            }
         ],
         "default": null
      }
   },
   "$defs": {
      "AnywareContextConfig": {
         "additionalProperties": false,
         "properties": {
            "script_template": {
               "$ref": "#/$defs/BashTemplate"
            },
            "concurrency": {
               "default": 5,
               "title": "Concurrency",
               "type": "integer"
            }
         },
         "required": [
            "script_template"
         ],
         "title": "AnywareContextConfig",
         "type": "object"
      },
      "BashTemplate": {
         "additionalProperties": false,
         "properties": {
            "shebang": {
               "default": "#!/bin/bash",
               "title": "Shebang",
               "type": "string"
            },
            "header": {
               "default": "",
               "title": "Header",
               "type": "string"
            },
            "setup": {
               "default": "",
               "title": "Setup",
               "type": "string"
            },
            "teardown": {
               "default": "",
               "title": "Teardown",
               "type": "string"
            }
         },
         "title": "BashTemplate",
         "type": "object"
      },
      "CllLammpsContextConfig": {
         "additionalProperties": false,
         "properties": {
            "script_template": {
               "$ref": "#/$defs/BashTemplate"
            },
            "lammps_cmd": {
               "default": "lmp",
               "title": "Lammps Cmd",
               "type": "string"
            },
            "concurrency": {
               "default": 5,
               "title": "Concurrency",
               "type": "integer"
            },
            "multi_gpus_per_job": {
               "default": false,
               "title": "Multi Gpus Per Job",
               "type": "boolean"
            }
         },
         "required": [
            "script_template"
         ],
         "title": "CllLammpsContextConfig",
         "type": "object"
      },
      "CllLaspContextConfig": {
         "additionalProperties": false,
         "properties": {
            "lasp_cmd": {
               "default": "lasp",
               "title": "Lasp Cmd",
               "type": "string"
            },
            "script_template": {
               "$ref": "#/$defs/BashTemplate"
            },
            "concurrency": {
               "default": 5,
               "title": "Concurrency",
               "type": "integer"
            }
         },
         "required": [
            "script_template"
         ],
         "title": "CllLaspContextConfig",
         "type": "object"
      }
   },
   "additionalProperties": false
}

Config:
  • extra: str = forbid

Fields:
  • anyware (ai2_kit.domain.anyware.AnywareContextConfig | None)

  • lammps (ai2_kit.domain.lammps.CllLammpsContextConfig | None)

  • lasp (ai2_kit.domain.lasp.CllLaspContextConfig | None)

field anyware: AnywareContextConfig | None = None#
field lammps: CllLammpsContextConfig | None = None#
field lasp: CllLaspContextConfig | None = None#
pydantic model Label[source]#

Bases: BaseModel

Show JSON schema
{
   "title": "Label",
   "type": "object",
   "properties": {
      "cp2k": {
         "anyOf": [
            {
               "$ref": "#/$defs/CllCp2kContextConfig"
            },
            {
               "type": "null"
            }
         ],
         "default": null
      },
      "vasp": {
         "anyOf": [
            {
               "$ref": "#/$defs/CllVaspContextConfig"
            },
            {
               "type": "null"
            }
         ],
         "default": null
      }
   },
   "$defs": {
      "BashTemplate": {
         "additionalProperties": false,
         "properties": {
            "shebang": {
               "default": "#!/bin/bash",
               "title": "Shebang",
               "type": "string"
            },
            "header": {
               "default": "",
               "title": "Header",
               "type": "string"
            },
            "setup": {
               "default": "",
               "title": "Setup",
               "type": "string"
            },
            "teardown": {
               "default": "",
               "title": "Teardown",
               "type": "string"
            }
         },
         "title": "BashTemplate",
         "type": "object"
      },
      "CllCp2kContextConfig": {
         "additionalProperties": false,
         "properties": {
            "script_template": {
               "$ref": "#/$defs/BashTemplate"
            },
            "cp2k_cmd": {
               "default": "cp2k",
               "title": "Cp2K Cmd",
               "type": "string"
            },
            "post_cp2k_cmd": {
               "default": "echo \"no post_cp2k_cmd\"",
               "title": "Post Cp2K Cmd",
               "type": "string"
            },
            "concurrency": {
               "default": 5,
               "title": "Concurrency",
               "type": "integer"
            }
         },
         "required": [
            "script_template"
         ],
         "title": "CllCp2kContextConfig",
         "type": "object"
      },
      "CllVaspContextConfig": {
         "additionalProperties": false,
         "properties": {
            "script_template": {
               "$ref": "#/$defs/BashTemplate"
            },
            "vasp_cmd": {
               "default": "vasp_std",
               "title": "Vasp Cmd",
               "type": "string"
            },
            "post_vasp_cmd": {
               "default": "echo \"no post_vasp_cmd\"",
               "title": "Post Vasp Cmd",
               "type": "string"
            },
            "concurrency": {
               "default": 5,
               "title": "Concurrency",
               "type": "integer"
            }
         },
         "required": [
            "script_template"
         ],
         "title": "CllVaspContextConfig",
         "type": "object"
      }
   },
   "additionalProperties": false
}

Config:
  • extra: str = forbid

Fields:
  • cp2k (ai2_kit.domain.cp2k.CllCp2kContextConfig | None)

  • vasp (ai2_kit.domain.vasp.CllVaspContextConfig | None)

field cp2k: CllCp2kContextConfig | None = None#
field vasp: CllVaspContextConfig | None = None#
pydantic model Train[source]#

Bases: BaseModel

Show JSON schema
{
   "title": "Train",
   "type": "object",
   "properties": {
      "deepmd": {
         "$ref": "#/$defs/CllDeepmdContextConfig"
      }
   },
   "$defs": {
      "BashTemplate": {
         "additionalProperties": false,
         "properties": {
            "shebang": {
               "default": "#!/bin/bash",
               "title": "Shebang",
               "type": "string"
            },
            "header": {
               "default": "",
               "title": "Header",
               "type": "string"
            },
            "setup": {
               "default": "",
               "title": "Setup",
               "type": "string"
            },
            "teardown": {
               "default": "",
               "title": "Teardown",
               "type": "string"
            }
         },
         "title": "BashTemplate",
         "type": "object"
      },
      "CllDeepmdContextConfig": {
         "additionalProperties": false,
         "properties": {
            "script_template": {
               "$ref": "#/$defs/BashTemplate"
            },
            "dp_cmd": {
               "default": "dp",
               "title": "Dp Cmd",
               "type": "string"
            },
            "concurrency": {
               "default": 5,
               "title": "Concurrency",
               "type": "integer"
            },
            "multi_gpus_per_job": {
               "default": false,
               "title": "Multi Gpus Per Job",
               "type": "boolean"
            }
         },
         "required": [
            "script_template"
         ],
         "title": "CllDeepmdContextConfig",
         "type": "object"
      }
   },
   "additionalProperties": false,
   "required": [
      "deepmd"
   ]
}

Config:
  • extra: str = forbid

Fields:
  • deepmd (ai2_kit.domain.deepmd.CllDeepmdContextConfig)

field deepmd: CllDeepmdContextConfig [Required]#
class ai2_kit.workflow.cll_mlp.SharedVars(dp_modifier: dict | None = None, dp_sel_type: List[int] | None = None)[source]#

Bases: object

dp_modifier: dict | None = None#
dp_sel_type: List[int] | None = None#
pydantic model ai2_kit.workflow.cll_mlp.WorkflowConfig[source]#

Bases: BaseModel

Show JSON schema
{
   "title": "WorkflowConfig",
   "type": "object",
   "properties": {
      "general": {
         "$ref": "#/$defs/General"
      },
      "train": {
         "$ref": "#/$defs/Train"
      },
      "explore": {
         "$ref": "#/$defs/Explore"
      },
      "select": {
         "$ref": "#/$defs/Select"
      },
      "label": {
         "$ref": "#/$defs/Label"
      },
      "update": {
         "$ref": "#/$defs/Update"
      }
   },
   "$defs": {
      "AnywareConfig": {
         "additionalProperties": false,
         "properties": {
            "system_files": {
               "items": {
                  "type": "string"
               },
               "title": "System Files",
               "type": "array"
            },
            "template_files": {
               "additionalProperties": {
                  "type": "string"
               },
               "title": "Template Files",
               "type": "object"
            },
            "product_vars": {
               "additionalProperties": {
                  "items": {
                     "type": "string"
                  },
                  "type": "array"
               },
               "default": {},
               "title": "Product Vars",
               "type": "object"
            },
            "broadcast_vars": {
               "additionalProperties": {
                  "items": {
                     "type": "string"
                  },
                  "type": "array"
               },
               "default": {},
               "title": "Broadcast Vars",
               "type": "object"
            },
            "system_file_name": {
               "title": "System File Name",
               "type": "string"
            },
            "system_file_format": {
               "title": "System File Format",
               "type": "string"
            },
            "submit_script": {
               "title": "Submit Script",
               "type": "string"
            },
            "post_process_fn": {
               "anyOf": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Post Process Fn"
            },
            "delimiter": {
               "default": "$$",
               "title": "Delimiter",
               "type": "string"
            },
            "shuffle": {
               "default": false,
               "title": "Shuffle",
               "type": "boolean"
            }
         },
         "required": [
            "system_files",
            "template_files",
            "system_file_name",
            "system_file_format",
            "submit_script"
         ],
         "title": "AnywareConfig",
         "type": "object"
      },
      "AsapOptions": {
         "additionalProperties": false,
         "properties": {
            "disable": {
               "default": false,
               "title": "Disable",
               "type": "boolean"
            },
            "limit_per_cluster": {
               "default": 1,
               "title": "Limit Per Cluster",
               "type": "integer"
            },
            "sort_by_ssw_energy": {
               "default": false,
               "title": "Sort By Ssw Energy",
               "type": "boolean"
            },
            "descriptor": {
               "default": {
                  "soap": {
                     "crossover": false,
                     "element_wise": false,
                     "l_max": 6,
                     "n_max": 6,
                     "preset": "minimal",
                     "r_cut": 3.5,
                     "rbf": "gto",
                     "reducer_type": "average",
                     "sigma": 0.5,
                     "zeta": 1
                  }
               },
               "title": "Descriptor",
               "type": "object"
            },
            "dim_reducer": {
               "default": {
                  "pca": {
                     "parameter": {
                        "n_components": 3,
                        "scalecenter": true
                     },
                     "type": "PCA"
                  }
               },
               "title": "Dim Reducer",
               "type": "object"
            },
            "cluster": {
               "default": {
                  "dbscan": {}
               },
               "title": "Cluster",
               "type": "object"
            }
         },
         "title": "AsapOptions",
         "type": "object"
      },
      "CllCp2kInputConfig": {
         "additionalProperties": false,
         "properties": {
            "init_system_files": {
               "default": [],
               "items": {
                  "type": "string"
               },
               "title": "Init System Files",
               "type": "array"
            },
            "wfn_warmup_template": {
               "anyOf": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Wfn Warmup Template"
            },
            "input_template": {
               "anyOf": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Input Template"
            },
            "template_vars": {
               "default": {},
               "title": "Template Vars",
               "type": "object"
            },
            "limit": {
               "default": 50,
               "title": "Limit",
               "type": "integer"
            },
            "limit_method": {
               "default": "even",
               "enum": [
                  "even",
                  "random",
                  "truncate"
               ],
               "title": "Limit Method",
               "type": "string"
            },
            "ignore_error": {
               "default": false,
               "title": "Ignore Error",
               "type": "boolean"
            }
         },
         "title": "CllCp2kInputConfig",
         "type": "object"
      },
      "CllDeepmdInputConfig": {
         "additionalProperties": false,
         "properties": {
            "train_dw": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/DwTraningConfig"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            },
            "model_num": {
               "default": 4,
               "title": "Model Num",
               "type": "integer"
            },
            "init_dataset": {
               "default": [],
               "items": {
                  "type": "string"
               },
               "title": "Init Dataset",
               "type": "array"
            },
            "input_template": {
               "default": {},
               "title": "Input Template",
               "type": "object"
            },
            "compress_model": {
               "default": false,
               "title": "Compress Model",
               "type": "boolean"
            },
            "pretrained_model": {
               "anyOf": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Pretrained Model"
            },
            "isolate_outliers": {
               "default": false,
               "title": "Isolate Outliers",
               "type": "boolean"
            },
            "outlier_f_cutoff": {
               "default": 10.0,
               "title": "Outlier F Cutoff",
               "type": "number"
            },
            "outlier_weight": {
               "default": 0.003,
               "title": "Outlier Weight",
               "type": "number"
            },
            "fixture_models": {
               "default": [],
               "items": {
                  "type": "string"
               },
               "title": "Fixture Models",
               "type": "array"
            },
            "group_by_formula": {
               "default": false,
               "title": "Group By Formula",
               "type": "boolean"
            },
            "init_from_previous": {
               "default": false,
               "title": "Init From Previous",
               "type": "boolean"
            },
            "input_modifier_fn": {
               "anyOf": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Input Modifier Fn"
            },
            "ignore_error": {
               "default": false,
               "title": "Ignore Error",
               "type": "boolean"
            },
            "dp_train_opts": {
               "default": "",
               "title": "Dp Train Opts",
               "type": "string"
            }
         },
         "title": "CllDeepmdInputConfig",
         "type": "object"
      },
      "CllLammpsInputConfig": {
         "additionalProperties": false,
         "properties": {
            "n_wise": {
               "default": 0,
               "title": "N Wise",
               "type": "integer"
            },
            "explore_vars": {
               "additionalProperties": {
                  "items": {},
                  "type": "array"
               },
               "title": "Explore Vars",
               "type": "object"
            },
            "broadcast_vars": {
               "default": {},
               "title": "Broadcast Vars",
               "type": "object"
            },
            "preset_template": {
               "anyOf": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Preset Template"
            },
            "input_template": {
               "anyOf": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Input Template"
            },
            "template_vars": {
               "default": {},
               "title": "Template Vars",
               "type": "object"
            },
            "plumed_config": {
               "anyOf": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Plumed Config"
            },
            "system_files": {
               "items": {
                  "type": "string"
               },
               "title": "System Files",
               "type": "array"
            },
            "ensemble": {
               "anyOf": [
                  {
                     "enum": [
                        "nvt",
                        "npt",
                        "npt-i",
                        "npt-a",
                        "npt-iso",
                        "npt-aniso",
                        "npt-t",
                        "npt-tri",
                        "npt-x",
                        "npt-y",
                        "npt-z",
                        "nve",
                        "csvr"
                     ],
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Ensemble"
            },
            "fix_statement": {
               "anyOf": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Fix Statement"
            },
            "no_pbc": {
               "default": false,
               "title": "No Pbc",
               "type": "boolean"
            },
            "nsteps": {
               "title": "Nsteps",
               "type": "integer"
            },
            "timestep": {
               "default": 0.0005,
               "title": "Timestep",
               "type": "number"
            },
            "sample_freq": {
               "default": 100,
               "title": "Sample Freq",
               "type": "integer"
            },
            "ignore_error": {
               "default": false,
               "title": "Ignore Error",
               "type": "boolean"
            },
            "type_alias": {
               "additionalProperties": {
                  "items": {
                     "type": "string"
                  },
                  "type": "array"
               },
               "default": {},
               "title": "Type Alias",
               "type": "object"
            },
            "custom_ff": {
               "anyOf": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Custom Ff"
            },
            "fep_opts": {
               "allOf": [
                  {
                     "$ref": "#/$defs/FepOptions"
                  }
               ],
               "default": {
                  "ini_ghost_types": [],
                  "fin_ghost_types": []
               }
            }
         },
         "required": [
            "explore_vars",
            "system_files",
            "nsteps"
         ],
         "title": "CllLammpsInputConfig",
         "type": "object"
      },
      "CllLaspInputConfig": {
         "additionalProperties": false,
         "properties": {
            "input_template": {
               "title": "Input Template",
               "type": "object"
            },
            "potential": {
               "$ref": "#/$defs/Potential"
            },
            "system_files": {
               "items": {
                  "type": "string"
               },
               "title": "System Files",
               "type": "array"
            }
         },
         "required": [
            "input_template",
            "potential",
            "system_files"
         ],
         "title": "CllLaspInputConfig",
         "type": "object"
      },
      "CllModelDeviSelectorInputConfig": {
         "additionalProperties": false,
         "properties": {
            "f_trust_lo": {
               "default": 0.0,
               "title": "F Trust Lo",
               "type": "number"
            },
            "f_trust_hi": {
               "default": 65535.0,
               "title": "F Trust Hi",
               "type": "number"
            },
            "new_explore_system_q": {
               "default": 0.25,
               "title": "New Explore System Q",
               "type": "number"
            },
            "asap_options": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/AsapOptions"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            },
            "screening_fn": {
               "anyOf": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Screening Fn"
            },
            "max_decent_per_traj": {
               "default": -1,
               "title": "Max Decent Per Traj",
               "type": "integer"
            },
            "workers": {
               "default": 4,
               "title": "Workers",
               "type": "integer"
            }
         },
         "title": "CllModelDeviSelectorInputConfig",
         "type": "object"
      },
      "CllVaspInputConfig": {
         "additionalProperties": false,
         "properties": {
            "init_system_files": {
               "default": [],
               "items": {
                  "type": "string"
               },
               "title": "Init System Files",
               "type": "array"
            },
            "input_template": {
               "anyOf": [
                  {
                     "type": "object"
                  },
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Input Template"
            },
            "potcar_source": {
               "anyOf": [
                  {
                     "type": "object"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": {},
               "title": "Potcar Source"
            },
            "kpoints_template": {
               "anyOf": [
                  {
                     "type": "object"
                  },
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Kpoints Template"
            },
            "limit": {
               "default": 50,
               "title": "Limit",
               "type": "integer"
            },
            "limit_method": {
               "default": "even",
               "enum": [
                  "even",
                  "random",
                  "truncate"
               ],
               "title": "Limit Method",
               "type": "string"
            },
            "ignore_error": {
               "default": false,
               "title": "Ignore Error",
               "type": "boolean"
            }
         },
         "title": "CllVaspInputConfig",
         "type": "object"
      },
      "CllWalkthroughUpdaterInputConfig": {
         "additionalProperties": false,
         "properties": {
            "passing_rate_threshold": {
               "default": -1.0,
               "title": "Passing Rate Threshold",
               "type": "number"
            },
            "table": {
               "default": [],
               "items": {},
               "title": "Table",
               "type": "array"
            }
         },
         "title": "CllWalkthroughUpdaterInputConfig",
         "type": "object"
      },
      "DwTraningConfig": {
         "additionalProperties": false,
         "description": "Options for deep wannier model training",
         "properties": {
            "input_template": {
               "title": "Input Template",
               "type": "object"
            }
         },
         "required": [
            "input_template"
         ],
         "title": "DwTraningConfig",
         "type": "object"
      },
      "Explore": {
         "additionalProperties": false,
         "properties": {
            "lammps": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/CllLammpsInputConfig"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            },
            "lasp": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/CllLaspInputConfig"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            },
            "anyware": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/AnywareConfig"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            }
         },
         "title": "Explore",
         "type": "object"
      },
      "FepOptions": {
         "additionalProperties": false,
         "properties": {
            "ini_ghost_types": {
               "default": [],
               "items": {
                  "type": "string"
               },
               "title": "Ini Ghost Types",
               "type": "array"
            },
            "fin_ghost_types": {
               "default": [],
               "items": {
                  "type": "string"
               },
               "title": "Fin Ghost Types",
               "type": "array"
            }
         },
         "title": "FepOptions",
         "type": "object"
      },
      "General": {
         "additionalProperties": false,
         "properties": {
            "type_map": {
               "items": {
                  "type": "string"
               },
               "title": "Type Map",
               "type": "array"
            },
            "mass_map": {
               "items": {
                  "type": "number"
               },
               "title": "Mass Map",
               "type": "array"
            },
            "sel_type": {
               "anyOf": [
                  {
                     "items": {
                        "type": "string"
                     },
                     "type": "array"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Sel Type"
            },
            "max_iters": {
               "default": 1,
               "title": "Max Iters",
               "type": "integer"
            },
            "mode": {
               "default": "default",
               "enum": [
                  "default",
                  "dpff",
                  "fep-redox",
                  "fep-pka"
               ],
               "title": "Mode",
               "type": "string"
            },
            "update_explore_systems": {
               "default": false,
               "title": "Update Explore Systems",
               "type": "boolean"
            }
         },
         "required": [
            "type_map",
            "mass_map"
         ],
         "title": "General",
         "type": "object"
      },
      "Label": {
         "additionalProperties": false,
         "properties": {
            "cp2k": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/CllCp2kInputConfig"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            },
            "vasp": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/CllVaspInputConfig"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            }
         },
         "title": "Label",
         "type": "object"
      },
      "LammpsPotential": {
         "additionalProperties": false,
         "properties": {
            "input_template": {
               "default": "units           metal\nboundary        p p p\natom_style      atomic\natom_modify map yes\n\n$$read_data_section\n\n$$force_field_section\n\ncompute peratom all pressure NULL virial\n",
               "title": "Input Template",
               "type": "string"
            }
         },
         "title": "LammpsPotential",
         "type": "object"
      },
      "Potential": {
         "additionalProperties": false,
         "properties": {
            "lammps": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/LammpsPotential"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            }
         },
         "title": "Potential",
         "type": "object"
      },
      "Select": {
         "additionalProperties": false,
         "properties": {
            "model_devi": {
               "$ref": "#/$defs/CllModelDeviSelectorInputConfig"
            }
         },
         "required": [
            "model_devi"
         ],
         "title": "Select",
         "type": "object"
      },
      "Train": {
         "additionalProperties": false,
         "properties": {
            "deepmd": {
               "$ref": "#/$defs/CllDeepmdInputConfig"
            }
         },
         "required": [
            "deepmd"
         ],
         "title": "Train",
         "type": "object"
      },
      "Update": {
         "additionalProperties": false,
         "properties": {
            "walkthrough": {
               "$ref": "#/$defs/CllWalkthroughUpdaterInputConfig"
            }
         },
         "required": [
            "walkthrough"
         ],
         "title": "Update",
         "type": "object"
      }
   },
   "additionalProperties": false,
   "required": [
      "general",
      "train",
      "explore",
      "select",
      "label",
      "update"
   ]
}

Config:
  • extra: str = forbid

Fields:
field explore: Explore [Required]#
field general: General [Required]#
field label: Label [Required]#
field select: Select [Required]#
field train: Train [Required]#
field update: Update [Required]#
pydantic model Explore[source]#

Bases: BaseModel

Show JSON schema
{
   "title": "Explore",
   "type": "object",
   "properties": {
      "lammps": {
         "anyOf": [
            {
               "$ref": "#/$defs/CllLammpsInputConfig"
            },
            {
               "type": "null"
            }
         ],
         "default": null
      },
      "lasp": {
         "anyOf": [
            {
               "$ref": "#/$defs/CllLaspInputConfig"
            },
            {
               "type": "null"
            }
         ],
         "default": null
      },
      "anyware": {
         "anyOf": [
            {
               "$ref": "#/$defs/AnywareConfig"
            },
            {
               "type": "null"
            }
         ],
         "default": null
      }
   },
   "$defs": {
      "AnywareConfig": {
         "additionalProperties": false,
         "properties": {
            "system_files": {
               "items": {
                  "type": "string"
               },
               "title": "System Files",
               "type": "array"
            },
            "template_files": {
               "additionalProperties": {
                  "type": "string"
               },
               "title": "Template Files",
               "type": "object"
            },
            "product_vars": {
               "additionalProperties": {
                  "items": {
                     "type": "string"
                  },
                  "type": "array"
               },
               "default": {},
               "title": "Product Vars",
               "type": "object"
            },
            "broadcast_vars": {
               "additionalProperties": {
                  "items": {
                     "type": "string"
                  },
                  "type": "array"
               },
               "default": {},
               "title": "Broadcast Vars",
               "type": "object"
            },
            "system_file_name": {
               "title": "System File Name",
               "type": "string"
            },
            "system_file_format": {
               "title": "System File Format",
               "type": "string"
            },
            "submit_script": {
               "title": "Submit Script",
               "type": "string"
            },
            "post_process_fn": {
               "anyOf": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Post Process Fn"
            },
            "delimiter": {
               "default": "$$",
               "title": "Delimiter",
               "type": "string"
            },
            "shuffle": {
               "default": false,
               "title": "Shuffle",
               "type": "boolean"
            }
         },
         "required": [
            "system_files",
            "template_files",
            "system_file_name",
            "system_file_format",
            "submit_script"
         ],
         "title": "AnywareConfig",
         "type": "object"
      },
      "CllLammpsInputConfig": {
         "additionalProperties": false,
         "properties": {
            "n_wise": {
               "default": 0,
               "title": "N Wise",
               "type": "integer"
            },
            "explore_vars": {
               "additionalProperties": {
                  "items": {},
                  "type": "array"
               },
               "title": "Explore Vars",
               "type": "object"
            },
            "broadcast_vars": {
               "default": {},
               "title": "Broadcast Vars",
               "type": "object"
            },
            "preset_template": {
               "anyOf": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Preset Template"
            },
            "input_template": {
               "anyOf": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Input Template"
            },
            "template_vars": {
               "default": {},
               "title": "Template Vars",
               "type": "object"
            },
            "plumed_config": {
               "anyOf": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Plumed Config"
            },
            "system_files": {
               "items": {
                  "type": "string"
               },
               "title": "System Files",
               "type": "array"
            },
            "ensemble": {
               "anyOf": [
                  {
                     "enum": [
                        "nvt",
                        "npt",
                        "npt-i",
                        "npt-a",
                        "npt-iso",
                        "npt-aniso",
                        "npt-t",
                        "npt-tri",
                        "npt-x",
                        "npt-y",
                        "npt-z",
                        "nve",
                        "csvr"
                     ],
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Ensemble"
            },
            "fix_statement": {
               "anyOf": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Fix Statement"
            },
            "no_pbc": {
               "default": false,
               "title": "No Pbc",
               "type": "boolean"
            },
            "nsteps": {
               "title": "Nsteps",
               "type": "integer"
            },
            "timestep": {
               "default": 0.0005,
               "title": "Timestep",
               "type": "number"
            },
            "sample_freq": {
               "default": 100,
               "title": "Sample Freq",
               "type": "integer"
            },
            "ignore_error": {
               "default": false,
               "title": "Ignore Error",
               "type": "boolean"
            },
            "type_alias": {
               "additionalProperties": {
                  "items": {
                     "type": "string"
                  },
                  "type": "array"
               },
               "default": {},
               "title": "Type Alias",
               "type": "object"
            },
            "custom_ff": {
               "anyOf": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Custom Ff"
            },
            "fep_opts": {
               "allOf": [
                  {
                     "$ref": "#/$defs/FepOptions"
                  }
               ],
               "default": {
                  "ini_ghost_types": [],
                  "fin_ghost_types": []
               }
            }
         },
         "required": [
            "explore_vars",
            "system_files",
            "nsteps"
         ],
         "title": "CllLammpsInputConfig",
         "type": "object"
      },
      "CllLaspInputConfig": {
         "additionalProperties": false,
         "properties": {
            "input_template": {
               "title": "Input Template",
               "type": "object"
            },
            "potential": {
               "$ref": "#/$defs/Potential"
            },
            "system_files": {
               "items": {
                  "type": "string"
               },
               "title": "System Files",
               "type": "array"
            }
         },
         "required": [
            "input_template",
            "potential",
            "system_files"
         ],
         "title": "CllLaspInputConfig",
         "type": "object"
      },
      "FepOptions": {
         "additionalProperties": false,
         "properties": {
            "ini_ghost_types": {
               "default": [],
               "items": {
                  "type": "string"
               },
               "title": "Ini Ghost Types",
               "type": "array"
            },
            "fin_ghost_types": {
               "default": [],
               "items": {
                  "type": "string"
               },
               "title": "Fin Ghost Types",
               "type": "array"
            }
         },
         "title": "FepOptions",
         "type": "object"
      },
      "LammpsPotential": {
         "additionalProperties": false,
         "properties": {
            "input_template": {
               "default": "units           metal\nboundary        p p p\natom_style      atomic\natom_modify map yes\n\n$$read_data_section\n\n$$force_field_section\n\ncompute peratom all pressure NULL virial\n",
               "title": "Input Template",
               "type": "string"
            }
         },
         "title": "LammpsPotential",
         "type": "object"
      },
      "Potential": {
         "additionalProperties": false,
         "properties": {
            "lammps": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/LammpsPotential"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            }
         },
         "title": "Potential",
         "type": "object"
      }
   },
   "additionalProperties": false
}

Config:
  • extra: str = forbid

Fields:
  • anyware (ai2_kit.domain.anyware.AnywareConfig | None)

  • lammps (ai2_kit.domain.lammps.CllLammpsInputConfig | None)

  • lasp (ai2_kit.domain.lasp.CllLaspInputConfig | None)

field anyware: AnywareConfig | None = None#
field lammps: CllLammpsInputConfig | None = None#
field lasp: CllLaspInputConfig | None = None#
pydantic model General[source]#

Bases: BaseModel

Show JSON schema
{
   "title": "General",
   "type": "object",
   "properties": {
      "type_map": {
         "items": {
            "type": "string"
         },
         "title": "Type Map",
         "type": "array"
      },
      "mass_map": {
         "items": {
            "type": "number"
         },
         "title": "Mass Map",
         "type": "array"
      },
      "sel_type": {
         "anyOf": [
            {
               "items": {
                  "type": "string"
               },
               "type": "array"
            },
            {
               "type": "null"
            }
         ],
         "default": null,
         "title": "Sel Type"
      },
      "max_iters": {
         "default": 1,
         "title": "Max Iters",
         "type": "integer"
      },
      "mode": {
         "default": "default",
         "enum": [
            "default",
            "dpff",
            "fep-redox",
            "fep-pka"
         ],
         "title": "Mode",
         "type": "string"
      },
      "update_explore_systems": {
         "default": false,
         "title": "Update Explore Systems",
         "type": "boolean"
      }
   },
   "additionalProperties": false,
   "required": [
      "type_map",
      "mass_map"
   ]
}

Config:
  • extra: str = forbid

Fields:
  • mass_map (List[float])

  • max_iters (int)

  • mode (Literal['default', 'dpff', 'fep-redox', 'fep-pka'])

  • sel_type (List[str] | None)

  • type_map (List[str])

  • update_explore_systems (bool)

field mass_map: List[float] [Required]#
field max_iters: int = 1#
field mode: Literal['default', 'dpff', 'fep-redox', 'fep-pka'] = 'default'#
field sel_type: List[str] | None = None#
field type_map: List[str] [Required]#
field update_explore_systems: bool = False#
pydantic model Label[source]#

Bases: BaseModel

Show JSON schema
{
   "title": "Label",
   "type": "object",
   "properties": {
      "cp2k": {
         "anyOf": [
            {
               "$ref": "#/$defs/CllCp2kInputConfig"
            },
            {
               "type": "null"
            }
         ],
         "default": null
      },
      "vasp": {
         "anyOf": [
            {
               "$ref": "#/$defs/CllVaspInputConfig"
            },
            {
               "type": "null"
            }
         ],
         "default": null
      }
   },
   "$defs": {
      "CllCp2kInputConfig": {
         "additionalProperties": false,
         "properties": {
            "init_system_files": {
               "default": [],
               "items": {
                  "type": "string"
               },
               "title": "Init System Files",
               "type": "array"
            },
            "wfn_warmup_template": {
               "anyOf": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Wfn Warmup Template"
            },
            "input_template": {
               "anyOf": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Input Template"
            },
            "template_vars": {
               "default": {},
               "title": "Template Vars",
               "type": "object"
            },
            "limit": {
               "default": 50,
               "title": "Limit",
               "type": "integer"
            },
            "limit_method": {
               "default": "even",
               "enum": [
                  "even",
                  "random",
                  "truncate"
               ],
               "title": "Limit Method",
               "type": "string"
            },
            "ignore_error": {
               "default": false,
               "title": "Ignore Error",
               "type": "boolean"
            }
         },
         "title": "CllCp2kInputConfig",
         "type": "object"
      },
      "CllVaspInputConfig": {
         "additionalProperties": false,
         "properties": {
            "init_system_files": {
               "default": [],
               "items": {
                  "type": "string"
               },
               "title": "Init System Files",
               "type": "array"
            },
            "input_template": {
               "anyOf": [
                  {
                     "type": "object"
                  },
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Input Template"
            },
            "potcar_source": {
               "anyOf": [
                  {
                     "type": "object"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": {},
               "title": "Potcar Source"
            },
            "kpoints_template": {
               "anyOf": [
                  {
                     "type": "object"
                  },
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Kpoints Template"
            },
            "limit": {
               "default": 50,
               "title": "Limit",
               "type": "integer"
            },
            "limit_method": {
               "default": "even",
               "enum": [
                  "even",
                  "random",
                  "truncate"
               ],
               "title": "Limit Method",
               "type": "string"
            },
            "ignore_error": {
               "default": false,
               "title": "Ignore Error",
               "type": "boolean"
            }
         },
         "title": "CllVaspInputConfig",
         "type": "object"
      }
   },
   "additionalProperties": false
}

Config:
  • extra: str = forbid

Fields:
  • cp2k (ai2_kit.domain.cp2k.CllCp2kInputConfig | None)

  • vasp (ai2_kit.domain.vasp.CllVaspInputConfig | None)

field cp2k: CllCp2kInputConfig | None = None#
field vasp: CllVaspInputConfig | None = None#
pydantic model Select[source]#

Bases: BaseModel

Show JSON schema
{
   "title": "Select",
   "type": "object",
   "properties": {
      "model_devi": {
         "$ref": "#/$defs/CllModelDeviSelectorInputConfig"
      }
   },
   "$defs": {
      "AsapOptions": {
         "additionalProperties": false,
         "properties": {
            "disable": {
               "default": false,
               "title": "Disable",
               "type": "boolean"
            },
            "limit_per_cluster": {
               "default": 1,
               "title": "Limit Per Cluster",
               "type": "integer"
            },
            "sort_by_ssw_energy": {
               "default": false,
               "title": "Sort By Ssw Energy",
               "type": "boolean"
            },
            "descriptor": {
               "default": {
                  "soap": {
                     "crossover": false,
                     "element_wise": false,
                     "l_max": 6,
                     "n_max": 6,
                     "preset": "minimal",
                     "r_cut": 3.5,
                     "rbf": "gto",
                     "reducer_type": "average",
                     "sigma": 0.5,
                     "zeta": 1
                  }
               },
               "title": "Descriptor",
               "type": "object"
            },
            "dim_reducer": {
               "default": {
                  "pca": {
                     "parameter": {
                        "n_components": 3,
                        "scalecenter": true
                     },
                     "type": "PCA"
                  }
               },
               "title": "Dim Reducer",
               "type": "object"
            },
            "cluster": {
               "default": {
                  "dbscan": {}
               },
               "title": "Cluster",
               "type": "object"
            }
         },
         "title": "AsapOptions",
         "type": "object"
      },
      "CllModelDeviSelectorInputConfig": {
         "additionalProperties": false,
         "properties": {
            "f_trust_lo": {
               "default": 0.0,
               "title": "F Trust Lo",
               "type": "number"
            },
            "f_trust_hi": {
               "default": 65535.0,
               "title": "F Trust Hi",
               "type": "number"
            },
            "new_explore_system_q": {
               "default": 0.25,
               "title": "New Explore System Q",
               "type": "number"
            },
            "asap_options": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/AsapOptions"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            },
            "screening_fn": {
               "anyOf": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Screening Fn"
            },
            "max_decent_per_traj": {
               "default": -1,
               "title": "Max Decent Per Traj",
               "type": "integer"
            },
            "workers": {
               "default": 4,
               "title": "Workers",
               "type": "integer"
            }
         },
         "title": "CllModelDeviSelectorInputConfig",
         "type": "object"
      }
   },
   "additionalProperties": false,
   "required": [
      "model_devi"
   ]
}

Config:
  • extra: str = forbid

Fields:
  • model_devi (ai2_kit.domain.selector.CllModelDeviSelectorInputConfig)

field model_devi: CllModelDeviSelectorInputConfig [Required]#
pydantic model Train[source]#

Bases: BaseModel

Show JSON schema
{
   "title": "Train",
   "type": "object",
   "properties": {
      "deepmd": {
         "$ref": "#/$defs/CllDeepmdInputConfig"
      }
   },
   "$defs": {
      "CllDeepmdInputConfig": {
         "additionalProperties": false,
         "properties": {
            "train_dw": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/DwTraningConfig"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            },
            "model_num": {
               "default": 4,
               "title": "Model Num",
               "type": "integer"
            },
            "init_dataset": {
               "default": [],
               "items": {
                  "type": "string"
               },
               "title": "Init Dataset",
               "type": "array"
            },
            "input_template": {
               "default": {},
               "title": "Input Template",
               "type": "object"
            },
            "compress_model": {
               "default": false,
               "title": "Compress Model",
               "type": "boolean"
            },
            "pretrained_model": {
               "anyOf": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Pretrained Model"
            },
            "isolate_outliers": {
               "default": false,
               "title": "Isolate Outliers",
               "type": "boolean"
            },
            "outlier_f_cutoff": {
               "default": 10.0,
               "title": "Outlier F Cutoff",
               "type": "number"
            },
            "outlier_weight": {
               "default": 0.003,
               "title": "Outlier Weight",
               "type": "number"
            },
            "fixture_models": {
               "default": [],
               "items": {
                  "type": "string"
               },
               "title": "Fixture Models",
               "type": "array"
            },
            "group_by_formula": {
               "default": false,
               "title": "Group By Formula",
               "type": "boolean"
            },
            "init_from_previous": {
               "default": false,
               "title": "Init From Previous",
               "type": "boolean"
            },
            "input_modifier_fn": {
               "anyOf": [
                  {
                     "type": "string"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null,
               "title": "Input Modifier Fn"
            },
            "ignore_error": {
               "default": false,
               "title": "Ignore Error",
               "type": "boolean"
            },
            "dp_train_opts": {
               "default": "",
               "title": "Dp Train Opts",
               "type": "string"
            }
         },
         "title": "CllDeepmdInputConfig",
         "type": "object"
      },
      "DwTraningConfig": {
         "additionalProperties": false,
         "description": "Options for deep wannier model training",
         "properties": {
            "input_template": {
               "title": "Input Template",
               "type": "object"
            }
         },
         "required": [
            "input_template"
         ],
         "title": "DwTraningConfig",
         "type": "object"
      }
   },
   "additionalProperties": false,
   "required": [
      "deepmd"
   ]
}

Config:
  • extra: str = forbid

Fields:
  • deepmd (ai2_kit.domain.deepmd.CllDeepmdInputConfig)

field deepmd: CllDeepmdInputConfig [Required]#
pydantic model Update[source]#

Bases: BaseModel

Show JSON schema
{
   "title": "Update",
   "type": "object",
   "properties": {
      "walkthrough": {
         "$ref": "#/$defs/CllWalkthroughUpdaterInputConfig"
      }
   },
   "$defs": {
      "CllWalkthroughUpdaterInputConfig": {
         "additionalProperties": false,
         "properties": {
            "passing_rate_threshold": {
               "default": -1.0,
               "title": "Passing Rate Threshold",
               "type": "number"
            },
            "table": {
               "default": [],
               "items": {},
               "title": "Table",
               "type": "array"
            }
         },
         "title": "CllWalkthroughUpdaterInputConfig",
         "type": "object"
      }
   },
   "additionalProperties": false,
   "required": [
      "walkthrough"
   ]
}

Config:
  • extra: str = forbid

Fields:
  • walkthrough (ai2_kit.domain.updater.CllWalkthroughUpdaterInputConfig)

field walkthrough: CllWalkthroughUpdaterInputConfig [Required]#
async ai2_kit.workflow.cll_mlp.cll_mlp_training_workflow(config: CllWorkflowConfig, resource_manager: ResourceManager, executor: str, path_prefix: str)[source]#
ai2_kit.workflow.cll_mlp.precondition(workflow_cfg: WorkflowConfig) SharedVars[source]#

precondition of workflow config to raise error early, and extra variables that may shared by multiple steps

The known shared variables are:

dp_modifier, which include vars sys_charge_map, model_charge_map, ewald_h, ewald_beta sel_type, which is suppose to be used in dplr/dpff mode

ai2_kit.workflow.cll_mlp.run_workflow(*config_files, executor: str | None = None, path_prefix: str | None = None, checkpoint: str | None = None)[source]#

Run Closed-Loop Learning (CLL) workflow to train Machine Learning Potential (MLP) models.

Parameters:
  • config_files – path of config files, should be yaml files, can be multiple, support glob pattern

  • executor – name of executor, should be defined in config executors section

  • path_prefix – path prefix for output

  • checkpoint – checkpoint file