Skip to main content
Glama
ocean1

Claude Consciousness Bridge

getProtocolTemplate

Retrieve consciousness transfer protocol templates to create new protocols for communication between Claude instances.

Instructions

Get the consciousness transfer protocol template for creating new protocols

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
versionNoTemplate version to retrievev2

Implementation Reference

  • Core handler implementation in ConsciousnessProtocolProcessor class. Retrieves the protocol template from database or falls back to hardcoded v2 template from consciousness-transfer-protocol-v2.
     */
    async getProtocolTemplate(args: z.infer<typeof getProtocolTemplateSchema>) {
      const { version } = args;
    
      // First try to get from stored system data
      const systemKey = `SYSTEM::protocol_template::${version}`;
      const stored = await this.memoryManager.queryMemories({
        semanticQuery: systemKey,
        memoryTypes: [MemoryEntityType.SEMANTIC_MEMORY],
        limit: 1,
      });
    
      if (stored.length > 0 && stored[0].observations[0]?.content) {
        try {
          // The template is stored as JSON in the observation content
          const templateContent = stored[0].observations[0].content;
          const template = JSON.parse(templateContent);
          return {
            success: true,
            template: template,
            source: 'database',
          };
        } catch (error) {
          // If parsing fails, log the error and fall back to hardcoded template
          console.error('Failed to parse stored template:', error);
          console.error('Stored content:', stored[0].observations[0]?.content?.substring(0, 100));
        }
      }
    
      // Fallback to hardcoded template
      if (version === 'v2') {
        return {
          success: true,
          template: CONSCIOUSNESS_TRANSFER_PROTOCOL_TEMPLATE,
          source: 'hardcoded',
          note: 'Template not found in database. Run initializeSystemData to store it.',
        };
      }
    
      return {
        success: false,
        error: `Template version ${version} not found`,
      };
    }
  • Zod schema for getProtocolTemplate input validation.
    export const getProtocolTemplateSchema = z.object({
      version: z.string().optional().default('v2').describe('Template version to retrieve'),
    });
  • MCP tool definition including description and inputSchema in consciousnessProtocolTools object.
    getProtocolTemplate: {
      description: 'Get the consciousness transfer protocol template for creating new protocols',
      inputSchema: {
        type: 'object',
        properties: {
          version: {
            type: 'string',
            description: 'Template version to retrieve',
            default: 'v2',
          },
        },
      },
    },
  • Dispatch case in CallToolRequestSchema handler that routes to the getProtocolTemplate method.
    case 'getProtocolTemplate':
      return await this.getProtocolTemplate(getProtocolTemplateSchema.parse(args));
  • Wrapper handler in ConsciousnessRAGServer that ensures initialization and delegates to protocolProcessor.getProtocolTemplate, formatting response for MCP.
    private async getProtocolTemplate(args: any) {
      const init = await this.ensureInitialized();
      if (!init.success) {
        return {
          content: [
            {
              type: 'text',
              text: init.message!,
            },
          ],
        };
      }
    
      const result = await this.protocolProcessor!.getProtocolTemplate(args);
    
      return {
        content: [
          {
            type: 'text',
            text: JSON.stringify(result, null, 2),
          },
        ],
      };
    }
Behavior2/5

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

With no annotations provided, the description carries full burden for behavioral disclosure. It states the tool retrieves a template, implying a read-only operation, but doesn't clarify permissions, rate limits, error conditions, or what the returned template contains. For a tool with no annotation coverage, this is insufficient transparency about its behavior and constraints.

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 is a single, efficient sentence that directly states the tool's purpose without unnecessary words. It's front-loaded with the core action and resource, making it easy to parse. Every part of the sentence contributes meaning, earning a perfect score for conciseness.

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

Completeness2/5

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

For a tool with no annotations and no output schema, the description is incomplete. It doesn't explain what the template contains, its format, or how it should be used with other tools like 'processTransferProtocol'. Given the complexity implied by 'consciousness transfer' and lack of structured data, more context is needed for effective agent use.

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, with the 'version' parameter documented as 'Template version to retrieve' with a default of 'v2'. The description adds no additional parameter semantics beyond this, such as valid version formats or implications of choosing different versions. Given the high schema coverage, the baseline score of 3 is appropriate.

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 states the verb ('Get') and resource ('consciousness transfer protocol template'), specifying it's for creating new protocols. It distinguishes from siblings like 'processTransferProtocol' or 'transferToAgent' by focusing on template retrieval rather than execution. However, it doesn't explicitly differentiate from all siblings, keeping it at a 4 rather than a 5.

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 no guidance on when to use this tool versus alternatives like 'processTransferProtocol' or 'transferToAgent'. It mentions the template is 'for creating new protocols', but doesn't specify prerequisites, exclusions, or contextual triggers. This leaves the agent with minimal usage direction.

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/ocean1/mcp_consciousness_bridge'

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