HomeiOS DevelopmentKits All of the Means Down

Kits All of the Means Down


All the pieces that occurred on github.com/Cocoanetics because the SwiftCross put up (June 2 – June 13, 2026). 4 new kits, a fourteen-year-old flagship that got here residence, and the stretch the place the extraction sample began delivery to customers.


Once I printed the SwiftCross put up on June 2nd, I left two threads dangling: an agent was refactoring SwiftMCP’s package deal construction so client-only customers wouldn’t drag in SwiftNIO, and if that labored it will unlock SwiftAgents on Home windows. I anticipated to report on that “finally.” Each landed earlier than the day was over. That set the tone for the week — I preserve discovering that the limiting issue is not how briskly issues get constructed, however how briskly I can resolve what to construct subsequent.

The free ends didn’t keep free for a day

SwiftCross itself didn’t sit nonetheless previous lunch. By the night of June 2nd it had grown WallClock — a conveyable nanosecond wall-clock (clock_gettime on POSIX, GetSystemTimePreciseAsFileTime on Home windows) that I wanted for span timing in agent traces — launched as 1.1.0, and Setting.set, a conveyable setenv for .env loaders, launched as 1.2.0. Two tags in a single night for a package deal I had introduced that morning.

The identical night, SwiftMCP 1.5.0 shipped the package-traits refactor from the put up: Server, Consumer, and OpenAPI traits, all on by default, with swift-nio, swift-crypto, and swift-certificates gated behind Server. A client-only shopper now will get a completely NIO-free construct — which is the entire ballgame for Home windows. (1.5.1 adopted the subsequent morning to widen the swift-crypto vary; dependency hygiene by no means sleeps.)

And SwiftAgents cashed the test instantly: it now hyperlinks SwiftMCP with traits: [Client] solely, dropped swift-nio totally, migrated its remaining shims to SwiftCross, and the Home windows CI probe went inexperienced. The factor I described as “if that works out” within the final put up was a merged PR about three hours later.

SwiftMCP then bought two extra modernization passes in the course of the week: all three server transports now conform to swift-service-lifecycle‘s Service (swish SIGTERM/SIGINT shutdown replaces my bespoke sign handler, and the stdio transport lastly exits on EOF as a substitute of politely polling at 10 Hz), and the HTTP transport was rebuilt on apple/swift-http-types — typed header fields and strategies as a substitute of strings, with NIOHTTPTypesHTTP1 deleting a pile of hand-rolled conversions.

The cascade reached SwiftMail

That is my favourite a part of having a small ecosystem: a launch in a single package deal turns into a one-line diff within the subsequent. SwiftMail 1.7.0 (June 3) adopted SwiftCross 1.2.0, dropped my swift-nio-imap fork in favor of Apple’s upstream, refreshed each dependency, and bought Home windows and Android CI. A day later 1.7.1 mounted a genuinely refined bug — and never considered one of mine: contributor tabmail-kmyi discovered that the pipelined FETCH dispatcher may drop later physique components when a server batches untagged responses. Mounted with correct EmbeddedChannel regression assessments. The packages being presentable sufficient that strangers debug IMAP pipelining for you is a quiet milestone of its personal.

The brokers audited their very own playground

On June 4th I did one thing that also makes me smile: I let an agent free inside the SwiftBash sandbox and instructed it to poke round like a suspicious consumer. It got here again with a stack of points — stat leaked my actual host uid/gid by the digital filesystem, the time key phrase didn’t parse, ps couldn’t see the shell it was operating in, /tmp didn’t present up in ls /, assorted GNU choices have been lacking from xxd, od, and realpath.

Then, over that night time and the subsequent day, the brokers mounted every part on their very own checklist. SwiftBash now experiences digital identification on the filesystem boundary, has an actual mount command with a digital mount desk, parses time and experiences actual/consumer/sys, and its ps is not blind to itself. ShellKit bought the matching ProcessTable lifecycle work, and BinCatalog moved from ShellKit into SwiftBash the place it belongs. The README gained a “What’s digital (and what which means)” part, as a result of if an agent wanted to find these solutions empirically, so would you. There’s one thing pleasingly self-referential about an agent submitting bugs in opposition to the sandbox constructed to include brokers — after which resolving them.

