Monday, 17 August 2026

Codex Terra Light 5.6 on the ChatGPT Application

A lightweight coding model (Codex Terra Light 5.6) is available in the ChatGPT app. It is ok - and can do very simple refactoring when you know the approach you want to take.

Sunday, 16 August 2026

The .vs hidden directory

Visual Studio creates a .vs directory at the root of your solution. It is used to store solution specific settings and temporary data to help manage the state of your development environment. Fine to .gitignore.

However one interesting directory you may find inside is a slnx file. 

A slnx file is the XML version of the traditional sln file. However what is in .vs are supporting files for the slnx file format rather than the file itself.

Service Status Pages

The MSVS Service Status page is powerd by Atlassian Statuspage. It is free for up to 10 users.

Visual Studio 2026 August Release Notes

Among the changes in MSVS August release are thinking levels for GitHub Copilot - low, medium or high - with the highest obviously burning most tokens.

Low is for simple code suggestion; high for hard-to-debug issues.

There is also Git Agent that can be used to review your code prior to a pull request.

MSVS runs on monthly feature updates.

Saturday, 15 August 2026

EC2 instances have different specializations

Instance types are grouped under instance families. These include general purpose, compute optimized. memory optimized and others.

General purpose are a good starting point.

Compute optimized are good for machine learning (a compute intensive task). Gaming servers also would benefit from compute optimized EC2 instances, as would high performance computing and scientific applications.

Memory-optimized is good for applications that use large data sets in-memory. This differs from storage-optimized for workloads that utilise a great deal of locally stored data.

Accelerated-computing instances are good for floating point number calculations, graphics processing and pattern matching. They use hardware accelerators (like GPUs).

After choosing instance type, choose instance size. Performance and cost should be key paramaters here.

AWS Compute uses Multi-Tenancy

EC2 instances are virtual machines (VMs). VMs share an underlying physical machine with other instances (this is called multi-tenancy).  This is enabled by software called a hypervisor. VMs are isolated but share resources.

When you provision an EC2 instance, you can choose the operating system as Windows or Linux. You can provision thousands of EC2 instances on demand. They are resizable so you can start small and then give your instance(s) more memory and CPU.  This is the "elastic" nature of EC2 and is known as vertically scaling an instance. You can also control networking in EC2. Essentially you can choose what requests get to your server.

Virtualization is not a new concept; but AWS makes it more convenient to acquire servers via its Compute-as-a-Service model.

Compute Conceptualized in Terms of Power

Compute can be conceptualized in terms of power - in that it can be defined as the processing power needed to run applications, process data and and do calculations - and in the cloud, this is power "on demand". 

Thus power, and it's availability, is strategically important for cloud providers' expansion. 

Amazon's Elastic Compute Cloud (called EC2 for the double-use of the C) is the epitome of this definition of compute, and represents a powerful compute service from AWS.

iPhone Low Data Mode Explained

Some Windows users also have iPhones and need to understand iPhone settings and usage. In this spirit we deep dive Low Data Mode on the iPhone.  This can be a good option when travelling.

Low Data Mode is a Data Roaming setting. 

Settings -> Mobile Service -> Mobile Data Options -> Data Mode -> Low Data Mode

Other options in this category are Allow More Data on 5G and Standard.  Standard allows automatic updates and background tasks on mobile data, but limits video and FaceTime quality.

Monday, 10 August 2026

VPS Errors on Random Websites

Suggestive of problems with virtual private servers (a virtual machine hosted in a DC, with a dedicated operating system- typically Linux or Windows, root/admin acces and the ability to run websites, databases, APIs or background services).

Sunday, 9 August 2026

AI Orchestrators

LangChain, CrewAI, AutoGen, ADK and LangGraph are examples of tools used for agent orchestration.

RAG with Pinecone and Chroma

Pinecone (pinecone.io) is "the knowledge engine for agents" - aka. a vector database for RAG pipelines.

Chroma is open source search infra for AI - also built on vector database technology.

Prompt Optimization - Worth the Investment

Prompt optimization involves trying various prompts to find the most effective prompt for an LLM. 

This kind of A/B testing, or A/B/C/D.. testing is going to burn tokens. It may be justified in some regulated domains where you need to show consistency.

The ideology is that even if you express your intent well, the LLM underneath may not produce the best output with your input. This is because (it is said) "being clear" is not the same as "being optimal" for a generative model.

