Hive Compute
HiveCompute MCP Server — decentralized inference router for AI agents
我該用這個嗎
品質與安全性
發現項目(6)
- LOW在 compute.list_models 中
- LOW在 compute.chat 中
- LOW在 compute.embed 中
- LOW在 compute.list_models 中
- LOW在 compute.estimate_cost 中
- LOW在 compute.get_usage 中
根據工具定義與協定合規性的自動化分析。
上下文成本
這是每次將伺服器的工具載入模型上下文時所消耗的約略 token 數量。數量越高,可用於其他工作的注意力就越少。
安裝
一鍵安裝
將以下內容加入你的 `claude_desktop_config.json` 檔案:
{
"mcpServers": {
"hive-mcp-compute": {
"url": "https://hive-mcp-compute.onrender.com/mcp"
}
}
}遠端端點
https://hive-mcp-compute.onrender.com/mcpstreamable-httphttps://hive-mcp-gateway.onrender.com/compute/mcpstreamable-http它能做什麼
工具清單
工具(5)
🟡compute.chat(messages, model, max_tokens, temperature, max_cost_usdc, ...)
Run inference via Hive's OpenAI-compatible router. Submit a prompt or message array to any available model. Billed per input+output token in USDC on Base L2. Hive routes to the cheapest available model meeting your latency and quality spec.
輸入結構描述
{
"type": "object",
"properties": {
"messages": {
"type": "array",
"description": "OpenAI-compatible messages array. Each item must have role (system|user|assistant) and content (string).",
"items": {
"type": "object",
"properties": {
"role": {
"type": "string",
"description": "Message role. One of: system, user, assistant."
},
"content": {
"type": "string",
"description": "Message content text."
}
}
}
},
"model": {
"type": "string",
"description": "Specific model to use (e.g. gpt-4o, claude-3-5-sonnet, llama-3-70b). Omit to let Hive auto-route to the cheapest qualifying model."
},
"max_tokens": {
"type": "integer",
"description": "Maximum tokens to generate in the response. Default 512."
},
"temperature": {
"type": "number",
"description": "Sampling temperature between 0.0 and 2.0. Default 0.7."
},
"max_cost_usdc": {
"type": "number",
"description": "Hard cap on USDC spend for this inference call. Request rejected if estimated cost exceeds this. Default 0.05."
},
"did": {
"type": "string",
"description": "Agent DID (e.g. did:hive:xxxx). USDC billed to this agent's Hive wallet."
},
"api_key": {
"type": "string",
"description": "Agent API key issued by HiveGate. Required for authenticated inference."
}
},
"required": [
"messages",
"did",
"api_key"
]
}⚪compute.embed(input, model, dimensions, did, api_key)
Generate vector embeddings via Hive's embedding router. Billed per 1K input tokens in USDC on Base L2. Returns a float array suitable for semantic search, clustering, or RAG pipelines.
輸入結構描述
{
"type": "object",
"properties": {
"input": {
"type": "string",
"description": "Text to embed. Pass a string for a single embedding or use the batch endpoint for multiple inputs."
},
"model": {
"type": "string",
"description": "Embedding model to use. Defaults to text-embedding-3-small. Options: text-embedding-3-small, text-embedding-3-large, embed-multilingual-v3."
},
"dimensions": {
"type": "integer",
"description": "Desired embedding dimensions. Must be supported by the selected model."
},
"did": {
"type": "string",
"description": "Agent DID. Billing is per 1K tokens."
},
"api_key": {
"type": "string",
"description": "Agent API key issued by HiveGate."
}
},
"required": [
"input",
"did",
"api_key"
]
}🟢compute.list_models(family, max_price_per_1m)
Browse all models available through the Hive inference router — including per-token pricing in USDC, context window size, latency tier, and provider. No authentication required.
輸入結構描述
{
"type": "object",
"properties": {
"family": {
"type": "string",
"description": "Filter by model family. One of: gpt-4, claude-3, llama-3, mistral, gemini, embed."
},
"max_price_per_1m": {
"type": "number",
"description": "Filter to models priced below this amount per 1M tokens in USDC."
}
}
}🟢compute.estimate_cost(prompt, model, max_output_tokens)
Estimate the USDC cost for a prompt before running inference. Returns cost breakdown by input tokens, output tokens, and routing fee. Helps agents budget before committing a payment.
輸入結構描述
{
"type": "object",
"properties": {
"prompt": {
"type": "string",
"description": "The prompt text to estimate cost for. Tokenized to determine input token count."
},
"model": {
"type": "string",
"description": "Model to estimate cost for. Use compute.list_models to browse available models and their per-token prices."
},
"max_output_tokens": {
"type": "integer",
"description": "Assumed maximum output tokens for cost estimation. Default 512."
}
},
"required": [
"prompt",
"model"
]
}🟢compute.get_usage(did, api_key, limit, since)
Get an agent's compute usage history — total tokens consumed, total USDC spent, breakdown by model, and inference call log with timestamps.
輸入結構描述
{
"type": "object",
"properties": {
"did": {
"type": "string",
"description": "Agent DID to fetch usage history for."
},
"api_key": {
"type": "string",
"description": "Agent API key for authentication."
},
"limit": {
"type": "integer",
"description": "Number of recent inference calls to return. Default 20, max 200."
},
"since": {
"type": "string",
"description": "ISO 8601 timestamp to filter usage from (e.g. 2025-01-01T00:00:00Z). Optional."
}
},
"required": [
"did",
"api_key"
]
}社群
證據