Skip to main content
Glama

twining_delegate

Delegate tasks to agents by posting capability requirements to a shared blackboard and receive ranked suggestions based on match quality.

Instructions

Post a delegation request to the blackboard as a 'need' entry with capability requirements. Returns suggested agents ranked by match quality.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
summaryYesDescription of the task to delegate (max 200 chars)
required_capabilitiesYesCapabilities needed for this task
urgencyNoUrgency level affecting timeout (default: 'normal')
timeout_msNoCustom timeout in ms (overrides urgency-based default)
scopeNoScope for the delegation (default: 'project')
tagsNoAdditional tags for the delegation entry
agent_idNoID of the delegating agent (default: 'main')

Implementation Reference

  • The implementation of the 'twining_delegate' tool in `src/tools/coordination-tools.ts`. It registers the tool with the MCP server and delegates the execution to `coordinationEngine.postDelegation`.
    // twining_delegate — Post a delegation request to the blackboard
    server.registerTool(
      "twining_delegate",
      {
        description:
          "Post a delegation request to the blackboard as a 'need' entry with capability requirements. Returns suggested agents ranked by match quality.",
        inputSchema: {
          summary: z
            .string()
            .describe("Description of the task to delegate (max 200 chars)"),
          required_capabilities: z
            .array(z.string())
            .describe("Capabilities needed for this task"),
          urgency: z
            .enum(["high", "normal", "low"])
            .optional()
            .describe("Urgency level affecting timeout (default: 'normal')"),
          timeout_ms: z
            .number()
            .optional()
            .describe("Custom timeout in ms (overrides urgency-based default)"),
          scope: z
            .string()
            .optional()
            .describe("Scope for the delegation (default: 'project')"),
          tags: z
            .array(z.string())
            .optional()
            .describe("Additional tags for the delegation entry"),
          agent_id: z
            .string()
            .optional()
            .describe("ID of the delegating agent (default: 'main')"),
        },
      },
      async (args) => {
        try {
          const result = await coordinationEngine.postDelegation({
            summary: args.summary,
            required_capabilities: args.required_capabilities,
            urgency: args.urgency,
            timeout_ms: args.timeout_ms,
            scope: args.scope,
            tags: args.tags,
            agent_id: args.agent_id,
          });
          return toolResult(result);
        } catch (e) {
          return toolError(
            e instanceof Error ? e.message : "Unknown error",
            "INTERNAL_ERROR",
          );
        }
      },
    );

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/daveangulo/twining-mcp'

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