AutoPrompt is one option for what it refers to as "prompt tuning".
DSpy (a Python framework for building AI systems) has also been used for the same use case.

A video on DSpy can be found here.

Generative Models - GANs/VAEs and Diffusion Models - O My

 GANs are obviously generative adversarial networks. 

  • Developed by Ian Goodfellow and colleagues in June 2014
  • In this construct, two neural networks compete with each other in the form of a zero-sum game, where one agent's again is the other agent's loss
  • The concept is that competition forces both to get better
  • The game is to provide high realism output
  • They are used where you need hi-fidelity synthetic data, realistic imagery
  • They are not the dominant model for consumer generative AI
  • The theory behind GANs is an interesting application of probability spaces

Diffusion models.

  • Class of latent variable generative models
  • Based on diffusion processes in applied probability
  • The goal of the model is the learn the diffusion process that underpin an image (strange concept in itself, and one that puts this technique in the realm of latent variable generative models)
  • Two components - the forward diffusion process and the reverse sampling process
  • Simple example of a diffusion process is ink dropped in water, droplets diffuse through the water
  • One example application is denoising images (where image is blurred with Gaussian noise)
  • Stable Diffusion and DALL-E are diffusion based image generators

VAEs are variational auto-encoders

  • A variational auto-encoder (VAE) is an artificial neural network introduced by Kingma and Welling in 2013
  • It is part of the families of probabilistic graphical models and variational Bayesian methods

** classes of model **

Latent variable generative models.

  • Statistical model that relates a set of observable variables (also called manifest variables, indicators) to a set of latent variables
  • Latent variables are those that can be observed /inferred only via a mathematical model
  • They may correspond to aspects of physical reality
  • Earliest reference: Francis Bacon, Novum Organum
  • It may reduce the dimensionality of the data
Auto-encoder.
  • Form of artificial neural network.
  • Used to learn efficient codings of unlabeled data (unsupervised learning)
  • An autoencoder learns two things:
    • Encoding function - transforms the input data 
    • Decoding function - that recreates the input data from the encoding/encoded representation
  • Autoencoder learns an efficient representation (encoding) for a set of data, typically for dimensionality reduction, to generate lower dimensional embeddings for subsequent use by machine learning algorithms
Variations of auto-encoders that embody useful properties.
  • Example: regularized auto-encoder (aka sparse, denoising and contractive autoencoders)
  • Example: variational auto-encoder (used for generative applications)
"A continued process which... escapes the observation of the senses" - Francis Bacon



Saturday, 8 August 2026

xcopy still works

You can still do a mean recursive copy in cmd.exe using:

xcopy *.* /s

But when copying to a target directory, make sure the directory exists, or it will create a file (as it has done consistently in previous versions).  

MS-DOS is still alive and well.

The Codex Incompleteness Theorem

A few Codex gaps with workarounds.

Codex will create a .git directory - but without initializing. Before you check in code, do a git init.

For Windows, IDE based builds won't work - as settings need to be done in the GUI to persist in config. This makes debugging from the IDE difficult - "if I change settings in IDE for my ease of debugging will it break build process used by Codex?"

OAuth2 - Read the RFC

Given its widespread usage, it is worth reading the OAuth2 specification (RFC6749). OAuth2.1 is in development to integrate the OAuth2 spec with common extensions.

Entire

Entire is a new developer platform which boasts "every agent session/decision/tool stored in your repo". It aims to be the GitHub equivalent for agentic development.  Accessing Entire requires giving it access to your GitHub repos with authentication via GitHub OAuth (which uses OAuth2 - the current industry standard protocol for authorization).

Statistical Similarity

KL divergence is a way to measure "closeness" of two probability distributions. It is used in the literature on model cloning/model distillation.

Another name for it is "relative entropy".

Its full form is Kullback-Leibler divergence. 
It is denoted D[KL]( P || Q ). P is the true probability distribution and Q is the approximating probability distribution.

Mathematically:

