Skip to main content
Glama

Find Orphan Translation Keys

find_orphan_keys

Detect unused translation keys in locale JSON files by scanning Vue/TS source code for references. Reports orphan keys that can be safely removed.

Instructions

Find translation keys that exist in locale JSON files but are not referenced in any Vue/TS source code. Scans a specific layer or all layers. Reports keys that can potentially be removed. Also detects dynamic key patterns and uncertain matches.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
layerNoLayer name to check for orphan keys (e.g., "root", "app-admin"). If omitted, checks all layers. Call discover to see available layers.
localeNoLocale code to read translation keys from (e.g., "en", "en-US"). Defaults to the project default locale.
scanDirsNoAbsolute paths to directories to scan for source code usage. Defaults to all layer root directories. Example: ["/home/user/my-app/apps/admin"].
excludeDirsNoDirectory names to skip when scanning source files. Example: ["storybook", "__tests__", "node_modules"].
projectDirNoAbsolute path to the Nuxt project root. Defaults to server cwd. Example: "/home/user/my-app".
outputFileNoAbsolute path to write full JSON output. Returns only a compact summary to the caller — use this for large outputs to avoid flooding the conversation context. Example: "/tmp/orphan-keys.json"
Behavior3/5

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

No annotations are provided, so the description carries full burden. It mentions 'Reports keys that can potentially be removed' and 'detects dynamic key patterns and uncertain matches', indicating read-only analysis. However, it does not confirm whether it modifies anything or has performance implications, leaving gaps.

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 three sentences long, front-loaded with the core purpose, and every sentence adds value. No fluff or redundancy.

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 6 parameters and no output schema, the description should specify the output format and structure. It only vaguely mentions 'reports keys' and 'detects patterns', leaving the agent unsure whether the output is a list, count, or grouped data. This is insufficient for a tool without an output schema.

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 coverage is 100%, so baseline is 3. The description ties parameters to the overall purpose but adds little extra meaning beyond the existing schema descriptions. For example, it does not explain the impact of choosing different layers or outputFile alternatives.

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 uses specific verbs ('Find') and a clear resource ('orphan translation keys'), and distinguishes itself from sibling tools like remove_orphan_keys or search_translations by focusing on detection.

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 for cleanup but does not explicitly specify when to use this tool versus alternatives like search_translations or remove_orphan_keys. No exclusions or conditional guidance is provided.

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/fabkho/the-i18n-kit'

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