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.
npx agentmods add commands/ambient-code/platform/trex.kind.newgit clone --depth 1 https://github.com/ambient-code/platformWhat 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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00000 | $0.00730 |
| Opus 5 | $0.00000 | $0.00365 |
| Sonnet 5 | $0.00000 | $0.00146 |
| Haiku 4.5 | $0.00000 | $0.00073 |
Grade A, and why
trex.kind.new 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 3d 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.
Copies of this mod
1 near-identical copy found in the catalogue:
- trex.kind.new — 100% identical, 0 lines differ
How it starts
The opening of the file, as written. The whole thing — 86 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Generate a New Kind
Generate a complete CRUD entity (Kind) using the automated generator script.
Instructions
Use the TodoWrite tool to track progress.
Step 1: Gather Requirements
Ask the user for:
- Kind name (singular, PascalCase): e.g., "Widget", "Rocket", "Customer"
- Fields beyond the base Meta fields (optional):
- Name (use snake_case): e.g., "fuel_type", "max_speed"
- Type:
string,int,int64,bool,float64,time - Nullability:
:requiredor:optional(default: nullable)
Step 2: Run the Generator
go run ./scripts/generator.go --kind {KindName}
With custom fields:
go run ./scripts/generator.go --kind {KindName} --fields "{field1}:{type1}:{nullability},{field2}:{type2}"
Example:
go run ./scripts/generator.go --kind Rocket --fields "name:string:required,fuel_type:string,max_speed:int"
The generator automatically:
- Creates 11 new files (plugin, model, DAO, mock, service, presenters, handlers, migration, OpenAPI spec, test factory, integration tests)
- Modifies 3 existing files (
cmd/ambient-api-server/main.go,pkg/db/migrations/migration_structs.go,openapi/openapi.yaml) - Runs
make generateto regenerate the OpenAPI client - Formats all Go files with
gofmt
Step 3: Build and Verify
make binary
Fix any compilation errors if they occur.
Step 4: Test
make test-integration
Or run just the new Kind's tests:
TESTFLAGS="-run Test{Kind}" make test-integration
Field Type Reference
| User Type | Go (required) | Go (nullable) | OpenAPI type | OpenAPI format | DB Type |
|---|---|---|---|---|---|
| string | string |
*string |
string | varchar | |
| int | int |
*int |
integer | int32 | integer |
| int64 | int64 |
*int64 |
integer | int64 | bigint |
| bool | bool |
*bool |
boolean | boolean | |
| float64 | float64 |
*float64 |
number | double | float8 |
| time | time.Time |
*time.Time |
string | date-time | timestamptz |
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.
- 3d ago First seen · 86 lines · 0 tokens per session scan A 831f0db5cbd2
trex.kind.new is a command published in the GitHub repository ambient-code/platform (129 stars, last pushed 3d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 730 tokens. 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-30.
Other commands, from other repositories
MIGRATE_DESIGN
Design doc for the migration tool PR. Author: Sol ([email protected]). Co-authored-by: wakesync.
diff-script
Compare an MDL script against the project's current state.
toh-help
Display all Toh Framework commands and quick usage guide.
learn-story-flow
Learn story-flow concepts with interactive guidance for junior developers.
doctor
Validate, install, and update Hydraia's external dependencies (codegraph, markitdown, E2E browser binaries).
respond-to-issue
Respond to an issue triggered by @elixpoo mention or the ELIXPO label.