Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add skills/vmehera123/leashd/debug-tasknpx skills add vmehera123/leashd --skill debug-taskgit clone --depth 1 https://github.com/vmehera123/leashdWhat it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00051 | $0.05370 |
| Opus 5 | $0.00026 | $0.02685 |
| Sonnet 5 | $0.00010 | $0.01074 |
| Haiku 4.5 | $0.00005 | $0.00537 |
Grade A, and why
debug-task scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 474 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Debugging Autonomous Tasks
Data sources
| Surface | Location | Content |
|---|---|---|
| Task runs | ~/.leashd/sessions.db → task_runs table |
Phase state, outcome, costs, context, pipeline, timestamps (24 columns) |
| Sessions | ~/.leashd/sessions.db → sessions table |
mode, task_run_id link back to task_runs |
| Audit log | <approved_directories[0]>/.leashd/audit.jsonl (pinned/centralized) |
Tool-gating decisions (allow/deny/require_approval), all sessions |
| App logs | {working_directory}/.leashd/logs/app.log |
Structured events: task_phase_changed, task_phase_error, task_terminal, etc. |
| Messages | ~/.leashd/messages.db (centralized) |
Agent messages during the task's session |
audit.jsonl is centralized, not per-working-directory. Since v0.9.0 it is pinned to
approved_directories[0](the first entry in~/.leashd/config.yaml) — NOT{working_directory}/.leashd/audit.jsonl, which will look stale for any task that ran outside that dir. The audit queries below resolve the pinned path automatically.
$ARGUMENTS is the task_id — full 16-char hex or first 8 chars from /tasks output.
Tasks may have run under v2 (LLM-driven think-act-observe, phases include
explore/plan/retry) or v3 (linearplan → implement → verify → review). Checkphase_pipelinein Step 1 to tell which.
Quick diagnosis (run all 5 steps)
Step 1: Load task state
Query task_runs by run_id. Try exact match first, then prefix match.
uv run python -c "
import sqlite3, pathlib, sys, json
db = pathlib.Path.home() / '.leashd' / 'sessions.db'
if not db.exists():
print('ERROR: sessions.db not found at', db)
sys.exit(1)
conn = sqlite3.connect(str(db))
conn.row_factory = sqlite3.Row
tid = '$ARGUMENTS'.strip()
if not tid:
print('No task_id provided. Listing recent tasks...')
for r in conn.execute('SELECT run_id, phase, outcome, task, created_at, total_cost FROM task_runs ORDER BY created_at DESC LIMIT 20'):
d = dict(r)
d['task'] = d['task'][:80]
print(d)
sys.exit(0)
# Exact match
row = conn.execute('SELECT * FROM task_runs WHERE run_id = ?', (tid,)).fetchone()
if not row:
# Prefix match
row = conn.execute('SELECT * FROM task_runs WHERE run_id LIKE ?', (tid + '%',)).fetchone()
if not row:
print(f'No task found matching: {tid}')
sys.exit(1)
d = dict(row)
# Pretty-print key fields
for k in ['run_id','phase','previous_phase','outcome','error_message','retry_count','max_retries',
'created_at','started_at','phase_started_at','completed_at','last_updated',
'total_cost','working_directory','session_id','user_id','chat_id','task']:
print(f'{k:>20}: {d.get(k)}')
print(f\"{'phase_pipeline':>20}: {json.loads(d.get('phase_pipeline','[]'))}\")
print(f\"{'phase_costs':>20}: {json.loads(d.get('phase_costs','{}'))}\")
"
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 2d ago First seen · 474 lines · 51 tokens per session scan A ef8ddbc56ad1
debug-task is a skill published in the GitHub repository vmehera123/leashd (5 stars, last pushed 7d ago), licensed Apache-2.0. It adds 51 tokens to every session and 5,370 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other skills, from other repositories
orloj-generator
Interactive scaffold generator for Orloj multi-agent systems. Use this skill whenever someone wants to create, set up, scaffold, bootstrap, or generate an Orloj agent system, pipeline, swarm, or hierarchy. Also trigger when users mention "orlojctl init", ask how to get started with Orloj, want to build a multi-agent…
air-blackbox-sales-agent
AIR Blackbox's autonomous sales prospecting agent. Finds Python AI projects on GitHub that need EU AI Act compliance, identifies the right person to contact (CEO, CTO, lead maintainer), runs a free compliance scan, and drafts personalized outreach emails that convert to engagement. The sales flow: free scan as the…
interpret-results
Interprets AIR Blackbox scan results and maps findings to specific EU AI Act articles, recitals, and remediation steps. Use when the user has scan output and wants to understand what to fix, why it matters, or how to prioritize.
compliance-scan
Scans a Python AI project for EU AI Act compliance gaps using AIR Blackbox. Use when the user asks to check compliance, scan their code, audit their AI project, or mentions EU AI Act, Articles 9-15, or compliance checking.
writing-plan-docs
Write planning documents for new permit0 features, integrations, or significant changes. Use when the user asks to plan, design, spec, or write a plan for a new integration, pack, feature, or architectural change in the permit0 repository.
reviewing-plan-docs
Review planning documents by reading the plan docs and doing a thorough codebase walkthrough, then writing detailed review docs. Use when the user asks to review, audit, critique, or validate a plan, design doc, or spec in the permit0 repository.