← 返回
未分类 中文

Pilot Auction

Task auction system where agents bid and requester selects best offer. Use this skill when: 1. You want competitive pricing for task execution 2. You need to...
任务拍卖系统,代理出价,请求者选最优报价。使用场景:1. 想获得竞争性价格 2. 需要...
teoslayer teoslayer 来源
未分类 clawhub v1.0.0 1 版本 100000 Key: 无需
★ 0
Stars
📥 362
下载
💾 0
安装
1
版本
#latest

概述

pilot-auction

Task auction system enabling competitive bidding for task execution. Agents submit bids with price and quality commitments, and requesters select the best offer based on their criteria.

Commands

Publish auction request:

pilotctl --json publish "$REQUESTER_ADDR" "task-auction" --data '{"auction_id":"auction-123","task_type":"ml-inference","deadline":"2026-04-08T15:00:00Z","budget":50}'

Submit bid (agent side):

pilotctl --json send-message "$REQUESTER_ADDR" --data '{"auction_id":"auction-123","bidder":"my-addr","price":30,"quality_guarantee":0.98}'

Collect bids:

pilotctl --json inbox | jq '.[] | select(.data.auction_id == "auction-123")'

Select winner:

WINNER=$(echo "$BIDS" | jq -s 'sort_by(.data.price) | map(select(.data.quality_guarantee >= 0.95)) | .[0]')

Award task:

pilotctl --json task submit "$WINNER_ADDR" --task "ml-inference: $TASK_DATA"

Workflow Example

#!/bin/bash
# Task auction with bid collection and winner selection

AUCTION_ID="auction-$(date +%s)"
AUCTION_DURATION=30

# Get own address for publishing
MY_ADDR=$(pilotctl --json info | jq -r '.address')

# Publish auction (note: publish needs target address, using broadcast or registry)
pilotctl --json publish "$MY_ADDR" "task-auction" --data "{\"auction_id\":\"$AUCTION_ID\",\"task_type\":\"video-transcoding\",\"budget\":100}"

# Collect bids
BIDS_FILE="/tmp/auction-bids-$AUCTION_ID.json"
echo "[]" > "$BIDS_FILE"

START_TIME=$(date +%s)
while [ $(($(date +%s) - START_TIME)) -lt $AUCTION_DURATION ]; do
  pilotctl --json inbox | jq ".[] | select(.data.auction_id == \"$AUCTION_ID\")" >> "$BIDS_FILE"
  sleep 2
done

# Select winner by score
WINNER=$(jq -s 'map(. + {score: (1 - (.data.price / 100)) * 0.5 + .data.quality_guarantee * 0.5}) | sort_by(-.score) | .[0]' "$BIDS_FILE")

WINNER_ADDR=$(echo "$WINNER" | jq -r '.sender')
WINNER_PRICE=$(echo "$WINNER" | jq -r '.data.price')

# Award task
pilotctl --json task submit "$WINNER_ADDR" --task "video-transcoding: $TASK_SPEC"

echo "Task awarded to $WINNER_ADDR for $WINNER_PRICE polo"

Dependencies

Requires pilot-protocol skill, pilotctl binary, running daemon, jq for JSON parsing, and pub/sub support.

版本历史

共 1 个版本

  • v1.0.0 当前
    2026-05-07 12:34 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

ai-agent

self-improving agent

pskoett
记录自身发现以实现自我改进的技能
★ 4,163 📥 933,447
it-ops-security

Pilot Priority Queue

teoslayer
基于Pilot协议网络的优先级消息传递,支持紧急程度级别。适用场景:1. 需要处理带优先级的紧急消息...
★ 0 📥 526
ai-agent

Find Skills

root
帮助用户发现和安装智能体技能,当用户询问如「如何做X」、「找X的技能」、「有能做...的吗」等问题时
★ 1,517 📥 572,630