cratis-fundamentals-concept-go

cratis-fundamentals-concept-go is a skill for Claude Code, Codex from Cratis/AI. It costs 53 tokens per session (904 once invoked), scanned A, original, MIT.

A Go coding guide for defining domain values as distinct types, such as an AuthorID, instead of treating them as ordinary strings or UUIDs. It also covers converting those values to and from JSON.

In plain words
What is it for?
Use it when building Go services that need strongly separated identifiers or other scalar values, with constructors and JSON codecs.
Why use it?
It prevents unrelated values from being accidentally mixed even when they share the same basic representation. It also gives those values consistent text and JSON formats.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it when building Go services that need strongly separated identifiers or other scalar values, with constructors and JSON codecs.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/cratis/ai/cratis-fundamentals-concept-go
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add Cratis/AI --skill cratis-fundamentals-concept-go
Clone the repo
git clone --depth 1 https://github.com/Cratis/AI

Made for: Claude Code, Codex.

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 cratis-fundamentals-concept-go

README.md
[![agentmods](https://agentmods.dev/badge/skills/cratis/ai/cratis-fundamentals-concept-go/github.svg)](https://agentmods.dev/skills/cratis/ai/cratis-fundamentals-concept-go)
Your own site
<a href="https://agentmods.dev/skills/cratis/ai/cratis-fundamentals-concept-go"><img src="https://agentmods.dev/badge/skills/cratis/ai/cratis-fundamentals-concept-go/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 cratis-fundamentals-concept-go

Your own site · 80×15
<a href="https://agentmods.dev/skills/cratis/ai/cratis-fundamentals-concept-go"><img src="https://agentmods.dev/badge/skills/cratis/ai/cratis-fundamentals-concept-go.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 53 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 904 The whole file, excluding the scripts and references it only reads on demand.
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.00053 $0.00904
Opus 5.5 $0.00021 $0.00362
Sonnet 5.5 $0.00011 $0.00181
Haiku 4.5 $0.00005 $0.00090

Measured today against content hash 744fa1f552f3, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

cratis-fundamentals-concept-go 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 today.

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.

.cratis/ai/skills/cratis-fundamentals-concept-go/SKILL.md · 96 lines

How it starts

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

Typed domain values in Go

Use a defined type for each domain value, not a type alias that remains interchangeable with every UUID/string. Plain constructors are enough; adopting concepts does not require a dependency-injection container.

Define and encode an identity

In an existing module using Go 1.26 or later, add the dependency with go get github.com/cratis/fundamentals.go. This complete package defines an author identity and its codecs:

// Copyright (c) Cratis. All rights reserved.
// Licensed under the MIT license. See LICENSE file in the project root for full license information.

package domain

import "github.com/cratis/fundamentals.go/concepts"

// AuthorID identifies an author in the domain.
type AuthorID concepts.UUID

var _ concepts.Concept[concepts.UUID] = AuthorID{}

// ConceptValue exposes the declared scalar representation.
func (id AuthorID) ConceptValue() concepts.UUID { return concepts.UUID(id) }

// MarshalText encodes canonical dashed UUID text.
func (id AuthorID) MarshalText() ([]byte, error) {
	return concepts.UUID(id).MarshalText()
}

// MarshalJSON encodes a UUID string, not a byte array.
func (id AuthorID) MarshalJSON() ([]byte, error) {
	return concepts.UUID(id).MarshalJSON()
}

// UnmarshalText decodes UUID text without changing id on failure.
func (id *AuthorID) UnmarshalText(data []byte) error {
	return (*concepts.UUID)(id).UnmarshalText(data)
}

// UnmarshalJSON decodes a UUID string without changing id on failure.
func (id *AuthorID) UnmarshalJSON(data []byte) error {
	return (*concepts.UUID)(id).UnmarshalJSON(data)
}

// ParseAuthorID reads an identity in dashed UUID notation.
func ParseAuthorID(text string) (AuthorID, error) {
	id, err := concepts.ParseUUID(text)
	return AuthorID(id), err
}

Defined types do not inherit methods. Without these forwarding codecs, a UUID-derived value can serialize as an array. Value encoding receivers also work for unaddressable map entries; decoding needs a pointer receiver. Test text, JSON, map-key and invalid-input round trips, not just the marker assertion.

Read the full file on GitHub · 96 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. today Changed · -16 lines · +5 tokens per session 744fa1f552f3
  2. 1mo ago Changed · -15 tokens per session 24ccbbf7bd7f
  3. 1mo ago Changed · -1 lines d70d157a5a11
  4. 1mo ago First seen · 113 lines · 63 tokens per session scan A 4f9add72d0a2

Subscribe to this mod's changes

cratis-fundamentals-concept-go is a skill published in the GitHub repository Cratis/AI (4 stars, last pushed today), licensed MIT. It adds 53 tokens to every session and 904 once invoked, about $0.0002 per session on Opus 5.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-10-13.

Related

cratis-fundamentals-concept-go compared with skills from other repositories

cratis-fundamentals-concept-go next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
cratis-fundamentals-concept-goCratis/AISkill4todayMITA53Claude Code, Codex
imagegenopenai/codexSkill137ktodayApache-2.0A113Codex
playwright-climicrosoft/playwrightSkill101ktodayApache-2.0A19Claude Code
browser-automationopenclaw/openclawSkill395ktodayMITA36Claude Code
systematic-debuggingobra/superpowersSkill330k2d agoMITA21Claude Code
free-llm-apismnfst/awesome-free-llm-apisSkill14kyesterdayCC0-1.0A113Claude Code, Codex
next-cache-components-adoptionvercel/next.jsSkill144ktodayMITA95Claude Code