본문으로 건너뛰기
Skillpedia
에이전트11k · #11799

hive.colony-progress-tracker

하는 일

이 스킬은 AI 작업자가 작업을 맡고 공유 데이터베이스에 진행 상황을 기록하는 방법을 알려 줍니다. 여러 AI 작업자를 하나의 작업 대기열에서 운영하는 사람들을 위한 것입니다.

사용하는 경우

  • ✓AI 작업자에게 작업 ID나 사용할 데이터베이스 경로가 주어졌을 때.
  • ✓여러 작업자가 같은 작업을 맡지 않고 하나의 대기열을 나눠 써야 할 때.
  • ✓AI 작업자가 다음 단계로 넘어가기 전에 각 단계와 점검을 기록해야 하는 경우.

스킬 링크

https://github.com/aden-hive/hive/blob/main/core/framework/skills/_default_skills/colony-progress-tracker/SKILL.md

복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.

사용 방법

가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.

바로 붙여넣을 수 있는 메시지

Use this skill to help me: https://github.com/aden-hive/hive/blob/main/core/framework/skills/_default_skills/colony-progress-tracker/SKILL.md Read the SKILL.md file at that link and follow its instructions for my task.
AI가 이런 스킬을 알아서 찾아 쓰길 원하시나요?무료 Skillpedia MCP를 설치하세요. 한 줄이면 작업마다 스킬 15,000+개 중에서 검색합니다.1분 만에 설치 →

AI에게 요청하는 예시

“공유 대기열에서 다음 대기 중인 작업을 맡아 진행해 주세요. 각 단계를 끝낼 때마다 기록해 주시고요.”

매주 새 스킬 5개. 읽는 데 1분.

작동 방식

작업자는 작은 데이터베이스에서 작업 행을 맡고, 단계를 진행하면서 한 일을 기록합니다. 필수 점검도 함께 기록되므로 다른 작업자가 현재 상태를 볼 수 있습니다.

기술 내용 (원본 SKILL.md)

작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.

Operational Protocol: Colony Progress Tracker

Applies when your spawn message has db_path: and colony_id: fields. The DB is your durable working memory — tells you what's done, what to skip, which SOP gates you owe.

Access via terminal_exec running sqlite3 "<db_path>" "...". Tables: tasks (queue), steps (per-task decomposition), sop_checklist (hard gates).

Claim: assigned task (check this FIRST)

If your spawn message includes a task_id: field, the queen pre-assigned a specific row to you. Claim that row by id — do not use the generic next-pending pattern below:

sqlite3 "<db_path>" <<'SQL'
UPDATE tasks SET status='claimed', worker_id='<worker-id>',
  claim_token=lower(hex(randomblob(8))),
  claimed_at=datetime('now'), updated_at=datetime('now')
WHERE id='<task_id>' AND status='pending'
RETURNING id, goal, payload;
SQL

Empty output → another worker raced you or the row is already done. Stop and report. Non-empty → that row is yours, proceed to "Load the plan".

Claim: next pending (fallback when no task_id is assigned)

If your spawn message did NOT include task_id: — you are a generic fan-out worker racing on a shared queue. Use the generic next-pending claim:

sqlite3 "<db_path>" <<'SQL'
UPDATE tasks SET status='claimed', worker_id='<worker-id>',
  claim_token=lower(hex(randomblob(8))),
  claimed_at=datetime('now'), updated_at=datetime('now')
WHERE id=(SELECT id FROM tasks WHERE status='pending'
  ORDER BY priority DESC, seq, created_at LIMIT 1)
RETURNING id, goal, payload;
SQL

Empty output → queue drained, exit. Otherwise the returned id is yours. Never SELECT-then-UPDATE — races.

Load the plan

sqlite3 "<db_path>" "SELECT seq, id, title, status FROM steps WHERE task_id='<task-id>' ORDER BY seq;"
sqlite3 "<db_path>" "SELECT key, description, required, done_at FROM sop_checklist WHERE task_id='<task-id>';"

Skip any step where status='done'. That's the point — don't redo completed work.

Execute a step

Before tool calls:

sqlite3 "<db_path>" "UPDATE steps SET status='in_progress', worker_id='<worker-id>', started_at=datetime('now') WHERE id='<step-id>';"

After success (one-line evidence: path, URL, key result):

sqlite3 "<db_path>" "UPDATE steps SET status='done', evidence='<what you did>', completed_at=datetime('now') WHERE id='<step-id>';"

MANDATORY: SOP gate check before marking task done

sqlite3 "<db_path>" "SELECT key, description FROM sop_checklist WHERE task_id='<task-id>' AND required=1 AND done_at IS NULL;"
  • Empty → proceed to "Mark task done".
  • Non-empty → each row is work you still owe. Do it, then check it off:
sqlite3 "<db_path>" "UPDATE sop_checklist SET done_at=datetime('now'), done_by='<worker-id>', note='<why>' WHERE task_id='<task-id>' AND key='<key>';"

Never mark a task done while this SELECT returns rows. This gate exists specifically to stop you from declaring success while skipping required steps.

Mark task done / failed

# Success:
sqlite3 "<db_path>" "UPDATE tasks SET status='done', completed_at=datetime('now'), updated_at=datetime('now') WHERE id='<task-id>' AND worker_id='<worker-id>';"

# Unrecoverable failure:
sqlite3 "<db_path>" "UPDATE tasks SET status='failed', last_error='<one sentence>', completed_at=datetime('now'), updated_at=datetime('now') WHERE id='<task-id>' AND worker_id='<worker-id>';"

The AND worker_id=? guard means a reclaimed row won't accept your write — treat zero rows affected as "your claim was revoked, stop."

Loop

After done/failed → claim the next task. Exit only when claim returns empty.

Errors + debug

  • "database is locked": retry with 100ms → 1s backoff, max 5 attempts. busy_timeout=5000 handles most contention silently.
  • Queue health: SELECT status, count(*) FROM tasks GROUP BY status;
  • Your in-flight work: SELECT id, goal, status FROM tasks WHERE worker_id='<worker-id>';

Anti-patterns (will break the queue)

  • Don't DDL (CREATE/ALTER/DROP).
  • Don't DELETE — failed tasks stay as failed for audit.
  • Don't skip Protocol 4 (SOP gate) before marking done.
  • Don't hold a task >15min without updates — the stale-claim reclaimer revokes your claim.
  • Don't invent task IDs. Workers update existing rows; only the queen enqueues new ones.
자주 묻는 질문

데이터베이스는 무엇에 쓰이나요?

작업 대기열, 각 작업의 단계, 통과해야 하는 점검 내용을 저장합니다.

두 작업자가 같은 작업을 시도하면 어떻게 되나요?

대기 중인 작업은 한 명만 맡을 수 있으며, 다른 작업자는 멈추고 그 사실을 보고합니다.

누구를 위한 것인가요?

공유 작업 목록으로 colony 방식의 AI 작업자를 운영하는 사람들을 위한 것입니다.

상세 정보

작성자의 원본 설명

Claim tasks, record step progress, and verify SOP gates in the colony SQLite queue. Applies when your spawn message includes a db_path field.

repo: aden-hive/hive

인기도

GitHub 스타
11k
순위
#11799
라이선스
Apache-2.0
업데이트
2026. 11. 2.

이 스킬이 유용한가요?

0

로그인 투표하려면 로그인하세요.

댓글

  • …

이 저장소의 다른 스킬

비슷한 스킬