Design kit command

page.go

Go to page

Makes a page the current one, by its id or its index, as clicking it in the Pages list does; answers its id, index and name. Agents name the page a step acts on with `at.part` instead, which goes there for that step only.

Kit
Design 0.1.0 (.kdesign)
Changes the document
no

Parameters

Parameters of page.go
NameTypeRequiredDescription
idinteger | stringnoThe page to go to, by its id (inspect's `pages[].id`), which stays the same when pages are added, moved or renamed.
indexintegernoThe page to go to, counted from 0 (its `index` in inspect's `pages`).

Call through design_run

text
design_run {
  "path": "<file>.kdesign",
  "steps": [{ "command": "page.go" }]
}

The required parameters, with placeholders for their types: not a tested example. Optional: id, index. design_run answers the step’s result in completed[i].result.

Result

Result of page.go
NameTypeRequiredDescription
idintegeryes
indexintegeryesCounted from 0.
namestringyes
Result JSON Schema
json
{
  "additionalProperties": false,
  "properties": {
    "id": {
      "type": "integer"
    },
    "index": {
      "description": "Counted from 0.",
      "type": "integer"
    },
    "name": {
      "type": "string"
    }
  },
  "required": [
    "id",
    "index",
    "name"
  ],
  "type": "object"
}

Parameter schema

json
{
  "additionalProperties": false,
  "properties": {
    "id": {
      "description": "The page to go to, by its id (inspect's `pages[].id`), which stays the same when pages are added, moved or renamed.",
      "oneOf": [
        {
          "type": "integer"
        },
        {
          "type": "string"
        }
      ],
      "x-khp-types": [
        "Node"
      ]
    },
    "index": {
      "description": "The page to go to, counted from 0 (its `index` in inspect's `pages`).",
      "type": "integer"
    }
  },
  "returns": "{id, index, name}",
  "type": "object"
}

Generated from the command list of @kition/[email protected] and the kit itself (design_commands through @kition/[email protected], built from KitionAI/kition-design@abc7e16). As data: commands.jsonl.