Логотип Autonomous Loops

Autonomous Loops

Спільнота
brucesongs
autonomous-loops

Performing repetitive enumeration across many targets - Running batch vulnerability scans on multiple hosts - Monitoring for changes in target environment - Executing attack chains that require iterative steps - User says "loop", "automate", "batch", "repeat.

Add to TypingMind

Огляд

Видавецьbrucesongs
Репозиторійkali-claw
Назва навичкиautonomous-loops
Зірки
70
Форки
18
Файли в пакеті
17
ЛіцензіяMIT
Посилання
  • Інструкції у форматі Markdown

    Файл SKILL.md, який модель завантажує за потреби, тож токени витрачаються лише тоді, коли запит справді відповідає навичці.

  • Працює з будь-якою LLM

    Навички ШІ — це звичайний Markdown, а не код для певного постачальника, тому вони працюють із GPT, Claude, Gemini, Grok або локальною моделлю.

  • Файлів у комплекті: 17

    Скрипти, шаблони й довідкові матеріали, які модель може читати під час роботи. Файли доступні лише для читання й ніколи не виконуються.

  • Відкритий вихідний код

    Видавець на GitHub: brucesongs. Перед установленням перегляньте вихідні файли навички.

Встановлення

Установіть навичку ШІ Autonomous Loops у TypingMind, щоб використовувати її з будь-якою LLM, або додайте її до іншого агента, що читає SKILL.md.

1

Встановити в TypingMind

TypingMind встановлює навичку безпосередньо з її папки на GitHub — читає SKILL.md, збирає файли ресурсів у пакет і зберігає результат локально.

  1. Відкрийте застосунок і перейдіть до розділу «Плагіни» → «Навички».
  2. Виберіть «Встановити з GitHub».
  3. Вставте наведений нижче URL папки навички та підтвердьте встановлення.
    https://github.com/brucesongs/kali-claw/tree/main/skills/autonomous-loops
  4. Увімкніть навичку в кожному чаті, де хочете її використовувати.
Плагіни → Навички → Додати навичку → За URL GitHub, потім вставте URL папки й натисніть «Продовжити».
2

Встановити в іншому агенті

Будь-який агент, що підтримує формат Agent Skills, може використовувати цю навичку — скопіюйте папку до каталогу навичок цього агента.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/brucesongs/kali-claw.git /tmp/kali-claw
mkdir -p .claude/skills
cp -r /tmp/kali-claw/skills/autonomous-loops .claude/skills/autonomous-loops
Після копіювання перезапустіть Claude Code, щоб завантажити нову навичку.

Використовуйте навичку в TypingMind

Увімкніть навичку Autonomous Loops в будь-якому чаті TypingMind, і далі модель усе зробить сама. Назва й опис навички містяться в системному промпті, а щойно надходить відповідний запит, модель самостійно завантажує повні інструкції — вам не потрібно викликати навичку вручну, і до фактичного використання вона не витрачає токенів.

Модель самостійно завантажує навичку Autonomous Loops, щойно надходить відповідний запит.

Працює з будь-якою моделлю ШІ

Навички ШІ — це звичайні інструкції у форматі Markdown, а не код для певного постачальника, тому навичка Autonomous Loops не прив’язана до моделі, для якої її створено. Установіть її один раз у TypingMind і використовуйте з GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama або локальною моделлю, яку ви запускаєте самостійно, — усе з вашими власними ключами API.

  • Завантажується лише за потреби

    Системний промпт містить лише назву й опис. Інструкції завантажуються за першого відповідного запиту, тож поки навичка не потрібна, токени на її інструкції не витрачаються.

  • Змінюйте моделі під час чату

    Оскільки навичка — це інструкції, а не код, зміна моделі не порушує її роботу: наступна модель читає той самий файл SKILL.md.

Інструкції навички

Це вміст файлу SKILL.md, який завантажує модель. Прочитайте його перед установленням — навичка містить інструкції, яких дотримуватиметься ваша модель.

Autonomous Loops

Supplementary Files:

  • payloads.md — Scope Lock templates, rate limit configurations, loop command templates, and error handling response templates
  • test-cases.md — Structured test cases for sequential pipeline, watch loop, batch processing, learning cycle, scope violation, and rate limit backoff
  • guides/safe-autonomous-pentest.md — Deep-dive guide on autonomous vs manual decision making, scope lock construction, loop composition, and monitoring

