Nx Import
nrwl/nx
Import, merge, or combine repositories into an Nx workspace using nx import.
Describes the hexagonal architecture (ports and adapters) used across the Packmind monorepo.
$ npx skills add PackmindHub/packmind --skill hexagonal-architecture -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install PackmindHub/packmind hexagonal-architecture --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/PackmindHub/packmind.git skills-src && mkdir -p .claude/skills && cp -r skills-src/packages/.agents/skills/hexagonal-architecture .claude/skills/hexagonal-architecture && rm -rf skills-srcUse ~/.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/
Install the "hexagonal-architecture" agent skill from https://github.com/PackmindHub/packmind/tree/main/packages/.agents/skills/hexagonal-architecture into .claude/skills/hexagonal-architecture/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "hexagonal-architecture", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/PackmindHub/packmind/tree/main/packages/.agents/skills/hexagonal-architectureType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add PackmindHub/packmind --skill hexagonal-architecture -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install PackmindHub/packmind hexagonal-architecture --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/PackmindHub/packmind.git skills-src && mkdir -p .agents/skills && cp -r skills-src/packages/.agents/skills/hexagonal-architecture .agents/skills/hexagonal-architecture && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "hexagonal-architecture" agent skill from https://github.com/PackmindHub/packmind/tree/main/packages/.agents/skills/hexagonal-architecture into .agents/skills/hexagonal-architecture/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "hexagonal-architecture", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add PackmindHub/packmind --skill hexagonal-architecture -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install PackmindHub/packmind hexagonal-architecture --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/PackmindHub/packmind.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/packages/.agents/skills/hexagonal-architecture .cursor/skills/hexagonal-architecture && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "hexagonal-architecture" agent skill from https://github.com/PackmindHub/packmind/tree/main/packages/.agents/skills/hexagonal-architecture into .cursor/skills/hexagonal-architecture/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "hexagonal-architecture", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/PackmindHub/packmind.git --path packages/.agents/skills/hexagonal-architecture--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add PackmindHub/packmind --skill hexagonal-architecture -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install PackmindHub/packmind hexagonal-architecture --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/PackmindHub/packmind.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/packages/.agents/skills/hexagonal-architecture .gemini/skills/hexagonal-architecture && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "hexagonal-architecture" agent skill from https://github.com/PackmindHub/packmind/tree/main/packages/.agents/skills/hexagonal-architecture into .gemini/skills/hexagonal-architecture/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "hexagonal-architecture", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install PackmindHub/packmind hexagonal-architectureInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add PackmindHub/packmind --skill hexagonal-architecture -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/PackmindHub/packmind.git skills-src && mkdir -p .github/skills && cp -r skills-src/packages/.agents/skills/hexagonal-architecture .github/skills/hexagonal-architecture && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "hexagonal-architecture" agent skill from https://github.com/PackmindHub/packmind/tree/main/packages/.agents/skills/hexagonal-architecture into .github/skills/hexagonal-architecture/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "hexagonal-architecture", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add PackmindHub/packmind --skill hexagonal-architecture -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install PackmindHub/packmind hexagonal-architecture --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/PackmindHub/packmind.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/packages/.agents/skills/hexagonal-architecture .opencode/skills/hexagonal-architecture && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "hexagonal-architecture" agent skill from https://github.com/PackmindHub/packmind/tree/main/packages/.agents/skills/hexagonal-architecture into .opencode/skills/hexagonal-architecture/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "hexagonal-architecture", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
hexagonal-architectureDescribes the hexagonal architecture (ports and adapters) used across the Packmind monorepo.
Hexagonal Architecture is an agent skill from PackmindHub/packmind. Describes the hexagonal architecture (ports and adapters) used across the Packmind monorepo. This skill should be used when creating new domain packages, use cases, services, repositories, domain error classes, or any architectural component to follow established patterns, including how a failure raised in a use case becomes an HTTP response.
Its SKILL.md is about 2.3k tokens, which your agent loads only when the skill is triggered. The skill folder holds 15 other files (for example `components/adapter.md`, `components/contract.md` and `components/event.md`).
It sits in Development, covering Monorepo tooling. The repository describes itself as: Packmind seamlessly captures your engineering playbook and turns it into AI context, guardrails, and governance. The licence is Apache-2.0.
2 steps, taken from the first numbered list in SKILL.md.
Read from SKILL.md and the folder at commit 8a10541. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
No scripts in the folder and no shell commands in SKILL.md.
From the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md.
From URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Hexagonal Architecture loads about 2.3k tokens when it runs. Until then it costs about 92 tokens; SKILL.md has 722 words of instructions outside code blocks.
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.
The automated check found no risky patterns in SKILL.md.
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.
The full file from PackmindHub/packmind at commit 8a10541, republished under its Apache-2.0 licence (© PackmindHub). 722 words, ~2,329 tokens.
.claude/skills/hexagonal-architecture/SKILL.md (or your agent's skills folder). This skill also uses 13 other files; get the full folder from GitHub.Every domain package follows a three-layer hexagonal (ports & adapters) architecture. Dependencies flow inward only: Infrastructure -> Application -> Domain.
packages/{domain}/src/
├── domain/ # Pure business logic, zero dependencies
│ ├── entities/ # Domain entities and value objects
│ ├── repositories/ # Repository interfaces (ports)
│ ├── jobs/ # Delayed job definitions
│ ├── errors/ # Domain-specific error classes
│ ├── utils/ # Domain-specific utility functions
│ └── types/ # Domain-specific type definitions
│
├── application/ # Orchestration & coordination
│ ├── useCases/{name}/ # One folder per use case
│ │ └── {name}.usecase.ts
│ ├── services/ # Domain services + service aggregator
│ ├── adapter/ # Outbound adapter (implements port)
│ ├── listeners/ # Domain event listeners
│ └── jobs/ # Delayed job implementations
│
├── infra/ # Concrete implementations
│ ├── repositories/ # Repository implementations (TypeORM)
│ ├── schemas/ # TypeORM EntitySchema definitions
│ └── jobs/ # Job factories
│
└── index.ts # Package exports + {Domain}Hexa facade| Layer | Depends On | Purpose | Details |
|---|---|---|---|
| Domain | Nothing (pure TS + @packmind/types) | Business rules, entity definitions, port interfaces | domain-layer.md |
| Application | Domain | Use case orchestration, services, adapters, events | application-layer.md |
| Infrastructure | Domain + Application | Persistence, schemas, job queues | infrastructure-layer.md |
Each component type has its own detailed guide with templates and examples:
| Component | Layer | File Pattern | Guide |
|---|---|---|---|
| Use Case | Application | application/useCases/{name}/{name}.usecase.ts | usecase.md |
| Service | Application | application/services/{Name}Service.ts | service.md |
| Adapter | Application | application/adapter/{Domain}Adapter.ts | adapter.md |
| Port | Types package | packages/types/src/{domain}/ports/I{Domain}Port.ts | port.md |
| Contract | Types package | packages/types/src/{domain}/contracts/{UseCaseName}.ts | contract.md |
| Repository (interface) | Domain | domain/repositories/I{Entity}Repository.ts | repository.md |
| Repository (impl) | Infrastructure | infra/repositories/{Entity}Repository.ts | repository.md |
| Schema | Infrastructure | infra/schemas/{Entity}Schema.ts | schema.md |
| Listener | Application | application/listeners/{Domain}Listener.ts | listener.md |
| Event | Types package | packages/types/src/events/{EventName}.ts | event.md |
| Hexa Facade | Root | {Domain}Hexa.ts + index.ts | hexa-facade.md |
API (NestJS controllers)
│
▼
┌─────────────┐
│ HexaRegistry │ ── Central DI container
└──────┬──────┘
│ getAdapter<IXxxPort>(portName)
▼
┌─────────────┐
│ {Domain}Hexa │ ── Facade: wires repos, services, adapter
└──────┬──────┘
│
┌────┴────┐
▼ ▼
Adapter Services ── Application layer
│ │
▼ ▼
Use Cases ──► Domain entities + Repository interfaces
│
▼
Infra Repositories ── Concrete persistence (TypeORM)Domains talk to each other through two mechanisms:
Synchronous - Via ports injected through the HexaRegistry during initialize().
Example: StandardsAdapter calls IGitPort.commitToGit().
Asynchronous - Via domain events emitted through PackmindEventEmitterService.
Example: StandardCreatedEvent triggers DeploymentsListener.handleStandardCreated().
See event.md and adapter.md for patterns.
A failure raised in a use case becomes an HTTP response through DomainExceptionFilter,
registered globally as an APP_FILTER. The filter recognises an error by its kind.
packages/types/src/errors/ declares three interfaces that carry one — DomainError,
InternalError and UpstreamError — whose kind values do not overlap. They partition
failures by fault: the caller's (DomainError), ours (InternalError), a third
party's (UpstreamError). Fault is the axis, not the HTTP status class — classify by
whose fault it is, then read the status off the table:
| kind | HTTP | Log level | Message returned | Frontend retries |
|---|---|---|---|---|
not_found | 404 | warn | yes | no |
forbidden | 403 | warn | yes | no |
invalid_input | 400 | warn | yes | no |
conflict | 409 | warn | yes | no |
internal (PackmindInternalError) | 500 | error + stack | no, generic body | yes, once |
upstream_unavailable (PackmindUpstreamError) | 502 | warn | yes | yes, once |
upstream_rate_limited (PackmindUpstreamError) | 429 | warn | yes, plus Retry-After | no |
Two rows look wrong until you read them by fault, so leave them alone. upstream_unavailable
answers 502, not 503: a 503 claims we are unavailable, while it is the thing behind us
that failed. upstream_rate_limited answers a 4xx and is still not a DomainErrorKind:
the caller did not misuse the API — our shared credential hit someone else's quota, and
waiting, not a corrected request, is the remedy. When the provider said how long to wait, the
error carries retryAfterSeconds and the filter emits it as the Retry-After header.
Never throw new Error(...) from a use case or a service. A bare Error carries no
kind, so it reaches Nest's ExceptionsHandler and answers 500 with a full stack logged at
error level — even when the correct answer was a 404.
Controllers propagate; they never translate. No instanceof plus throw new NotFoundException(...) — the filter is the only place kind maps to a status.
They also never log. A catch block that does logger.error(msg, { error: error.message }) and then throw error; records an expected, caller-correctable failure
at error level, throws away the stack and the typed context, and leaves the filter to
log the same failure a second time at warn. Two records of one event, and the louder
carries less. Delete the catch — the filter records it once, with more.
Listeners run outside the HTTP request scope, so the filter never sees their exceptions: a
listener logs a domain error at warn, an upstream error at warn too, and an internal
error at error with its stack.
Full rules, including the non-leaking cross-tenant rule, are in the
domain-error-handling standard. See domain-layer.md for the
class shape.
@packmind/node-utils, error bases from @packmind/types)| Class | Purpose |
|---|---|
BaseHexa<TOpts, TPort> | Hexagon lifecycle (construct -> initialize -> destroy) |
HexaRegistry | Central dependency injection container |
AbstractMemberUseCase<C, R> | Use case with org member authorization |
AbstractSpaceMemberUseCase<C, R> | Use case with org + space member authorization |
AbstractAdminUseCase<C, R> | Use case with admin authorization |
AbstractRepository<T> | Base TypeORM repository with soft delete support |
PackmindListener<TAdapter> | Event subscription base class |
UserAccessError | Reference shape for a domain error: kind + literal reason union + typed context + fixed message |
PackmindInternalError (@packmind/types) | Base for a broken invariant: reason + context + message; the message is for the log only, never returned |
PackmindUpstreamError (@packmind/types) | Base for a third-party failure: same shape plus a kind and an optional retryAfterSeconds; unlike PackmindInternalError, its message is returned to the caller |
DomainExceptionFilter | Global APP_FILTER; holds the only kind -> HTTP status mapping, for domain and upstream kinds alike (@packmind/node-utils/filters) |
PackmindEventEmitterService | Event bus for domain events |
© PackmindHub, 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
SKILL.md and 13 other files in packages/.agents/skills/hexagonal-architecture of PackmindHub/packmind.
Open the folder on GitHubat commit 8a10541
Hexagonal Architecture 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.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Hexagonal Architecture this skillPackmindHub/packmind | 317 | — | ~2.3k | Automated safety check: Pass | Apache-2.0 | |
| Nx Importnrwl/nx | 29k | 6 repos | ~3.5k | Automated safety check: Pass | MIT | |
| Nx Workspacenomcopter/react-mosaic | 4.8k | 8 repos | ~1.9k | Automated safety check: Pass | Custom licence | |
| Electron Multi-Process ArchitectureiOfficeAI/AionUi | 33k | 1 repos | ~1.8k | Automated safety check: Pass | Apache-2.0 | |
| Nx Run Tasksnomcopter/react-mosaic | 4.8k | 8 repos | ~613 | Automated safety check: Pass | Custom licence | |
| Astro Developerwithastro/astro | 63k | 1 repos | ~1.5k | Automated safety check: Pass | Custom licence |
nrwl/nx
Import, merge, or combine repositories into an Nx workspace using nx import.
nomcopter/react-mosaic
Explore and understand Nx workspaces. An agent skill from nomcopter/react-mosaic.
iOfficeAI/AionUi
Tells the agent where new code belongs in an Electron multi-process project and which APIs each process may use, with rules for new bridges, services, agents and workers.
nomcopter/react-mosaic
Helps with running tasks in an Nx workspace. An agent skill from nomcopter/react-mosaic.
withastro/astro
Comprehensive guide for developing in the Astro monorepo. An agent skill from withastro/astro.
TryGhost/Ghost
Moves a package from another TryGhost repository into Ghost as an internal workspace package while keeping its Git history, with checkpoints for the steps that need an administrator.
PackmindHub/packmind
Produce proof-of-execution demos of the Packmind CLI (packmind-cli) as terminal-styled images (colors and formatting preserved exactly), for embedding in a GitHub PR.
PackmindHub/packmind
Record polished UI demo videos and screenshots of a running web app using Playwright MCP — for client deliverables, release notes, feature walkthroughs, or bug repros.
PackmindHub/packmind
Guide for creating effective skills. An agent skill from PackmindHub/packmind.
PackmindHub/packmind
Audit Packmind end-user documentation (apps/doc/) for broken links, outdated CLI references, non-existent concepts, misleading information, and missing coverage.
PackmindHub/packmind
Execute the implementation plan produced by /feature-spec. An agent skill from PackmindHub/packmind.
PackmindHub/packmind
Review an implemented GitHub issue the way a senior Packmind engineer would — the human-judgment checks that ESLint, the TypeScript compiler, and e2e tests cannot catch (authorization scoping…
Categories
Describes the hexagonal architecture (ports and adapters) used across the Packmind monorepo. Hexagonal Architecture is an agent skill from PackmindHub/packmind. Describes the hexagonal architecture (ports and adapters) used across the Packmind monorepo.
Hexagonal Architecture fits situations like: tasks that involve Monorepo tooling.
Run `npx skills add PackmindHub/packmind --skill hexagonal-architecture -a claude-code`. Or copy the skill folder (packages/.agents/skills/hexagonal-architecture in PackmindHub/packmind) into .claude/skills/hexagonal-architecture in your project. Claude Code loads it when a task matches its description.
Run `npx skills add PackmindHub/packmind --skill hexagonal-architecture -a codex`. Or copy the skill folder (packages/.agents/skills/hexagonal-architecture in PackmindHub/packmind) into .agents/skills/hexagonal-architecture in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add PackmindHub/packmind --skill hexagonal-architecture -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/hexagonal-architecture, .gemini/skills/hexagonal-architecture, .github/skills/hexagonal-architecture and .opencode/skills/hexagonal-architecture in your project.
SKILL.md names no scripts, command-line tools or credentials: Hexagonal Architecture is instructions for the agent only.
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.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
Hexagonal Architecture 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.
About 2.3k tokens (SKILL.md is roughly 9.3k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with Hexagonal Architecture: Nx Import (nrwl/nx, 29k stars), Nx Workspace (nomcopter/react-mosaic, 4.8k stars), Electron Multi-Process Architecture (iOfficeAI/AionUi, 33k stars) and Nx Run Tasks (nomcopter/react-mosaic, 4.8k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
PackmindHub (a GitHub organization) maintains it in PackmindHub/packmind, which has 317 GitHub stars. The repository holds 35 skills in this directory. The repository was last updated on October 8, 2026.
Source: PackmindHub/packmind on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.