{"id":"compute.graph--CreateGraphTrainingPlan","name":"CreateGraphTrainingPlan","owner":"yeho","package":"compute.graph","kind":"function","signature":"external CreateGraphTrainingPlan(text name, graphExecutionPlan executionPlan, graphGradientSpec gradient, graphOptimizerState optimizer, graphCheckpointPolicy checkpoint, graphReproducibilitySettings reproducibility, text datasetKey, text note) returns graphTrainingPlan","description":"Create graph training plan from the supplied values.","context":"Describe compute work as an explicit graph with package-owned validation and scheduling metadata.","parameters":[{"name":"name","type":"text","description":"Supply name as text."},{"name":"executionPlan","type":"graphExecutionPlan","description":"Supply execution plan as graphExecutionPlan."},{"name":"gradient","type":"graphGradientSpec","description":"Supply gradient as graphGradientSpec."},{"name":"optimizer","type":"graphOptimizerState","description":"Supply optimizer as graphOptimizerState."},{"name":"checkpoint","type":"graphCheckpointPolicy","description":"Supply checkpoint as graphCheckpointPolicy."},{"name":"reproducibility","type":"graphReproducibilitySettings","description":"Supply reproducibility as graphReproducibilitySettings."},{"name":"datasetKey","type":"text","description":"Supply dataset key as text."},{"name":"note","type":"text","description":"Supply note as text."}],"returns":"graphTrainingPlan","members":[],"tags":["compute","compute.graph","cpu","function","graph","source-example","yeho"],"updated":"2026-09-09","source":{"repository":"yeho","path":"packages/compute/graph/training.yh","line":303,"sha256":"df3f352a0daeea888785284ad41be26df4c606c7ffe50b68ed7188f4fcee4410"},"status":"source-declared","notes":["Package presence and a declaration do not establish support on every host. Host services need their platform and lifecycle setup."],"examples":[{"id":"usage","title":"Use CreateGraphTrainingPlan","description":"A complete small caller. Values are illustrative; check the returned result and package requirements before connecting live resources.","code":"using compute.graph\n\n// Describe compute work as an explicit graph with package-owned validation and scheduling metadata.\ntext name = \"Nova\"\ngraphExecutionPlan executionPlan = graphExecutionPlan(\"Nova\", graphModel(\"Nova\", \"model Kind\", [], [], \"note\"), graphCachePolicy(\"key\", \"scope\", true, true, \"note\"), graphFallbackPolicy(\"primary Path\", \"fallback Path\", \"reason\", true, true, \"note\"), graphSchedulerRule(\"Nova\", \"path Order\", \"fusion Rule\", \"cache Rule\", \"note\"), \"note\")\ngraphGradientSpec gradient = graphGradientSpec(\"Nova\", \"loss Kind\", \"target Kind\", 1, true, \"note\")\ngraphOptimizerState optimizer = graphOptimizerState(\"key\", \"optimizer Kind\", \"learning Rate\", \"momentum\", \"weight Decay\", 1, \"note\")\ngraphCheckpointPolicy checkpoint = graphCheckpointPolicy(\"key\", \"png\", \"location\", true, true, true, 1, \"note\")\ngraphReproducibilitySettings reproducibility = graphReproducibilitySettings(\"key\", 1, true, true, true, \"backend Policy\", \"note\")\ntext datasetKey = \"dataset Key\"\ntext note = \"note\"\ngraphTrainingPlan result = CreateGraphTrainingPlan(name, executionPlan, gradient, optimizer, checkpoint, reproducibility, datasetKey, note)\nConsole.Log(\"Inspect result in your debugger\")\n","manifest":"manifestVersion = \"2\"\npackage = \"api.example.compute_graph__creategraphtrainingplan\"\nversion = \"0.1.0\"\nlanguageEdition = \"yeho-core-2026.1\"\n\n[app]\nkind = \"headless\"\n\n[[dependencies]]\npackage = \"compute.buffer\"\nversion = \"0.1.0\"\npath = \"../../../yeho/packages/compute/buffer\"\n\n[[dependencies]]\npackage = \"compute.device\"\nversion = \"0.1.0\"\npath = \"../../../yeho/packages/compute/device\"\n\n[[dependencies]]\npackage = \"compute.graph\"\nversion = \"0.1.0\"\npath = \"../../../yeho/packages/compute/graph\"\n\n[[dependencies]]\npackage = \"compute.kernels\"\nversion = \"0.1.0\"\npath = \"../../../yeho/packages/compute/kernels\"\n\n[[dependencies]]\npackage = \"compute.tensor\"\nversion = \"0.1.0\"\npath = \"../../../yeho/packages/compute/tensor\"\n\n[[dependencies]]\npackage = \"console\"\nversion = \"0.1.0\"\npath = \"../../../yeho/packages/console\"\n\n[[dependencies]]\npackage = \"diagnostics\"\nversion = \"0.1.0\"\npath = \"../../../yeho/packages/diagnostics\"\n","tags":["cpu","source-example"],"verification":"type checked","run":"cpu-oracle","sha256":"02d52708b75e2a298857aa060a4ab484eb4eb03131d5c320bccb94017eec58ec","checked":"2026-09-09","diagnostic":"","observedOutput":null,"checkedBackend":null}],"searchTerms":[],"url":"https://demonhunterlabs.com/academy/api?item=compute.graph--CreateGraphTrainingPlan","json":"https://demonhunterlabs.com/reference/items/compute.graph--CreateGraphTrainingPlan.json","markdown":"https://demonhunterlabs.com/reference/text/compute.graph--CreateGraphTrainingPlan.md"}