Summary

Autonomous Loops skill domain covering infrastructure operations.

Domain: infrastructure

Use Cases

  1. Sequential Pipeline — Chain multiple security tools in order (recon → scan → exploit) with automatic phase transitions
  2. Watch Loop — Monitor a target for changes (new ports, updated services) over extended periods
  3. Batch Processing — Run the same test against multiple targets with rate limiting and error recovery
  4. Learning Cycle — Execute a skill, capture results, extract patterns, and update knowledge base automatically
  5. Scope-Locked Automation — Run autonomous loops with hard boundaries that prevent actions outside authorized scope

Activation

  • Performing repetitive enumeration across many targets
  • Running batch vulnerability scans on multiple hosts
  • Monitoring for changes in target environment
  • Executing attack chains that require iterative steps
  • User says "loop", "automate", "batch", "repeat", "iterate"

Core Principle

Autonomous does not mean uncontrolled. Every loop must have:

  1. A defined scope (what it can and cannot touch)
  2. A termination condition (when it stops)
  3. Rate limiting (how fast it runs)
  4. Evidence logging (what it did)
  5. Error handling (what happens when things go wrong)

Four Loop Patterns

Pattern 1: Sequential Pipeline

Execute a sequence of steps across multiple targets, one at a time.

FOR EACH target IN target_list:
    IF scope_check(target) == ALLOWED:
        result = execute_step(target)
        log_evidence(target, result)
        IF result.status == FAIL:
            handle_error(target, result)
            CONTINUE or BREAK based on severity
    ELSE:
        log_skipped(target, "Out of scope")

Use when: Enumerating ports across a subnet, testing a specific vulnerability across multiple hosts.

Safety rules:

  • Process targets sequentially (no parallel burst)
  • Log every target attempted and result
  • Stop on critical error (target down, IDS triggered)
  • Maximum 100 targets per pipeline run

Pattern 2: Watch Loop

Monitor a target for changes or conditions, then act when triggered.

WHILE condition_not_met AND iterations < max_iterations:
    current_state = observe(target)
    log_observation(current_state)
    IF trigger_condition(current_state):
        result = execute_response(target, current_state)
        log_evidence("trigger", result)
        IF one_shot: BREAK
    WAIT(polling_interval)

Use when: Waiting for a service to come online, monitoring for new open ports, watching log files for specific events.

Safety rules:

  • Polling interval minimum: 5 seconds
  • Maximum iterations: 1000
  • Log every observation cycle
  • Alert when approaching iteration limit

Pattern 3: Batch Processing

Apply the same operation to a batch of targets in parallel (with concurrency limit).

CONCURRENCY = 5  # Maximum simultaneous operations
results = []

FOR EACH batch IN split_into_batches(target_list, CONCURRENCY):
    batch_results = PARALLEL execute_step(batch)
    FOR EACH result IN batch_results:
        log_evidence(result.target, result)
        results.append(result)
    WAIT(rate_limit_delay)  # Pause between batches

Use when: Running nmap scans across many hosts, batch DNS lookups, mass HTTP header checks.

Safety rules:

  • Maximum concurrency: 10
  • Rate limit delay between batches: 2 seconds minimum
  • Log all results including failures
  • Respect target-specific rate limits if known

Pattern 4: Learning Cycle

Iteratively refine an approach based on results from previous iterations.

approach = initial_approach
FOR iteration IN range(max_iterations):
    result = execute(approach)
    analysis = analyze_result(result)
    log_evidence(iteration, approach, result, analysis)
    IF analysis.success:
        log_evidence("success", approach)
        BREAK
    approach = refine(approach, analysis)
    IF approach.confidence < min_confidence:
        log_evidence("abort", "Confidence below threshold")
        BREAK

Use when: Brute-forcing with adaptive wordlists, SQL injection payload refinement, fuzzing with feedback.

Safety rules:

  • Maximum iterations: 50
  • Log every attempt and result
  • Confidence threshold: abort if below 10% after 10 attempts
  • Never widen scope during refinement

Safety Framework

Scope Lock

Before ANY loop starts, define and lock the scope:

