Skip to content

feat(swift,kotlin): mirror the recipe → Pattern rename in the ports — phase 2 - #1062

Merged
zachshallbetter merged 2 commits into
mainfrom
feat/pattern-rename-phase2-ports
Jul 9, 2026
Merged

feat(swift,kotlin): mirror the recipe → Pattern rename in the ports — phase 2#1062
zachshallbetter merged 2 commits into
mainfrom
feat/pattern-rename-phase2-ports

Conversation

@zachshallbetter

Copy link
Copy Markdown
Owner

Phase 2 of the recipe → Pattern rename epic — the Swift + Kotlin port mirror of phase 1's public-boundary rename (#1061).

Renamed (with deprecation aliases) in FundamentalCore (Swift) and :fundamental-core (Kotlin), plus the FieldLab/lab consumers:

  • FieldRecipeFieldPattern
  • CompiledRecipeCompiledPattern
  • compileRecipecompilePattern
  • FieldRecipes catalog namespace → FieldPatterns

Internal references are migrated to the new names (Swift/Kotlin emit real build warnings on deprecated-alias use, unlike JS JSDoc); the old names stay as @available(*, deprecated) / @Deprecated aliases, removed at 1.0. Internal helper type names (BodyRecipe, RecipeTier, …) are deferred — an exact mirror of phase 1.

Verified locally:

  • Swift: swift build complete (all targets incl. FieldLab); swift test 234 tests pass, incl. the cross-plane conformance golden ("every golden case is reproduced by the Swift force within tolerance").
  • Kotlin: :fundamental-core:test :lab:test217 tests, 0 failures (JDK 17).

The parity matrix (data/parity-matrix.json) tracks force catalogs + FieldHandle, not recipe symbols — confirmed unaffected by this rename.

…— phase 2

Phase 2 of the recipe -> Pattern rename epic — the Swift + Kotlin port mirror of the
JS phase-1 public-boundary rename (#1061). FieldRecipe -> FieldPattern, CompiledRecipe
-> CompiledPattern, compileRecipe -> compilePattern, and the FieldRecipes catalog
namespace -> FieldPatterns, in both FundamentalCore (Swift) and :fundamental-core
(Kotlin), plus the FieldLab / lab consumers.

Internal references are migrated to the new names (Swift/Kotlin emit real build
warnings on deprecated-alias use, unlike JS JSDoc); the old names are kept as
@available(deprecated) / @deprecated aliases for back-compat, removed at 1.0 —
mirroring phase 1's alias set. Internal helper type names (BodyRecipe, RecipeTier,
...) are left as-is, matching phase 1 (a later phase).

Verified locally:
- Swift: `swift build` complete (all targets incl. FieldLab); `swift test` 234 tests
  pass incl. the cross-plane conformance golden ("every golden case is reproduced by
  the Swift force within tolerance").
- Kotlin: `:fundamental-core:test :lab:test` BUILD SUCCESSFUL, 217 tests, 0 failures
  (JDK 17; local default JDK 26 crashes the bundled Kotlin compiler's version parse —
  an environment issue, not the diff).

The parity-matrix regen + CHANGELOG note land at finalize, once #1061 (phase 1) is on
main, so the matrix shows all three planes aligned rather than ports-ahead-of-JS.
@vercel

vercel Bot commented Jul 9, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
fundamental-engine Ready Ready Preview Jul 9, 2026 6:11am

Request Review

@zachshallbetter
zachshallbetter merged commit fb5f1fa into main Jul 9, 2026
19 checks passed
@zachshallbetter
zachshallbetter deleted the feat/pattern-rename-phase2-ports branch July 9, 2026 06:14

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: b1a8795f6e

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +115 to +118
typealias FieldRecipe = FieldPattern

@Deprecated("Renamed to FieldPatterns", ReplaceWith("FieldPatterns"))
typealias FieldRecipes = FieldPatterns

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Preserve the deprecated Kotlin JVM symbols

For Java callers or already-compiled Kotlin/JVM clients that still use the 0.x recipe API, these typealias declarations are erased and do not emit the old com.fundamental.core.recipes.FieldRecipe / FieldRecipes bytecode. That makes the advertised deprecation window source-only for Kotlin and a hard compile/load break for those clients instead of a warning; keep deprecated wrapper classes/objects (and the old CompiledRecipe JVM type/signatures) if the old names are meant to remain usable until 1.0.

Useful? React with 👍 / 👎.

zachshallbetter added a commit that referenced this pull request Jul 10, 2026
Rolls the seven publishable packages **0.9.3 → 0.9.4** (additive
release) and dates the CHANGELOG `[Unreleased]` as **`[0.9.4]` —
2026-07-10**. `FIELD_VERSION` bumped in lockstep (enforced by
`version.test.ts`). `apps/site` (0.2.0) + `apps/starter` (0.1.0) version
independently and are untouched.

**0.9.4 collects (all additive — 0.x patch):**
- **focus / attention substrate** (EXPERIMENTAL) — operator attention as
an input, agent attention as an output over one field
([#1063](#1063)).
- **recipe → `Pattern` rename** phases 1 + 2 — JS public API
([#1061](#1061))
+ Swift/Kotlin ports
([#1062](#1062)),
with deprecation aliases (old names still work, removed at 1.0).
- **core folder standardization** — `src/core` → `src/engine`, `math/`
extraction.

Verified: `build` · `version.test.ts` lockstep · `check:api` ·
`check:readme` green.

**Publish is yours:** merging this doesn't publish — pushing the
`v0.9.4` tag triggers the provenance publish workflow. I don't
tag/publish autonomously.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant