Task Planner (To-Do)

One of the key features of AnyLLM is the agent's ability not just to execute commands, but to plan its actions when working on complex, multi-step tasks. This transforms it from a simple tool into a methodical assistant that thinks before it acts.

How It Works

When you give the agent a complex request, such as "build me an entire application," it no longer tries to solve it in a single impulsive operation. Instead, it:

  1. Decomposes the Task: The agent first breaks the large goal into small, manageable steps.
  2. Forms a Plan: It creates an internal To-Do list.
  3. Shows You the Plan: The agent informs you of the created plan, making its intentions completely transparent.
  4. Executes Step-by-Step: It begins to execute the task step by step, checking off completed items.

This makes the development process predictable, controllable, and significantly increases the chances of successfully completing complex assignments.

Example in Action

Let's see what this looks like in practice.

User's Request:

Create a full-featured CLI "todo-app" in PHP. First, create a plan of action.

Agent's Response and Actions:

• First run in session. Analyzing task...
• Task identified: User wants to create a full CLI 'todo-app' on PHP and requests a plan of action first.

I will create an action plan to build the "todo-app" CLI application in PHP.

// --- STEP 1: PLANNING ---
// The agent thinks and calls the internal add_todo tool for each step.

│ Internal: Task 'Create project structure (directories and files)' added to the to-do list.
│ Internal: Task 'Create data files (JSON for storing tasks)' added to the to-do list.
│ Internal: Task 'Develop application classes (Task, TaskManager, TodoApp)' added to the to-do list.
│ Internal: Task 'Implement CLI menu and command handling (add, list, done, delete, clear, help)' added to the to-do list.
│ Internal: Task 'Create the main executable file (index.php) to run the application' added to the to-do list.
│ Internal: Task 'Create a README.md file with usage instructions' added to the to-do list.

// --- STEP 2: DISPLAYING THE PLAN ---
// The agent shows you the created plan.

│ Internal: Current To-Do List:
- [ ] Create project structure (directories and files)
- [ ] Create data files (JSON for storing tasks)
- [ ] Develop application classes (Task, TaskManager, TodoApp)
- [ ] Implement CLI menu and command handling (add, list, done, delete, clear, help)
- [ ] Create the main executable file (index.php) to run the application
- [ ] Create a README.md file with usage instructions

The action plan for creating the "todo-app" CLI application in PHP is ready.
...
Starting execution of the plan.

// --- STEP 3: EXECUTION ---
// The agent proceeds to the first item on the plan and starts writing code.

### Step 1: Creating the project structure
🛠  Using tool: execute_shell_command
🛠  Using tool: write_file
... (creates the App/Models/Task.php file) ...

As you can see from the example, the agent first dedicated time to planning and only then, after getting a clear and implicitly approved plan, proceeded to execution.