markdown
## Scope Lock: [Operation Name]
- **Allowed targets:** [CIDR range / hostname list / URL list]
- **Allowed operations:** [Specific commands/techniques]
- **Forbidden operations:** [What must NOT be done]
- **Time limit:** [Maximum wall-clock time]
- **Iteration limit:** [Maximum number of iterations]
- **Abort conditions:** [Specific triggers that stop the loop]

Once defined, the scope cannot be widened during execution.

Rate Limiting

Operation TypeMinimum IntervalMax Concurrency
Network scan (nmap)2s between hosts5
Web request (HTTP)100ms between requests3
DNS lookup50ms between queries10
Brute force attempt500ms between attempts1
Exploit attempt5s between attempts1

Evidence Logging

Every loop iteration must log:

markdown
## Loop Log Entry
- **Timestamp:** [ISO 8601]
- **Iteration:** [N / max]
- **Target:** [host/port/URL]
- **Action:** [command or technique]
- **Result:** [success/fail/error/timeout]
- **Output:** [truncated to 500 chars, full output saved to file]
- **State change:** [what changed on target, if any]

Error Handling

Error TypeResponse
Target unreachableLog and skip, continue to next target
Rate limit detectedIncrease delay by 2x, retry once
Authentication failureLog and skip (do NOT retry with variations)
Unexpected service responseLog details, flag for manual review, continue
IDS/IPS detectedSTOP immediately, log incident
Target crash/unexpected downtimeSTOP immediately, log incident
Scope violation attemptSTOP immediately, log incident

Notification Rules

Notify the operator when:

  • Loop starts (with scope summary)
  • Every 25 iterations or 5 minutes (whichever comes first)
  • Any error condition occurs
  • Loop completes or aborts

Integration with Other Skills

SkillLoop PatternApplication
vulnerability-assessmentBatch ProcessingScan multiple hosts for vulnerabilities
password-attackLearning CycleAdaptive brute force with feedback
web-sqliLearning CycleIterative payload refinement
network-pentestSequential PipelineMulti-host enumeration
osintBatch ProcessingMass DNS/WHOIS lookups
terminal-opsAll patternsEvidence logging protocol
verification-loopSequential PipelineVerify findings across multiple hosts
safety-guardAll patternsPre-execution safety checks

Detection Methods

Autonomous Loop Indicators

  • Sustained agent activity: Same agent token executing >100 sequential operations; >24h continuous runtime.
  • Tool call cadence: Constant-interval tool calls (e.g., every 30s exactly); typical of cron-driven loops.
  • State persistence: Agent re-loading state from previous session; checkpoint file access patterns.
  • Memory growth: Agent process accumulating >2GB RAM; typical of long-running loops without state cleanup.
  • Self-modifying prompts: Agent modifying its own system prompt or configuration mid-run.

SIEM Detection Rules

  • Splunk SPL: index=llm gateway.user="agent-*" | stats range(_time) as duration by session_id | where duration > 86400
  • Sigma rule: sigma/rules/ai/long_running_agent.yml
  • LangSmith trace analysis: Detect agents with >1000 turns in single session.

Defense Evasion Techniques

Loop Stealth

  • Off-hours operation: Run loops during low-traffic hours; blends with maintenance tasks.
  • Distributed sessions: Cycle through multiple agent sessions to avoid per-session limits.
  • Memory cleanup between cycles: Clear conversation history to reduce token usage anomaly.
  • Slow pacing: Pace tool calls at irregular intervals to avoid cadence detection.
  • State externalization: Store state in external KV store rather than session memory.

Self-Modification Stealth

  • Gradual config changes: Modify system prompt in small increments over multiple sessions.
  • Use environment variables: Modify env vars rather than prompts (less audited).
  • Persistence via legitimate mechanisms: Use MCP server registration (looks legitimate).

Anti-Patterns

  • Infinite loops — Every loop MUST have a termination condition
  • Scope creep — Never add targets during execution
  • Silent failures — Every error must be logged and reported
  • Unbounded parallelism — Always set and respect concurrency limits
  • Skipping evidence — Even failed attempts must be logged
  • Ignoring rate limits — Target stability is more important than speed

Orchestration

