Skip to main content
Glama
PlumyCat

MCP LangChainJS Search Server

by PlumyCat

MCP LangChainJS Server

CI

Serveur MCP (Model Context Protocol) en TypeScript permettant de rechercher des exemples et du code dans le dépôt GitHub LangChainJS (langchain-ai/langchainjs). Il expose un outil search_langchain que les clients MCP (ex. Claude Desktop) peuvent appeler pour retrouver rapidement des snippets TS/JS/MD pertinents.

Aperçu

  • Outil principal: search_langchain

  • Source: GitHub Search Code API via @octokit/rest

  • Transport: stdio (pour intégration avec clients MCP)

  • Langage: TypeScript (build vers dist/)

Related MCP server: github-rag-mcp

Prérequis

  • Node.js 18+ et npm

  • (Optionnel) Un jeton GitHub personnel pour des quotas plus généreux

    • Variable d’environnement: GITHUB_TOKEN

Installation

npm install
npm run build

Démarrage

  • Développement (TypeScript, sans build):

npm run dev
  • Watch (redémarrage auto):

npm run watch
  • Production (depuis dist/):

npm start

Le serveur écoute via stdio et est destiné à être lancé par un client MCP.

Configuration du client MCP (ex. Claude Desktop)

Exemple de configuration Claude Desktop (à adapter à votre chemin local) :

{
  "mcpServers": {
    "langchain-js": {
      "command": "node",
      "args": [
        "/chemin/vers/votre/projet/dist/index.js"
      ],
      "env": {
        "GITHUB_TOKEN": "votre_token_optionnel"
      }
    }
  }
}

Notes:

  • GITHUB_TOKEN est recommandé pour éviter les limitations strictes de l’API publique.

  • Ne commitez jamais de secrets. Préférez des variables d’environnement ou un fichier .env ignoré par Git.

Variables d’environnement

Vous pouvez fournir un jeton GitHub pour augmenter les limites d’API :

export GITHUB_TOKEN=ghp_xxx_votre_token

Ou via un fichier .env (non commité) si votre outil de lancement le supporte.

Outils exposés

  • search_langchain

    • Entrée:

      • query (string, requis): la requête de recherche (TS/JS/MD)

    • Sortie (texte): liste des correspondances avec nom, chemin, et URL HTML

Exemple d’appel (côté client MCP):

{
  "name": "search_langchain",
  "arguments": { "query": "RetrievalQA" }
}

Architecture

  • src/index.ts: serveur MCP + transport stdio, enregistrement des handlers

  • src/tools/search.ts: schéma de l’outil et handler search_langchain

  • src/github-client.ts: client GitHub (Octokit) pour recherche et lecture de contenu

  • src/types.ts: types internes (exemples, résultats)

Scripts npm

  • npm run dev: exécute src/index.ts avec ts-node

  • npm run watch: redémarre avec nodemon sur changements

  • npm run build: compile TypeScript vers dist/

  • npm start: lance node dist/index.js

Dépannage

  • Erreurs 403/abuse/ratelimit: fournissez GITHUB_TOKEN.

  • Résultats vides: vérifiez la requête (query) et les extensions ciblées (TS/JS/MD).

  • Import/ESM: le projet est configuré en type: commonjs avec ts-node adapté; utilisez npm run build puis npm start en prod.

Sécurité

  • Ne mettez jamais un jeton en clair dans le dépôt.

  • Préférez des variables d’environnement et des gestionnaires de secrets.

Licence

ISC

Available Tools

1 tool
search_langchainB

Search for examples and code in the LangChainJS GitHub repository

ParametersJSON Schema
NameRequiredDescriptionDefault
queryYesSearch query for finding relevant examples (TS/JS/MD)

TDQS

B3.3/5.0
Behavior2/5

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

No annotations provided, so description must carry full behavioral disclosure. It only states the action and target, but does not disclose return value format, whether authentication is needed, any limits, or read-only nature. This is a minimal functional description.

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, front-loaded, no redundant information.

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

Completeness3/5

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

Simple tool with one parameter and no output schema, but the description does not explain what result is returned or any usage caveats. For a search tool, knowing something about the return (list of files, code snippets) would be helpful, so it's adequate but not complete.

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 covers 100% of parameters with a clear description ('Search query for finding relevant examples (TS/JS/MD)'). The tool description adds the context 'examples and code' but does not add additional parameter specifics, so baseline 3 is appropriate.

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?

Clear verb 'Search', specific resource 'LangChainJS GitHub repository', and object 'examples and code'. Though no siblings exist to differentiate from, the description is precise and unambiguous.

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

Usage Guidelines2/5

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

No guidance on when to use this tool versus alternatives, no exclusions or context. Since there are no sibling tools, the absence is less critical, but the description still lacks any conditionality.

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

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. 1 tool updatev1.0.0
    • First observedsearch_langchain

TDQS

A3.7/5.0
Disambiguation5/5

With only one tool available, there is no possibility of confusing it with another tool. The tool's purpose is clearly defined by its name and description.

Naming Consistency5/5

The single tool name follows a clear verb_noun pattern (search_langchain), and since there are no other tools, there is no inconsistency to worry about.

Tool Count3/5

The server is explicitly a search-only server, so one tool is arguably appropriate, but it falls below the typical 3-15 tool range, making it feel minimal.

Completeness5/5

For its stated purpose of searching LangChainJS examples and code, the tool provides the core functionality without obvious gaps. The agent can search and receive results directly.

Maintenance

ActivityInactive
ResponsivenessNo issues

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Connectors

Related MCP Servers

  • A
    license
    Not graded
    quality
    D
    maintenance
    Provides real-time access to official LangChain documentation, API references, and GitHub code examples to assist in LangChain-based development. It enables LLMs to search for tutorials, version info, and detailed class specifications directly from live sources.
    1
    MIT
  • A
    license
    Not graded
    quality
    A
    maintenance
    Enables AI agents to search and retrieve context from GitHub issues, pull requests, releases, and documentation using hybrid semantic search and time-ordered activity scans.
    103
    Apache 2.0
  • A
    license
    A
    quality
    C
    maintenance
    Enables AI agents to prospect across GitHub, PyPI, and npm, searching repositories, packages, and code patterns with read-only tools.
    7
    3
    MIT

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/PlumyCat/mcp-github-langchain-js'

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