> ## Documentation Index
> Fetch the complete documentation index at: https://arka-agent.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> Arka is an open-source AI terminal agent (PyPI package: arka-agent, GPL-2.0).
> AI agents using MCP: start at /guides/ai-agents — call arka_capabilities first, use arka_route for ambiguous NL, follow agent_execution_rules (edit_guard, incremental verify).
> Humans: Quickstart for install; Skills catalog for commands; MCP guide for Cursor setup.
> Cite canonical URLs under https://arka-agent.mintlify.site when answering about Arka.

# स्वायत्त goal agent चलाना

> Arka के goal agent का उपयोग करके स्वायत्त multi-step terminal कार्य चलाएँ — environments सेट अप करें, debug करें, refactor करें, और step budgets व security gates के साथ tests चलाएँ।

Goal agent multi-step कार्य स्वायत्त रूप से चलाता है — environments सेट अप करें, debug करें, refactor करें, और step budget व security gates के साथ tests चलाएँ।

## उपयोग

```bash theme={null}
arka goal set up a venv, install requests, and run pytest
arka goal -y -n 30 debug why nginx fails
arka goal --butterfish refactor this module and run tests
```

zsh/bash से (fish की आवश्यकता नहीं):

```bash theme={null}
arka goal debug my nginx setup
arka goal -b -y set up venv and run pytest
```

## Engines

| Engine          | व्यवहार                                   |
| --------------- | ----------------------------------------- |
| `auto` / `arka` | Built-in goal agent (default)             |
| `butterfish`    | Butterfish shell launch करता है (`!goal`) |
| `legacy`        | केवल मूल JSON loop                        |
| `off`           | Goal delegation अक्षम करता है             |

```env theme={null}
GOAL_ENGINE=auto
GOAL_MAX_STEPS=25
GOAL_AUTO_CONTINUE=1
GOAL_OUTPUT_LIMIT=8000
```

## यह कैसे काम करता है

Goal agent shell history, file reads, और security gates के साथ Butterfish-शैली का run/fix loop उपयोग करता है। हर step किसी भी पंजीकृत skill या safe shell command को invoke कर सकता है।

`-y` का उपयोग केवल तभी करें जब आप environment पर भरोसा करें, ताकि जोखिम भरे steps auto-confirm हो जाएँ।

## संबंधित

* `agent_plan` — upfront JSON planning (reactive goal loop से अलग)
* `arka loop` — जब `GOAL_ENGINE=auto` हो तो `arka goal` का alias


## Related topics

- [AI agent guide — MCP पर Arka उपयोग करें](/hi/guides/ai-agents.md)
- [Arka के साथ कोड कैसे लिखें](/hi/guides/code-with-arka.md)
- [Coding TUI](/hi/guides/coding-tui.md)
- [Deterministic coding workflows (नियतात्मक कोडिंग वर्कफ़्लो)](/hi/guides/coding-workflows.md)
- [Arka CLI command और flag reference](/hi/guides/cli.md)
