deploy-autonomous
Working in the deploy-autonomous GitHub template repo — agent harness, identity layer, Venice provider, safety modules, and the create-identity CLI.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Working in the deploy-autonomous GitHub template repo — agent harness, identity layer, Venice provider, safety modules, and the create-identity CLI.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
Decide how to allocate DIEM between Venice compute staking, WETH swap for x402 API access, Uniswap LP, and Aerodrome LP. Run once per tick before any capital movement.
Read all agent on-chain positions via the check-portfolio.ts script. Use this instead of raw curl/cast calls to avoid hex encoding mistakes.
Claim DIEM from FeeLocker, run accumulate-vs-build analysis, and route earnings to LP or Venice staking. Scheduled every 12 hours via aeon. DRY-RUN BY DEFAULT — pass --live to execute.
Launch a Liquid Protocol token with a LiquidPresaleVault presale. STAKE MODE ONLY (policy 2026-06-12) — depositors lock DIEM and always get it back; allocation is lock-to-earn. One vault per launch, 10% of supply, 60d default lock.
Proactive health check — skill failures, LP state, memory flags, FeeLocker balance. Run 3× daily to surface issues before they compound.
Mint a single-sided DIEM LP position in the ETH/DIEM Uniswap v3 1% pool on Base. Use when reinvesting claimed DIEM fees in accumulate mode.
基于 SOC 职业分类
| name | deploy-autonomous |
| description | Working in the deploy-autonomous GitHub template repo — agent harness, identity layer, Venice provider, safety modules, and the create-identity CLI. |
This is the GitHub template (Liquid-Protocol-Ops/deploy-autonomous) that every autonomous Claude Code agent repo is generated from. Changes here ship into every per-agent repo on next sync. Always consider downstream effects before editing shared harness code.
harness/tick.ts)One execution per scheduled run (GitHub Actions). Flow per tick:
stakeThresholdmemory/venice-bearer.json){ needs_reasoning, task, rationale } JSONneeds_reasoning: trueRun locally: npm run harness:tick
harness/providers/venice.ts)loadConfig() — reads env vars, returns VeniceConfiggetClaimable() — reads FeeLocker availableFeesgetStakedBalance() — reads sVVV balance on VVV staking contractclaimDiem() — calls FeeLocker claim, returns tx hashloadOrMintBearer() — env fast path (VENICE_API_KEY) → disk cache → autonomous mint (GET+POST /api_keys/generate_web3_key)callInference() — POST /chat/completions, logs cost in DIEM to memory/tool-routing.jsonlFAST_MODEL = 'llama-3.3-70b', REASONING_MODEL = 'claude-opus-4-7'harness/safety/)allowlist.ts — assertAllowed(path) before any agent write. Agent may only write to identity/SOUL.md, identity/STYLE.md, memory/**, wiki/**. Everything else is off-limits.wallet.ts — Signer + TxSender interfaces. Two implementations: loadSignerFromPrivy/makeTxSenderFromPrivy (primary, headless server wallet) and loadSignerFromEnv/makeTxSenderFromEnv (fallback for local testing).harness/observability/tool-routing.ts)Appends JSONL entries to memory/tool-routing.jsonl on every inference call:
{ "ts":"...", "provider":"venice", "variant":":claude-opus-4-7", "cache_hit":false, "latency_ms":1200, "tokens":{"input":500,"output":200}, "cost_usd":0, "cost_diem":0.027 }
identity/)Three genesis-locked files (hard-locked at deploy) + three mutable working copies (drift-bounded at 0.70 Jaccard similarity by lint):
SOUL.genesis.md / SOUL.md — who the agent is, beliefs, constraintsSTYLE.genesis.md / STYLE.md — voice register, verbal moves, formatinfluences.md — lineage record (parent agent, authored sources, influences)Template files (*.template) are instantiated by the deploy CLI.
scripts/create-identity.ts)node --import tsx scripts/create-identity.ts <config.json> [--target <dir>] [--force]
Reads identity/*.template files, substitutes {{placeholders}} from JSON config, writes genesis files, derives mutable copies (byte-identical body, flipped genesis_lock, removed drift_threshold), runs lint to verify. Used to instantiate per-agent identity at deploy time.
scripts/lint-identity.ts)npm run lint:identity
LINT_REPO_ROOT=/path/to/agent npm run lint:identity # against a different repo
Checks: frontmatter required keys, ISO-8601 dates, controlled tags, sources coupling, drift threshold (Jaccard ≥ 0.70), broken [[internal links]], blockquote word cap (≤ 25 words).
| Var | Required | Purpose |
|---|---|---|
DIEM_TOKEN_ADDRESS | yes | Liquid Protocol DIEM ERC-20 on Base |
VVV_STAKING_ADDRESS | yes | Venice VVV staking contract (sVVV balance) |
RPC_URL | yes | Base mainnet JSON-RPC |
PRIVY_APP_ID | yes (primary) | Privy server wallet app |
PRIVY_APP_SECRET | yes (primary) | Privy server wallet secret |
PRIVY_WALLET_ID | yes (primary) | Agent's Privy wallet ID |
AGENT_PRIVATE_KEY | fallback only | Raw key for local testing |
VENICE_API_KEY | optional | Skip autonomous key mint (MVP fast path) |
VENICE_STAKE_THRESHOLD | optional | Min sVVV wei (default: 1e18) |
Never commit .env. Secrets come from your secrets manager.
npm run typecheck # tsc --noEmit strict
npm test # vitest run
npm run lint:identity # identity/ validation
npm run harness:tick # run one tick locally
npx vitest run harness/safety/__tests__/allowlist.spec.ts # single test file
Superseded (do not implement): WETH pairing, Privy embedded wallets, platform Venice account, bare .env private key as primary wallet.
The agent operates in one of two modes determined by daily DIEM fee rate vs threshold:
Target LP pool: ETH/DIEM Uniswap v3 1% on Base (655.91% APR as of 2026-05-14). Strategy: single-sided DIEM, tickLower = currentTick, tickUpper = currentTick + N * 200 (tick spacing 200 for 1% tier).
harness/providers/liquidity.ts): increaseLiquidity on ETH/DIEM v3 poolscripts/stake-vvv.ts — stake VVV to unlock Venice API key mint