Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

keel init

Scaffold a new Keel project.

keel init                  # initialize in the current directory
keel init <project-name>   # create a new subdirectory
keel init <path>           # create at an absolute or relative path

What it creates

├── main.keel      # Starter agent
└── .gitignore

The generated main.keel:

use std/io

# myproject — built with Keel

agent Myproject {
  @tools [io]
  @role "Describe what this agent does"

  @on_start {
    io.show("Hello from Myproject!")
    stop(self)
  }
}

run(Myproject)

The agent name is derived from the project name in PascalCase: my-email-botMyEmailBot.

Examples

# Initialize in the current directory
mkdir myproject && cd myproject
keel init
keel run main.keel

# Create a named subdirectory
keel init task-sorter
keel run task-sorter/main.keel

# Use an absolute path (basename is used as the project name)
keel init /tmp/mybot
keel run /tmp/mybot/main.keel

keel init refuses to overwrite an existing main.keel or directory.