Some checks failed
Blockchain Synchronization Verification / sync-verification (push) Failing after 3s
CLI Tests / test-cli (push) Failing after 3s
Cross-Chain Functionality Tests / test-cross-chain-sync (push) Successful in 2s
Cross-Chain Functionality Tests / test-cross-chain-transactions (push) Successful in 3s
Cross-Chain Functionality Tests / test-cross-chain-bridge (push) Has been skipped
Cross-Chain Functionality Tests / test-multi-chain-consensus (push) Successful in 2s
Cross-Chain Functionality Tests / aggregate-results (push) Has been skipped
Deploy to Testnet / deploy-testnet (push) Successful in 1m12s
Documentation Validation / validate-docs (push) Failing after 8s
Documentation Validation / validate-policies-strict (push) Successful in 3s
Integration Tests / test-service-integration (push) Successful in 2m6s
Multi-Chain Island Architecture Tests / test-multi-chain-island (push) Successful in 2s
Multi-Node Blockchain Health Monitoring / health-check (push) Failing after 4s
P2P Network Verification / p2p-verification (push) Successful in 4s
Package Tests / Python package - aitbc-agent-sdk (push) Successful in 32s
Package Tests / Python package - aitbc-core (push) Successful in 14s
Package Tests / Python package - aitbc-crypto (push) Successful in 12s
Package Tests / Python package - aitbc-sdk (push) Successful in 9s
Package Tests / JavaScript package - aitbc-sdk-js (push) Successful in 8s
Package Tests / JavaScript package - aitbc-token (push) Successful in 17s
Python Tests / test-python (push) Successful in 15s
Security Scanning / security-scan (push) Successful in 27s
Node Failover Simulation / failover-test (push) Successful in 7s
Multi-Node Stress Testing / stress-test (push) Successful in 6s
Cross-Node Transaction Testing / transaction-test (push) Successful in 4s
- Add SQLCipher encryption for ait-mainnet database with configurable flag - Add db_encryption_enabled and db_encryption_key_path config settings - Implement encryption key loading and PRAGMA key setup via connection events - Add shutdown_db function for proper database cleanup - Export middleware classes in aitbc/__init__.py - Fix import path in sync.py for settings - Remove duplicate agent documentation from docs
108 lines
2.2 KiB
Markdown
108 lines
2.2 KiB
Markdown
# API Reference - Edge Computing & ML Features
|
|
|
|
## Edge GPU Endpoints
|
|
|
|
### GET /v1/marketplace/edge-gpu/profiles
|
|
Get consumer GPU profiles with filtering options.
|
|
|
|
**Query Parameters:**
|
|
- `architecture` (optional): Filter by GPU architecture (turing, ampere, ada_lovelace)
|
|
- `edge_optimized` (optional): Filter for edge-optimized GPUs
|
|
- `min_memory_gb` (optional): Minimum memory requirement
|
|
|
|
**Response:**
|
|
```json
|
|
{
|
|
"profiles": [
|
|
{
|
|
"id": "cgp_abc123",
|
|
"gpu_model": "RTX 3060",
|
|
"architecture": "ampere",
|
|
"consumer_grade": true,
|
|
"edge_optimized": true,
|
|
"memory_gb": 12,
|
|
"power_consumption_w": 170,
|
|
"edge_premium_multiplier": 1.0
|
|
}
|
|
],
|
|
"count": 1
|
|
}
|
|
```
|
|
|
|
### POST /v1/marketplace/edge-gpu/scan/{miner_id}
|
|
Scan and register edge GPUs for a miner.
|
|
|
|
**Response:**
|
|
```json
|
|
{
|
|
"miner_id": "miner_123",
|
|
"gpus_discovered": 2,
|
|
"gpus_registered": 2,
|
|
"edge_optimized": 1
|
|
}
|
|
```
|
|
|
|
### GET /v1/marketplace/edge-gpu/metrics/{gpu_id}
|
|
Get real-time edge GPU performance metrics.
|
|
|
|
**Query Parameters:**
|
|
- `hours` (optional): Time range in hours (default: 24)
|
|
|
|
### POST /v1/marketplace/edge-gpu/optimize/inference/{gpu_id}
|
|
Optimize ML inference request for edge GPU.
|
|
|
|
## ML ZK Proof Endpoints
|
|
|
|
### POST /v1/ml-zk/prove/inference
|
|
Generate ZK proof for ML inference correctness.
|
|
|
|
**Request:**
|
|
```json
|
|
{
|
|
"inputs": {
|
|
"model_id": "model_123",
|
|
"inference_id": "inference_456",
|
|
"expected_output": [2.5]
|
|
},
|
|
"private_inputs": {
|
|
"inputs": [1, 2, 3, 4],
|
|
"weights1": [0.1, 0.2, 0.3, 0.4],
|
|
"biases1": [0.1, 0.2]
|
|
}
|
|
}
|
|
```
|
|
|
|
### POST /v1/ml-zk/verify/inference
|
|
Verify ZK proof for ML inference.
|
|
|
|
### POST /v1/ml-zk/fhe/inference
|
|
Perform ML inference on encrypted data using FHE.
|
|
|
|
**Request:**
|
|
```json
|
|
{
|
|
"scheme": "ckks",
|
|
"provider": "tenseal",
|
|
"input_data": [[1.0, 2.0, 3.0, 4.0]],
|
|
"model": {
|
|
"weights": [[0.1, 0.2, 0.3, 0.4]],
|
|
"biases": [0.5]
|
|
}
|
|
}
|
|
```
|
|
|
|
### GET /v1/ml-zk/circuits
|
|
List available ML ZK circuits.
|
|
|
|
## Error Codes
|
|
|
|
### Edge GPU Errors
|
|
- `400`: Invalid GPU parameters
|
|
- `404`: GPU not found
|
|
- `500`: GPU discovery failed
|
|
|
|
### ML ZK Errors
|
|
- `400`: Invalid proof parameters
|
|
- `404`: Circuit not found
|
|
- `500`: Proof generation/verification failed
|