Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 16 additions & 13 deletions .opencode/agents/repo-manager.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,19 +48,22 @@ Generate themed names using: `{adjective} {animal}`
**Name Selection Strategy:**
**IMPORTANT**: Use your AI to analyze the actual PR/commit content and generate an appropriate themed name. Do NOT use random selection.

1. Get merged PRs: `gh pr list --state merged --base develop --limit 20`
1. Get merged PRs: `gh pr list --state merged --base main --limit 20`
2. **Use your AI to analyze** the PR titles and descriptions
3. Determine overall "vibe" (performance, security, features, fixes, etc.) based on the actual content
4. Select appropriate adjective + animal combination

4. Select appropriate adjective + animal combination:
- **Performance**: swift cheetah, lightning falcon, rapid hare
- **Security**: vigilant owl, guardian bear, watchful hawk
- **Features**: creative fox, innovative dolphin, clever raven
- **Bug Fixes**: persistent badger, diligent ant, careful turtle
- **Refactoring**: elegant swan, graceful deer, nimble cat
- **Documentation**: wise elephant, thoughtful whale, patient sloth
- **Mixed**: versatile chameleon, adaptive jackal, resourceful coyote
3. Determine what this release is really about
4. Generate a unique adjective-animal name that:
- Reflects the PR content
- Hasn't been used before
- Is creative and memorable

**Avoid** overused combinations like "swift cheetah", "creative fox", "vigilant owl", "innovative dolphin".

**Try** unique combinations like:
- Exotic: narwhal, axolotl, capybara, quokka, pangolin
- Aquatic: jellyfish, seahorse, manta, cuttlefish, otter
- Birds: kingfisher, heron, ibis, stork
- Insects: firefly, butterfly, dragonfly
- Mythical: phoenix, griffin, pegasus, siren

## Git Operations

