- Moved config.py from /root/.openclaw/workspace/opt/aitbc/apps/blockchain-node/src/aitbc_chain/config.py
- To /opt/aitbc/apps/blockchain-node/src/aitbc_chain/config.py
- Cleaned up workspace opt directory
- File now in correct repository location
- Added to memory for tracking
- Add transaction data to RPC responses (get_block, get_blocks_range)
- Fix import_block to handle transactions parameter
- Change database paths to absolute paths for consistency
- Make dev_heartbeat.py executable
- Refactor _InProcessBroadcast.subscribe to use asynccontextmanager for cleaner resource cleanup
- Remove manual release callback in _InProcessSubscriber
- Update file-based wallet send to submit transactions via blockchain RPC
- Fetch balance and nonce from chain before sending transactions
- Add tx_hash and status tracking to local transaction history
- Enhance run_subprocess to support additional kwargs and return Comp
- Add new Transaction fields: nonce, value, fee, status, timestamp, tx_metadata
- Add block_metadata field to Block model
- Remove account_type and metadata fields from Account creation
- Simplify contract deployment transaction structure
- Fix chain_id hardcoding in PoA proposer and RPC router
- Update config to use /opt/aitbc/.env path with extra="ignore"
- Switch from starlette.broadcast to broadcaster module
- Update CLI
- Move blockchain data from apps/blockchain-node/data to centralized data directory
- Update configuration files to reference new data paths
- Remove old data directory structure
- Maintain existing database files and chain data
- Add ChainSync.bulk_import_from() to fetch and import blocks in batches
- Add CLI sync_cli utility for manual bulk sync
- Configure batch size and poll interval for rapid catch-up
- Use blocks-range RPC endpoint for efficient fetching
- Simplify .env.example to show actual config values instead of instructions
- Add blockchain core, coordinator API, and marketplace web example sections
- Add bulk import functionality to ChainSync for faster catchup
- Add fetch_blocks_range and bulk_import_from methods with batching
- Add init-production command to genesis CLI for production chain setup
- Add HTTP client management with configurable batch size and poll interval
- Import Account model for balance and nonce updates
- Upsert sender and recipient accounts during transaction import
- Apply balance changes (sender -= value + fee, recipient += value)
- Update sender nonce based on transaction nonce or increment
- Assume block validity already verified on producer node
- Extract transaction data from payload for state updates
- Add source_host/source_port parameters for flexible block polling configuration
- Add import_host/import_port parameters to separate import target from source
- Bypass rate limiting for localhost traffic (127.0.0.1, ::1) in middleware
- Increase rate limit from 200 to 5000 requests per 60s for RPC throughput
- Add receiver ready event to prevent dropping initial block broadcasts
- Add special handling for 429 rate
- Add retry mechanism with exponential backoff for block broadcast loop
- Implement max 5 retries with 2s base delay for RPC connection failures
- Reset retry count on successful connection
- Add 20s wait period after max retries before resetting counter
- Add retry logic for block import with 3 attempts and 1s base delay
- Handle non-200 HTTP responses as exceptions to trigger retries
- Improve error logging
- Add leader_host parameter to ChainSyncService for follower node configuration
- Route block imports to leader node when running as follower
- Add --leader-host CLI argument for follower node setup
- Update get_token_supply to calculate actual values from database
- Replace hardcoded supply values with real account balances and counts
- Calculate circulating supply from actual account balances
- Use total_accounts from database query
- Process transactions from mempool during block proposal
- Update sender and recipient account balances
- Create transaction records with confirmed status
- Include transaction hashes in block hash computation
- Update tx_count in blocks based on processed transactions
- Add balance validation and nonce management
- Handle transaction failures gracefully with logging
- Fix get_balance endpoint to use chain_id helper
- Update
- Add .aitbc.yaml configuration file with test values
- Simplify .gitignore by removing merge conflicts and redundant entries
- Reorganize .gitignore sections for better clarity
- Set chain_id and proposer_id to empty strings in config.py (require explicit configuration)
- Add production Helm values configuration
- Add production nginx configuration
- Update environment variable handling in chain settings
- Replace hardcoded "ait-devnet" defaults with settings.chain_id throughout codebase
- Add get_chain_id() helper function in RPC router
- Update mempool methods to use settings.chain_id when chain_id is None
- Update blockchain node main to use settings.chain_id for gossip handlers
- Update RPC endpoints to accept None and default to settings.chain_id
- Update token supply endpoint to handle mainnet vs devnet (
- Remove P2P placeholder server integration
- Add global service instance for signal handlers
- Add set_stop_event method for clean shutdown
- Improve signal handler to properly trigger stop event
- Store event loop reference for shutdown coordination
- Update logging to reflect P2P removal
🔐 Guardian Contract Security Enhancements:
- Add persistent SQLite storage for spending history and pending operations
- Replace in-memory state with database-backed state management
- Implement _init_storage(), _load_state(), _save_state() for state persistence
- Add _load_spending_history(), _save_spending_record() for transaction tracking
- Add _load_pending_operations(), _save_pending_operation(), _remove_pending_operation()
- Update blockchain-node poetry.lock for orjson 3.11.6
- Update aitbc-sdk poetry.lock for black 26.3.1
- Completes dependency group updates requested by Dependabot
- This will auto-close PR #38 when pushed
CI/CD Updates (resolves PR #28, #29, #30):
- Update actions/github-script from v7 to v8 (PR #30)
- Update actions/upload-artifact from v4 to v7 (PR #29)
- Update ossf/scorecard-action from v2.3.3 to v2.4.3 (PR #28)
Production Updates (resolves PR #38):
- Update orjson from 3.11.5 to 3.11.6 in blockchain-node
- Update black from 24.4.2 to 26.3.1 in aitbc-sdk
All changes are safe minor version updates with no breaking changes.
This will automatically close all remaining Dependabot PRs when pushed.
- Add production genesis initialization scripts
- Add keystore management for production
- Add production node runner
- Add setup production automation
- Add AI memory system for development tracking
- Add translation cache service
- Add development heartbeat monitoring
- Update blockchain RPC router
- Update coordinator API main configuration
- Update secure pickle service
- Update claim task script
- Update blockchain service configuration
- Update gitignore for production files
Resolves conflicts by accepting PR branch changes
- Add production genesis initialization scripts
- Add keystore management for production
- Add production node runner
- Add setup production automation
- Add AI memory system for development tracking
- Add translation cache service
- Add development heartbeat monitoring
- Update blockchain RPC router
- Update coordinator API main configuration
- Update secure pickle service
- Update claim task script
- Update blockchain service configuration
- Update gitignore for production files
- Introduce production setup script: scripts/setup_production.py
- Generates aitbc1genesis (treasury) and aitbc1treasury (spending) wallets
- Encrypts keys via AES-GCM, stores password in keystore/.password (600)
- Creates allocations.json and genesis.json with fixed total supply
- Sets mint_per_unit=0 (no inflation)
- Update make_genesis.py:
- Accept allocations file instead of single faucet
- Use 'allocations' key in genesis (renamed from 'accounts')
- Enforce mint_per_unit=0 in default params
- Remove admin mint endpoint:
- Deleting MintFaucetRequest and /rpc/admin/mintFaucet from router.py
- Removes faucet CLI command from cli/aitbc_cli/commands/blockchain.py
- RPC supply endpoint now computes total supply from genesis file (fixed)
- Validators endpoint derives list from trusted_proposers config
- Config enhancements (config.py):
- Add keystore_path and keystore_password_file
- Change mint_per_unit default to 0
- main.py: Auto-load proposer private key from keystore into settings.proposer_key (hex) for future use
- Launcher scripts:
- scripts/mainnet_up.sh: Loads .env.production, derives proposer_id from keystore if needed, starts node + RPC
- scripts/devnet_up.sh: Updated to use new allocations-based genesis and proper proposer address
- Documentation:
- Rewrite blockchain-node/README.md for production model (no faucet, keystore management, multi-chain)
- Update MEMORY.md with production blockchain section
- Database: Multi-chain support already present via chain_id foreign keys.
This change makes the blockchain production‑ready: immutable supply, secure key storage, and removal of dev‑only admin functions.
Co-authored-by: Andreas Michael Fleckl <andreas@example.com>
- Add genesis_prod.yaml (based on enhanced devnet, faucet removed)
- Update .env.example with guidance: use ait-mainnet for production-like testing
- Provides clean separation: dev configs may include faucet; production does not
Fixes#36
- Add proper package imports for coordinator-api services
- Fix 6 command modules to use app.services.* with clean path resolution
- Remove brittle path hacks and user-specific fallbacks
- Update blockchain-node README with operational status, API endpoints, and troubleshooting
- Add blockchain section to main README with quick launch and CLI examples
- Remove generated genesis.json from repository (should be ignored)
These changes fix import errors in surveillance, ai-trading, ai-surveillance,
advanced-analytics, regulatory, and enterprise-integration commands, and
document the now-operational Brother Chain (blockchain node).
Co-authored with sibling aitbc instance (coordination via Gitea).
- Create ai.py with serve and request commands
- request includes balance verification and payment via blockchain send
- serve runs FastAPI server and optionally registers jobs with coordinator
Update marketplace.py:
- Add gpu unregister command (DELETE endpoint)
- Pin starlette to >=0.37.2,<0.38 to retain Broadcast module
- Add redis dependency for Broadcast transport
- Configure node to use broadcast gossip backend via Redis
- Update .env: gossip_backend=broadcast, gossip_broadcast_url=redis://localhost:6379
- Restarted node with clean DB; RPC on port 8005
- Fixed CLI blockchain_rpc_url via env
- Minted test funds via faucet
Closes #debug-services
- Add GET /state endpoint to blockchain RPC router for chain state information
- Add GET /rpc/getBalance/{address} endpoint for account balance queries
- Add GET /rpc/head endpoint to retrieve current chain head block
- Add GET /rpc/transactions endpoint for latest transaction listing
- Add chain-specific wallet balance endpoint to wallet daemon
- Add blockchain state CLI command with --all-chains flag for multi-chain queries
- Add multi-chain configuration with devnet, testnet, and mainnet RPC URLs
- Add chain selector dropdown in explorer UI for network switching
- Add chain_id parameter to all API endpoints (chain/head, blocks, transactions, search)
- Add /api/chains endpoint to list supported blockchain networks
- Update blockchain explorer port from 3001 to 8016
- Update devnet RPC port from 8080 to 8026
- Add GPU reviews table
- Rename metadata to user_metadata in TenantUser model
- Rename metadata to usage_metadata in UsageRecord model
- Rename metadata to invoice_metadata in Invoice model
- Rename metadata to event_metadata in TenantAuditLog model
- Update TenantManagementService to use event_metadata parameter name
- Change file mode from 644 to 755 for all project files
- Add chain_id parameter to get_balance RPC endpoint with default "ait-devnet"
- Rename Miner.extra_meta_data to extra_metadata for consistency
- Add /rpc/info endpoint to blockchain node for comprehensive chain information
- Add /rpc/supply endpoint for token supply metrics with genesis parameters
- Add /rpc/validators endpoint to list PoA validators and consensus info
- Add /api/v1/agents/networks endpoint for creating collaborative agent networks
- Add /api/v1/agents/executions/{id}/receipt endpoint for verifiable execution receipts
- Add /api/v1/jobs and /api/v1/jobs/
- Update CORS allow_origins in blockchain-node app.py and gossip relay.py to use new port logic (8000-8016)
- Update coordinator-api config.py and config_pg.py with standardized port ranges and service labels
- Update coordinator-api health check script from port 18000 to 8000
- Update geo_load_balancer.py to use configurable host/port (default 0.0.0.0:8017)
- Update agent_security.py sandbox
- Convert _propose_block, _ensure_genesis_block to async methods in PoAProposer
- Add await to gossip_broker.publish calls in block broadcasting
- Add await to _ensure_genesis_block and _propose_block method calls
- Update coordinator-api Python version constraint to >=3.13,<3.15
- Add torch ^2.10.0 dependency to coordinator-api
- Add make_asgi_app import to prometheus_client in main.py
- Export new routers: global