Golang Patterns
affaan-m/ECC
Go-specific design patterns and best practices including functional options, small interfaces, dependency injection, concurrency patterns, error handling, and package organization.
Trigger Pattern Always required for DAML audits - Inject Into Breadth agents, depth-state-trace, depth-edge-case
$ npx skills add PlamenTSV/plamen --skill choice-semantics -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install PlamenTSV/plamen choice-semantics --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/PlamenTSV/plamen.git skills-src && mkdir -p .claude/skills && cp -r skills-src/agents/skills/daml/choice-semantics .claude/skills/choice-semantics && 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 "choice-semantics" agent skill from https://github.com/PlamenTSV/plamen/tree/main/agents/skills/daml/choice-semantics into .claude/skills/choice-semantics/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "choice-semantics", 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/PlamenTSV/plamen/tree/main/agents/skills/daml/choice-semanticsType 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 PlamenTSV/plamen --skill choice-semantics -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install PlamenTSV/plamen choice-semantics --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/PlamenTSV/plamen.git skills-src && mkdir -p .agents/skills && cp -r skills-src/agents/skills/daml/choice-semantics .agents/skills/choice-semantics && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "choice-semantics" agent skill from https://github.com/PlamenTSV/plamen/tree/main/agents/skills/daml/choice-semantics into .agents/skills/choice-semantics/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "choice-semantics", 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 PlamenTSV/plamen --skill choice-semantics -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install PlamenTSV/plamen choice-semantics --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/PlamenTSV/plamen.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/agents/skills/daml/choice-semantics .cursor/skills/choice-semantics && 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 "choice-semantics" agent skill from https://github.com/PlamenTSV/plamen/tree/main/agents/skills/daml/choice-semantics into .cursor/skills/choice-semantics/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "choice-semantics", 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/PlamenTSV/plamen.git --path agents/skills/daml/choice-semantics--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 PlamenTSV/plamen --skill choice-semantics -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install PlamenTSV/plamen choice-semantics --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/PlamenTSV/plamen.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/agents/skills/daml/choice-semantics .gemini/skills/choice-semantics && 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 "choice-semantics" agent skill from https://github.com/PlamenTSV/plamen/tree/main/agents/skills/daml/choice-semantics into .gemini/skills/choice-semantics/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "choice-semantics", 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 PlamenTSV/plamen choice-semanticsInstalls 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 PlamenTSV/plamen --skill choice-semantics -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/PlamenTSV/plamen.git skills-src && mkdir -p .github/skills && cp -r skills-src/agents/skills/daml/choice-semantics .github/skills/choice-semantics && 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 "choice-semantics" agent skill from https://github.com/PlamenTSV/plamen/tree/main/agents/skills/daml/choice-semantics into .github/skills/choice-semantics/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "choice-semantics", 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 PlamenTSV/plamen --skill choice-semantics -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install PlamenTSV/plamen choice-semantics --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/PlamenTSV/plamen.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/agents/skills/daml/choice-semantics .opencode/skills/choice-semantics && 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 "choice-semantics" agent skill from https://github.com/PlamenTSV/plamen/tree/main/agents/skills/daml/choice-semantics into .opencode/skills/choice-semantics/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "choice-semantics", 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.
choice-semanticsTrigger Pattern Always required for DAML audits - Inject Into Breadth agents, depth-state-trace, depth-edge-case
Choice Semantics is an agent skill from PlamenTSV/plamen. Trigger Pattern Always required for DAML audits - Inject Into Breadth agents, depth-state-trace, depth-edge-case
Its SKILL.md is about 1.5k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.
The repository describes itself as: Autonomous Web3 security audit agent for Claude Code. The licence is MIT.
4 steps, taken from the step headings in SKILL.md.
Read from SKILL.md and the folder at commit 795962b. 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 (its code samples are markdown).
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 these keys or tokens, usually read from environment variables:
NO_SUCH_KEYFrom names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Choice Semantics loads about 1.5k tokens when it runs. Until then it costs about 32 tokens; SKILL.md has 556 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 PlamenTSV/plamen at commit 795962b, republished under its MIT licence (© PlamenTSV). 556 words, ~1,546 tokens.
.claude/skills/choice-semantics/SKILL.md (or your agent's skills folder).Trigger Pattern: Always required for DAML audits Inject Into: Breadth agents, depth-state-trace, depth-edge-case Finding prefix:
[DML-CHS-N]Rules referenced: R8, R10, R12, R14
In DAML a "write" is a choice that archives a contract and creates a successor. The consume-mode of a choice determines whether the contract survives the exercise: a consuming choice (the default) archives the contract on the first exercise; a nonconsuming choice leaves it active. Misusing consume-mode is the DAML analog of double-spend: a value-moving choice marked nonconsuming can be exercised repeatedly on the same contract. Pre/postconsuming ordering bugs (self-fetch after archive), value-conservation gaps across split/merge/transfer, accumulator/cap drift across transactions, and cancel/abort paths that leave consequences un-unwound round out this class.
For EVERY choice, record its consume-mode and whether the action should be one-shot:
| Template.Choice | Consume-Mode | Moves Value / Mutates State? | Should Be One-Shot? | Mismatch? |
|---|---|---|---|---|
{T.C} | consuming/nonconsuming/preconsuming/postconsuming | YES/NO | YES/NO | [DML-CHS-N] if nonconsuming + should-be-one-shot |
Critical patterns to flag:
nonconsuming choice that transfers, mints, splits, or withdraws value → exercisable repeatedly on the same active contract ([ELEVATE:NONCONSUMING_REPLAY], double-spend).consuming choice intended to be repeatable that archives the contract and strands its peers.DAML note: A consuming choice archives the contract; a SECOND exerciseCmd on the same ContractId MUST fail with CONTRACT_NOT_FOUND. That failure REFUTES a double-spend claim for a consuming choice. Double-spend is only reachable when the value-mover is nonconsuming (or recreates an equivalent contract).
preconsuming archives BEFORE the body runs; postconsuming archives AFTER. A body that fetches self (or this via key) behaves differently across the two.
| Template.Choice | Consume-Mode | Body Self-Fetch / Self-Exercise? | Reads Pre-Archive State? | Finding? |
|---|---|---|---|---|
{T.C} | pre/postconsuming | YES/NO | YES/NO | [DML-CHS-N] if ordering-dependent |
Attack: A preconsuming choice that fetches its own contract by key in the body gets NO_SUCH_KEY/CONTRACT_NOT_FOUND because the archive already happened — either a brick (liveness) or, if guarded by a lookupByKey, a silent wrong branch. A postconsuming choice that re-exercises a sibling assuming self is gone may double-act.
Each value-moving choice should produce successor contracts that conserve value and carry forward every invariant field.
| Template.Choice | Inputs (contracts/amounts) | Outputs Created | Conservation Check | Fields Carried Forward | Gap? |
|---|---|---|---|---|---|
{T.C} | {in} | {out} | out1.amt + out2.amt == in.amt? | owner/lock/maintainer | [DML-CHS-N] if value created/destroyed or field dropped |
Check for:
locked, owner, or maintainer field present in the predecessor (metadata/lock erase).totalIssued, mintedSoFar) that is NOT updated on the create path, so the cap is never enforced across transactions ([ELEVATE:VALUE_CONSERVATION], R14).A choice that allocates or locks resources must unwind them on the cancel/abort/reject path.
| Template.Choice | Allocates/Locks On Success | Cancel/Reject Choice Exists? | Unwinds Allocation? | Finding? |
|---|---|---|---|---|
{T.C} | {child created / asset locked} | YES/NO | YES/NO | [DML-CHS-N] if no unwind |
Attack: A Propose/Reserve choice creates a child contract or locks an asset; the Cancel/Reject choice archives the proposal but leaves the child/locked asset active. The reserved value is stranded or double-counted. Verify the cancel path archives every contract the success path created.
**ID**: [DML-CHS-N]
**Severity**: [Critical if double-spend/value-creation, High if conservation/lock-erase, Medium if liveness-only]
**Step Execution**: ✓1,2,3,4 | ✗(reasons) | ?(uncertain)
**Rules Applied**: [R8:✓/✗, R10:✓/✗, R12:✓/✗, R14:✓/✗]
**Location**: {Module}.daml:LineN (template X, choice Y)
**Title**: {Choice} nonconsuming value-mover / value-conservation gap allows {double-spend / value inflation}
**Description**: [Consume-mode or conservation gap with the exact in/out amounts and the field or successor that breaks]
**Impact**: [Repeated exercise on same contract / value created or destroyed / stranded locked asset / cap unenforced]
**PoC steer**: exercise the same `ContractId` twice (nonconsuming double-spend), or assert `out1.amt + out2.amt /= in.amt`, or `query@T` a stranded child after cancel.| Section | Required | Completed? | Notes |
|---|---|---|---|
| 1. Consume-Mode Inventory | YES | ✓/✗/? | Every choice, value-movers especially |
| 2. Pre/Postconsuming Ordering Trace | IF pre/postconsuming present | ✓/✗(N/A)/? | Every self-fetch/self-exercise |
| 3. Successor-State Completeness | YES | ✓/✗/? | Every split/merge/transfer + accumulator |
| 4. Cancel / Abort Unwind | IF allocate/lock-then-cancel pattern | ✓/✗(N/A)/? | Every reserve/propose with a cancel path |
© PlamenTSV, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
Just SKILL.md in agents/skills/daml/choice-semantics of PlamenTSV/plamen.
Open the folder on GitHubat commit 795962b
Choice Semantics 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 |
|---|---|---|---|---|---|---|
| Choice Semantics this skillPlamenTSV/plamen | 303 | — | ~1.5k | Automated safety check: Pass | MIT | |
| Golang Patternsaffaan-m/ECC | 275k | — | ~1.1k | Automated safety check: Pass | MIT | |
| React Audit Grep Patternsgithub/awesome-copilot | 40k | 1 repos | ~461 | Automated safety check: Pass | MIT | |
| Dotnet Patternsaffaan-m/ECC | 275k | 1 repos | ~2.3k | Automated safety check: Pass | MIT | |
| Fastapi Patternsaffaan-m/ECC | 275k | — | ~2.3k | Automated safety check: Pass | MIT | |
| Kotlin Exposed Patternsaffaan-m/ECC | 275k | 4 repos | ~5.5k | Automated safety check: Pass | MIT |
affaan-m/ECC
Go-specific design patterns and best practices including functional options, small interfaces, dependency injection, concurrency patterns, error handling, and package organization.
github/awesome-copilot
Provides the complete, verified grep scan command library for auditing React codebases before a React 18.3.1 or React 19 upgrade.
affaan-m/ECC
Idiomatic C and .NET patterns, conventions, dependency injection, async/await, and best practices for building robust, maintainable .NET applications.
affaan-m/ECC
FastAPI patterns for async APIs, dependency injection, Pydantic request and response models, OpenAPI docs, tests, security, and production readiness.
affaan-m/ECC
JetBrains Exposed ORM patterns including DSL queries, DAO pattern, transactions, HikariCP connection pooling, Flyway migrations, and repository pattern.
affaan-m/ECC
Python-specific design patterns and best practices including protocols, dataclasses, context managers, decorators, async/await, type hints, and package organization.
PlamenTSV/plamen
Prepare Solidity projects for a security audit — test coverage, test quality, NatSpec docs, code hygiene, dependency health, best-practice enforcement, deployment readiness, and project…
PlamenTSV/plamen
Trigger Pattern Always (used by all verifier agents) - Inject Into security-verifier agents (Phase 5)
PlamenTSV/plamen
Trigger Pattern Always (Aptos Move) - foundational security check - Inject Into Breadth agents, depth agents
PlamenTSV/plamen
Trigger Pattern Always (Sui Move) -- foundational security check - Inject Into Breadth agents, depth agents
PlamenTSV/plamen
Trigger Pattern ACCOUNTCLOSING flag detected (close/CloseAccount usage) - Inject Into Breadth agents, depth agents
PlamenTSV/plamen
Trigger Pattern Always required for Solana audits - Inject Into Breadth agents, depth agents
Trigger Pattern Always required for DAML audits - Inject Into Breadth agents, depth-state-trace, depth-edge-case. Choice Semantics is an agent skill from PlamenTSV/plamen.
Choice Semantics fits situations like: pattern Always required for DAML audits - Inject Into Breadth agents; depth-state-trace; depth-edge-case.
Run `npx skills add PlamenTSV/plamen --skill choice-semantics -a claude-code`. Or copy the skill folder (agents/skills/daml/choice-semantics in PlamenTSV/plamen) into .claude/skills/choice-semantics in your project. Claude Code loads it when a task matches its description.
Run `npx skills add PlamenTSV/plamen --skill choice-semantics -a codex`. Or copy the skill folder (agents/skills/daml/choice-semantics in PlamenTSV/plamen) into .agents/skills/choice-semantics 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 PlamenTSV/plamen --skill choice-semantics -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/choice-semantics, .gemini/skills/choice-semantics, .github/skills/choice-semantics and .opencode/skills/choice-semantics in your project.
Going by SKILL.md and its folder, Choice Semantics needs credentials named NO_SUCH_KEY. Our summary lists: A credential in NO_SUCH_KEY.
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.
Choice Semantics is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 1.5k tokens (SKILL.md is roughly 6.2k 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 Choice Semantics: Golang Patterns (affaan-m/ECC, 275k stars), React Audit Grep Patterns (github/awesome-copilot, 40k stars), Dotnet Patterns (affaan-m/ECC, 275k stars) and Fastapi Patterns (affaan-m/ECC, 275k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
PlamenTSV (a GitHub user) maintains it in PlamenTSV/plamen, which has 303 GitHub stars. The repository holds 87 skills in this directory. The repository was last updated on September 26, 2026.
Source: PlamenTSV/plamen on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.