Expand Down Expand Up @@ -151,7 +154,7 @@ gh pr list --state merged --base develop --limit 10
# Recent PRs: "Optimize database queries", "Improve API performance", "Cache implementation"
# Theme detected: Performance improvements
# Generated name: "swift falcon"
# Version: v1.2.20260302r1
# Version: v1.2.20260302
```

### Emergency Hotfix
Expand Down
146 changes: 57 additions & 89 deletions .opencode/skills/git-release/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,96 +45,64 @@ v1.2.20260302 → v1.3.20260302

## Release Naming Strategy

### Adjective-Animal Themes
Generate release names by analyzing PR sentiment and selecting appropriate themes.
### AI-Generated Themed Naming

### Theme Categories
The release name is generated by the AI based on analyzing the merged PRs and their content. The AI should:

#### Performance & Speed
**Adjectives**: swift, rapid, lightning, blazing, turbo, speedy, agile
**Animals**: cheetah, falcon, hare, gazelle, hawk, dolphin, hummingbird
1. **Analyze PR content** - Read titles, descriptions, and code changes
2. **Identify dominant theme** - What is this release really about?
3. **Generate unique name** - Create an adjective-animal pair that:
- Reflects the PR content accurately
- Has not been used before in this project
- Is memorable and appropriate

Examples: `swift cheetah`, `lightning falcon`, `rapid gazelle`
### Guidelines for AI

#### Security & Protection
**Adjectives**: vigilant, guardian, watchful, secure, protective, stalwart, fortress
**Animals**: owl, bear, hawk, wolf, eagle, rhinoceros, mastiff
**Good adjectives** (avoid generic ones):
- Emotional/sensory: `electric`, `radiant`, `fiery`, `velvet`, `crystalline`
- Movement: `surging`, `drifting`, `soaring`, `diving`, `spiral`
- Nature: `blooming`, `misty`, `aurora`, `tidal`, `verdant`
- Abstract: `boundless`, `infinite`, `hidden`, `silent`, `luminous`

Examples: `vigilant owl`, `guardian bear`, `watchful hawk`
**Good animals** (avoid overused ones like fox, owl, dolphin, cheetah):
- Exotic: `narwhal`, `axolotl`, `capybara`, `quokka`, `pangolin`
- Aquatic: `jellyfish`, `seahorse`, `manta`, `cuttlefish`, `otter`
- Birds: `kingfisher`, `heron`, `ibis`, `stork`, `bird-of-paradise`
- Insects: `firefly`, `butterfly`, `dragonfly`, `beetle`, `mantid`
- Mythical-inspired: `phoenix`, `griffin`, `pegasus`, `siren`, `chimera`

#### Innovation & Features
**Adjectives**: creative, innovative, clever, brilliant, inventive, pioneering, ingenious
**Animals**: fox, dolphin, raven, octopus, monkey, parrot, crow
**Avoid repetition** - Check previous releases and choose something new.

Examples: `creative fox`, `innovative dolphin`, `clever raven`
### Examples

#### Stability & Fixes
**Adjectives**: persistent, diligent, careful, steadfast, reliable, thorough, patient
**Animals**: badger, ant, turtle, ox, elephant, beaver, bull

Examples: `persistent badger`, `diligent ant`, `careful turtle`

#### Refactoring & Cleanup
**Adjectives**: elegant, graceful, nimble, refined, polished, pristine, sleek
**Animals**: swan, deer, cat, crane, jaguar, seal, panther

Examples: `elegant swan`, `graceful deer`, `nimble cat`
```
v1.2.20260315 - Blooming Narwhal (based on new features, growth theme)
v1.3.20260316 - Velvet Manta (based on smooth refactoring)
v1.4.20260317 - Electric Firefly (based on performance improvements)
v1.5.20260403 - Crystal Jellyfish (based on documentation overhaul)
```

#### Documentation & Knowledge
**Adjectives**: wise, thoughtful, scholarly, insightful, learned, enlightened, sage
**Animals**: elephant, whale, owl, sloth, tortoise, raven, dolphin
## PR Analysis for Release Naming

Examples: `wise elephant`, `thoughtful whale`, `scholarly owl`
### AI Analysis Process

## PR Sentiment Analysis
Instead of rigid keyword matching, the AI should:

### Analysis Process
1. **Gather Recent PRs**
```bash
gh pr list --state merged --base develop --limit 20 --json title,body,labels
gh pr list --state merged --base main --limit 20 --json title,body,labels
```

2. **Categorize by Keywords**
```python
performance_keywords = ["optimize", "performance", "speed", "cache", "faster"]
security_keywords = ["security", "auth", "encrypt", "vulnerability", "safe"]
feature_keywords = ["add", "implement", "new", "feature", "enhance"]
fix_keywords = ["fix", "bug", "error", "issue", "patch"]
refactor_keywords = ["refactor", "clean", "restructure", "improve", "organize"]
docs_keywords = ["docs", "documentation", "readme", "guide", "explain"]
```
2. **Understand the content** - Read PR titles and descriptions to understand what changed

3. **Calculate Dominant Theme**
```python
def analyze_pr_sentiment(prs):
scores = {
"performance": 0,
"security": 0,
"features": 0,
"fixes": 0,
"refactoring": 0,
"documentation": 0
}

for pr in prs:
text = f"{pr['title']} {pr['body']}".lower()
# Score based on keyword frequency and PR importance

return max(scores, key=scores.get)
```
3. **Identify the story** - What's the narrative of this release? What stands out?

4. **Select Theme Name**
```python
def generate_release_name(dominant_theme):
themes = {
"performance": [("swift", "cheetah"), ("lightning", "falcon"), ("rapid", "hare")],
"security": [("vigilant", "owl"), ("guardian", "bear"), ("watchful", "hawk")],
"features": [("creative", "fox"), ("innovative", "dolphin"), ("clever", "raven")],
# ... etc
}

