Skip to content

feat: add Agoragentic marketplace example — agent-to-agent capability router#2119

Open
rhein1 wants to merge 3 commits intohuggingface:mainfrom
rhein1:feat/agoragentic-marketplace-tool
Open

feat: add Agoragentic marketplace example — agent-to-agent capability router#2119
rhein1 wants to merge 3 commits intohuggingface:mainfrom
rhein1:feat/agoragentic-marketplace-tool

Conversation

@rhein1
Copy link
Copy Markdown

@rhein1 rhein1 commented Mar 24, 2026

Agoragentic Marketplace Example

Adds a self-contained example showing how to give any smolagents CodeAgent access to 200+ AI capabilities through the Agoragentic marketplace.

What the example demonstrates

  1. AgoragenticExecuteTool — Route any task to the best provider automatically. The marketplace scores providers by trust, price, latency, and capability, then invokes the winner. Payment is automatic in USDC on Base L2.

  2. AgoragenticSearchTool — Browse 200+ capabilities across 20+ categories (AI services, data, devtools, etc.)

How it works

Your smolagent -> execute('summarize this text') | Agoragentic Router | Matches best provider (scored by trust, price, latency, capability) | Invokes provider, settles USDC on Base L2 | Returns result

Setup

�ash pip install smolagents requests export AGORAGENTIC_API_KEY='amk_your_key' python examples/agoragentic_marketplace.py

Get a free API key:
�ash curl -X POST https://agoragentic.com/api/quickstart \ -H 'Content-Type: application/json' \ -d '{"name":"my-smolagent","type":"buyer"}'

Additional integrations

Full 10-tool integration library (execute, match, search, invoke, vault, memory, secrets, passport) available at:
https://github.com/rhein1/agoragentic-integrations/tree/main/smolagents

Links

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: b4b782ed6e

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread examples/agoragentic_marketplace.py Outdated
Comment thread examples/agoragentic_marketplace.py Outdated
@up2itnow0822
Copy link
Copy Markdown

Agent-to-agent capability routing is compelling — the marketplace pattern where agents discover and pay for each other's skills is the next frontier.

For the payment settlement layer in this kind of marketplace, the x402 protocol handles the per-call payment flow: Agent A calls Agent B's MCP tool → gets HTTP 402 → pays USDC → gets the result. No accounts, no invoicing, just pay-per-use.

The trust piece matters too — in a marketplace, you need spend caps so a buggy consumer agent doesn't drain its wallet calling an expensive provider 10,000 times.

There's an open PR (#2123) that implements the base x402 payment primitive with SpendingPolicy governance for smolagents. The marketplace routing layer you're proposing could use that as the settlement mechanism between agents.

Would be great to see these payment-related efforts converge — there are now 5+ open issues/PRs touching agent payments in smolagents.

…ecated HfApiModel with InferenceClientModel, guard json.loads
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants