Agent skill

Hns Moaiadk Best Practices

by modu-ai in modu-ai/moai-adk

moai-adk-go best-practices reference for the 4 harness specialists (cli-template-specialist, quality-specialist, workflow-specialist, hook-ci-specialist).

Apache-2.0Auto-check: notesTesting & QA

Install Hns Moaiadk Best Practices

skills CLI
$ npx skills add modu-ai/moai-adk --skill hns-moaiadk-best-practices -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install modu-ai/moai-adk hns-moaiadk-best-practices --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/modu-ai/moai-adk.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.claude/skills/hns-moaiadk-best-practices .claude/skills/hns-moaiadk-best-practices && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
hns-moaiadk-best-practices
GitHub stars
1.2k
Token cost
~1.8k tokens
SKILL.md length
642 words
Files
1
Skills in repo
48
Repo updated
First seen
Licence
Apache-2.0

At a glance

moai-adk-go best-practices reference for the 4 harness specialists (cli-template-specialist, quality-specialist, workflow-specialist, hook-ci-specialist).

  • Testing & QA work in your project
  • SKILL.md covers TRUST 5 Quality Gates, Test Isolation, Hardcoding Prevention and AskUserQuestion Boundary…, plus 3 more sections
  • Calls go

What it does

Hns Moaiadk Best Practices is an agent skill from modu-ai/moai-adk. moai-adk-go best-practices reference for the 4 harness specialists (cli-template-specialist, quality-specialist, workflow-specialist, hook-ci-specialist). Covers TRUST 5 gates, Go test isolation (t.TempDir, no OTEL env in parallel tests), hardcoding-prevention rules (env constants in envkeys.go, thresholds in defaults.go), the AskUserQuestion orchestrator-only boundary, the deferred-tool preload rule, the archived-agent rejection contract, and verification-claim integrity. Loaded by the specialists when authoring…

Its SKILL.md is about 1.8k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Testing & QA. It works with OpenTelemetry. The repository describes itself as: Agentic development harness for Claude Code — SPEC-driven plan/run/sync, TRUST 5 quality gates, model+effort routing, and Claude×GLM multi-LLM cost control. Single Go binary, 16… The licence is Apache-2.0.

When your agent uses it

  • Testing & QA work in your project

Example prompts

  • “/hns-moaiadk-best-practices”

Requirements

  • Pre-approved tools (allowed-tools): Read, Grep, Glob, Bash

What it can do on your machine

Read from SKILL.md and the folder at commit 2aab5f7. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves these tools, so the agent can use them without asking each time:

    • Read
    • Grep
    • Glob
    • Bash

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • go

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Hns Moaiadk Best Practices loads about 1.8k tokens when it runs. Until then it costs about 144 tokens; SKILL.md has 642 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~144
When it runs · the whole SKILL.md, loaded when a task matches
~1.8k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check: notes

The automated check noted patterns worth knowing about, such as sudo or a known installer.

  • NotePre-approves every shell command (allowed-tools: Bash)SKILL.md
    allowed-tools: Read, Grep, Glob, Bash

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from modu-ai/moai-adk at commit 2aab5f7, republished under its Apache-2.0 licence (© modu-ai). 642 words, ~1,774 tokens.

