Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/Emanuele-web04/dpcode/llms.txt

Use this file to discover all available pages before exploring further.

DP Code organizes your work into two concepts: projects and threads. A project maps to a directory on disk — your workspace root — and acts as a home for all the AI sessions you run against that codebase. A thread is a single conversation session with an AI agent: it holds your messages, the agent’s replies, file checkpoints, and activity history.

Projects

A project stores a title, a workspace root path, a default model selection, and a set of optional runnable scripts (like test, build, lint). When you open DP Code, you see all your projects in the sidebar. Each project contains one or more threads.

Create a project

1

Open the new project dialog

Click the + icon in the sidebar, or use the New project action in the command palette.
2

Set a title and workspace root

Enter a name for the project and select the root directory of your codebase. DP Code uses this path as the working directory for all agent sessions in the project.
3

Choose a default model (optional)

Pick a provider and model that all new threads in this project will start with. You can override this per thread.
4

Save

Click Create project. The project appears in the sidebar and is ready for threads.

Threads

A thread is an individual session with an AI agent. Every thread belongs to a project and carries its own message history, agent session state, Git branch or worktree reference, and file checkpoints.

Thread environment modes

When you create a thread you choose how it interacts with the filesystem:
The agent runs directly in the project’s workspace root on the current branch. Changes made by the agent are immediately visible in your working tree. This is the default mode.
Use worktree mode when you want the agent to make sweeping changes without disturbing your current working tree, or when you are running two threads in parallel on the same project.

Open a thread

1

Select a project

Click a project in the sidebar to expand it and see its threads.
2

Create or resume a thread

Click New thread to start a fresh session, or click an existing thread to resume it exactly where you left off — messages, checkpoints, and all.
3

Send a message

Type in the composer at the bottom of the screen and press Enter. The agent starts a new turn and its response streams in above.

Thread lifecycle

StateWhat it means
idleThe thread has no active agent session.
startingA new agent session is being launched.
runningThe agent is processing a turn.
readyThe session is live and waiting for the next message.
interruptedA turn was stopped before it completed.
stoppedThe session was stopped cleanly.
errorThe session encountered an unrecoverable error.

Interrupting a turn

Click Stop (or press the stop button in the toolbar) at any point while the agent is running to send an interrupt signal. The agent finishes its current atomic step and pauses, leaving the thread in an interrupted state. You can then review what happened, revert to a checkpoint, or send a new message.

Reverting to a checkpoint

DP Code records a file checkpoint after each completed turn. To go back:
1

Open the thread's activity panel

Click the Activity tab on the right side of the thread view.
2

Find the checkpoint you want

Each completed turn shows a checkpoint badge with a list of changed files.
3

Revert

Click Revert to this checkpoint. DP Code restores the files to their state at that turn and trims the subsequent turns from the conversation.
Reverting removes all turns after the selected checkpoint from the thread’s history. This cannot be undone. Export your thread or create a fork if you want to keep the later work.

Compacting context

When a thread’s conversation grows very long, you can compact it to reduce the context sent to the model on each turn. Use the Compact option in the thread menu. Compaction is provider-dependent and not supported by all agents.

Approval policies

Each thread can be configured with an approval policy that controls how much autonomy the agent has when it needs to run commands or make changes:

untrusted

Every command and file change requires explicit user approval before the agent can proceed.

on-failure

The agent runs freely and only pauses to ask for approval when something goes wrong.

on-request

The agent runs freely and only pauses when it explicitly decides a decision is needed.

never

The agent never pauses for approvals — it has full autonomy for the session.

Sandbox modes

Sandbox modes set the boundaries of what the agent is allowed to do on the filesystem:
ModeWhat the agent can do
read-onlyRead files only. No writes or command execution.
workspace-writeRead and write files within the workspace root.
danger-full-accessUnrestricted access to the entire filesystem and all shell commands.
danger-full-access gives the agent full shell access. Only use it in isolated environments or when you fully trust the task you are running.

Slash commands in the composer

Type / in the composer to open the slash-command palette. Available commands depend on the active provider. Common commands include context inclusion, memory management, and provider-specific plan or review actions.
The slash-command list is populated at runtime by asking the active provider which commands it supports. If the palette is empty, the provider binary may not be running yet.

Build docs developers (and LLMs) love