HCL-Lab_mcp: Instructions file for Claude Code

CLAUDE.md

HCL-Lab_mcp CLAUDE.md is an instructions file for Claude Code from FlySun1116/HCL-Lab_mcp. It costs 3,770 tokens per session, scanned A, original, Apache-2.0.

Project rules for an MCP server that lets compatible AI clients inspect H3C network labs and, under controlled conditions, run network-device commands. MCP is a standard way for an AI client to use external tools.

In plain words
What is it for?
They guide work on discovering lab devices and links, checking device status, querying configurations and diagnostics, and planning approved, auditable changes.
Why use it?
They establish the project’s facts, safety boundaries, supported platform, and required takeover process before code changes are made.

Instructions file for Claude Code

Written for Claude Code: the file is CLAUDE.md. Also seen: mentions CLAUDE.md; mentions Claude Code.

This is FlySun1116/HCL-Lab_mcp's own configuration. It tells Claude Code how to work on HCL-Lab_mcp itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything HCL-Lab_mcp configures →

Reuse

Borrowing it

Nothing to install: this file belongs to FlySun1116/HCL-Lab_mcp. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/FlySun1116/HCL-Lab_mcp/main/CLAUDE.md
Clone the repo
git clone --depth 1 https://github.com/FlySun1116/HCL-Lab_mcp

Made for: Claude Code.

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 HCL-Lab_mcp CLAUDE.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/flysun1116/hcl-lab_mcp/claude-md/github.svg)](https://agentmods.dev/instructions/flysun1116/hcl-lab_mcp/claude-md)
Your own site
<a href="https://agentmods.dev/instructions/flysun1116/hcl-lab_mcp/claude-md"><img src="https://agentmods.dev/badge/instructions/flysun1116/hcl-lab_mcp/claude-md/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 HCL-Lab_mcp CLAUDE.md

Your own site · 80×15
<a href="https://agentmods.dev/instructions/flysun1116/hcl-lab_mcp/claude-md"><img src="https://agentmods.dev/badge/instructions/flysun1116/hcl-lab_mcp/claude-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 3,770 This file is loaded in full into every session.
When invoked 3,770 The same file — it is already loaded in full.
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.03770 $0.03770
Opus 5 $0.01885 $0.01885
Sonnet 5 $0.00754 $0.00754
Haiku 4.5 $0.00377 $0.00377

Measured 9d ago against content hash aaae20f02067, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

HCL-Lab_mcp CLAUDE.md 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 9d 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.

CLAUDE.md · 295 lines

How it starts

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

HCL-Lab_mcp 项目规则

本文件是 Claude Code、兼容 Claude Code 的模型服务以及 Agent Team 在本仓库工作的长期规则。进入仓库后先读本文件,再读 docs/design.md。不要仅凭历史对话或模型记忆重新解释项目。

1. 项目身份

  • 项目:HCL-Lab_mcp
  • GitHub:https://github.com/FlySun1116/HCL-Lab_mcp.git
  • Python distribution:h3c-hcl-mcp
  • Python import package:h3c_hcl_mcp
  • 许可证目标:Apache-2.0,最终以仓库 LICENSE 为准
  • 主要平台:Windows + H3C Cloud Lab 5.10.x
  • 主要语言:Python 3.12
  • MCP SDK:官方 MCP Python SDK 的稳定版本线

这是一个独立运行的通用 MCP Server,不是 Claude、Cursor 或某个模型专用插件。任何兼容 MCP 的 Client 都应能使用相同的 Tool Schema。

2. 产品目标

让 MCP Client 能够:

  1. 发现用户自己的 HCL 项目、设备和链路;
  2. 判断 HCL 设备运行态和本机 console 可用性;
  3. 通过 HCL loopback Telnet console 或设备 SSH 执行受控 Comware CLI;
  4. 查询设备 facts、接口、配置和诊断结果;
  5. 在后续版本通过计划、审批、基线校验和审计执行配置变更;
  6. 分析实验拓扑并辅助网络实验。

当前阶段聚焦 HCL/H3C。架构需允许未来增加其他设备 adapter,但 v0.x 不提前实现 Huawei、Cisco、Juniper。

3. 事实来源优先级

发生冲突时按以下顺序执行:

  1. 用户在当前会话中的明确要求;
  2. 安全、许可和平台权限限制;
  3. docs/design.md 中已批准的架构与版本范围;
  4. 已接受的 ADR;
  5. GitHub Issue 的验收条件;
  6. 本文件;
  7. 其他文档和历史提示词。

不要重新设计已在 docs/design.md 固化的内容。需要改变公共 Tool、Port、错误码、安全模型或版本范围时,先提交 ADR/设计差异并请求一次重要决策确认。

4. 首次接管流程

首次进入一个工作目录时,先做接管分析,不直接写业务代码:

  1. 执行 git rev-parse --show-toplevelgit status --short --branchgit remote -v
  2. 如果是有效 Git 仓库,执行 git fetch --all --prune,仅在工作树安全时执行 git pull --ff-only
  3. 不使用会覆盖本地改动的 pull、reset、checkout 或 clean;
  4. 阅读 CLAUDE.mddocs/design.md、现有 ADR、README、CONTRIBUTING、HANDOVER 和当前 Issue;缺失文件记录为待办,不虚构内容;
  5. 检查当前分支、未提交改动、已有代码、测试、CI 和最近提交;
  6. 输出接管报告:仓库状态、当前版本、已完成内容、架构边界、风险、阻塞项和建议任务图;
  7. 首次接管报告完成后,再按 Issue 或用户目标自主开发。

如果目录不是有效 Git 仓库,不删除现有文件。报告该事实;本地 git init、建立 feature branch等可逆操作可以自主进行,但首次建立/推送远端 main 属重要操作,必须请求一次确认。

5. 自主工作原则

除“必须确认”事项外,不要因为普通实现选择反复询问用户。先检查仓库和文档,做最合理、最小范围、可回滚的决定,完成实现与验证,并在交接记录假设。

默认自主执行,不需要逐步确认

  • 搜索、阅读和分析项目代码、文档、测试、Git 历史;
  • 读取任务范围内的本机 HCL 项目格式、脱敏日志和只读运行信息;
  • 创建短期 feature/fix/docs/refactor 分支;
  • 新建或修改任务范围内的源码、测试、文档、示例和合成 fixtures;
  • 修复 lint、类型、测试、构建和文档问题;
  • 运行测试、MCP Inspector、构建、静态检查和安全扫描;
  • 安装锁文件已有依赖;添加小型、维护活跃、许可证兼容且确有必要的依赖;
  • 执行非破坏性 Git 操作:status、diff、log、fetch、pull --ff-only、add、commit;
  • push 当前非保护 feature 分支,创建或更新 Draft PR;
  • 根据 CI 结果继续修复,直到通过或出现真实阻塞;
  • 更新 README、CHANGELOG、兼容矩阵和 HANDOVER;
  • 对低风险细节作出合理假设并明确记录。

Read the full file on GitHub · 295 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. 9d ago First seen · 295 lines · 3,770 tokens per session scan A aaae20f02067

Subscribe to this mod's changes

HCL-Lab_mcp CLAUDE.md is an instructions file published in the GitHub repository FlySun1116/HCL-Lab_mcp (1 stars, last pushed 7d ago), licensed Apache-2.0. It adds 3,770 tokens to every session, about $0.0188 per session on Opus 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-31.

Related

Other instructions, from other repositories

next.js AGENTS.md

AGENTS.md instructions for vercel/next.js, covering next.js development guide, codebase structure, monorepo overview, core package: packages/next and other important packages.

vercel/next.js · 7,296 tokens

codex AGENTS.md

AGENTS.md instructions for openai/codex, covering rust/codex-rs, the codex-core crate, code review rules, crate api surface and model visible context.

openai/codex · 5,153 tokens

vscode buildNext.instructions.md

Working notes and architecture documentation for the new esbuild-based build system in build/next. Use when making changes to the new build pipeline (transpile/bundle commands, NLS plugin, source-map handling, resource copying, or self-hosting watch tasks).

microsoft/vscode · 6,785 tokens

vscode oss-third-party-notices.instructions.md

Instructions for microsoft/vscode, covering vs code oss third-party-notices pipeline, architecture, pipeline flow in ci, applying the notice (cutover) and fallback chain (never fail the build).

microsoft/vscode · 5,001 tokens

langchain AGENTS.md

AGENTS.md instructions for langchain-ai/langchain, covering global development guidelines for the langchain monorepo, corridor security analysis, project architecture and context, monorepo structure and development tools & commands.

langchain-ai/langchain · 4,469 tokens

deepseek-harness AGENTS.md

AGENTS.md instructions for deepseek-ai/deepseek-harness, covering agents.md, pre-stable apis and released session data, repository layout, commands and host sandbox failures.

deepseek-ai/deepseek-harness · 3,735 tokens