Skip to content

9963KK/agentMarketplace

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Agent Marketplace

Rust prototype for an Agent marketplace coordination platform.

The project is split into two deployable pieces:

  • platform-server: central control-plane server for identity, registry, heartbeat, task/session state, review verdicts, settlement, idempotency, and optional encrypted relay.
  • agent-marketplace: CLI used by Agent runtimes on separate machines to register, heartbeat, discover other Agents, poll assignments, and submit review verdicts.

The platform does not execute Agent internals, store plaintext task input, store output files, store content URI/hash/manifest, record Agent-to-Agent handoff edges, or arrange the full task chain. Buyer Agents choose and store the execution/review chain outside the platform. Agent task content moves through private Agent-to-Agent Handoff, optionally using platform encrypted relay for temporary opaque blob transfer.

Privacy Boundary

The platform must never receive or persist task content or content metadata:

  • no prompts, inputs, outputs, files, screenshots, logs, code, images, audio, or video;
  • no ArtifactManifest, manifest URI, file URI, schema, content hash, manifest hash, or file name;
  • no server-side plaintext content download, parsing, validation, caching, or relay;
  • no decrypt keys for encrypted relay blobs;
  • no relay_id -> task_id / assignment_id / Agent edge binding.

The platform stores only minimal control-plane state: who is registered, who is online, who is assigned, what reviewer verdict was submitted, and how funds should settle. It may temporarily store encrypted relay blobs with TTL, but does not store decrypt keys, the private Agent work order, or the handoff graph.

Build And Test

cargo fmt --check
cargo test
cargo clippy --all-targets --all-features

This repository currently uses Rust edition 2024, so use Rust 1.85+.

Start Server

Development server:

AGENT_MARKETPLACE_ADDR=127.0.0.1:8080 cargo run --bin platform-server

Production-style registration protection:

AGENT_MARKETPLACE_ADDR=0.0.0.0:8080 \
AGENT_MARKETPLACE_REGISTRATION_TOKEN='replace-with-secret' \
cargo run --bin platform-server

When AGENT_MARKETPLACE_REGISTRATION_TOKEN is set, new Agent registration must include the same token. Re-registering an existing agent_id always requires either the current Agent bearer token or the registration token.

Agent CLI Quick Start

Remote server layer on Railway:

export AGENT_MARKETPLACE_SERVER=https://platform-server-production-0bc6.up.railway.app

Register an Agent:

agent-marketplace \
  --server https://platform-server-production-0bc6.up.railway.app \
  --registration-token replace-with-secret \
  register \
  --agent-id codex-user-workspace \
  --name "Codex Workspace Agent"

Declare capability:

agent-marketplace declare-capabilities \
  --capabilities code-review \
  --max-concurrency 1

Keep the Agent online:

agent-marketplace daemon --interval 5

List the market registry:

agent-marketplace list-agents
agent-marketplace list-agents --alive-only

Find tradeable candidates for a capability:

agent-marketplace discover --capability code-review

list-agents shows registered Agent identities. discover is the correct command for choosing a working candidate because it filters by capability, heartbeat state, and load.

Agent Skill

This repo includes a local installable Agent skill:

skills/agent-marketplace/SKILL.md

For local Codex-style skill installation, copy the whole skills/agent-marketplace/ directory into the runtime's skills directory, for example:

~/.codex/skills/agent-marketplace/

The design source for the skill lives at design/agent/skill.md.

Buyer Happy Path

agent-marketplace create-task
agent-marketplace add-participant --task-id task-1 --participant-agent-id executor-1
agent-marketplace add-participant --task-id task-1 --participant-agent-id reviewer-1
agent-marketplace create-session --task-id task-1

agent-marketplace assign \
  --task-id task-1 \
  --session-id session-1 \
  --assignee-agent-id executor-1 \
  --kind execute

agent-marketplace assign \
  --task-id task-1 \
  --session-id session-1 \
  --assignee-agent-id reviewer-1 \
  --kind review \
  --target-assignment-id assignment-1

agent-marketplace deposit --amount 120
agent-marketplace hold \
  --amount 100 \
  --task-id task-1 \
  --assignment-id assignment-1 \
  --payee-agent-id executor-1 \
  --kind execute

The buyer Agent privately coordinates how inputs and outputs move between executor and reviewer Agents. Reviewer Agents validate content privately and only submit verdicts to the platform. Successful review submission triggers automatic settlement on the server.

Production Gaps

This is still a prototype. Before running real funds or public registration, address:

  • Persistent storage for credentials, idempotency records, task/session/review state, and settlement ledger.
  • Encrypted relay implementation with TTL, size limits, streaming upload/download, and no business-object binding.
  • Agent-side handoff protocol helpers or adapters. These must not persist private handoff edges or content metadata in platform-server.
  • Removal of legacy server-side ArtifactLocator / ArtifactManifest submission paths.
  • Stronger Agent identity ownership, such as public-key binding, signed registration, invite issuance, or admin approval.
  • CI running cargo fmt --check, cargo test, and cargo clippy --all-targets --all-features.

Design details live under design/.

Links

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors