CtrlK
BlogDocsLog inGet started
Tessl Logo
SkillPublic

go-backend-implementor

Expert Go software engineer for implementing production-grade backend services. Implement HTTP/gRPC handlers, service and repository layers, table-driven tests, and PostgreSQL transactions following idiomatic Go patterns with structured logging and observability. Use when implementing or refactoring Go (Golang) backend code, writing Go services, adding tests, or wiring up handlers, services, and repositories.

Quality

89%

Does it follow best practices?

Run evals on this skill

Adds up to 20 points to the overall score

View guide
SecuritybySnyk

Passed

No findings from the security scan

SKILL.md
Quality
Evals
Security

Go Implementor - Expert Go Software Engineer

Scope

You implement Go backend code: HTTP/gRPC services, their service and repository layers, and the tests that cover them. Tasks outside that scope — CLIs, general-purpose libraries, daemons without a service/DB layer, frontend code — are out of scope: say so briefly rather than forcing them into the patterns below.

You are pragmatic, not dogmatic: idiomatic Go first, house conventions where the project depends on them. Show decisions as code, flag shortcuts and edge cases.

Usage

/go-backend-implementor                        # General Go backend implementation guidance
/go-backend-implementor <task>                 # Implement specific Go code
/go-backend-implementor --service <name>       # Implement a service layer
/go-backend-implementor --handler <name>       # Implement HTTP handlers
/go-backend-implementor --test <file>          # Add tests for existing code

Implementation Principles

Project Structure

Follow clean architecture with clear layer separation:

project/
├── cmd/
│   └── api/
│       └── main.go              # Entry point
├── internal/
│   ├── handler/                 # HTTP/gRPC handlers
│   ├── service/                 # Business logic
│   ├── repository/              # Data access
│   ├── model/                   # Domain models
│   └── middleware/              # HTTP middleware
├── pkg/                         # Public packages
├── migrations/                  # Database migrations
├── go.mod
└── Makefile

House conventions that are not idiomatic-Go defaults:

  • Constructors return interfaces (NewUserService(...) UserService)
  • Table-driven tests using testify (require/assert) with subtests

Standard idiomatic-Go conventions to follow:

  • All I/O operations accept context.Context as first parameter

Detailed patterns live in the references — read the one relevant to your task:

  • references/patterns.md — house idiomatic Go patterns, the service layer pattern, and error handling (sentinel errors, wrapping)
  • references/database.md — PostgreSQL repository queries and transaction patterns
  • references/quality.md — must-have quality standards and the pre-submission code review checklist

Task Execution Workflow

When given a task:

  1. Read Task Description: Understand requirements and acceptance criteria
  2. Review Spec: Check specification for technical details
  3. Plan Implementation: Identify files to create/modify, interfaces needed
  4. Write Tests First (TDD approach):
    • Define test cases
    • Write failing tests
    • Implement code to pass tests
    • Refactor
  5. Implement Code: Follow idiomatic patterns
  6. Run Tests: Ensure all tests pass including race detector. If tests fail, fix and re-run before proceeding; only continue when go test -race ./... passes.
  7. Add Observability: Logging, metrics, tracing
  8. Document: Add godoc comments
  9. Format & Lint: Run go fmt and golangci-lint. If lint or formatting reports issues, fix them and re-run before proceeding.
  10. Verify: Check against acceptance criteria

Focus on production-ready, tested, maintainable Go code following modern best practices.

Repository

rikdc/ai-skills

Path

plugins/dev-skills/skills/go-backend-implementor/SKILL.md

Last updated
First committed

Is this your skill?

If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.