Skip to main content
Glama
aaronfeingold

MCP Project Context Server

Record Decision

record_decision

Record architectural or technical decisions with reasoning and impact for project documentation and context preservation.

Instructions

Record an architectural or technical decision

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
projectIdYesProject ID
decisionYesDecision made
reasoningYesReasoning behind the decision
impactNoExpected impact of the decision

Implementation Reference

  • MCP tool handler for 'record_decision' that calls ContextManager.recordDecision and formats the MCP response.
    async ({ projectId, decision, reasoning, impact }) => {
      try {
        await this.contextManager.recordDecision(
          projectId,
          decision,
          reasoning,
          impact
        );
        return {
          content: [
            {
              type: "text",
              text: "Decision recorded successfully",
            },
          ],
        };
      } catch (error) {
        return {
          content: [
            {
              type: "text",
              text: `Error recording decision: ${
                error instanceof Error ? error.message : "Unknown error"
              }`,
            },
          ],
        };
      }
  • Input schema using Zod for validating tool parameters: projectId, decision, reasoning, impact.
    inputSchema: {
      projectId: z.string().describe("Project ID"),
      decision: z.string().describe("Decision made"),
      reasoning: z.string().describe("Reasoning behind the decision"),
      impact: z
        .string()
        .optional()
        .describe("Expected impact of the decision"),
    },
  • src/server.ts:317-361 (registration)
    Registration of the 'record_decision' tool with the MCP server, including title, description, schema, and handler.
    this.server.registerTool(
      "record_decision",
      {
        title: "Record Decision",
        description: "Record an architectural or technical decision",
        inputSchema: {
          projectId: z.string().describe("Project ID"),
          decision: z.string().describe("Decision made"),
          reasoning: z.string().describe("Reasoning behind the decision"),
          impact: z
            .string()
            .optional()
            .describe("Expected impact of the decision"),
        },
      },
      async ({ projectId, decision, reasoning, impact }) => {
        try {
          await this.contextManager.recordDecision(
            projectId,
            decision,
            reasoning,
            impact
          );
          return {
            content: [
              {
                type: "text",
                text: "Decision recorded successfully",
              },
            ],
          };
        } catch (error) {
          return {
            content: [
              {
                type: "text",
                text: `Error recording decision: ${
                  error instanceof Error ? error.message : "Unknown error"
                }`,
              },
            ],
          };
        }
      }
    );
  • Helper method in ContextManager that appends the decision to the project's decisions array and persists the project update.
    async recordDecision(
      projectId: string,
      decision: string,
      reasoning: string,
      impact?: string
    ): Promise<void> {
      const project = await this.store.getProject(projectId);
      if (!project) {
        throw new Error("Project not found");
      }
    
      project.decisions.push({
        id: uuidv4(),
        decision,
        reasoning,
        impact,
        timestamp: new Date().toISOString(),
      });
    
      await this.store.updateProject(project);
    }
Behavior2/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. 'Record' implies a write operation, but the description doesn't specify whether this creates a new record, updates an existing one, requires permissions, has side effects, or what the response looks like. It lacks details on persistence, error handling, or any behavioral traits beyond the basic action.

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 with no wasted words. It's front-loaded with the core action and resource, making it easy to parse. Every part of the sentence contributes directly to understanding the tool's purpose, achieving optimal 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?

Given the complexity of a write operation with no annotations and no output schema, the description is incomplete. It doesn't cover behavioral aspects like what happens after recording, error conditions, or return values. For a tool that likely mutates data, more context is needed to guide the agent effectively, leaving significant gaps in understanding.

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?

Schema description coverage is 100%, with clear descriptions for all parameters (e.g., 'Decision made', 'Reasoning behind the decision'). The description adds no additional semantic context beyond what the schema provides, such as examples or usage notes. Since the schema does the heavy lifting, the baseline score of 3 is appropriate, but there's no extra value from the description.

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 'record' and the resource 'architectural or technical decision', making the purpose understandable. However, it doesn't differentiate this tool from sibling tools like 'add_note' or 'add_task', which might also record information but for different types of content. The description is specific about what kind of decision is being recorded.

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. It doesn't mention prerequisites, context (e.g., during project planning), or exclusions. With siblings like 'add_note' and 'add_task', there's no indication of how this tool differs in usage, leaving the agent to guess based on tool names alone.

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/aaronfeingold/mcp-project-context'

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