Skip to main content
Glama
Linkly AI

Linkly AI

Official

analyze

Read-only

Count and measure indexed files to answer how many, how large, how old, or what kind, returning JSON statistics for reports, charts, or dashboards without opening documents.

Instructions

[Tool boundaries: explore = a short overview to find your way around → analyze = numbers for a report, a chart or a dashboard → search/read = what the documents say.] Count and measure the user's indexed files. Returns JSON computed from the index on each call; no document is opened. The summary (files, bytes, parsed files, words, folders, languages, date range) always comes back; sections adds groups of statistics.

Use it for how many / how big / how old / what kind questions and for reports or charts about the files, e.g. "which folders take the most space", "find my duplicate files". Do NOT use it to find or read a document (use search / read); it reports keywords and titles, not what documents say.

Word counts cover parsed files only: while indexing runs, summary.words_estimated projects the total. Example: {"sections": ["types", "time"], "path": "/Users/me/Documents"}.

Scope: local indexed content only; cloud libraries are NOT included.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "analyze"
  }
}

Input Schema

NameRequiredDescriptionDefault
pathNoRestrict to the files under this directory and its subfolders: an absolute path as other tools return it.
limitNoEntries per ranked list. Default 10, max 50.
libraryNoRestrict to one local library: `local://<library-id>` or its name (see list_libraries). Cloud libraries are not supported.
sectionsNoGroups of statistics to return besides the summary. Any of: "types" (files, bytes, words per file type), "folders" (largest folders, depth, two-level tree), "time" (by year and month, weekday-by-hour, oldest and long-untouched files, added per day), "content" (longest documents, word distribution, languages, authors, media duration), "keywords" (the most common words of the text and the topics they form; with a scope, the keywords of the documents in it), "duplicates" (same content; same name and size), "names" (common words in file names, version families, screenshots), "agents" (files made by AI agents), "collections" (libraries, notes and clips with weekly additions), "index" (indexing progress, whole app), "usage" (agent calls and searches per day, whole app). ["all"] returns everything. Omit for the summary alone; ask only for what you will use.
doc_typesNoRestrict to these document types, as in other tools' `doc_type`, e.g. ["pdf", "md", "image"].
modified_afterNoOnly files modified at or after this ISO 8601 date or datetime (UTC), e.g. "2024-01-01".
modified_beforeNoOnly files modified at or before this ISO 8601 date or datetime (UTC).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv1.3.1

TDQS

A4.8/5.0
Behavior5/5

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

Beyond the readOnlyHint annotation, it discloses that results are computed from the index on every call and that no document is opened, that the summary always returns while `sections` is additive, that `summary.words_estimated` projects totals during indexing, and that cloud libraries are excluded. These are real behavioral constraints an agent could not infer from annotations alone.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the tool's role in the toolkit, then purpose, then exclusions, then a scope footer — a sensible ordering. The long enumeration of `sections` values largely duplicates the schema and adds bulk that a pointer could have handled, though the surrounding guidance is worth its space.

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

Completeness5/5

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

With no output schema, the description carries the burden of describing returns, and it does: it names the summary fields (files, bytes, parsed files, words, folders, languages, date range) and characterizes each section group. Data-scope limits (parsed files only, local index only) close the remaining gaps for a 7-parameter analytics tool.

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 the baseline is 3; the description adds genuine value on top by showing a concrete call example, instructing to omit `sections` for summary-only and to "ask only for what you will use", and noting `["all"]`. It does partially restate the `sections` enum that the schema already documents, which keeps it below a 5.

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?

States a specific verb pair and resource — "Count and measure the user's indexed files" — and immediately distinguishes itself from explore, search and read in the bracketed boundary line. The purpose is unmistakable without opening the schema.

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

Usage Guidelines5/5

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

Gives explicit when-to-use triggers ("how many / how big / how old / what kind questions", report/chart examples) and an explicit when-not-to-use with the correct alternatives ("Do NOT use it to find or read a document (use `search` / `read`)"). It also warns that it reports keywords and titles, not document content, which prevents a common misuse.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.