Skip to content

docs(skills): add go-concurrency skill - #663

Merged
edenreich merged 1 commit into
mainfrom
docs/go-concurrency-skill
Jun 27, 2026
Merged

edenreich merged 1 commit into
mainfrom
docs/go-concurrency-skill

Conversation

@edenreich

Copy link
Copy Markdown
Contributor

Part of #657.

Adds a go-concurrency skill under .agents/skills/ — a concise quick-reference distilled from luk4z7/go-concurrency-guide for agents writing or reviewing concurrent Go.

Contents

  • Pick your tool — channel vs Mutex/RWMutex/WaitGroup/Once/Pool/Cond/atomic/context
  • Channel states — the read·send·close × nil·open·closed truth table
  • select idioms — timeout, non-blocking poll, cancellation
  • Gotchas — data race, goroutine leak, deadlock, closed-channel panic, loop-var capture, livelock/starvation
  • Signature patterns — copy-ready snippets: done-channel, fan-out/fan-in, pipeline, or-done, context, semaphore
  • Scheduler — G·M·P, work-stealing, go test -race

Kept deliberately short (highlights only); lower-frequency patterns (tee, bridge, or-channel, heartbeat, replicated requests) are one-line pointers.

Acceptance criteria (#657)

  • Skills directory created under .agents/skills/*
  • Skill for concurrency + common practices
  • Bubble Tea skill
  • Remaining curated skills (up to 4–5)
  • Tested locally with agents
  • System-prompt adjustment (if needed) / follow-ups

Leaving the issue open for the remaining items.

Quick-reference distilled from luk4z7/go-concurrency-guide: sync primitives, channel-state table, select idioms, gotchas, and the signature channel patterns (done-channel, fan-out/in, pipeline, or-done, context, worker-pool).
@edenreich
edenreich requested a review from a team as a code owner June 27, 2026 17:23
@edenreich
edenreich merged commit c77ac33 into main Jun 27, 2026
1 check passed
@edenreich
edenreich deleted the docs/go-concurrency-skill branch June 27, 2026 18:14
edenreich added a commit that referenced this pull request Jun 27, 2026
Part of #657.

Adds three **v2-pinned** Charm skills under `.agents/skills/`, distilled
from charmbracelet's own docs/examples (not our code) for the stack the
project actually uses via the `charm.land/<lib>/v2` import path.

| Skill | Library | Covers |
| --- | --- | --- |
| `bubbletea-v2` | `charm.land/bubbletea/v2` v2.0.7 | The Elm
Architecture (`Model`/`Init`/`Update`/`View`), the `tea.View` struct,
commands & messages, input, program options |
| `lipgloss-v2` | `charm.land/lipgloss/v2` v2.0.4 | Styles, the
`Color()`/`LightDark` color model, layout joins, borders, tables |
| `bubbles-v2` | `charm.land/bubbles/v2` v2.1.0 | The embed-and-delegate
contract + component cheat-table (viewport, textinput, spinner,
progress, key, help) |

Each **leads with a "v2 vs the v1 you remember" correction table** — the
highest-value part, since agents default to v1 idioms that don't compile
on this stack. Every signature was **verified against the installed
module cache**, which caught real traps:

- `View()` returns **`tea.View`** (not `string`); wrap with
`tea.NewView(s)`
- full-screen / mouse are **View fields** (`v.AltScreen`, `v.MouseMode`)
— the `WithAltScreen()` / `WithMouseCellMotion()` options were removed
- keys are **`tea.KeyPressMsg`** (`KeyMsg` is now an interface)
- `lipgloss.Color()` is a **func → `image/color.Color`**;
`AdaptiveColor` gone → `LightDark()`
- bubbles use **functional-options** constructors; `key.Matches` is
generic
- `tea.Quit` is a `Cmd` you pass, not call

Per #657's "core trio, not too many", glamour/huh/fang (2/1/1 files)
were intentionally left out. Docs-only; markdownlint clean.

## Acceptance criteria (#657)
- [x] Skills directory under `.agents/skills/*`
- [x] A skill for the charm Bubble Tea framework (+ lipgloss & bubbles)
- [x] Skills added from the curated set (go-concurrency in #663 + these
3 = 4)
- [ ] Tested locally with agents
- [ ] Default system prompt adjusted (if applicable)
- [ ] Follow-ups created for any broken/partial skills

Leaving the issue open for local testing and any follow-ups.
@edenreich edenreich linked an issue Jun 27, 2026 that may be closed by this pull request
6 tasks
inference-gateway-releaser Bot added a commit that referenced this pull request Jun 28, 2026
## [0.125.0](v0.124.1...v0.125.0) (2026-06-28)

### 🚀 Features

* **reminders:** configurable reminders on a shared hook-point catalog ([#675](#675)) ([179cad1](179cad1)), closes [#270](#270) [#669](#669) [#270](#270) [#525](#525) [#270](#270)
* **channels:** retain inbound voice/audio recordings with bounded cleanup ([#671](#671)) ([8fd29ce](8fd29ce))
* **hooks:** run configured shell commands at agent hook points ([#676](#676)) ([990f2c0](990f2c0)), closes [#270](#270) [#675](#675) [#675](#675) [#270](#270) [#675](#675) [#675](#675) [#669](#669) [#270](#270)

### 🐛 Bug Fixes

* **agent:** keep the internal completion check out of channel replies ([#672](#672)) ([96b166c](96b166c))
* **docs:** replace em dashes with hyphens for consistency in SKILL.md and configuration-reference.md ([1c9196d](1c9196d))

### ♻️ Code Refactoring

* dead-code cleanup, Go 1.26 modernization, width-aware truncation, race testing ([#667](#667)) ([7a97f3b](7a97f3b))
* interfaces, fix context propagation, and reduce delays ([#666](#666)) ([1a93ff8](1a93ff8))

### 📚 Documentation

* **skills:** add charm v2 skills (bubbletea, lipgloss, bubbles) ([#664](#664)) ([c7242c7](c7242c7)), closes [#657](#657) [#663](#663)
* **skills:** add Go skills adapted from spf13/go-skills ([#665](#665)) ([971ac23](971ac23))
* **skills:** add go-concurrency skill ([#663](#663)) ([c77ac33](c77ac33)), closes [#657](#657)

### ✅ Tests

* relax TestSessionID_Age_Recent upper bound to tolerate slow CI ([#673](#673)) ([9cfe203](9cfe203)), closes [#671](#671)
@inference-gateway-releaser

Copy link
Copy Markdown
Contributor

🎉 This PR is included in version 0.125.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@inference-gateway-releaser inference-gateway-releaser Bot added the released Shipped in a release label Jun 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

released Shipped in a release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEATURE] Add Golang skills selectively

1 participant