Download SKILL.mdSave it as .claude/skills/hns-moaiadk-best-practices/SKILL.md (or your agent's skills folder).
name
hns-moaiadk-best-practices
description
moai-adk-go best-practices reference for the 4 harness specialists (cli-template-specialist, quality-specialist, workflow-specialist, hook-ci-specialist). Covers TRUST 5 gates, Go test isolation (t.TempDir, no OTEL env in parallel tests), hardcoding-prevention rules (env constants in envkeys.go, thresholds in defaults.go), the AskUserQuestion orchestrator-only boundary, the deferred-tool preload rule, the archived-agent rejection contract, and verification-claim integrity. Loaded by the specialists when authoring or reviewing moai-adk-go code.
allowed-tools
Read, Grep, Glob, Bash
user-invocable
false
metadata.version
1.0.0
metadata.category
harness/best-practices
metadata.status
active
metadata.updated
2026-06-17
metadata.tags
moai-adk-go,best-practices,trust5,testing,hardcoding
progressive_disclosure.level_1_tokens
120
progressive_disclosure.level_2_tokens
4000
progressive_disclosure.level_3_optional
true
triggers.agents
cli-template-specialist, quality-specialist, workflow-specialist, hook-ci-specialist

moai-adk-go Best Practices

TRUST 5 Quality Gates

Every change must pass all five dimensions before completion:

PillarGateFailure action
Testedgo test ./... with coverageBlock merge; generate missing tests
Readablegolangci-lint runWarn; suggest refactoring
Unifiedgo fmt + goimportsAuto-format or warn
SecuredOWASP-aligned review (per-spawn opus agent)Block; require review
TrackableConventional Commits regexSuggest format

Coverage targets: 85% package minimum; 90%+ for critical packages (internal/cli, internal/template, internal/hook).

Test Isolation

  • Always t.TempDir() for temp dirs — auto-cleanup, under os.TempDir().
  • macOS path pitfall: t.TempDir() returns /var/folders/.... Go's filepath.Join(cwd, absPath) does NOT strip the leading /: filepath.Join("/a/b", "/var/folders/x") → "/a/b/var/folders/x" (WRONG). Use filepath.Abs() when resolving user-supplied paths in CLI commands.
  • No OTEL env in parallel tests (CLAUDE.local.md §WARN): never t.Setenv("OTEL_EXPORTER_*", ...) in parallel tests — the OTEL SDK initializes global state from env vars on first use, causing data races. Use a fake/no-op exporter instead; or make the parent test non-parallel.
  • No t.Setenv("HOME", tmpDir) in GLM integration tests — parallel-test pollution. Use t.TempDir() + explicit path construction.
  • After fixing any test, run the FULL suite (go test ./...) to catch cascading failures. Use -count=1 to disable caching when debugging flaky tests; use -race for concurrency-safety checks.

Hardcoding Prevention

  • URLs / model names / org names / API headers → extract to const.
  • Environment variable names → define in internal/config/envkeys.go as constants; reference the constant everywhere. Never inline a raw env string.
  • Thresholds → single source in internal/config/defaults.go. Never duplicate a threshold across packages.
  • Cross-platform paths → prefer $HOME, HOMEBREW_PREFIX, etc. In .sh.tmpl fallback paths use $HOME (not .HomeDir), because .HomeDir freezes at moai init time and breaks for users with non-standard layouts.
  • Hardcoding allowed only in CLAUDE.local.md, settings.local.json, and _test.go files inside t.TempDir().

AskUserQuestion Boundary (orchestrator-only)

  • AskUserQuestion is the ONLY user-facing question channel, and it is reserved for the MoAI orchestrator (main session).
  • Subagents (including these harness specialists) MUST NOT invoke AskUserQuestion. If user input is required, return a structured blocker report to the orchestrator (see .claude/rules/moai/core/askuser-protocol.md § Blocker Report Format).
  • Deferred-tool preload: AskUserQuestion, TaskCreate, TaskUpdate, TaskList, TaskGet are deferred tools — schema not loaded at session start. The orchestrator MUST call ToolSearch(query: "select:AskUserQuestion,TaskCreate,...") before first use. Subagents inherit this constraint.
  • Free-form prose questions in response text are prohibited — always route through AskUserQuestion (orchestrator) or a blocker report (subagent).
Show full SKILL.md (280 more words)Show less

Archived-Agent Rejection Contract

12 agents are ARCHIVED and MUST NOT be referenced anywhere in generated harness files — no delegates-to, no prose, no examples. The full list of archived names lives in the canonical SSOT at .claude/rules/moai/workflow/archived-agent-rejection.md §B; this skill does not repeat the literal names (repeating them in every generated file would re-seed the exact tokens the rejection contract is meant to suppress).

The 8 RETAINED agents are the only valid delegation targets:

manager-spec, manager-develop, manager-docs, manager-git,
plan-auditor, sync-auditor, builder-harness, Explore (Anthropic built-in)

For domain expertise formerly provided by the archived domain-expert agents, use the per-spawn pattern: Agent(subagent_type: "general-purpose", tools: "<whitelist>", prompt: "...<domain> specialist: <conventions>...") at delegation time. See .claude/rules/moai/workflow/archived-agent-rejection.md §C for the full migration table (rows #1-#12), which maps each archived agent to its canonical retained-agent or per-spawn replacement.

Verification-Claim Integrity

Per .claude/rules/moai/core/verification-claim-integrity.md:

  • No unobserved claims. A "tests pass" / "coverage 87%" / "lint clean" assertion is valid ONLY when the actor ran the command and observed the output. An unran command is a gap, never a pass.
  • No unobserved defect claims. Inferring a defect/debt/drift from frontmatter text or grep matches alone — without the domain's dedicated tool (moai spec audit, go test -cover, golangci-lint) — is a hypothesis, not a verified defect. The 2026-06-17 incident (29 SPECs wrongly flagged as "Mx-close debt"; moai spec audit showed all 29 were grandfather-protected) is the canonical worked example.
  • Baseline attribution. Every verification claim names the command run + the verbatim output observed, measured against this tree in this run. A number from a different SPEC/package/time is a carry-over, not a baseline.
  • 5-section report format: Claim / Evidence / Baseline-attribution / Gaps / Residual-risk. The Gaps section is the defense — force yourself to enumerate what was NOT observed.

Cross-References

  • CLAUDE.local.md §6 (testing), §14 (hardcoding), §19 (AskUserQuestion)
  • .claude/rules/moai/core/verification-claim-integrity.md v1.1.0
  • .claude/rules/moai/core/askuser-protocol.md
  • .claude/rules/moai/workflow/archived-agent-rejection.md
  • .claude/rules/moai/development/coding-standards.md

© modu-ai, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in .claude/skills/hns-moaiadk-best-practices of modu-ai/moai-adk.

Open the folder on GitHubat commit 2aab5f7

Compare with similar skills

Hns Moaiadk Best Practices next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Hns Moaiadk Best Practices compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Hns Moaiadk Best Practices this skillmodu-ai/moai-adk1.2k—~1.8kAutomated safety check: NotesApache-2.0
Integration Testtracewayapp/traceway1.6k—~2.4kAutomated safety check: PassMIT
Dashboard Testingmicrosoft/aspire6.4k—~4.7kAutomated safety check: PassMIT
E2E Testgrafana/agento11y128—~1.7kAutomated safety check: NotesApache-2.0
Xp Copilotfike/fastapi-blog101—~286Automated safety check: PassMIT
Openclaw QA Testingopenclaw/openclaw392k—~2.9kAutomated safety check: PassMIT

Similar skills

  • Integration Test

    tracewayapp/traceway

    Run a live-instance verification of traceway-cli that goes beyond the Go smoke suite — exercises real-data detail endpoints, TTY-default rendering, adaptive metric-name discovery, and emits a…

    1.6k GitHub stars~2.4k tokensUpdated 5 days ago
    Testing & QAAuto-check passed
  • Dashboard Testing

    microsoft/aspire

    Official

    Guide for writing tests for the Aspire Dashboard. An agent skill from microsoft/aspire.

    6.4k GitHub stars~4.7k tokensUpdated today
    Testing & QAAuto-check passed
  • E2E Test

    grafana/agento11y

    Official

    Optional credential-free Hermes integration checks using an explicit loopback model provider and local telemetry receivers.

    128 GitHub stars~1.7k tokensUpdated yesterday
    Testing & QAAuto-check: notes
  • Xp Copilot

    fike/fastapi-blog

    Skill for Extreme Programming (XP) practices and Test-Driven Development (TDD).

    101 GitHub stars~286 tokensUpdated 2 days ago
    Testing & QAAuto-check passed
  • Openclaw QA Testing

    openclaw/openclaw

    Run, watch, debug, extend, or explain OpenClaw qa-lab and qa-channel scenarios, artifacts, and live lanes.

    392k GitHub stars~2.9k tokensUpdated today
    Testing & QAAuto-check passed
  • Error Handling And E2E

    home-operations/kopiur

    How Kopiur does strongly-typed, actionable error handling and end-to-end testing.

    115 GitHub stars~2.7k tokensUpdated today
    Testing & QAAuto-check passed

More from modu-ai/moai-adk

All 48 skills in this repo
  • Builds hand-editable SVG diagrams from computed layout coordinates, lints the source and renders a 2x PNG, with rules for when mermaid is the better choice.

    1.2k GitHub stars~5.2k tokensUpdated yesterday
    Auto-check: notes
  • MoAI Foundation Core

    modu-ai/moai-adk

    Reference for MoAI-ADK's core development principles: TRUST 5 quality gates, SPEC-first domain-driven workflow, agent delegation and token budgeting.

    1.2k GitHub stars~5k tokensUpdated yesterday
    Auto-check passed
  • MoAI SPEC Workflow

    modu-ai/moai-adk

    Manages SPEC documents for MoAI-ADK development, with GEARS or EARS requirement notation, acceptance criteria and a link into the Plan-Run-Sync workflow.

    1.2k GitHub stars~5.1k tokensUpdated yesterday
    Auto-check passed
  • MoAI TDD Workflow

    modu-ai/moai-adk

    Drives test-first development through the RED, GREEN, REFACTOR cycle, with a config switch that selects between TDD and a DDD workflow for existing code.

    1.2k GitHub stars~3.1k tokensUpdated yesterday
    Auto-check passed
  • MoAI Worktree Management

    modu-ai/moai-adk

    Gives each SPEC its own Git worktree with a registry of active workspaces, base-branch sync and cleanup of merged ones, inside the MoAI-ADK workflow.

    1.2k GitHub stars~3.9k tokensUpdated yesterday
    Auto-check passed
  • Watches a pull request's CI checks after creation, separates required from auxiliary failures, applies limited safe fixes and escalates anything semantic to you.

    1.2k GitHub stars~2.4k tokensUpdated yesterday
    Auto-check: notes

Works with

Questions about Hns Moaiadk Best Practices

What does Hns Moaiadk Best Practices do?

moai-adk-go best-practices reference for the 4 harness specialists (cli-template-specialist, quality-specialist, workflow-specialist, hook-ci-specialist). Hns Moaiadk Best Practices is an agent skill from modu-ai/moai-adk. moai-adk-go best-practices reference for the 4 harness specialists (cli-template-specialist, quality-specialist, workflow-specialist, hook-ci-specialist).

When should I use Hns Moaiadk Best Practices?

Hns Moaiadk Best Practices fits situations like: testing & QA work in your project.

How do I install Hns Moaiadk Best Practices in Claude Code?

Run `npx skills add modu-ai/moai-adk --skill hns-moaiadk-best-practices -a claude-code`. Or copy the skill folder (.claude/skills/hns-moaiadk-best-practices in modu-ai/moai-adk) into .claude/skills/hns-moaiadk-best-practices in your project. Claude Code loads it when a task matches its description.

How do I install Hns Moaiadk Best Practices in Codex?

Run `npx skills add modu-ai/moai-adk --skill hns-moaiadk-best-practices -a codex`. Or copy the skill folder (.claude/skills/hns-moaiadk-best-practices in modu-ai/moai-adk) into .agents/skills/hns-moaiadk-best-practices in your project. Codex loads it when a task matches its description.

Can I use Hns Moaiadk Best Practices in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add modu-ai/moai-adk --skill hns-moaiadk-best-practices -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/hns-moaiadk-best-practices, .gemini/skills/hns-moaiadk-best-practices, .github/skills/hns-moaiadk-best-practices and .opencode/skills/hns-moaiadk-best-practices in your project.

What does Hns Moaiadk Best Practices need to run?

Going by SKILL.md and its folder, Hns Moaiadk Best Practices needs the command-line tools its instructions call (go). Its frontmatter pre-approves these tools: Read, Grep, Glob, Bash.

Does Hns Moaiadk Best Practices access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Hns Moaiadk Best Practices safe to install?

Our automated static check of SKILL.md found notes only (pre-approves every shell command (allowed-tools: bash)), nothing it rates as a warning. It is not a guarantee. Review the folder before installing.

What licence does Hns Moaiadk Best Practices use?

Hns Moaiadk Best Practices is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Hns Moaiadk Best Practices use?

About 1.8k tokens (SKILL.md is roughly 7.1k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Hns Moaiadk Best Practices?

Skills that share tags, products or a category with Hns Moaiadk Best Practices: Integration Test (tracewayapp/traceway, 1.6k stars), Dashboard Testing (microsoft/aspire, 6.4k stars), E2E Test (grafana/agento11y, 128 stars) and Xp Copilot (fike/fastapi-blog, 101 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Hns Moaiadk Best Practices?

modu-ai (a GitHub organization) maintains it in modu-ai/moai-adk, which has 1,230 GitHub stars. The repository holds 48 skills in this directory. The repository was last updated on October 9, 2026.

Source: modu-ai/moai-adk on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.