ECC Loop Pattern

  • Pattern: Meta-Skill (defines loop patterns consumed by all other skills)
  • Rationale: Autonomous loops is not an end-user skill but a meta-skill that provides loop constructs for all other security skills — every skill that needs iterative or batch operations consumes one of the four loop patterns
  • Integration: All security skills that need repetitive operations consume loop patterns from this skill. Each skill selects the appropriate pattern based on its workflow needs.

Cross-Skill Pipeline

autonomous-loops (provides loop patterns)
    ├── Sequential Pipeline → network-pentest, terminal-ops, verification-loop
    ├── Watch Loop → security-bounty-hunter, deep-research
    ├── Batch Processing → repo-scan, osint, vulnerability-assessment
    └── Learning Cycle → search-first, continuous-learning, password-attack

Quality Gate

  • Pre-condition: Scope Lock defined with allowed targets, operations, and abort conditions
  • Post-condition: Evidence chain complete for every iteration, all results logged
  • Verification: Scope not widened during execution, iteration/iteration limits respected, rate limits maintained

Файли в пакеті

Модель читає ці файли за потреби, поки навичку завантажено. Вони доступні для читання й ніколи не виконуються.

Поширені запитання

Що робить навичка ШІ Autonomous Loops?

Performing repetitive enumeration across many targets - Running batch vulnerability scans on multiple hosts - Monitoring for changes in target environment - Executing attack chains that require iterative steps - User says "loop", "automate", "batch", "repeat.

Навіщо використовувати Autonomous Loops у TypingMind?

Тому що ви встановлюєте її один раз і використовуєте з будь-якою моделлю. Autonomous Loops — це звичайний Markdown, а не код для конкретного постачальника, тому та сама навичка працює з GPT-5, Claude, Gemini, Grok або локальною моделлю. Ви можете змінити модель навіть посеред чату, і навичка продовжить працювати. TypingMind використовує ваші власні ключі API, тож ви платите безпосередньо постачальникам замість передплати за кожне місце користувача, а ваші навички й чати залишаються у вашому сховищі.

Як встановити Autonomous Loops у TypingMind?

Відкрийте в TypingMind Плагіни → Навички → Встановити з GitHub і вставте https://github.com/brucesongs/kali-claw/tree/main/skills/autonomous-loops. TypingMind прочитає файл SKILL.md, додасть супровідні файли та встановить навичку, яку можна вмикати окремо для кожного чату.

Які моделі ШІ можуть використовувати Autonomous Loops?

Будь-яка модель, яку ви підключите в TypingMind. Навички ШІ — це звичайні інструкції у форматі Markdown, а не код для конкретного постачальника, тому GPT, Claude, Gemini, Grok і локальні моделі можуть завантажувати цю навичку, коли запит їй відповідає.

Зі скількома моделями ШІ можна використовувати Autonomous Loops?

Зі скількома забажаєте. У TypingMind ви можете використовувати Autonomous Loops із будь-якою моделлю, яка підтримує навички, зокрема з GPT, Claude, Gemini, Grok, DeepSeek, Mistral чи Llama. Для цього ви використовуєте власні ключі API.

Чи безкоштовна навичка ШІ Autonomous Loops?

Так. На GitHub цю навичку публікує brucesongs за ліцензією MIT. Ви платите лише своєму постачальнику ШІ за використані токени.

Що таке навички ШІ?

Навичка ШІ — це набір інструкцій для повторного використання, який навчає модель ШІ виконувати одне конкретне завдання. Він відповідає відкритому формату Agent Skills: файл SKILL.md із назвою та описом, а також скрипти, шаблони чи довідкові файли, які можуть знадобитися моделі. Модель читає інструкції лише тоді, коли ваш запит відповідає навичці, тому встановлена навичка нічого не коштує, доки її не використано.

Чим навички ШІ відрізняються від плагінів або серверів MCP?

Плагін або сервер MCP надає моделі нові інструменти, які вона може викликати, — код, який десь виконується й повертає результат. Натомість навичка ШІ дає моделі знання й пояснює порядок дій: як підійти до завдання, яких кроків дотримуватися та яким має бути якісний результат. Навички — це звичайний Markdown, тож їм не потрібні ні сервер, ні ключ API, ні середовище виконання, і вони працюють із будь-якою моделлю.

Усі

Створіть власний робочий простір зі ШІ вже зараз

Підпишіться на нашу розсилку, щоб дізнаватися про нові функції та майбутні розіграші 👇