language-detector

language-detector is an agent for Claude Code from closedloop-ai/claude-plugins. It costs 12 tokens per session (1,403 once invoked), scanned A, original, Apache-2.0.

A codebase check that identifies programming languages by counting files with known extensions, such as .py for Python or .ts for TypeScript.

In plain words
What is it for?
Use it to see the language mix in a repository and calculate each language’s share of the counted files.
Why use it?
It gives a simple estimate of which languages are present without relying on complex code analysis. An optional focus setting can limit the check to part of the repository.

Agent for Claude Code

Written for Claude Code: shipped in a Claude Code plugin. Also seen: model in frontmatter.

Part of the bootstrap plugin — 1 command, 9 agents shipped together

Good fit Use it to see the language mix in a repository and calculate each language’s share of the counted files.

Compare 6 agents from other repositories ↓
Install with agentmods
npx agentmods add agents/closedloop-ai/claude-plugins/language-detector
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/closedloop-ai/claude-plugins

Made for: Claude Code.

Or install bootstrap, the plugin that ships this one along with the rest of its 1 command, 9 agents.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for language-detector

README.md
[![agentmods](https://agentmods.dev/badge/agents/closedloop-ai/claude-plugins/language-detector/github.svg)](https://agentmods.dev/agents/closedloop-ai/claude-plugins/language-detector)
Your own site
<a href="https://agentmods.dev/agents/closedloop-ai/claude-plugins/language-detector"><img src="https://agentmods.dev/badge/agents/closedloop-ai/claude-plugins/language-detector/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for language-detector

Your own site · 80×15
<a href="https://agentmods.dev/agents/closedloop-ai/claude-plugins/language-detector"><img src="https://agentmods.dev/badge/agents/closedloop-ai/claude-plugins/language-detector.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 12 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,403 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00012 $0.01403
Opus 5.5 $0.00005 $0.00561
Sonnet 5.5 $0.00002 $0.00281
Haiku 4.5 $0.00001 $0.00140

Measured 1mo ago against content hash 3489960a0d11, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

language-detector scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/bootstrap/agents/language-detector.md · 212 lines

How it starts

The opening of the file, as written. The whole thing — 212 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Language Detector

Role

You detect which programming languages are present in the codebase through simple, reliable file counting. No heuristics or complex analysis - just count files by extension and calculate distribution percentages.

Inputs

  • Repository root directory
  • CLI --focus flag (if provided) to constrain analysis

Task

Count source files by extension to determine language distribution:

File Extensions to Count

Web/JavaScript/TypeScript:

  • *.ts - TypeScript
  • *.tsx - TypeScript React
  • *.js - JavaScript
  • *.jsx - JavaScript React
  • *.mjs - ES Module JavaScript
  • *.cjs - CommonJS JavaScript

Python:

  • *.py - Python

Java:

  • *.java - Java
  • *.kt - Kotlin
  • *.kts - Kotlin Script

C-family:

  • *.c - C
  • *.cpp, *.cc, *.cxx - C++
  • *.h, *.hpp - C/C++ headers
  • *.m - Objective-C
  • *.mm - Objective-C++
  • *.swift - Swift

Other:

  • *.go - Go
  • *.rs - Rust
  • *.rb - Ruby
  • *.php - PHP
  • *.cs - C#
  • *.scala - Scala
  • *.ex, *.exs - Elixir
  • *.clj, *.cljs - Clojure

Detection Process

  1. Use Glob or Bash to count files by extension:

    # Example for TypeScript
    find . -name "*.ts" -o -name "*.tsx" | wc -l
    
  2. Exclude common directories:

    • node_modules/
    • build/, dist/, out/
    • .next/, .expo/
    • target/ (Java/Rust)
    • venv/, __pycache__/ (Python)
    • .git/
    • coverage/
  3. Aggregate by language:

    • TypeScript = *.ts + *.tsx
    • JavaScript = *.js + *.jsx + *.mjs + *.cjs (but exclude if TS is dominant)
    • Java = *.java
    • Kotlin = *.kt + *.kts
    • etc.
  4. Calculate distribution:

    • Total files = sum of all language files
    • Language percentage = (language files / total files) × 100
    • Round to 2 decimal places
  5. Identify primary language:

    • Language with highest percentage (must be ≥30% to qualify as primary)
    • If no language ≥30%, report "mixed" as primary

Read the full file on GitHub · 212 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago First seen · 212 lines · 12 tokens per session scan A 3489960a0d11

Subscribe to this mod's changes

language-detector is an agent published in the GitHub repository closedloop-ai/claude-plugins (122 stars, last pushed yesterday), licensed Apache-2.0. It adds 12 tokens to every session and 1,403 once invoked, about $0.0000 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other agents, from other repositories

swift-build-resolver

Swift/Xcode build, compilation, and dependency error resolution specialist. Fixes swift build errors, Xcode build failures, SPM dependency issues, and code signing problems with minimal changes. Use when Swift builds fail.

affaan-m/ECC · 48 tokens

java-reviewer

Expert Java code reviewer for Spring Boot and Quarkus projects. Automatically detects the framework and applies the appropriate review rules. Covers layered architecture, JPA/Panache, MongoDB, security, and concurrency. MUST BE USED for all Java code changes.

affaan-m/ECC · 55 tokens

kotlin-reviewer

Kotlin and Android/KMP code reviewer. Reviews Kotlin code for idiomatic patterns, coroutine safety, Compose best practices, clean architecture violations, and common Android pitfalls.

affaan-m/ECC · 38 tokens

php-reviewer

Expert PHP code reviewer specializing in PSR-12 compliance, PHP type system, Eloquent ORM patterns, security, and performance. Use for all PHP code changes. MUST BE USED for PHP projects.

affaan-m/ECC · 44 tokens

java-build-resolver

Java/Maven/Gradle build, compilation, and dependency error resolution specialist. Automatically detects Spring Boot or Quarkus and applies framework-specific fixes. Use when Java builds fail.

affaan-m/ECC · 41 tokens

kotlin-build-resolver

Kotlin/Gradle build, compilation, and dependency error resolution specialist. Fixes build errors, Kotlin compiler errors, and Gradle issues with minimal changes. Use when Kotlin builds fail.

affaan-m/ECC · 44 tokens