Skip to main content
Glama

bittensor_code

Generate code using Bittensor's AI models to automate programming tasks and accelerate development workflows through the Swarmrails MCP server.

Instructions

Advanced code generation via Bittensor subnet 11. Cost: $0.01 per call.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
promptYesCode generation request

Implementation Reference

  • Handler logic for the bittensor_code tool in the CallToolRequest handler.
    case "bittensor_code":
      result = await callGateway({ route: "bittensor-code", prompt: a.prompt });
      break;
  • src/index.ts:135-145 (registration)
    Definition/Registration of the bittensor_code tool in the TOOLS array.
      name: "bittensor_code",
      description:
        "Advanced code generation via Bittensor subnet 11. Cost: $0.01 per call.",
      inputSchema: {
        type: "object",
        properties: {
          prompt: { type: "string", description: "Code generation request" },
        },
        required: ["prompt"],
      },
    },
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden of behavioral disclosure. It successfully communicates the financial cost per invocation, which is critical for agent decision-making. However, it fails to describe the output format (crucial given no output schema exists), latency expectations, or whether the tool executes generated code versus returning source text.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description consists of two efficient sentences with zero waste. The first sentence front-loads the core capability (code generation via specific subnet), and the second sentence provides essential cost information. Every word serves a distinct purpose in aiding tool selection.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a single-parameter tool with complete schema coverage, the description adequately covers the basic purpose and cost. However, given the absence of both annotations and an output schema, the description should have specified the return format (e.g., raw code, JSON wrapper, multiple files) and distinguished this from the general-purpose LLM sibling to be considered complete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema has 100% description coverage for its single 'prompt' parameter, establishing a baseline score of 3. The description does not add any semantic clarifications about the prompt's expected format, examples of valid requests, or constraints beyond the schema's 'Code generation request' definition.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly identifies the resource (code) and action (generation) and specifies the unique backend ('Bittensor subnet 11'), which distinguishes it from sibling tools like bittensor_image or bittensor_text. However, it does not explicitly differentiate from bittensor_llm, which could also generate code, and the term 'Advanced' adds vague marketing language without clarifying scope.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides cost information ('$0.01 per call') but offers no guidance on when to use this tool versus similar generation tools like bittensor_llm or bittensor_text. It does not specify supported programming languages, complexity limits, or prerequisites for the prompt parameter.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/wizerai1111/swarmrails-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server