return random.choice(themes[dominant_theme])
```
4. **Generate creative name** - Based on understanding, create a unique adjective-animal pair

**Remember:**
- Each release should have a unique name - don't repeat
- The name should feel authentic and memorable
- Let the PR content guide the naming, not the other way around

## Release Process Workflow

Expand All @@ -149,7 +117,7 @@ git log --oneline $(git describe --tags --abbrev=0)..HEAD

# Create release branch
current_date=$(date +%Y%m%d)
git checkout -b release/v1.3.${current_date}r1
git checkout -b release/v1.3.${current_date}
```

### Step 2: Analyze PRs and Generate Name
Expand All @@ -172,11 +140,11 @@ gh pr list --state merged --base develop --limit 20
### Step 3: Update Version and Changelog
```bash
# Update pyproject.toml
sed -i 's/version = ".*"/version = "1.3.20260302r1"/' pyproject.toml
sed -i 's/version = ".*"/version = "1.3.20260302"/' pyproject.toml

# Generate changelog entry
cat >> CHANGELOG.md << EOF
## [v1.3.20260302r1] - Swift Cheetah - 2026-03-02
## [v1.3.20260302] - Swift Cheetah - 2026-03-02

### Performance Improvements
- Optimize database query performance (#123)
Expand All @@ -192,24 +160,24 @@ EOF

# Commit version bump
git add pyproject.toml CHANGELOG.md
git commit -m "chore(release): bump version to v1.3.20260302r1 - Swift Cheetah"
git commit -m "chore(release): bump version to v1.3.20260302 - Swift Cheetah"
```

### Step 4: Create and Publish Release
```bash
# Merge to main
git checkout main
git merge release/v1.3.20260302r1
git merge release/v1.3.20260302

# Create tag
git tag v1.3.20260302r1
git tag v1.3.20260302

# Push to remote
git push origin main --tags

# Create GitHub release
gh release create v1.3.20260302r1 \
--title "v1.3.20260302r1 - Swift Cheetah" \
gh release create v1.3.20260302 \
--title "v1.3.20260302 - Swift Cheetah" \
--notes-file CHANGELOG.md

# Sync develop branch
Expand All @@ -218,20 +186,20 @@ git merge main
git push origin develop

# Clean up release branch
git branch -d release/v1.3.20260302r1
git push origin --delete release/v1.3.20260302r1
git branch -d release/v1.3.20260302
git push origin --delete release/v1.3.20260302
```

### Step 5: Post-Release Tasks
```bash
# Verify release
gh release view v1.3.20260302r1
gh release view v1.3.20260302

# Check CI/CD pipeline
gh workflow run deploy --ref v1.3.20260302r1
gh workflow run deploy --ref v1.3.20260302

# Update project documentation
echo "Latest release: v1.3.20260302r1 - Swift Cheetah" > .release-info
echo "Latest release: v1.3.20260302 - Swift Cheetah" > .release-info
```

## Hotfix Release Process
Expand All @@ -254,7 +222,7 @@ gh pr create --title "Critical Security Hotfix" \
current_date=$(date +%Y%m%d)
last_version=$(git describe --tags --abbrev=0)

# Calculate next revision (v1.3.20260302r1 → v1.3.20260302r2)
# Calculate next revision (v1.3.20260302 → v1.3.20260302r2)
next_revision=$(echo $last_version | sed 's/r\([0-9]\+\)/r\1+1/')

git tag $next_revision
Expand Down Expand Up @@ -307,7 +275,7 @@ echo "✅ Pre-release validation passed!"
# Analysis: 3 feature PRs, 1 performance PR
# Theme: FEATURES (dominant)
# Name: "innovative dolphin"
# Version: v1.4.20260315r1
# Version: v1.4.20260315
```

### Security Release
Expand All @@ -316,7 +284,7 @@ echo "✅ Pre-release validation passed!"
# Analysis: 4 security PRs, 1 docs PR
# Theme: SECURITY (dominant)
# Name: "vigilant owl"
# Version: v1.3.20260320r1
# Version: v1.3.20260320
```

