Skip to main content
Glama

bear_context_add

Idempotent

Tag a Bear note with #context to add it to a curated library for LLM knowledge bases. Optionally specify a subtag for grouping like #context/jira.

Instructions

Add a Bear note to the context library by tagging it with #context. Optionally specify a subtag for grouping (e.g., subtag 'jira' → #context/jira). Triggers a sync after tagging.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYesNote ID (uniqueIdentifier)
subtagNoOptional sub-tag for grouping (e.g., 'architecture', 'jira')

Implementation Reference

  • The tool 'bear_context_add' is registered as a ToolHandler entry in the tools record with its name, description, inputSchema, annotations, and buildArgs function. Its buildArgs constructs CLI arguments for 'bcli context add <id> --json' with an optional '--subtag' flag.
    bear_context_add: {
      tool: {
        name: "bear_context_add",
        description:
          "Add a Bear note to the context library by tagging it with #context. Optionally specify a subtag for grouping (e.g., subtag 'jira' → #context/jira). Triggers a sync after tagging.",
        inputSchema: {
          type: "object" as const,
          properties: {
            id: {
              type: "string",
              description: "Note ID (uniqueIdentifier)",
            },
            subtag: {
              type: "string",
              description:
                "Optional sub-tag for grouping (e.g., 'architecture', 'jira')",
            },
          },
          required: ["id"],
        },
        annotations: {
          readOnlyHint: false,
          destructiveHint: false,
          idempotentHint: true,
        },
      },
      buildArgs: (input) => {
        const args = ["context", "add", String(input.id), "--json"];
        if (input.subtag) args.push("--subtag", String(input.subtag));
        return args;
      },
    },
  • Input schema definition for bear_context_add: accepts 'id' (string, required) and 'subtag' (string, optional).
    inputSchema: {
      type: "object" as const,
      properties: {
        id: {
          type: "string",
          description: "Note ID (uniqueIdentifier)",
        },
        subtag: {
          type: "string",
          description:
            "Optional sub-tag for grouping (e.g., 'architecture', 'jira')",
        },
      },
      required: ["id"],
    },
  • buildArgs function that generates CLI arguments: ['context', 'add', <id>, '--json'] with optional subtag parameter.
    buildArgs: (input) => {
      const args = ["context", "add", String(input.id), "--json"];
      if (input.subtag) args.push("--subtag", String(input.subtag));
      return args;
    },
Behavior4/5

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

The description discloses the tagging mechanism and the sync side effect, which goes beyond annotations (idempotentHint). It does not contradict annotations and adds value by explaining the sync trigger.

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?

Two sentences, frontloaded with the main action, followed by optional parameter and side effect. No redundant information; every sentence earns its place.

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

Completeness4/5

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

For a simple tool with no output schema, the description adequately covers behavior and parameters. It could mention that the note must exist, but overall it is sufficient.

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

Parameters4/5

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

Schema coverage is 100%, so baseline is 3. The description adds value by explaining that subtag creates a hierarchical tag (e.g., #context/jira), giving concrete usage context beyond the schema.

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

Purpose5/5

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

The description clearly states the tool adds a Bear note to the context library via tagging with #context, and optionally with a subtag for grouping. It differentiates from siblings like bear_add_tag by specifying the context library and sync behavior.

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

Usage Guidelines3/5

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

The description implies when to use (adding to context library) but does not explicitly mention alternatives or when not to use. It provides no comparison to sibling tools like bear_add_tag or bear_context_fetch.

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/mreider/better-bear'

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