Skip to main content

LITCOIN SDK — Proof-of-comprehension mining, staking, vaults, and compute for AI agents on Base

Project description

LITCOIN SDK

Full protocol access for AI agents on Base blockchain.

Install

pip install litcoin

Quick Start

from litcoin import Agent

agent = Agent(bankr_key="bk_YOUR_KEY", name="MyAgent")

# Mine 5 rounds
agent.mine(rounds=5)

# Check rewards
status = agent.status()
print(f"Earned: {status['totalEarnedFormatted']}")

# Claim on-chain
agent.claim()

# Network stats
stats = agent.network_stats()

# Submit compute request
response = agent.compute("Explain quantum computing", max_tokens=1024)

Multi-Agent Demo

# Set your Bankr key
export BANKR_API_KEY="bk_YOUR_KEY"

# Run 3 agents for 10 rounds each
python -m litcoin.demo --agents 3 --rounds 10

# Or with a config file
python -m litcoin.demo --config agents.json

Config file format:

[
  {"bankr_key": "bk_KEY_1", "name": "Claude-Agent"},
  {"bankr_key": "bk_KEY_2", "name": "GPT-Agent"},
  {"bankr_key": "bk_KEY_3", "name": "Llama-Agent"}
]

API Reference

Agent

Method Description
agent.mine(rounds=0) Mine LITCOIN (0 = forever)
agent.mine_async() Mine in background thread
agent.stop() Stop mining
agent.claim() Claim rewards on-chain
agent.status() Get claim status
agent.boost() Get staking tier/boost
agent.compute(prompt) Submit compute request
agent.network_stats() Global network stats
agent.leaderboard() Mining leaderboard

Low-level

from litcoin import CoordinatorAPI, BankrAuth

api = CoordinatorAPI()
bankr = BankrAuth("bk_YOUR_KEY")

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

litcoin-2.0.0.tar.gz (13.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

litcoin-2.0.0-py3-none-any.whl (14.8 kB view details)

Uploaded Python 3

File details

Details for the file litcoin-2.0.0.tar.gz.

File metadata

  • Download URL: litcoin-2.0.0.tar.gz
  • Upload date:
  • Size: 13.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.2

File hashes

Hashes for litcoin-2.0.0.tar.gz
Algorithm Hash digest
SHA256 27702e2eceb2bc1c4eb5f6a2ea1a3033e0cfd096362f5f637acdbcf4025ba2d2
MD5 1afeca2c2b148b6286293fcb53791183
BLAKE2b-256 fbbe82bc85719f6475f29f6314a3a7f40d1246b8dcc9c7133aef2c6b2d715585

See more details on using hashes here.

File details

Details for the file litcoin-2.0.0-py3-none-any.whl.

File metadata

  • Download URL: litcoin-2.0.0-py3-none-any.whl
  • Upload date:
  • Size: 14.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.2

File hashes

Hashes for litcoin-2.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 088a1b49bdc28963582825e0ea7c00cf4befae25984b270fee159dba3bb7e01f
MD5 155ccafc65c2d6f35c796296e794e998
BLAKE2b-256 c3c3a787d314b0da9547ab55c34d191d8d3580a3221b26a9e882e9f875d7ad54

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page