sqlite3 to byte-parity, then out the door

Additionally on June 4th, the SwiftPorts sqlite3 shell port went by a parity marathon: .dump constancy with correct identifier quoting, byte-exact floating-point formatting through a small C shim, .databases/.schema/.present/.width/.restrict conduct matched in opposition to the true factor.

It turned out that it was exceptionally simple to get sqlite3 to construct for all platforms as a result of the code is basically a single c file. After which I remembered that there was a full textual content search extension (FTS) that Apple selected to not ship in sqlite3. I requested the brokers, if we may that. They sayed “Sure!” and constructed it. Then I remembered that there was additionally a vector search extension for sqlite3. Identical story: if you happen to can assume it, they will make it.

For this reason we bought FTS5 and sqlite-vec which you’ll be able to allow individually through SPM traits.

At which level the SQLite stack had clearly outgrown its host, and on June eighth it was extracted into SQLiteKit — a brand new repo: a cross-platform Swift wrapper over a vendored SQLite amalgamation with ready statements, FTS5 full-text search, and sqlite-vec semantic search behind traits. Twelve thousand strains left SwiftPorts in a single commit. If that transfer sounds acquainted, it’s precisely what SwiftCross was: the third time you copy one thing, it needs to be a package deal.

Instructing the brokers to look

SQLiteKit instantly had a buyer. For a very long time I saved saying that macOS and iOS must get an un-neutered model of sqlite3. Since final 12 months CoreSpotlight clearly has a semantic index, which cries out “vector DB”. However there is no such thing as a first-party public semantic DB functionality to be discovered on Apple platforms.

Final 12 months I experimented with a easy linear vector search in SwiftAgents, in addition to the semantic search that OpenAI offers us. There you add paperwork to OpenAI and you should use a file search software to complement your completions.

Now it was inside my grasp to develop SwiftAgents a persistent SQLiteVectorStore — vec0 KNN plus FTS5 bm25 plus hybrid search with line-span provenance — after which, in a single day of eight consecutive PRs, absorbed the retrieval methods from tobi’s qmd: sensible markdown chunking that respects code fences, reciprocal rank fusion, lex/vec/hyde question enlargement, LLM-gated enlargement, a batch reranker, and question/doc embedding asymmetry. On-device Apple NL embeddings by default; OpenAI solely when a secret’s current.

The deliberate half was the order. qmdquestion markdown — and the OpenClaw equal every carried numerous hard-won, embedded data about tips on how to construct a memory-retrieval pipeline, and I didn’t need that data trapped inside a CLI. So I had the agent rebuild the index engine inside SwiftAgents first, the place something can reuse it, and solely then — as a result of the engine existed — QMDKit bought constructed on prime of it in about two days: one other new repo, a qmd clone that indexes and semantically searches Markdown, accessible as a standalone CLI and as a sandboxed ShellKit builtin. Which suggests SwiftBash classes — the identical sandbox the brokers work in — now have semantic search over my notes as a shell command. The brokers constructed their very own retrieval tooling, then put in it in their very own atmosphere. I simply watched.

GitKit, and a lesson in humility from libgit2

June ninth: I needed SwiftPorts’ git to cease relying on a private libgit2 fork. The fork I’d been leaning on minted a recent department and package deal for each single libgit2 launch; I needed the alternative form — one construct that pulls the C supply straight from upstream as a git submodule, version-matched, so bumping libgit2 turns into a submodule pointer slightly than a brand-new repo. So GitKit grew to become the third new repo of the week — libgit2 1.9.4 packaged for SwiftPM with a pristine upstream submodule, pushed to inexperienced on macOS, iOS, Linux, Home windows, and Android in a single afternoon (Home windows wanted a curated header umbrella; Android wanted its personal toolchain rituals; tvOS and watchOS have been dropped as a result of libgit2 forks processes, they usually don’t).

