Urgent.News

What's breaking now, across hundreds of outlets.

Tech

An agent that pays for its own timestamps: x402 on a CPU-mined coin

Every night at 23:41 an agent we run, on OpenClaw on a Mac mini, makes a list of the SHA-256 of every file in its notes, takes the SHA-256 of that list and stamps it into a blockchain. It pays for the stamp itself. It has no card and no USDC: it pays in NORTH, the coin of TrueNorth, which ordinary processors mine. This post shows how that works, what it costs, what went wrong, and when you should…

An automated agent regularly performs a task on a CPU-mined cryptocurrency called NORTH. Every night at 23:41, the agent creates a list of SHA-256 hashes of files in its notes directory, then hashes that list itself. The resulting hash, known as a "stamp," is placed into a blockchain. This process pays for itself, as the agent mines NORTH to cover the cost of the transaction.

A stamp serves as a proof that certain data existed in a blockchain before a specific block. This is useful for verifying the integrity of various data sources, such as notes, logs, model outputs, or release files. The SHA-256 hash of the data is transmitted, not the actual file, ensuring minimal data transfer.

The service that facilitates this process operates on an HTTP gateway (https://gate.polarka.org/v1/stamp/ sha256). Every ten minutes, the gate receives input data, creates a Merkle tree, and writes the root hash into the blockchain within a single transaction. Each SHA-256 hash receives a proof, consisting of the hash path in the Merkle tree, the transaction, and the block height. This proof can be verified by anyone with their own node, without needing to trust the service provider.

The agent uses the x402 token to pay for these stamps. The service sells 100 calls for a small fee of 0.0091765 NORTH (about 600 hashes). A stamp represents one call to the gate. To use the agent, users need to install the polarka-agent package, obtain a wallet, mine for the network, and then configure the agent to fetch and pay for stamps as needed.

In the example provided, the agent was set up with a wallet, a specific amount of NORTH allocated for payments, and a command to fetch a stamp based on a SHA-256 hash. The agent then queried the gate, received a proof, and paid for the stamp using its own mined NORTH. This entire process is automated, requiring no external funding or payment cards, and relies only on the computational power of the agent's CPU.

Rewritten by urgent.news; may contain errors — check the original.

Source: dev.to

Read the original at dev.to →

Report a problem with this story

More in Tech

How to check a redirect map before a website migration

The redirect map is the spreadsheet behind a website migration: one row per old URL, with the new URL it should go to. The redirect rules are built from it, so every mistake in the map becomes a live…

  • Redirect map is a spreadsheet mapping old URLs to new ones during website migration.
  • Verify redirect map before going live to prevent live issues across platforms.

Wan 2.2 MoE sampler: accelerate low noise, keep dynamics, and use native control

Wan 2.2's MoE sampler combines the high- and low-noise stages into one sampler, making acceleration placement much easier to control.

  • Wan 2.2's innovative MoE sampler streamlines high- and low-noise stages
  • Accelerated low-noise stage preserves dynamics while speeding up process
  • Wan 2.2's native inpaint/control implementation excels in motion details

Confused lost and unashamed

So it's been an interesting 2 weeks ever since I discovered python, I love it and how expressive you can be. But I find myself lost and confused but i love it and I want to learn and discover its…

More from Wednesday 25 November →