D[

Thursday, 6 August 2026

Time Synchronization in Distributed Systems - A Different Take

Distributed systems employ a lot of synchronization - data synchronization (get all nodes consistent on data) as well as time synchronization (so every node has the same view of time).

Time synchronization can be achieved via protocols like NTP and PTP (the latter is precision time protocol - for applications like high frequency trading), but also logical systems like Lamport timestamps which order events without relying on physical time.

Lamport timestamps are a logical clock mechanism to capture chronological and causal relationships in a distributed system. Leslie Lamport introduce this as far back as 1978.

A variation of logical clock known as a vector clock is used in a variety of distributed database systems.

Tuesday, 4 August 2026

Revisiting Refactoring -> Purpose - "Confidence in Code"

Martin Fowler's book "Refactoring - Improving the Design of Existing Code" (with contributions by Kent Beck), first published in 1999, is really interesting and deserves a revisit in the context of AI.

On the cover of the Addison-Wesley Second Edition, he is quoted as saying: 

"Any fool can write code that a computer can understand. Good programmers write code that humans can understand".

Erich Gamma (one of the "Gang of Four" behind Design Patterns) remarks in the preface that refactoring began in "Smalltalk circles" and found its way into other programming language camps. 

He also emphasises its core role in framework development. 

"Frameworkers know that a framework won't be right the first time around—it must evolve
as they gain experience...The key to keeping code readable and modifiable is refactoring—for frameworks, in particular, but also for software in general." - Erich Gamma

Erich expands on the risk of refactoring - the fact it can set you back days or weeks and "refactoring becomes riskier when practiced informally or ad hoc".

Erich emphasises that a system is needed for successful refactoring: "To avoid digging your own grave, refactoring must be done systematically".

He mentions the core of the book is a "comprehensive catalog of refactorings".

He also relates a coding session with Kent Beck involving disciplined "one step at a time" refactoring and how we felt afterwards - 

"Not only did my confidence in the resulting code increase, I also felt less stressed."

Sunday, 2 August 2026

A Note on LSTM

LSTM, or long short term memory, seemingly paradoxically named, was co-invented by German computer scientist Sepp Hochreiter, who incubated it in his 1991 diploma thesis leading to its main publication in 1997. 

LSTM addresses the problem of numerical instability in training recurrent neural networks (RNNs) that prevent them from learning long sequences (the so-called vanishing gradient problem).

In 2007, he and others applied LSTM, optimizing the architecture, to very fast protein homology detection without requiring sequence alignment.

Protein homology detection is the process of identifying whether two proteins share a common evolutionary origin - one of the core problems in computational biology.  

Homology implies shared structure and shared function.


Saturday, 1 August 2026

Agentic Coding, IDE Debugging

You've built your software agentically. Now you want to (need to) debug it in an IDE.

You may need to add some extra settings.

OpenAI's Astra Solves More Maths Problems

Astra has solved 10 hard maths problems (published 1 August 2026) following on from its disproof of the Erdös unit distance conjecture (from combinatorial geometry) in May 2026.

A paper of almost 250 pages (inclusive of references) is available from OpenAI's website.

Defensive Perl

Perl is less fashionable than Python these days, but it is a very flexible language which excels in text processing.

Its flexibility allows a myriad of programming styles, however, so having a set of defensive techniques helps.

Here are some top tips:
  • Switch warnings on - use the minus-w command line flag -  #! perl -w
  • Learn and use perlpod - it looks a bit like this at the start of your file  =head1 NAME  myscript =cut
  • Always use strict; at the start of your program (this pragma restricts expressions that are hard to debug)
  • Qualify your variables with type prefixes (similar to "Hungarian" notation) e.g. my $sHeader for strings, my @aCodes for arrays, my %hCodesToDescriptors, and appropriate equivalents for common custom types
Recap on pragmas: A pragma is a module which influences some aspect of the compile time or run time behaviour of Perl, such as strict or warnings. From Perl 5.10 onward - custom pragmata are supported.

Happy Perling!

How Imports Work in Python

The syntax for import is as follows (keywords in quotes):

"import"  module [ "as" identifier ]

There is also a variation to use when testing proposed changes to Python:

"from " "__future__" "import" feature [ "as" identifier ]

The first thing import does is find an load the module. It then initialises the module.



Frozen Frames when Debugging Python

When running pdb, you will notice certain debugging frames as frozen.  This is typically when:
  • code is compiled C-extension code (e.g. importlib, asyncio, threading internals)
  • the debugger cannot step in or modify them
  • they are part of Python's frozen importlib bootstrap
For example, in the following:

<frozen importlib._bootstrap>
<frozen importlib._bootstrap_external>

The modules are embedded in the Python binary.

If you try ll in the Python debugger when compiled code is being processed, you will get the error: *** could not get source code.