Blog

Technical deep-dives on infrastructure, CI/CD, and backend systems

Engineering insights from production deployments—not theory. I write about the problems I've actually solved and the patterns that work at scale.

Browse blog series →

The Three-Tier Terraform Data Pattern

Part 3 of 3 in Sudoblark Best Practices

An evolution of the Terraform data structures pattern — separating WHAT from HOW from WHERE for smaller teams and AI-assisted development.

— Written 30 March 2026 · Written by Benjamin Clark

Rebuilding the Bookshelf: Replacing the Manual Bedrock Chain with pydantic-ai

Part 2 of 2 in AI Vision Inference

How migrating from tightly-coupled Bedrock API calls to a pydantic-ai Agent decouples the AI integration from platform-specific code — making provider switching trivial, silent failures explicit, and tool integration possible.

— Written 21 March 2026 · Edited 27 March 2026 · Written by Benjamin Clark

Event-Driven Vision Inference with Bedrock, Pydantic, and Parquet

Part 1 of 2 in AI Vision Inference

How to integrate vision inference into serverless architectures without specialised ML infrastructure using AWS Bedrock, Pydantic validation, and Parquet storage.

— Written 17 March 2026 · Edited 27 March 2026 · Written by Benjamin Clark

Database interoperability in Python utilising the Repository Enterprise Pattern

Part 3 of 3 in Software Odds and Ends

How I used the Repository pattern to decouple a hand-built monitoring platform from its database backend — and what that made possible when it came time to migrate.

— Written 05 September 2025 · Edited 27 March 2026 · Written by Benjamin Clark

Multi-layer Perceptrons and Backpropagation

Part 3 of 3 in Foundations of AI

How stacking non-linear layers solves XOR, what loss and gradient descent actually do, and a from-scratch NumPy implementation of backpropagation.

— Written 28 August 2025 · Edited 28 March 2026 · Written by Benjamin Clark

Activation Functions

Part 2 of 3 in Foundations of AI

Why activation functions exist, how the common ones differ, and which I'd reach for — with a Python demo showing the effect of swapping activation functions on a small network.

— Written 05 August 2025 · Edited 27 March 2026 · Written by Benjamin Clark

Perceptrons

Part 1 of 3 in Foundations of AI

An overview of the Perceptron and its influence on modern neural networks.

— Written 28 July 2025 · Edited 28 March 2026 · Written by Benjamin Clark

Strategies for CI/CD at scale

Part 2 of 3 in Sudoblark Best Practices

A write-up of my thoughts of CI/CD at scale as presented at various talks and conferences.

— Written 27 March 2025 · Edited 29 March 2026 · Written by Benjamin Clark

Terraform with Data Structures and Algorithms

Part 1 of 3 in Sudoblark Best Practices

How applying data structures and algorithms to Terraform turns infrastructure from a bottleneck into a self-service platform — with working code and a real proof point.

— Written 14 March 2025 · Edited 29 March 2026 · Written by Benjamin Clark

Refactoring monsternames-api to use modern Terraform

Part 3 of 3 in Infrastructure as Code (IaC)

How I replaced a Docker/EC2/MySQL monolith with a fully serverless REST API — and made the Python as data-driven as the Terraform.

— Written 04 December 2024 · Edited 28 March 2026 · Written by Benjamin Clark

The Python dictionary dispatch pattern

Part 2 of 3 in Software Odds and Ends

A little primer on said pattern, with some quite silly examples.

— Written 25 March 2024 · Edited 29 March 2026 · Written by Benjamin Clark

Provisioning API Gateway from an OpenAPI spec and deploying SwaggerUI to S3

One OpenAPI spec driving both the Terraform that provisions an API Gateway and a SwaggerUI documentation site — with CORS as the main gotcha.

— Written 21 August 2023 · Edited 28 March 2026 · Written by Benjamin Clark

Managing GitHub with Terraform (and GitHub!)

Part 2 of 3 in Infrastructure as Code (IaC)

How I used Terraform to manage all of Sudoblark's GitHub repositories — covering the three-tier data pattern, bootstrapping paradox, and drift detection.

— Written 07 August 2023 · Edited 28 March 2026 · Written by Benjamin Clark

Setting up Terraform for AWS: what I got wrong, and how I fixed it

Part 1 of 3 in Infrastructure as Code (IaC)

In 2023 I bootstrapped Terraform for my own AWS account. Three years on, looking back at that setup is professionally embarrassing — long-lived credentials, a single account, no tests. Here's what I built instead, and what I'd tell someone starting today.

— Written 26 July 2023 · Edited 28 March 2026 · Written by Benjamin Clark

The dungeon crawler I never shipped, and the API I did

I once tried to make a terminal dungeon crawler. It never shipped. But the monster name generator I built for it became a surprisingly functional REST API — and taught me more about BDD testing than any tutorial ever did.

— Written 25 July 2023 · Edited 28 March 2026 · Written by Benjamin Clark

Recursion and Pagination

Part 1 of 3 in Software Odds and Ends

How a three-parameter recursive function handles pagination across almost any REST API — page numbers, next-link cursors, nested responses, and the cases where it still breaks.

— Written 24 July 2023 · Edited 28 March 2026 · Written by Benjamin Clark