> For the complete documentation index, see [llms.txt](https://docs.walnutai.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.walnutai.ai/development-and-infrastructure/cloud-agent/task-assignment-execution-and-pr-management.md).

# Task Assignment, Execution, and PR Management

**Task Assignment Workflow:** Tasks are created directly from the Gap Analysis module, allowing for flexible distribution across your agents.

* **Creation:** Select the identified issues in Gap Analysis and click 'Create Task'.

<figure><img src="/files/gyzz4gCW54cSMkvTFgaS" alt=""><figcaption></figcaption></figure>

* **Assignment Types:**

  * Bulk Assign: Send all selected issues to a single agent for consolidated processing.

  <figure><img src="/files/6MI5Aq9Qa6WU7OMM9qMD" alt=""><figcaption></figcaption></figure>

  * Individual Assign: Distribute specific issues to different agents based on their workload or machine capacity.

  <figure><img src="/files/0znIEGzYFXfG8DQGxAZa" alt=""><figcaption></figcaption></figure>
* **Execution:** Once you click 'Create Task', the system wakes up the assigned agent. The agent pulls tasks from its queue, executes them sequentially, and returns to an Idle state once the queue is empty.

<figure><img src="/files/QuqWrhH5iOGFHwKnudOY" alt=""><figcaption></figcaption></figure>

**Live Code Execution Environment:** The system launches a real-time, browser-based environment on the cloud machine that functions like a high-performance IDE.

* Autonomous Progress: The editor automatically loads and begins the first task in the queue. You can watch the agent analyze files and apply code fixes in real time.
* Streamlined Logic: To maximize efficiency, this environment skips manual approval gates the system automatically approves and executes actions to maintain momentum.

**Pull Requests and Comment Resolution:** After completing a task, the agent automatically generates the required code changes and creates a Pull Request (PR) in the repository.

* For example, in Azure Repos, the Pull Request may be raised by the Walnut Cloud Agent, including the necessary code modifications and fixes identified during task execution.
* Users can add comments to the pull request. If feedback is provided, users can click Fix PR Comments. This allows the agent to review the comments and apply the necessary fixes to resolve the feedback.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.walnutai.ai/development-and-infrastructure/cloud-agent/task-assignment-execution-and-pr-management.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