Then actuality arrived on schedule. SwiftPorts adopted GitKit, and git stash apply broke. The perpetrator was splendidly obscure: feature-define names inherited from one other fork that not matched libgit2 1.9.4’s dialect, silently disabling issues like nanosecond timestamps. Undertake, regress, revert, repair, re-adopt — all inside about 9 hours, each leg verified by the five-platform CI. That is the outer loop from the SwiftCross put up doing precisely what I claimed it does, besides this time the pink checkmark saved me from delivery a subtly damaged git.

The week closed with the now-familiar transfer: SwiftPorts’ complete Swift git layer was lifted out and have become the GitKit 2.0.0 SDK — a full idiomatic Repository API over libgit2 — leaving SwiftPorts with simply the sandbox-aware face and CLI. Zero duplication. (There was additionally a short comedy in three acts about how a tagged package deal might rely upon the untagged swift-archive; the reply, after one rejected fork-with-a-minted-tag, is: pin the upstream commit and let traits prune it.)

The parser needed to be a package too

If the primary 9 days had a chorus, it was “the third time you copy one thing, it needs to be a package deal.” Day eleven onward simply saved proving it — beginning, of all locations, with the oldest piece of code in the entire org.

For years the tolerant HTML parser inside SwiftText was a quiet workhorse: a Swift rewrite of DTHTMLParser, itself a chunk of DTFoundation that predates most of those repos by greater than a decade. On June 12 it lastly moved out by itself. XMLKit — an async streaming HTMLParser constructed on libxml2’s SAX interface, so it handles real-world malformed HTML gracefully and by no means builds a DOM except you ask it to. It left SwiftText carrying its full git historical past, and SwiftText instantly adopted it again as a dependency. Launched as 1.0.0 that afternoon, then 1.0.1 a number of hours later as soon as CI was constructing and operating the check suite on all 5 platforms — macOS, iOS, Linux, Home windows, Android. The identify is a promise: an XML SAX module alongside the identical strains is the apparent subsequent tenant.

The trustworthy set off was narrower than the outcome. I didn’t wish to drag swift-markdown into DTCoreText simply to achieve the HTML parser, and my first intuition was a budget repair — a trait inside SwiftText that gates the dependency away. However the earlier extractions had taught me higher: the third time you attain for a factor by a wall of unrelated dependencies, it needs to be its personal package deal. XMLKit is, at coronary heart, libxml2 plus a skinny layer of Swift wrappers — and as a result of it stands alone, with nothing else cluttering the manifest, I may chase all of it the best way to inexperienced CI on all 5 platforms. That five-platform checkmark is my present gold normal, and realistically you solely earn it one library at a time.

After which the fourteen-year-old flagship got here residence

That is the half I didn’t see coming. DTCoreText — the CoreText-meets-HTML library with six thousand stars and a decade and a half of historical past — shipped 2.1.0 on June 13, and it’s probably the most fascinating launch of the stretch exactly as a result of it’s the least new.

Two issues occurred to it without delay. It bought options: HTML tables with an actual NSTextTable-compatible mannequin (colspan/rowspan, border-collapse, row-by-row pagination), CSS floats (float/clear with textual content wrapping), CSS border-spacing, and — the one which made me grin — native iOS 27 TextKit bridging, so DTCoreText’s textual content blocks and tables lay out as actual NSTextBlock/NSTextTable on the brand new SDK. Roughly 8,600 strains throughout 5 PRs, the primary function launch constructed on this spring’s Swift 2.0 rewrite.

The tables particularly are a fourteen-year lastly. The primary request to render an HTML

