> ## Documentation Index
> Fetch the complete documentation index at: https://docs.tuneplane.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# tp init

> Create a fine-tuning repository with the installed CLI

```bash theme={"theme":{"light":"github-light","dark":"github-dark-dimmed"}}
uv tool install tuneplane     # or: pip install tuneplane
tp init my-lab
cd my-lab
```

`tp init` scaffolds a self-contained project on your machine. The CLI comes from PyPI — you do not
clone the platform repository to get it, and you do not clone it to use it.

That project is also one **project** in console terms: `name` in `tuneplane.yaml` is what groups
every run of every experiment in it.

## Install the CLI

```bash theme={"theme":{"light":"github-light","dark":"github-dark-dimmed"}}
uv tool install tuneplane
# or, without uv
pip install tuneplane
```

Prefer `uv tool install`. It puts the CLI in its own environment, so it cannot collide with the
packages of whatever project you are standing in, and `tp update` can upgrade it in place.
Installed with `pip` into a system Python, `tp update` refuses and names the command that would
work instead.

Verify:

```bash theme={"theme":{"light":"github-light","dark":"github-dark-dimmed"}}
tp --help
tp --install-completion    # optional: shell completion
```

Upgrade with [`tp update`](https://docs.tuneplane.ai/en/cli/update), which detects how it was installed and uses the right
command.

## Create a repository

```bash theme={"theme":{"light":"github-light","dark":"github-dark-dimmed"}}
tp init my-lab                 # interactive: directory / name / git
tp init my-lab --yes           # non-interactive, all defaults
tp init . --name my-lab --yes  # initialize the current directory
```

Layout:

```text theme={"theme":{"light":"github-light","dark":"github-dark-dimmed"}}
my-lab/
├── tuneplane.yaml     # repo marker + project name (the only signal `tuneplane` uses to find the root)
├── experiments/       # `tp new` creates experiments here
├── configs/           # official bases + model fragments (yours to edit or pin)
├── common/            # shared repository code (data scripts / envs / rewards)
├── .gitignore
└── README.md
```

The platform's own runtime is neither written into the project nor uploaded. `tp submit` packs
only the experiment, `common/` and `configs/`; after admission the server injects a
content-addressed Job Capsule — a manifest, a bootstrap script and a PEX runner.

## Project discovery

Commands that need a project (`tp new`, `tp submit`, `tp ls`, `tp validate`) walk up from the current directory looking for `tuneplane.yaml`, the same way git finds a repository root.

| Method | When |
| - | - |
| `cd my-lab && tp …` | Normal: run inside the project or a subdirectory |
| `TUNEPLANE_CLIENT_REPO_ROOT=/path/to/my-lab tp …` | CI / scripts: set explicitly, no `cd` |

`tp login` / `logout` / `status` are global and do not require a project.

## Next

```bash theme={"theme":{"light":"github-light","dark":"github-dark-dimmed"}}
cd my-lab
tp login --server https://tuneplane.your-company.com
tp new my-grpo --method nemo-rl/grpo
tp submit my-grpo --profile h200:8
```

## `tp init`

Create a TunePlane project

```bash theme={"theme":{"light":"github-light","dark":"github-dark-dimmed"}}
tp init [DIRECTORY] [options]
```

| Argument | Description |
| - | - |
| `DIRECTORY` | The repo directory (asked interactively when omitted; . means the current directory) |

| Option | Description |
| - | - |
| `--name` | Project name, written into tuneplane.yaml (default: the directory name) |
| `--no-git` | Do not initialise a git repository |
| `--yes`, `-y` | Non-interactive: take every default |


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.