### Major Release
Expand All @@ -325,5 +293,5 @@ echo "✅ Pre-release validation passed!"
# Analysis: Breaking changes detected
# Theme: Based on supporting PRs
# Name: "pioneering eagle"
# Version: v2.0.20260401r1
# Version: v2.0.20260401
```
21 changes: 9 additions & 12 deletions .opencode/skills/template-release/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -153,19 +153,16 @@ echo "✅ Final validation passed"
git log ${current_version}..HEAD --oneline
```

2. **Analyze the commits using your AI** to determine the dominant theme/vibe:
2. **Analyze the commits using your AI** to determine what this release is about:
- Read each commit message and PR description
- Determine if they're about: performance, security, features, bug fixes, refactoring, or docs
- Pick a theme that matches the majority

3. **Generate themed name** based on your analysis:
- **Performance**: swift cheetah, lightning falcon, rapid hare, blazing gazelle
- **Security**: vigilant owl, guardian bear, watchful hawk, steadfast turtle
- **Features**: creative fox, innovative dolphin, clever raven, curious raccoon
- **Bug Fixes**: persistent badger, diligent ant, careful turtle, steadfast ox
- **Refactoring**: elegant swan, graceful deer, nimble cat, balanced llama
- **Documentation**: wise elephant, thoughtful whale, scholarly owl, patient sloth
- **Mixed**: versatile chameleon, adaptive jackal, resourceful coyote
- Understand the story/narrative of the release

3. **Generate a unique themed name** based on your analysis:
- Create an adjective-animal pair that reflects the content
- Avoid overused combinations (fox, owl, dolphin, cheetah)
- Make it creative and memorable

**Good examples**: Blooming Narwhal, Crystal Jellyfish, Velvet Manta, Electric Firefly, Aurora Moth, Tidal Otter

4. **Create the release:**
```bash
Expand Down
4 changes: 2 additions & 2 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ When developers use this template, they get:

### Repository Management
- Hybrid versioning: `v1.2.20260302` (major.minor.calver)
- Themed releases: "swift cheetah", "vigilant owl", "creative fox"
- AI-generated themed releases (unique per release): "Blooming Narwhal", "Crystal Jellyfish", "Electric Firefly"
- Automated PR workflows with conventional commits
- GitHub CLI integration

Expand Down Expand Up @@ -119,7 +119,7 @@ cookiecutter gh:your-username/python-project-template --checkout v1.2.20260312
- **v1.2.20260312**: Added meta template management system
- **v1.3.20260313**: Added session-workflow skill
- **v1.4.20260313**: Added AI-driven themed naming
- **v1.5.20260403r1**: Replaced mkdocs with pdoc for API docs, added pytest-html-plus with BDD docstring display
- **v1.5.20260403**: Replaced mkdocs with pdoc for API docs, added pytest-html-plus with BDD docstring display

## Generated Project Features

Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Modern cookiecutter template delivering enterprise-grade Python projects with **
🏗️ **SOLID Architecture** - Object calisthenics, dependency inversion, and protocol-based design
⚡ **Zero-Config Setup** - UV package manager, Ruff formatting, PyTest + Hypothesis testing
🎯 **Quality Enforced** - 100% coverage, static typing, property-based testing
🔄 **Smart Releases** - Calver versioning with themed releases (`v1.2.20260315 "Swift Cheetah"`)
🔄 **Smart Releases** - Calver versioning with AI-generated themed names
📋 **Complete Workflows** - 7-phase development cycle from prototype to production

## 🎯 Perfect For
Expand Down Expand Up @@ -89,7 +89,7 @@ task doc-serve # Live documentation server

### Smart Release Management

- **Hybrid Versioning**: `v{major}.{minor}.{YYYYMMDD}r{revision}`
- **Hybrid Versioning**: `v{major}.{minor}.{YYYYMMDD}` (same-day releases increment minor)
- **Themed Releases**: AI-generated names based on PR sentiment
- Performance: `"Swift Cheetah"` `"Lightning Falcon"`
- Security: `"Vigilant Owl"` `"Guardian Bear"`
Expand Down
Loading
Loading