is situation #144, filed in March 2012 and labeled — with brutal honesty — Sponsor Wanted. No one ever sponsored it, and the asks simply saved arriving each few years. What lastly broke the logjam wasn’t a cheque: it was iOS 27 publishing NSTextBlock/NSTextTable/NSTextTableBlock as actual courses — so there was a local mannequin value mirroring — plus an agent keen to jot down the eight thousand strains the bounty by no means purchased.

And it bought smaller: its dependency graph went from 5 packages to at least one. As a result of the one factor DTCoreText ever imported from SwiftText was that HTML parser — which now lives in XMLKit — it may drop SwiftText, swift-markdown, swift-cmark, swift-docc-plugin, SymbolKit, and swift-argument-parser in a single Bundle.swift edit, with zero supply adjustments. import HTMLParser resolves to the an identical module; solely the manifest moved.

So the lineage closed a loop. DTHTMLParser grew to become SwiftText’s parser grew to become XMLKit’s HTMLParser, and the fourteen-year-old library that the unique DTHTMLParser shipped in is now a one-dependency shopper of its personal great-grandchild. (It additionally quietly renamed its default department from develop to primary on the best way out the door.)

One core, many facades

Beneath the seen packages, the plumbing saved consolidating on the identical precept. On June 11 the virtual-to-host PathMapping logic — the factor that makes a sandbox present /workspace whereas the bytes stay someplace actual — moved down out of SwiftBash into ShellKit, the place each caller can share one authority as a substitute of every reinventing it. ShellKit grew PathMapping and a Sandbox.confined(to:residence:temporaryDirectory:) entry level; SwiftBash then re-consumed it as two skinny facades (a mounted filesystem and an exec confinement) and deleted its outdated identification mount on objective — a loud compile-time break for embedders, which is how this org likes its breaks. The identical day, SwiftBash additionally gave every sandbox its personal per-instance /tmp as a substitute of sharing the method temp listing.

It’s the BinCatalog/ProcessTable transfer from the SwiftCross week, one stage decrease: the shared primitive sinks to the bottom package deal that may personal it, and every part above it will get thinner.

SwiftGH, byte-for-byte

The GitHub-CLI port dwelling in SwiftPorts picked up a reputation this stretch — SwiftGH — and a parity obsession. Throughout a decent run of PRs it chased actual gh 2.89.0 to the byte: gh api --include now prints the complete Go-style header preamble with canonical MIME casing and CRLFs, --jq matches gojq’s compact key-sorted output, gh auth standing refuses API calls with no token and exits with the identical code upstream does, and the REST fashions grew fork metadata and PR-review sorts. Most of it was pulled alongside by a downstream app the commits preserve calling “RepoGraph” — the now-familiar form of a shopper dragging a library to completion.

The architecturally fascinating bit is the wiring. SwiftPorts now relies on GitKit pinned to department: primary, and on June 13 the 2 repos shipped a matched pair: GitKit added ColorPalette.colorizeDiffStat (the inexperienced/pink histogram coloring for git diff --stat), and SwiftPorts’ git port consumed it the identical day. The diff-coloring logic that GitKit inherited when its SDK was carved out of SwiftPorts final week is now flowing again the opposite method as a stay dependency. The extraction wasn’t a goodbye; it was a cellphone line.

Off to the facet, SwiftMCP opened a planning situation to undertake the upcoming 2026-07-28 MCP draft — dual-era assist and a protocol-version skills mannequin. That’s the subsequent large determination queued up slightly than a shipped one, nevertheless it’s value flagging: the protocol the entire agent stack speaks is about to achieve a versioned capabilities handshake.

The brokers’ reminiscence grew a second backend

The retrieval thread from final week saved going. SwiftAgents launched a store-agnostic SemanticStore protocol — indexText / indexFile / sync / search / rely — with two backends behind it: the present on-device SQLite retailer and a brand new hosted OpenAIVectorStore. One protocol, two shops, swap by configuration. It got here with a deliberate breaking rename (the outdated VectorStore identify collided with each the wire DTO and OpenAI’s personal product time period), which rippled downstream into QMDKit inside the hour, since QMDKit pins SwiftAgents at department: primary. QMDKit additionally reached qmd output parity the identical day — snippet extraction with diff-style line headers and clickable OSC-8 file hyperlinks within the terminal.

