Skip to main content
Glama

check_ai_health

Verify DEVONthink's AI services are operational and functioning correctly to ensure document summarization and classification features work as intended.

Instructions

Check if DEVONthink's AI services are available and working properly.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The check_ai_health tool definition, including the name, description, schema, and the run handler that executes a JXA script to probe DEVONthink AI.
    export const checkAiHealthTool = defineTool({
      name: "check_ai_health",
      description:
        "Check if DEVONthink's AI services are available and working properly.",
      schema: z.object({}),
      run: async (_args, executor) => {
        const script = `
          ${JXA_APP}
    
          var available = false;
          var message = "";
          var model = null;
    
          try {
            // Attempt a lightweight AI probe: ask a trivial question with no documents.
            // DEVONthink will throw if the AI engine is unavailable or misconfigured.
            var testAnswer = app.getChatResponseForMessage("Reply with the single word: OK", { temperature: 0 });
            available = true;
            message = "DEVONthink AI is available and responding.";
          } catch (e) {
            available = false;
            message = e.message || String(e);
          }
    
          JSON.stringify({ available: available, message: message, model: model });
        `;
    
        const result = executor.run(script);
        return JSON.parse(result.stdout) as {
          available: boolean;
          message: string;
          model: string | null;
        };
      },
    });
Behavior3/5

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

With no annotations provided, the description carries full burden. It discloses that this is a diagnostic check for availability and functionality, implying it's read-only and safe. However, it omits what constitutes 'working properly,' what the return value contains (boolean vs status object), or whether it performs actual AI inference tests versus simple connectivity checks.

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?

Single sentence of 10 words with no filler. Front-loaded with the action ('Check') and scope ('DEVONthink's AI services'). Every word earns its place in conveying the tool's function.

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?

Given the low complexity (no parameters, no nested objects, simple boolean/status return implied), the description is sufficiently complete for an agent to select and invoke it correctly. It could be improved by describing the return format, but the essential behavioral contract is clear.

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?

The tool has 0 parameters and schema description coverage is 100% (vacuously true). Per the baseline rule for zero-parameter tools, this scores a 4. No additional parameter semantics are needed or provided.

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 tool 'Check[s] if DEVONthink's AI services are available and working properly' - specific verb (check) and resource (AI services). It distinguishes from siblings like 'ask_ai_about_documents' and 'classify' by framing this as a diagnostic/availability check rather than an AI operation itself, though it doesn't explicitly name alternatives.

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 usage ('Check if... available') suggesting it should be used before attempting AI operations, but lacks explicit guidance such as 'call this before using ask_ai_about_documents' or troubleshooting scenarios. The when-to-use is inferred from the purpose but not stated directly.

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/mnott/Devon'

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