Then it began delivery

Right here’s the genuinely new type of exercise. For 9 days the work was constructing kits; on June 13 a noticeable share of it was delivery them to individuals.

Publish — my native mail daemon, MCP server, and CLI, constructed on SwiftMail, SwiftMCP, and SwiftText — bought a dependency refresh and went out as v1.6.7 by the homebrew-tap, which now serves 4 instruments by brew set up: put up, codexmonitor, swifttext, and swiftbutler. And ChatGPTExporter, the little Safari extension that saves a ChatGPT dialog as Markdown (footnoted citations and all), bought dressed for public launch the identical day — renamed from its working title to “ChatGPT Exporter,” given a CI workflow that compile-checks the app and extension unsigned, docs cleaned of a function that not exists, and a repair so code-interpreter file downloads resolve to actual bytes as a substitute of a JSON envelope.

None of those are kits, and that’s the purpose. The identical outer loop that drives a library to five-platform inexperienced additionally, it seems, drives a menu-bar app and a browser extension to the store-adjacent end line. The sample grew a roof.

The second it bought actual

All of this — the kits, the extractions, the five-platform CI — stays summary till you watch it run someplace it has no enterprise operating but. The opposite day I launched iBash, my still-in-development iOS shell, listed a folder of Markdown notes with qmd, after which, as a result of I may, opened sqlite3 proper there contained in the sandbox and queried the database it had simply written. And there it was: the precise vec0 vectors, the precise FTS5 rows — semantic and key phrase indexes sitting in an actual SQLite file, on a cellphone. WOW. It really works. Each layer I’d been assembling within the summary — SQLiteKit’s vec0 and FTS5, the SemanticStore engine, QMDKit’s pipeline, the SwiftBash sandbox internet hosting each the indexer and the inspector — collapsed into one operating factor I may poke at with a shell command. That’s the second a pile of packages stops being a dependency graph and turns into a software.

The sample, twelve days in

Trying again on the entire stretch: SwiftCross, SQLiteKit, GitKit, XMLKit — 4 packages that each one adopted the an identical arc. One thing will get constructed inside a bunch undertaking as a result of it’s wanted there, will get pushed to parity or manufacturing high quality by the CI outer loop, and the second a second shopper seems, the brokers make extraction almost free. PathMapping did it one stage down, sinking from SwiftBash into ShellKit. The costly components was the mechanical ones — transferring twelve thousand strains, re-wiring dependents, maintaining 5 platforms inexperienced by the entire shuffle. These now value roughly one well-phrased instruction.

It’s value saying plainly what a Package even is round right here, as a result of three of these 4 make it concrete: SQLiteKit is SQLite, GitKit is libgit2, XMLKit is libxml2. The recipe doesn’t differ. Take a gnarly C library, get it constructing with each final platform-specific intricacy on all 5 main Swift platforms — macOS, iOS, Linux, Home windows, Android — after which lay a Swift API over it that’s really nice to name. The five-platform inexperienced checkmark is the gold normal; the Swift floor is the rationale anybody reaches for it. That’s the entire suffix.

What shocked me within the again half was the attain. The sample didn’t simply spawn new kits; it pulled within the oldest code I've. DTCoreText — fourteen years outdated, six thousand stars — slimmed to a single dependency and gained fashionable CSS tables and iOS 27 TextKit bridging in the identical launch, as a result of the parser it all the time carried had lastly turn into a package deal its great-grandchild may share. After which the work turned outward: Homebrew formulae, a Safari extension prepped for the shop. Kits all the best way down, and now merchandise on prime.

What’s left for me is the half I really take pleasure in: noticing {that a} factor needs to be a package — or {that a} package is lastly able to be a product — and saying so.




Classes: Updates




































RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

- Advertisment -
Google search engine

Most Popular

Recent Comments