The open-source agent harness - the runtime layer that turns an LLM into a working agent.
Use Changeset for versioning and release (#232)
Chirag Jainb56c003e99d0
diff --git a/.changeset/README.md b/.changeset/README.mdnew file mode 100644index 000000000..654c6d475--- /dev/null+++ b/.changeset/README.md@@ -0,0 +1,8 @@+# Changesets++Hello and welcome! This folder has been automatically generated by `@changesets/cli`, a build tool that works+with multi-package repos, or single-package repos to help you version and publish your code. You can+find the full documentation for it [in our repository](https://github.com/changesets/changesets).++We have a quick list of common questions to get you started engaging with this project in+[our documentation](https://github.com/changesets/changesets/blob/main/docs/common-questions.md).diff --git a/.changeset/config.json b/.changeset/config.jsonnew file mode 100644index 000000000..74ae3de58--- /dev/null+++ b/.changeset/config.json@@ -0,0 +1,11 @@+{+ "$schema": "https://unpkg.com/@changesets/[email protected]/schema.json",+ "changelog": "@changesets/cli/changelog",+ "commit": false,+ "fixed": [],+ "linked": [],+ "access": "public",+ "baseBranch": "main",+ "updateInternalDependencies": "patch",+ "bumpVersionsWithWorkspaceProtocolOnly": true+}diff --git a/.changeset/pre.json b/.changeset/pre.jsonnew file mode 100644index 000000000..d1deaa4cf--- /dev/null+++ b/.changeset/pre.json@@ -0,0 +1,4 @@+{+ "mode": "pre",+ "tag": "rc"+}diff --git a/.changeset/tangy-cats-think.md b/.changeset/tangy-cats-think.mdnew file mode 100644index 000000000..ea8ce7e31--- /dev/null+++ b/.changeset/tangy-cats-think.md@@ -0,0 +1,7 @@+---+'@truefoundry/trueforge-core': minor+'@truefoundry/trueforge': minor+'@truefoundry/trueforge-sdk': minor+---++Initial 0.1.0-rc.1 prerelease of all public packages.diff --git a/.github/fern/generators.yml b/.github/fern/generators.ymlindex 96d9ac823..0732ed9b6 100644--- a/.github/fern/generators.yml+++ b/.github/fern/generators.yml@@ -3,7 +3,7 @@# openapi/openapi.json is committed by `pnpm openapi:write`, so Fern never needs the server.readme:introduction: >- TypeScript client for the TrueFoundry agent harness server: a self-hosted+ TypeScript client for the TrueForge agent harness server: a self-hostedruntime that executes agent turns and streams them over Server-Sent Events.@@ -42,6 +42,18 @@ groups:config:packageJson:name: '@truefoundry/trueforge-sdk'+ license: MIT+ author: TrueForge+ repository:+ type: git+ url: git+https://github.com/truefoundry/trueforge.git+ directory: packages/sdk+ homepage: https://github.com/truefoundry/trueforge/tree/main/packages/sdk#readme+ bugs:+ url: https://github.com/truefoundry/trueforge/issues+ publishConfig:+ access: public+ provenance: falseallowExtraFields: trueallowCustomFetcher: trueenableInlineTypes: falsediff --git a/.github/workflows/generate-sdk.yaml b/.github/workflows/generate-sdk.yamlindex fac179124..a8b3fe291 100644--- a/.github/workflows/generate-sdk.yaml+++ b/.github/workflows/generate-sdk.yaml@@ -113,7 +113,15 @@ jobs:git config user.name "github-actions[bot]"git config user.email "41898282+github-actions[bot]@users.noreply.github.com"- git add .github/fern/openapi packages/sdk pnpm-lock.yaml++ # Bot-authored sdk diffs need a changeset; the PR author never touches this commit.+ # Skip packages/sdk/.fern — Fern metadata only, not a consumer-facing change.+ # changeset:sdk-regen is a no-op if the sdk is already named in a pending file.+ if [ -n "$(git status --porcelain -- packages/sdk ':!packages/sdk/.fern')" ]; then+ pnpm changeset:sdk-regen+ fi++ git add .github/fern/openapi packages/sdk pnpm-lock.yaml .changesetgit commit -m "Regenerate OpenAPI document and TypeScript SDK"git push origin "HEAD:refs/heads/$BRANCH"diff --git a/.github/workflows/push-sandbox-image.yml b/.github/workflows/push-sandbox-image.ymlindex 13ba3d4c4..9a6d50a68 100644--- a/.github/workflows/push-sandbox-image.yml+++ b/.github/workflows/push-sandbox-image.yml@@ -22,7 +22,7 @@ jobs:with:artifactory_registry_url: ${{ vars.TRUEFOUNDRY_ARTIFACTORY_REGISTRY_URL }}artifactory_repository_url: ${{ vars.TRUEFOUNDRY_ARTIFACTORY_PUBLIC_REPOSITORY }}- image_artifact_name: truefoundry-utils-core-sandbox+ image_artifact_name: trueforge-sandboximage_tag: ${{ github.sha }}image_context: packages/harness/scripts/sandboxdockerfile_path: packages/harness/scripts/sandbox/sandbox.Dockerfile@@ -41,7 +41,7 @@ jobs:steps:- name: Print image URIenv:- IMAGE_URI: ${{ vars.TRUEFOUNDRY_ARTIFACTORY_PUBLIC_REPOSITORY }}/truefoundry-utils-core-sandbox:${{ github.sha }}+ IMAGE_URI: ${{ vars.TRUEFOUNDRY_ARTIFACTORY_PUBLIC_REPOSITORY }}/trueforge-sandbox:${{ github.sha }}run: |set -euo pipefailecho "Pushed image URI: $IMAGE_URI"diff --git a/.github/workflows/release-image-and-chart.yml b/.github/workflows/release-image-and-chart.ymlindex e2d29f6b0..0069cf1d8 100644--- a/.github/workflows/release-image-and-chart.yml+++ b/.github/workflows/release-image-and-chart.yml@@ -48,7 +48,7 @@ jobs:with:artifactory_registry_url: ${{ vars.TRUEFOUNDRY_ARTIFACTORY_REGISTRY_URL }}artifactory_repository_url: ${{ vars.TRUEFOUNDRY_ARTIFACTORY_PUBLIC_REPOSITORY }}- image_artifact_name: truefoundry-utils+ image_artifact_name: trueforgeimage_tag: ${{ github.sha }}image_context: .dockerfile_path: Dockerfile@@ -71,7 +71,7 @@ jobs:# commit SHA while remaining packageable. Image tag stays the raw SHA.VERSION: 0.0.0-${{ github.sha }}IMAGE_TAG: ${{ github.sha }}- CHART_DIR: charts/truefoundry-utils+ CHART_DIR: charts/trueforgeHELM_REGISTRY_URL: ${{ vars.TRUEFOUNDRY_ARTIFACTORY_REGISTRY_URL }}HELM_REGISTRY_USERNAME: ${{ secrets.TRUEFOUNDRY_ARTIFACTORY_PUBLIC_USERNAME }}HELM_REGISTRY_PASSWORD: ${{ secrets.TRUEFOUNDRY_ARTIFACTORY_PUBLIC_PASSWORD }}@@ -118,7 +118,7 @@ jobs:- name: Print image URIenv:- IMAGE_URI: ${{ vars.TRUEFOUNDRY_ARTIFACTORY_PUBLIC_REPOSITORY }}/truefoundry-utils:${{ github.sha }}+ IMAGE_URI: ${{ vars.TRUEFOUNDRY_ARTIFACTORY_PUBLIC_REPOSITORY }}/trueforge:${{ github.sha }}run: |set -euo pipefailecho "Pushed image URI: $IMAGE_URI"diff --git a/.github/workflows/release.yml b/.github/workflows/release.ymlindex 386ae1fee..5d799bfd1 100644--- a/.github/workflows/release.yml+++ b/.github/workflows/release.yml@@ -1,68 +1,76 @@+# npm publish for the four public packages.+#+# Filename is load-bearing: npm trusted publishers are bound to `release.yml`.+# Do not rename this file without updating every package on npmjs.com.+#+# On every push to main, changesets/action does one of:+# - pending `.changeset/*.md` → open/update the Version Packages PR+# - none pending → `pnpm release` (build + `changeset publish`)+# Merge the Version Packages PR to publish. There is no separate publish Action+# and no `v*` tag trigger.+#+# Auth is GitHub OIDC (no NPM_TOKEN). An `_authToken` in user `.npmrc` disables+# pnpm's OIDC exchange, so this job must not set NPM_TOKEN / NODE_AUTH_TOKEN.name: Release+on:push:- tags: ['v*']+ branches: [main]+ workflow_dispatch:++concurrency:+ group: ${{ github.workflow }}-${{ github.ref }}+ # Never cancel a publish that is already talking to npm.+ cancel-in-progress: falsepermissions:- contents: read- id-token: write # required for trusted publishing (OIDC)+ contents: write # Version Packages branch + optional GitHub Releases+ pull-requests: write # open/update the Version Packages PR+ id-token: write # npm trusted publishing (OIDC)jobs:- publish:+ release:+ name: Version or publishruns-on: ubuntu-latest+ # Same ceiling as generate-sdk.yaml: a Version Packages run that also+ # rebakes the SDK (Docker Fern) is the slow path. Publish is just CI + npm.+ timeout-minutes: 30steps:- uses: actions/checkout@v4+ with:+ # Full history so `changeset version` can write CHANGELOG from commits.+ fetch-depth: 0+ # Named branch, not a detached SHA: `pnpm publish` git-checks require+ # HEAD to be on `main` (the old tag-push job needed --no-git-checks).+ ref: ${{ github.ref }}- - uses: pnpm/action-setup@v4 # reads pnpm version from root packageManager field+ - uses: pnpm/action-setup@v4- uses: actions/setup-node@v4with:- node-version: 22+ node-version: 24+ cache: pnpmregistry-url: https://registry.npmjs.org- run: pnpm install --frozen-lockfile+- run: pnpm build- run: pnpm test- # Guard: git tag must match @truefoundry/trueforge-core (library is the version authority).- # npm publishes what's in package.json, not the tag name. @truefoundry/trueforge may- # use an independent version; bump it in the same release PR when the app changes.- - name: Verify tag matches trueforge-core version- working-directory: packages/harness+ # Root build copies FE into packages/server/dist/_frontend; refuse an API-only tarball.+ - name: Verify packaged UI is presentrun: |- PKG_VERSION="v$(node -p "require('./package.json').version")"- if [ "$PKG_VERSION" != "$GITHUB_REF_NAME" ]; then- echo "Tag $GITHUB_REF_NAME does not match packages/harness ($PKG_VERSION)"- exit 1- fi+ test -f packages/server/dist/cli.js+ test -f packages/server/dist/_frontend/index.html- # Library first: @truefoundry/trueforge pins workspace:* → this concrete version on publish.- # Prereleases (e.g. 0.1.9-rc.1) pass --tag explicitly; first preid → dist-tag (rc).- # --no-git-checks: this job checks out a tag (detached HEAD), so pnpm's default- # "current branch is main/master" check would otherwise always fail here.- - name: Publish @truefoundry/trueforge-core- working-directory: packages/harness- run: |- VERSION="$(node -p "require('./package.json').version")"- if [[ "$VERSION" == *-* ]]; then- TAG="${VERSION#*-}"- TAG="${TAG%%.*}"- echo "Publishing $VERSION with --tag $TAG"- pnpm publish --access public --tag "$TAG" --no-git-checks- else- echo "Publishing $VERSION (latest)"- pnpm publish --access public --no-git-checks- fi- # TODO(oss): add --provenance once the repo is public. Do NOT add it now:- # provenance publicly attests the source repo and commit.-- # TODO: Publish @truefoundry/trueforge-- # # Root build copies FE into packages/server/dist/_frontend; refuse an API-only tarball.- # - name: Verify packaged UI is present- # run: |- # test -f packages/server/dist/cli.js- # test -f packages/server/dist/_frontend/index.html-- # App + CLI from package root (dist/ includes dist/_frontend/).- # pnpm publish rewrites workspace:* deps to the trueforge-core version just published.+ - name: Create Version Packages PR or publish to npm+ uses: changesets/action@v1+ with:+ version: pnpm run version+ publish: pnpm run release+ createGithubReleases: true+ env:+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}+ # TODO(oss): set NPM_CONFIG_PROVENANCE once the repo is public. Do NOT+ # set it now: provenance publicly attests the source repo and commit.+ # publishConfig.provenance is false on every public package.diff --git a/README.md b/README.mdindex a550ae61d..1b418f600 100644--- a/README.md+++ b/README.md@@ -73,15 +73,15 @@ Every environment variable is documented in [`packages/server/.env.example`](pac### Hosted mode (Kubernetes)-The [`charts/truefoundry-utils`](charts/truefoundry-utils) Helm chart deploys hosted mode with bundled Postgres and Redis (or your own):+The [`charts/trueforge`](charts/trueforge) Helm chart deploys hosted mode with bundled Postgres and Redis (or your own):```bash# TODO: replace <HELM_REPO> with the published Helm repo URL-helm install truefoundry-utils oci://<HELM_REPO>/truefoundry-utils \+helm install trueforge oci://<HELM_REPO>/trueforge \--version <x.y.z>```-See the [chart README](charts/truefoundry-utils/README.md) (including [`configs.oidc`](charts/truefoundry-utils/README.md#oidc)) and [Quickstart](https://trueforge.dev/quickstart) for values and details.+See the [chart README](charts/trueforge/README.md) (including [`configs.oidc`](charts/trueforge/README.md#oidc)) and [Quickstart](https://trueforge.dev/quickstart) for values and details.## Build your first agentdiff --git a/RELEASING.md b/RELEASING.mdindex d6d431eb6..3a7af99d7 100644--- a/RELEASING.md+++ b/RELEASING.md@@ -1,45 +1,76 @@# Releasing-Two public packages ship from this repo:+Two pipelines ship from this repo:-| Package | Source | How it publishes |-| ----------------------------- | ------------------ | --------------------------------------------------------------- |-| `@truefoundry/trueforge-core` | `packages/harness` | From package root (`dist/`) |-| `@truefoundry/trueforge` | `packages/server` | From package root (`dist/`, including `dist/_frontend/` for UI) |+| What | Trigger | Workflow |+| ------------------------- | --------------------------- | ------------------------------------------------------------------------------------------------ |+| Four public npm packages | Push to `main` (Changesets) | [`.github/workflows/release.yml`](.github/workflows/release.yml) |+| Server image + Helm chart | Manual `workflow_dispatch` | [`.github/workflows/release-image-and-chart.yml`](.github/workflows/release-image-and-chart.yml) |-The git tag `v*` must match **`packages/harness` (`@truefoundry/trueforge-core`) version**.-`@truefoundry/trueforge` may use an independent version — bump it in the same release PR-whenever the app/CLI changes. CI publishes **core first**, then `@truefoundry/trueforge` (so-`workspace:*` rewrites to the core version that just landed on npm).+They are independent. Publishing npm does not stamp or push the chart, and the chart workflow does not publish npm.-> **Currently only `@truefoundry/trueforge-core` publishes.** The `@truefoundry/trueforge`-> publish step in `release.yml` is deferred (`TODO`); CI still builds and tests it.+| Package | Source | Notes |+| ----------------------------- | --------------------------- | ---------------------------------------------- |+| `@truefoundry/trueforge-core` | `packages/harness` | Library. `files: ["dist"]`. |+| `@truefoundry/trueforge` | `packages/server` | App + CLI. Tarball includes `dist/_frontend/`. |+| `@truefoundry/trueforge-sdk` | `packages/sdk` | Fern-generated client. Do not hand-edit. |+| `@truefoundry/trueforge-ui` | `packages/trueforge-ui-sdk` | Embeddable chat UI. |++`frontend` is private and is not published; the server build copies its output into `dist/_frontend/`.++Internal deps use `workspace:*`. On publish, pnpm rewrites those to the exact version in the dependency's `package.json`. `changeset publish` publishes in dependency order (core before server, sdk before ui), so a published dependent never points at an unpublished dep from the same run.----# Releasing `@truefoundry/trueforge-core`+# Releasing npm packages-Interim setup for the fast development phase: the library in-`packages/harness` is published **publicly** to npm as `@truefoundry/trueforge-core`-so the gateway can consume it like any normal dependency. The real-open-source release happens later — every deferred item carries a-`TODO(oss):` comment in code so we can grep for them when that day comes.+## Per-release flow-> **Reality check we've accepted:** a public npm package is discoverable-> regardless of its name (npm's public change feed is scraped, and the-> package is listed on npmjs.com/org/truefoundry). Anything that must NOT be-> effectively public should not ship in the tarball. Note: sourcemaps are-> currently **enabled** (`sourcemap: true` in tsup, `declarationMap` in-> tsconfig.build.json), which embeds/references original TypeScript source in-> the published tarball — this is a deliberate, accepted trade-off for now.+There is no `v*` git-tag publish. One workflow both versions and publishes:++1. **Land a changeset on `main`.** In the same PR as the code change:++ ```bash+ pnpm changeset+ # or, non-interactive:+ pnpm change --bump patch --summary "…" @truefoundry/trueforge-core+ ```++ Name only the packages that should bump. A dep can ship without its dependent (the dependent's `workspace:*` stays untouched until that package is itself changeset + published). SDK regen on a PR already adds `@truefoundry/trueforge-sdk` via `pnpm changeset:sdk-regen`.++2. **Merge to `main`.** `.github/workflows/release.yml` runs. If `.changeset/*.md` files are pending, `changesets/action` opens (or updates) a **Version Packages** PR. That PR is `pnpm run version`: `changeset version`, then `pnpm sdk:generate` only if `@truefoundry/trueforge-sdk`'s version actually moved (Fern rebakes version literals). Review the version bumps and CHANGELOGs, then merge.++3. **Merging Version Packages publishes.** The same workflow sees no pending changesets and runs `pnpm release` (`pnpm build && changeset publish`). Auth is trusted publishing (OIDC — no `NPM_TOKEN`). pnpm 11 implements the OIDC token exchange natively. Watch the repo Actions tab.++ **Dist-tags:** while `.changeset/pre.json` exists (`pnpm changeset pre enter rc`), publishes use the `rc` dist-tag, not `latest`. After `pnpm changeset pre exit`, the next Version Packages merge publishes to `latest`. Install an RC with `npx @truefoundry/trueforge@rc` or `@0.1.0-rc.1`; bare `npx @truefoundry/trueforge` stays on `latest`.++4. **Bump the pinned version in downstream consumers** (e.g. the gateway). Pin exact versions (no `^`) during the fast 0.x churn:++ ```json+ "@truefoundry/trueforge-core": "0.x.y"+ ```++`workflow_dispatch` on **Release** re-runs the same job (useful after a bot-only commit that GitHub did not chain into this workflow).++A push to `main` with **no** pending changesets still runs `changeset publish`, which publishes any package whose current `package.json` version is not yet on npm and no-ops the rest. The first time this workflow lands on `main`, unpublished packages at `0.1.0-rc.1` will try to publish.++## Prerelease mode++Pre mode is repo-wide (`.changeset/pre.json`), not per-package. The repo is currently in `rc`.++| Goal | Command | Then |+| -------------------- | ----------------------------- | ------------------------------------------------------------------------- |+| Stay on RCs | (already in pre) | Normal PRs + Version Packages. Versions look like `0.1.0-rc.N`. |+| Ship stable `latest` | `pnpm changeset pre exit` | Commit the deleted `pre.json`, merge, then merge the Version Packages PR. |+| Start a new RC line | `pnpm changeset pre enter rc` | Commit `pre.json`, merge, continue as above. |++`pre enter` / `pre exit` do not bump versions or publish. The Version Packages PR is what versions; merging it is what publishes.++Do not mix “this package stable, that package RC” in one `changeset version` — exit pre only when the next publish should be GA.-## Publishing model+## Publishing model (`@truefoundry/trueforge-core`)-The package publishes from the package root (`packages/harness`), same as-every other package in this repo. The build compiles every `src/**/*.ts` to-its own `.js` (CJS) + `.mjs` (ESM) + `.d.ts` triple under `dist/`, and-`package.json`'s `exports` map points at `./dist/...` paths; `files: ["dist"]`-scopes the published tarball to just the compiled output. Consequences:+The package publishes from the package root (`packages/harness`), same as every other package in this repo. The build compiles every `src/**/*.ts` to its own `.js` (CJS) + `.mjs` (ESM) + `.d.ts` triple under `dist/`, and `package.json`'s `exports` map points at `./dist/...` paths; `files: ["dist"]` scopes the published tarball to just the compiled output. Consequences:- Deep imports keep the same specifier as before, e.g.`@truefoundry/trueforge-core/core/llm/LLMTypes` — the package's own `"./*"`@@ -65,60 +96,19 @@ scopes the published tarball to just the compiled output. Consequences:explicit `--conditions=trueforge-dev` opt-in, which no externalconsumer would ever set — so it ships as truly inert dead weight.-## Per-release flow--1. **Bump versions via PR** (direct pushes to `main` are blocked by org- ruleset):-- ```bash- git checkout -b release/v0.x.y- cd packages/harness- npm version 0.x.y --no-git-tag-version # or 0.x.y-rc.N for a prerelease- cd ../server- npm version 0.x.y --no-git-tag-version # bump when the app/CLI changes; may differ from core- cd ../..- git add packages/harness/package.json packages/server/package.json- git commit -m "chore: release v0.x.y"- git push -u origin release/v0.x.y- ```-- Open the PR, get 1 approval, squash-merge.--2. **Tag the merged commit** (tags trigger the publish):-- ```bash- git checkout main && git pull- git tag v0.x.y # must equal packages/harness version (e.g. v0.1.9-rc.1)- git push origin v0.x.y- ```--3. **CI publishes automatically.** `.github/workflows/release.yml` installs,- builds, tests, verifies the tag matches `packages/harness/package.json`, then- runs `pnpm publish` from `packages/harness`. (The `@truefoundry/trueforge`- publish is deferred — see the note above.)-- Auth is trusted publishing (OIDC — no `NPM_TOKEN`). pnpm 11 implements the- OIDC token exchange natively (no npm CLI involved). Watch the repo Actions tab.-- **Dist-tags:** CI passes an explicit `--tag` for prereleases, derived from the- semver prerelease id (`0.2.0-rc.1` → `--tag rc`). Stable releases publish to- `latest`. Install with `npx @truefoundry/trueforge@rc` or `@0.2.0-rc.1`; bare- `npx @truefoundry/trueforge` stays on `latest`.--4. **Bump the pinned version in the gateway.** Pin exact versions (no `^`)- during the fast 0.x churn:-- ```json- "@truefoundry/trueforge-core": "0.x.y"- ```+> **Reality check we've accepted:** a public npm package is discoverable+> regardless of its name (npm's public change feed is scraped, and the+> package is listed on npmjs.com/org/truefoundry). Anything that must NOT be+> effectively public should not ship in the tarball. Note: sourcemaps are+> currently **enabled** (`sourcemap: true` in tsup, `declarationMap` in+> tsconfig.build.json), which embeds/references original TypeScript source in+> the published tarball — this is a deliberate, accepted trade-off for now.+> Every deferred OSS item carries a `TODO(oss):` comment so we can grep for+> them when that day comes.-## Why core must publish before `@truefoundry/trueforge`+## Why dependents pin exact versions-`@truefoundry/trueforge` depends on `@truefoundry/trueforge-core: workspace:*`. On-publish, pnpm rewrites that to the **version in `packages/harness/package.json`**.-If that core version is missing from npm (or is an older build without exports-the server imports), `npx @truefoundry/trueforge` fails at runtime. Always ship-matching core and `@truefoundry/trueforge` together when the app uses new core APIs.+`@truefoundry/trueforge` depends on `@truefoundry/trueforge-core: workspace:*` (and `@truefoundry/trueforge-ui` on the sdk the same way). On publish, pnpm rewrites that to the **version in the dependency's `package.json`**. If that version is missing from npm, `npx @truefoundry/trueforge` fails at runtime. Changeset both packages in the same Version Packages PR when the dependent uses new APIs from the dep.## Local iteration without publishing@@ -134,23 +124,24 @@ cd packages/server && pnpm packPoint consumers at a tarball via a `file:` dependency (or use `yalc`).Publish a real version when CI or teammates need it.+## npm trusted publishing++Each of the four packages must list this repo + workflow as a trusted publisher on npmjs.com:++- Repository: `truefoundry/trueforge`+- Workflow filename: `release.yml` (must match exactly; renaming the file breaks publish)+- No environment name (the job does not use a GitHub Environment)++Packages that have never been published need that trusted-publisher row **before** the first `changeset publish` (npm allows creating a package via OIDC when the org is configured for it). `@truefoundry/trueforge-core` already publishes this way; sdk / ui / server need the same config before they can land.+## Troubleshooting-- **Publish fails requiring a tag**: prerelease versions need `--tag`.- CI handles this; for local publishes use e.g. `pnpm publish --tag rc`.-- **Publish fails with 403/E403**: version already published (npm versions- are immutable — bump and re-tag), or the trusted publisher config doesn't- match the workflow filename/repo exactly.-- **Tag/version mismatch failure**: the guard step caught a tag that doesn't- match `packages/harness/package.json`. Delete the tag- (`git push origin :refs/tags/vX.Y.Z`), fix the version via PR, re-tag.-- **Missing `dist/_frontend/index.html`**: root `pnpm build` must build- `frontend` before `@truefoundry/trueforge`; the release job fails closed if the- copy is absent.-- **OIDC/auth error in the publish step**: trusted publishing requires- pnpm >= 11.0.7 (native OIDC token exchange; `pnpm/action-setup@v4` reads the- pinned version from root `packageManager`) and the npmjs.com trusted- publisher config (repo + workflow filename + ref) matching exactly.+- **Version Packages PR never appears**: no `.changeset/*.md` on `main` (only `config.json` / `README.md` / `pre.json` stay). Add a changeset in a PR and merge, or run **Release** via `workflow_dispatch`.+- **Publish fails requiring a tag**: prerelease versions need the `rc` dist-tag. `changeset publish` sets that while pre mode is on; for a local publish use `pnpm publish --tag rc`.+- **Publish fails with 403/E403**: version already published (npm versions are immutable — add a changeset and merge Version Packages again), or the trusted publisher config doesn't match the workflow filename/repo exactly.+- **OIDC/auth error in the publish step**: trusted publishing requires pnpm >= 11.0.7 (native OIDC; `pnpm/action-setup@v4` reads the pinned version from root `packageManager`) and the npmjs.com trusted publisher config matching exactly. Do not set `NPM_TOKEN` — a registry `_authToken` disables the OIDC exchange.+- **Missing `dist/_frontend/index.html`**: root `pnpm build` must build `frontend` before `@truefoundry/trueforge`; the release job fails closed if the copy is absent.+- **Version PR did not regenerate the SDK**: `scripts/version.mjs` only runs `pnpm sdk:generate` when `@truefoundry/trueforge-sdk`'s version changed. That step needs Docker on the runner (already true on `ubuntu-latest`).## Deferred to the real OSS release — grep for `TODO(oss)`@@ -160,7 +151,6 @@ CODE_OF_CONDUCT, issue/PR templates.| Item | Where || ---------------------------------------------------------------------------------- | ------------------------------------------------------- || Ship README (currently no `README.md` in `packages/harness`, npm page stays blank) | packages/harness |-| Add repository/homepage/bugs/keywords metadata | packages/harness/package.json || Add `--provenance` to publish | .github/workflows/release.yml || Private-repo links in shipped sandbox scripts | packages/harness/src/core/sandbox/scripts/mcp_client.py || Sourcemaps/declarationMap decision | packages/harness/tsup.config.ts, tsconfig.build.json |@@ -172,7 +162,7 @@ CODE_OF_CONDUCT, issue/PR templates.# Releasing the server image + Helm chartA separate pipeline ships the deployable artifacts: the server container image-(API + UI, built from the root `Dockerfile`) and the `charts/truefoundry-utils` Helm+(API + UI, built from the root `Dockerfile`) and the `charts/trueforge` Helmchart. It is driven by `.github/workflows/release-image-and-chart.yml` and runsonly on manual **`workflow_dispatch`** (Actions → "Release image and Helm chart"→ Run workflow).@@ -189,7 +179,7 @@ The dispatch commit SHA is the image tag. The workflow:`version` to `0.0.0-<sha>` (Helm SemVer-compatible prerelease), and`appVersion` / `image.tag` to the raw SHA. It does **not** commit thosestamps back to `main`.-3. **Publishes the chart** — packages `charts/truefoundry-utils` and pushes it to+3. **Publishes the chart** — packages `charts/trueforge` and pushes it tothe JFrog public OCI Helm repo. It does not attach artifacts to a GitHubRelease.@@ -200,9 +190,8 @@ The dispatch commit SHA is the image tag. The workflow:2. Watch the run. The image and chart land in JFrog; the job summary prints theimage URI.-> Publishing `@truefoundry/trueforge-core` (via `pnpm publish`) is a separate pipeline-> (`release.yml`) triggered by a `vX.Y.Z` GitHub Release tag that must match-> `packages/harness/package.json`. It is independent of this image/chart+> Publishing the npm packages is a separate pipeline (`release.yml`) triggered+> by pushes to `main` via Changesets. It is independent of this image/chart> workflow.## Required repository configuration@@ -217,7 +206,7 @@ Org/repo **secrets**: `TRUEFOUNDRY_ARTIFACTORY_PUBLIC_USERNAME`,## Bundled dependenciesThe chart bundles Postgres and Redis as optional Bitnami subcharts, declared in-`charts/truefoundry-utils/Chart.yaml` against the public Bitnami OCI archive+`charts/trueforge/Chart.yaml` against the public Bitnami OCI archive(`oci://registry-1.docker.io/bitnamicharts`) and pinned by the committed`Chart.lock`. The workflow fetches them with `helm dependency build` beforepackaging (the archive is public, no auth). Disable them with@@ -225,7 +214,7 @@ packaging (the archive is public, no auth). Disable them with**Images vs charts.** Bitnami left the charts public but relocated theircontainer images to `docker.io/bitnamilegacy` (frozen, no security updates). So-`charts/truefoundry-utils/values.yaml` overrides the subchart images to pinned legacy+`charts/trueforge/values.yaml` overrides the subchart images to pinned legacytags mirrored to the TrueFoundry JFrog registry, and sets`global.security.allowInsecureImages: true` (required once the registry differsfrom Bitnami's default). Mirror the images once per pinned tag:@@ -251,7 +240,7 @@ Fetch the subchart deps first (public archive, no auth), then lint/template:```bashpnpm chart:deps # helm dependency build (writes charts/, uses Chart.lock)-pnpm chart:lint # helm lint with charts/truefoundry-utils/ci/lint-values.yaml+pnpm chart:lint # helm lint with charts/trueforge/ci/lint-values.yamlpnpm chart:template # render the manifestspnpm chart:package # package to dist/ (gitignored)```diff --git a/charts/truefoundry-utils/.helmignore b/charts/trueforge/.helmignoresimilarity index 100%rename from charts/truefoundry-utils/.helmignorerename to charts/trueforge/.helmignorediff --git a/charts/truefoundry-utils/Chart.lock b/charts/trueforge/Chart.locksimilarity index 100%rename from charts/truefoundry-utils/Chart.lockrename to charts/trueforge/Chart.lockdiff --git a/charts/truefoundry-utils/Chart.yaml b/charts/trueforge/Chart.yamlsimilarity index 89%rename from charts/truefoundry-utils/Chart.yamlrename to charts/trueforge/Chart.yamlindex b64df3d1a..4fc8273d0 100644--- a/charts/truefoundry-utils/Chart.yaml+++ b/charts/trueforge/Chart.yaml@@ -1,6 +1,6 @@apiVersion: v2-name: truefoundry-utils-description: TrueFoundry Utils server (API + UI) served from a single container image.+name: trueforge+description: TrueForge server (API + UI) served from a single container image.type: application# version (chart) and appVersion are stamped at publish time by# .github/workflows/release-image-and-chart.yml (workflow_dispatch, commit SHA);@@ -12,7 +12,7 @@ home: https://truefoundry.comsources:- https://truefoundry.commaintainers:- - name: TrueFoundry+ - name: TrueForgeurl: https://truefoundry.com# Postgres and Redis ship as optional bundled dependencies, pulled from the# public Bitnami OCI chart archive at build time (`helm dependency build`, pinneddiff --git a/charts/truefoundry-utils/README.md b/charts/trueforge/README.mdsimilarity index 90%rename from charts/truefoundry-utils/README.mdrename to charts/trueforge/README.mdindex 179985dd8..4966783bc 100644--- a/charts/truefoundry-utils/README.md+++ b/charts/trueforge/README.md@@ -1,6 +1,6 @@-# truefoundry-utils Helm chart+# trueforge Helm chart-Deploys the TrueFoundry Utils server, a single container image that serves both the API+Deploys the TrueForge server, a single container image that serves both the APIand the UI (built from the repository-root `Dockerfile`).The chart always runs the server in **distributed** mode (`STANDALONE=false`) against@@ -31,7 +31,7 @@ Disable either dependency to point at an external service instead (see below).## Install```bash-helm install truefoundry-utils oci://<jfrog-public-helm-repo>/truefoundry-utils \+helm install trueforge oci://<jfrog-public-helm-repo>/trueforge \--version <x.y.z>```@@ -39,9 +39,9 @@ Optional: set the public origin once you expose the service (needed for MCP OAutand OIDC callbacks):```bash-helm upgrade --install truefoundry-utils oci://<jfrog-public-helm-repo>/truefoundry-utils \+helm upgrade --install trueforge oci://<jfrog-public-helm-repo>/trueforge \--version <x.y.z> \- --set server.publicBaseUrl=https://truefoundry-utils.example.com+ --set server.publicBaseUrl=https://trueforge.example.com```## Postgres@@ -100,16 +100,16 @@ Also set `server.publicBaseUrl` to the public origin and register```yamlserver:- publicBaseUrl: https://truefoundry-utils.example.com+ publicBaseUrl: https://trueforge.example.comconfigs:oidc:enabled: trueissuerUrl: https://idp.example.com/oauth2/default- clientId: truefoundry-utils+ clientId: trueforgeclientSecret:valueFrom:secretKeyRef:- name: truefoundry-utils-oidc+ name: trueforge-oidckey: client-secret# optional claim overrides (defaults shown):# userReferenceClaim: sub@@ -150,16 +150,16 @@ extraObjects:- apiVersion: networking.istio.io/v1kind: VirtualServicemetadata:- name: '{{ include "truefoundry-utils.fullname" . }}'+ name: '{{ include "trueforge.fullname" . }}'spec:hosts:- - truefoundry-utils.example.com+ - trueforge.example.comgateways:- istio-system/public-gatewayhttp:- route:- destination:- host: '{{ include "truefoundry-utils.fullname" . }}'+ host: '{{ include "trueforge.fullname" . }}'port:number: '{{ .Values.service.port }}'```@@ -169,7 +169,7 @@ extraObjects:| Value | Default | Description || --------------------- | ----------------------------------- | ------------------------------------- || `replicaCount` | `1` | Number of server replicas. |-| `image.repository` | `tfy.jfrog.io/tfy-images/truefoundry-utils` | Image repository. |+| `image.repository` | `tfy.jfrog.io/tfy-images/trueforge` | Image repository. || `image.tag` | chart `appVersion` | Image tag; stamped on release. || `server.publicBaseUrl`| `""` | Public origin for OAuth/OIDC callbacks (required for MCP OAuth / OIDC). || `configs.oidc.enabled`| `false` | Inject `OIDC_*` env for IdP login. |diff --git a/charts/truefoundry-utils/ci/lint-values.yaml b/charts/trueforge/ci/lint-values.yamlsimilarity index 100%rename from charts/truefoundry-utils/ci/lint-values.yamlrename to charts/trueforge/ci/lint-values.yamldiff --git a/charts/truefoundry-utils/templates/NOTES.txt b/charts/trueforge/templates/NOTES.txtsimilarity index 70%rename from charts/truefoundry-utils/templates/NOTES.txtrename to charts/trueforge/templates/NOTES.txtindex dfb8b87f7..c6bab284a 100644--- a/charts/truefoundry-utils/templates/NOTES.txt+++ b/charts/trueforge/templates/NOTES.txt@@ -1,16 +1,16 @@-TrueFoundry Utils {{ .Chart.AppVersion }} has been deployed as release {{ .Release.Name }}.+TrueForge {{ .Chart.AppVersion }} has been deployed as release {{ .Release.Name }}.-Image: {{ include "truefoundry-utils.image" . }}+Image: {{ include "trueforge.image" . }}Reach the server (API + UI) inside the cluster at:- http://{{ include "truefoundry-utils.fullname" . }}.{{ .Release.Namespace }}.svc:{{ .Values.service.port }}+ http://{{ include "trueforge.fullname" . }}.{{ .Release.Namespace }}.svc:{{ .Values.service.port }}Port-forward it locally with:- kubectl --namespace {{ .Release.Namespace }} port-forward svc/{{ include "truefoundry-utils.fullname" . }} 8790:{{ .Values.service.port }}+ kubectl --namespace {{ .Release.Namespace }} port-forward svc/{{ include "trueforge.fullname" . }} 8790:{{ .Values.service.port }}Then open http://localhost:8790 and check http://localhost:8790/healthz.-Postgres: {{ if .Values.postgresql.enabled }}bundled ({{ include "truefoundry-utils.postgres.host" . }}){{ else }}external ({{ include "truefoundry-utils.postgres.host" . }}){{ end }}+Postgres: {{ if .Values.postgresql.enabled }}bundled ({{ include "trueforge.postgres.host" . }}){{ else }}external ({{ include "trueforge.postgres.host" . }}){{ end }}Redis: {{ if .Values.redis.enabled }}bundled{{- else }}external (literal or valueFrom){{- end }}OIDC: {{ if .Values.configs.oidc.enabled }}enabled{{- else }}disabled (local admin identity){{- end }}@@ -21,7 +21,7 @@ OIDC callbacks require PUBLIC_BASE_URL. Registerhttps://<your-public-origin>/api/v1/auth/callback at your IdP.{{- else if not .Values.server.publicBaseUrl }}-WARNING: server.publicBaseUrl is empty. MCP OAuth and OIDC callbacks will fail until you set it to the public origin (e.g. https://truefoundry-utils.example.com).+WARNING: server.publicBaseUrl is empty. MCP OAuth and OIDC callbacks will fail until you set it to the public origin (e.g. https://trueforge.example.com).{{- end }}{{- if and (not .Values.postgresql.enabled) (not .Values.externalPostgres.host) }}diff --git a/charts/truefoundry-utils/templates/_helpers.tpl b/charts/trueforge/templates/_helpers.tplsimilarity index 73%rename from charts/truefoundry-utils/templates/_helpers.tplrename to charts/trueforge/templates/_helpers.tplindex eb28f529b..c1f85800f 100644--- a/charts/truefoundry-utils/templates/_helpers.tpl+++ b/charts/trueforge/templates/_helpers.tpl@@ -1,14 +1,14 @@{{/*Expand the name of the chart.*/}}-{{- define "truefoundry-utils.name" -}}+{{- define "trueforge.name" -}}{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" }}{{- end }}{{/*Create a default fully qualified app name.*/}}-{{- define "truefoundry-utils.fullname" -}}+{{- define "trueforge.fullname" -}}{{- if .Values.fullnameOverride }}{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" }}{{- else }}@@ -24,16 +24,16 @@ Create a default fully qualified app name.{{/*Chart name and version as used by the chart label.*/}}-{{- define "truefoundry-utils.chart" -}}+{{- define "trueforge.chart" -}}{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }}{{- end }}{{/*Common labels.*/}}-{{- define "truefoundry-utils.labels" -}}-helm.sh/chart: {{ include "truefoundry-utils.chart" . }}-{{ include "truefoundry-utils.selectorLabels" . }}+{{- define "trueforge.labels" -}}+helm.sh/chart: {{ include "trueforge.chart" . }}+{{ include "trueforge.selectorLabels" . }}{{- if .Chart.AppVersion }}app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}{{- end }}@@ -43,17 +43,17 @@ app.kubernetes.io/managed-by: {{ .Release.Service }}{{/*Selector labels.*/}}-{{- define "truefoundry-utils.selectorLabels" -}}-app.kubernetes.io/name: {{ include "truefoundry-utils.name" . }}+{{- define "trueforge.selectorLabels" -}}+app.kubernetes.io/name: {{ include "trueforge.name" . }}app.kubernetes.io/instance: {{ .Release.Name }}{{- end }}{{/*Service account name.*/}}-{{- define "truefoundry-utils.serviceAccountName" -}}+{{- define "trueforge.serviceAccountName" -}}{{- if .Values.serviceAccount.create }}-{{- default (include "truefoundry-utils.fullname" .) .Values.serviceAccount.name }}+{{- default (include "trueforge.fullname" .) .Values.serviceAccount.name }}{{- else }}{{- default "default" .Values.serviceAccount.name }}{{- end }}@@ -62,7 +62,7 @@ Service account name.{{/*Container image reference; tag falls back to the chart appVersion.*/}}-{{- define "truefoundry-utils.image" -}}+{{- define "trueforge.image" -}}{{- printf "%s:%s" .Values.image.repository (.Values.image.tag | default .Chart.AppVersion) }}{{- end }}@@ -70,7 +70,7 @@ Container image reference; tag falls back to the chart appVersion.True when .value is a non-empty string (vs a valueFrom map).Expects dict with key "value".*/}}-{{- define "truefoundry-utils.isLiteralString" -}}+{{- define "trueforge.isLiteralString" -}}{{- $v := index . "value" -}}{{- if and (kindIs "string" $v) (ne $v "") -}}true{{- end -}}{{- end }}@@ -79,7 +79,7 @@ Expects dict with key "value".Fail unless .value is a non-empty string or a map with valueFrom.Expects dict with keys "name" and "value".*/}}-{{- define "truefoundry-utils.requireStringOrValueFrom" -}}+{{- define "trueforge.requireStringOrValueFrom" -}}{{- $v := index . "value" -}}{{- $name := index . "name" -}}{{- if kindIs "string" $v -}}@@ -95,7 +95,7 @@ Expects dict with keys "name" and "value".Postgres connection. Sourced from the bundled Bitnami postgresql subchart whenpostgresql.enabled, otherwise from externalPostgres.*/}}-{{- define "truefoundry-utils.postgres.host" -}}+{{- define "trueforge.postgres.host" -}}{{- if .Values.postgresql.enabled -}}{{- printf "%s-postgresql" .Release.Name -}}{{- else -}}@@ -103,15 +103,15 @@ postgresql.enabled, otherwise from externalPostgres.{{- end -}}{{- end }}-{{- define "truefoundry-utils.postgres.port" -}}+{{- define "trueforge.postgres.port" -}}{{- if .Values.postgresql.enabled -}}5432{{- else -}}{{ .Values.externalPostgres.port }}{{- end -}}{{- end }}-{{- define "truefoundry-utils.postgres.user" -}}+{{- define "trueforge.postgres.user" -}}{{- if .Values.postgresql.enabled -}}{{ .Values.postgresql.auth.username }}{{- else -}}{{ .Values.externalPostgres.user }}{{- end -}}{{- end }}-{{- define "truefoundry-utils.postgres.database" -}}+{{- define "trueforge.postgres.database" -}}{{- if .Values.postgresql.enabled -}}{{ .Values.postgresql.auth.database }}{{- else -}}{{ .Values.externalPostgres.database }}{{- end -}}{{- end }}@@ -119,11 +119,11 @@ postgresql.enabled, otherwise from externalPostgres.Name of the Secret holding the Postgres password when using the bundledpostgresql subchart (existingSecret override or <release>-postgresql).*/}}-{{- define "truefoundry-utils.postgres.secretName" -}}+{{- define "trueforge.postgres.secretName" -}}{{- default (printf "%s-postgresql" .Release.Name) .Values.postgresql.auth.existingSecret -}}{{- end }}-{{- define "truefoundry-utils.redis.bundledUrl" -}}+{{- define "trueforge.redis.bundledUrl" -}}{{- printf "redis://%s-redis-master:6379" .Release.Name -}}{{- end }}@@ -133,12 +133,12 @@ Expects: name (env var), field (values path for errors), value.Literals become env value; valueFrom maps are passed through. The chart doesnot create Secrets — callers who need secretKeyRef must supply valueFrom.*/}}-{{- define "truefoundry-utils.env.fromStringOrValueFrom" -}}+{{- define "trueforge.env.fromStringOrValueFrom" -}}{{- $name := index . "name" -}}{{- $field := index . "field" -}}{{- $value := index . "value" -}}-{{- include "truefoundry-utils.requireStringOrValueFrom" (dict "name" $field "value" $value) -}}-{{- if eq (include "truefoundry-utils.isLiteralString" (dict "value" $value)) "true" -}}+{{- include "trueforge.requireStringOrValueFrom" (dict "name" $field "value" $value) -}}+{{- if eq (include "trueforge.isLiteralString" (dict "value" $value)) "true" -}}{{- dict "name" $name "value" $value | toJson -}}{{- else -}}{{- dict "name" $name "valueFrom" $value.valueFrom | toJson -}}@@ -149,7 +149,7 @@ not create Secrets — callers who need secretKeyRef must supply valueFrom.Full server container env list (YAML). Validates required string|valueFromfields, wires bundled Postgres/Redis, optional OIDC, then server.extraEnv.*/}}-{{- define "truefoundry-utils.server.env" -}}+{{- define "trueforge.server.env" -}}{{- $env := list -}}{{- $env = append $env (dict "name" "NODE_ENV" "value" "production") -}}{{- $env = append $env (dict "name" "PORT" "value" (.Values.server.port | toString)) -}}@@ -158,19 +158,19 @@ fields, wires bundled Postgres/Redis, optional OIDC, then server.extraEnv.{{- $env = append $env (dict "name" "GRACEFUL_TIMEOUT_SECONDS" "value" (.Values.server.gracefulTimeoutSeconds | toString)) -}}{{- if .Values.redis.enabled -}}-{{- $env = append $env (dict "name" "REDIS_URL" "value" (include "truefoundry-utils.redis.bundledUrl" .)) -}}+{{- $env = append $env (dict "name" "REDIS_URL" "value" (include "trueforge.redis.bundledUrl" .)) -}}{{- else -}}-{{- $env = append $env (include "truefoundry-utils.env.fromStringOrValueFrom" (dict "name" "REDIS_URL" "field" "externalRedis.url" "value" .Values.externalRedis.url) | fromJson) -}}+{{- $env = append $env (include "trueforge.env.fromStringOrValueFrom" (dict "name" "REDIS_URL" "field" "externalRedis.url" "value" .Values.externalRedis.url) | fromJson) -}}{{- end -}}-{{- $env = append $env (dict "name" "POSTGRES_HOST" "value" (include "truefoundry-utils.postgres.host" .)) -}}-{{- $env = append $env (dict "name" "POSTGRES_PORT" "value" (include "truefoundry-utils.postgres.port" . | toString)) -}}-{{- $env = append $env (dict "name" "POSTGRES_DB" "value" (include "truefoundry-utils.postgres.database" .)) -}}-{{- $env = append $env (dict "name" "POSTGRES_USER" "value" (include "truefoundry-utils.postgres.user" .)) -}}+{{- $env = append $env (dict "name" "POSTGRES_HOST" "value" (include "trueforge.postgres.host" .)) -}}+{{- $env = append $env (dict "name" "POSTGRES_PORT" "value" (include "trueforge.postgres.port" . | toString)) -}}+{{- $env = append $env (dict "name" "POSTGRES_DB" "value" (include "trueforge.postgres.database" .)) -}}+{{- $env = append $env (dict "name" "POSTGRES_USER" "value" (include "trueforge.postgres.user" .)) -}}{{- if .Values.postgresql.enabled -}}-{{- $env = append $env (dict "name" "POSTGRES_PASSWORD" "valueFrom" (dict "secretKeyRef" (dict "name" (include "truefoundry-utils.postgres.secretName" .) "key" "password"))) -}}+{{- $env = append $env (dict "name" "POSTGRES_PASSWORD" "valueFrom" (dict "secretKeyRef" (dict "name" (include "trueforge.postgres.secretName" .) "key" "password"))) -}}{{- else -}}-{{- $env = append $env (include "truefoundry-utils.env.fromStringOrValueFrom" (dict "name" "POSTGRES_PASSWORD" "field" "externalPostgres.password" "value" .Values.externalPostgres.password) | fromJson) -}}+{{- $env = append $env (include "trueforge.env.fromStringOrValueFrom" (dict "name" "POSTGRES_PASSWORD" "field" "externalPostgres.password" "value" .Values.externalPostgres.password) | fromJson) -}}{{- end -}}{{- if .Values.configs.oidc.enabled -}}@@ -178,7 +178,7 @@ fields, wires bundled Postgres/Redis, optional OIDC, then server.extraEnv.{{- $_ := required "configs.oidc.clientId is required when configs.oidc.enabled is true" .Values.configs.oidc.clientId -}}{{- $env = append $env (dict "name" "OIDC_ISSUER_URL" "value" .Values.configs.oidc.issuerUrl) -}}{{- $env = append $env (dict "name" "OIDC_CLIENT_ID" "value" .Values.configs.oidc.clientId) -}}-{{- $env = append $env (include "truefoundry-utils.env.fromStringOrValueFrom" (dict "name" "OIDC_CLIENT_SECRET" "field" "configs.oidc.clientSecret" "value" .Values.configs.oidc.clientSecret) | fromJson) -}}+{{- $env = append $env (include "trueforge.env.fromStringOrValueFrom" (dict "name" "OIDC_CLIENT_SECRET" "field" "configs.oidc.clientSecret" "value" .Values.configs.oidc.clientSecret) | fromJson) -}}{{- $env = append $env (dict "name" "OIDC_USER_REFERENCE_CLAIM" "value" .Values.configs.oidc.userReferenceClaim) -}}{{- $env = append $env (dict "name" "OIDC_USER_ROLE_CLAIM" "value" .Values.configs.oidc.userRoleClaim) -}}{{- $env = append $env (dict "name" "OIDC_ADMIN_ROLE_VALUE" "value" .Values.configs.oidc.adminRoleValue) -}}diff --git a/charts/truefoundry-utils/templates/deployment.yaml b/charts/trueforge/templates/deployment.yamlsimilarity index 85%rename from charts/truefoundry-utils/templates/deployment.yamlrename to charts/trueforge/templates/deployment.yamlindex 63339adfe..5d22cb753 100644--- a/charts/truefoundry-utils/templates/deployment.yaml+++ b/charts/trueforge/templates/deployment.yaml@@ -1,9 +1,9 @@apiVersion: apps/v1kind: Deploymentmetadata:- name: {{ include "truefoundry-utils.fullname" . }}+ name: {{ include "trueforge.fullname" . }}labels:- {{- include "truefoundry-utils.labels" . | nindent 4 }}+ {{- include "trueforge.labels" . | nindent 4 }}spec:{{- if not .Values.autoscaling.enabled }}replicas: {{ .Values.replicaCount }}@@ -14,11 +14,11 @@ spec:{{- end }}selector:matchLabels:- {{- include "truefoundry-utils.selectorLabels" . | nindent 6 }}+ {{- include "trueforge.selectorLabels" . | nindent 6 }}template:metadata:labels:- {{- include "truefoundry-utils.selectorLabels" . | nindent 8 }}+ {{- include "trueforge.selectorLabels" . | nindent 8 }}{{- with .Values.podLabels }}{{- toYaml . | nindent 8 }}{{- end }}@@ -31,7 +31,7 @@ spec:imagePullSecrets:{{- toYaml . | nindent 8 }}{{- end }}- serviceAccountName: {{ include "truefoundry-utils.serviceAccountName" . }}+ serviceAccountName: {{ include "trueforge.serviceAccountName" . }}{{- with .Values.podSecurityContext }}securityContext:{{- toYaml . | nindent 8 }}@@ -47,7 +47,7 @@ spec:{{- end }}containers:- name: server- image: {{ include "truefoundry-utils.image" . | quote }}+ image: {{ include "trueforge.image" . | quote }}imagePullPolicy: {{ .Values.image.pullPolicy }}{{- with .Values.securityContext }}securityContext:@@ -58,7 +58,7 @@ spec:containerPort: {{ .Values.server.port }}protocol: TCPenv:- {{- include "truefoundry-utils.server.env" . | nindent 12 }}+ {{- include "trueforge.server.env" . | nindent 12 }}{{- with .Values.startupProbe }}startupProbe:{{- toYaml . | nindent 12 }}diff --git a/charts/truefoundry-utils/templates/extra-objects.yaml b/charts/trueforge/templates/extra-objects.yamlsimilarity index 100%rename from charts/truefoundry-utils/templates/extra-objects.yamlrename to charts/trueforge/templates/extra-objects.yamldiff --git a/charts/truefoundry-utils/templates/hpa.yaml b/charts/trueforge/templates/hpa.yamlsimilarity index 74%rename from charts/truefoundry-utils/templates/hpa.yamlrename to charts/trueforge/templates/hpa.yamlindex c4a1e6d09..cf6061f36 100644--- a/charts/truefoundry-utils/templates/hpa.yaml+++ b/charts/trueforge/templates/hpa.yaml@@ -2,14 +2,14 @@apiVersion: autoscaling/v2kind: HorizontalPodAutoscalermetadata:- name: {{ include "truefoundry-utils.fullname" . }}+ name: {{ include "trueforge.fullname" . }}labels:- {{- include "truefoundry-utils.labels" . | nindent 4 }}+ {{- include "trueforge.labels" . | nindent 4 }}spec:scaleTargetRef:apiVersion: apps/v1kind: Deployment- name: {{ include "truefoundry-utils.fullname" . }}+ name: {{ include "trueforge.fullname" . }}minReplicas: {{ .Values.autoscaling.minReplicas }}maxReplicas: {{ .Values.autoscaling.maxReplicas }}metrics:diff --git a/charts/truefoundry-utils/templates/pdb.yaml b/charts/trueforge/templates/pdb.yamlsimilarity index 82%rename from charts/truefoundry-utils/templates/pdb.yamlrename to charts/trueforge/templates/pdb.yamlindex 9369f0d0d..41c1b92a0 100644--- a/charts/truefoundry-utils/templates/pdb.yaml+++ b/charts/trueforge/templates/pdb.yaml@@ -11,9 +11,9 @@apiVersion: policy/v1kind: PodDisruptionBudgetmetadata:- name: {{ include "truefoundry-utils.fullname" . }}+ name: {{ include "trueforge.fullname" . }}labels:- {{- include "truefoundry-utils.labels" . | nindent 4 }}+ {{- include "trueforge.labels" . | nindent 4 }}spec:{{- if ne $min "" }}minAvailable: {{ .Values.podDisruptionBudget.minAvailable }}@@ -23,5 +23,5 @@ spec:{{- end }}selector:matchLabels:- {{- include "truefoundry-utils.selectorLabels" . | nindent 6 }}+ {{- include "trueforge.selectorLabels" . | nindent 6 }}{{- end }}diff --git a/charts/truefoundry-utils/templates/service.yaml b/charts/trueforge/templates/service.yamlsimilarity index 68%rename from charts/truefoundry-utils/templates/service.yamlrename to charts/trueforge/templates/service.yamlindex 12a2fb776..a386745a8 100644--- a/charts/truefoundry-utils/templates/service.yaml+++ b/charts/trueforge/templates/service.yaml@@ -1,9 +1,9 @@apiVersion: v1kind: Servicemetadata:- name: {{ include "truefoundry-utils.fullname" . }}+ name: {{ include "trueforge.fullname" . }}labels:- {{- include "truefoundry-utils.labels" . | nindent 4 }}+ {{- include "trueforge.labels" . | nindent 4 }}{{- with .Values.service.labels }}{{- toYaml . | nindent 4 }}{{- end }}@@ -19,4 +19,4 @@ spec:protocol: TCPname: httpselector:- {{- include "truefoundry-utils.selectorLabels" . | nindent 4 }}+ {{- include "trueforge.selectorLabels" . | nindent 4 }}diff --git a/charts/truefoundry-utils/templates/serviceaccount.yaml b/charts/trueforge/templates/serviceaccount.yamlsimilarity index 63%rename from charts/truefoundry-utils/templates/serviceaccount.yamlrename to charts/trueforge/templates/serviceaccount.yamlindex 6fd29c4b3..9b80fd1bc 100644--- a/charts/truefoundry-utils/templates/serviceaccount.yaml+++ b/charts/trueforge/templates/serviceaccount.yaml@@ -2,9 +2,9 @@apiVersion: v1kind: ServiceAccountmetadata:- name: {{ include "truefoundry-utils.serviceAccountName" . }}+ name: {{ include "trueforge.serviceAccountName" . }}labels:- {{- include "truefoundry-utils.labels" . | nindent 4 }}+ {{- include "trueforge.labels" . | nindent 4 }}{{- with .Values.serviceAccount.annotations }}annotations:{{- toYaml . | nindent 4 }}diff --git a/charts/truefoundry-utils/values.yaml b/charts/trueforge/values.yamlsimilarity index 94%rename from charts/truefoundry-utils/values.yamlrename to charts/trueforge/values.yamlindex 4caaaa796..3758d3068 100644--- a/charts/truefoundry-utils/values.yaml+++ b/charts/trueforge/values.yaml@@ -1,9 +1,9 @@-# Default values for the truefoundry-utils chart.+# Default values for the trueforge chart.replicaCount: 1image:- repository: tfy.jfrog.io/tfy-images/truefoundry-utils+ repository: tfy.jfrog.io/tfy-images/trueforge# Tag defaults to the chart appVersion when empty; the release workflow stamps# the released version here.tag: ""@@ -70,7 +70,7 @@ configs:# clientSecret:# valueFrom:# secretKeyRef:- # name: truefoundry-utils-oidc+ # name: trueforge-oidc# key: client-secretuserReferenceClaim: subuserRoleClaim: groups@@ -157,22 +157,22 @@ externalRedis:# Extra raw manifests deployed alongside the server, e.g. an Istio# VirtualService, a Gateway, an Ingress, or a NetworkPolicy. Each entry is a# full Kubernetes object rendered through `tpl`, so Helm templating works and-# helpers like `{{ include "truefoundry-utils.fullname" . }}` resolve. Example:+# helpers like `{{ include "trueforge.fullname" . }}` resolve. Example:## extraObjects:# - apiVersion: networking.istio.io/v1# kind: VirtualService# metadata:-# name: '{{ include "truefoundry-utils.fullname" . }}'+# name: '{{ include "trueforge.fullname" . }}'# spec:# hosts:-# - truefoundry-utils.example.com+# - trueforge.example.com# gateways:# - istio-system/public-gateway# http:# - route:# - destination:-# host: '{{ include "truefoundry-utils.fullname" . }}'+# host: '{{ include "trueforge.fullname" . }}'# port:# number: '{{ .Values.service.port }}'extraObjects: []diff --git a/docs/authentication/overview.mdx b/docs/authentication/overview.mdxindex 189ebe87e..3fe7dae14 100644--- a/docs/authentication/overview.mdx+++ b/docs/authentication/overview.mdx@@ -157,7 +157,7 @@ The default. Do **not** set any `OIDC_*` variables, run TrueForge as usual ([QuiclientSecret:valueFrom:secretKeyRef:- name: truefoundry-utils-oidc+ name: trueforge-oidckey: client-secretuserReferenceClaim: emailuserRoleClaim: groups@@ -167,13 +167,13 @@ The default. Do **not** set any `OIDC_*` variables, run TrueForge as usual ([Qui- apiVersion: v1kind: Secretmetadata:- name: truefoundry-utils-oidc+ name: trueforge-oidctype: OpaquestringData:client-secret: "..."```- See the [chart README](https://github.com/truefoundry/trueforge/blob/main/charts/truefoundry-utils/README.md#oidc) for the full values shape.+ See the [chart README](https://github.com/truefoundry/trueforge/blob/main/charts/trueforge/README.md#oidc) for the full values shape.</Tab></Tabs>diff --git a/docs/openapi.json b/docs/openapi.jsonindex e2d15f814..8cc7779e5 100644--- a/docs/openapi.json+++ b/docs/openapi.json@@ -819,6 +819,45 @@],"type": "object"},+ "CreateMcpServerRequest": {+ "additionalProperties": false,+ "properties": {+ "auth": {+ "allOf": [+ {+ "$ref": "#/components/schemas/ConfiguredMcpServerAuth"+ },+ {+ "description": "Optional auth settings. Omit when the server needs no credentials."+ }+ ]+ },+ "name": {+ "allOf": [+ {+ "$ref": "#/components/schemas/ResourceName"+ },+ {+ "description": "Fully qualified name. Unique within a tenant."+ }+ ]+ },+ "type": {+ "$ref": "#/components/schemas/McpServerType"+ },+ "url": {+ "description": "URL of the remote MCP server.",+ "format": "uri",+ "type": "string"+ }+ },+ "required": [+ "type",+ "name",+ "url"+ ],+ "type": "object"+ },"CreateSessionAgent": {"anyOf": [{@@ -6348,6 +6387,70 @@],"x-fern-sdk-method-name": "list"},+ "post": {+ "description": "Creates an MCP server by `name`. Fails if `name` is already taken. Runs DCR registration when `auth.type` is `dcr`. Header secrets: real value required; redacted with no stored value returns 400.",+ "requestBody": {+ "content": {+ "application/json": {+ "schema": {+ "$ref": "#/components/schemas/CreateMcpServerRequest"+ }+ }+ },+ "required": true+ },+ "responses": {+ "200": {+ "content": {+ "application/json": {+ "schema": {+ "$ref": "#/components/schemas/PutMcpServerResponse"+ }+ }+ },+ "description": "The created MCP server with auth_status"+ },+ "400": {+ "content": {+ "application/json": {+ "schema": {+ "$ref": "#/components/schemas/RequestErrorResponse"+ }+ }+ },+ "description": "Invalid request body, or redacted header secret with no stored value to keep."+ },+ "409": {+ "content": {+ "application/json": {+ "schema": {+ "$ref": "#/components/schemas/RequestErrorResponse"+ }+ }+ },+ "description": "An MCP server with this name already exists."+ },+ "422": {+ "content": {+ "application/json": {+ "schema": {+ "$ref": "#/components/schemas/RequestErrorResponse"+ }+ }+ },+ "description": "The server cannot satisfy `auth.type: dcr` (e.g. it advertises no registration_endpoint)."+ }+ },+ "summary": "Create an MCP server",+ "tags": [+ "MCP Servers"+ ],+ "x-fern-sdk-group-name": [+ "settings",+ "mcpServers"+ ],+ "x-fern-sdk-method-name": "create"+ },"put": {"description": "Create or replace by `name`. Does not start DCR or change oauth client columns. Header secrets: real value sets/rotates; redacted keeps existing (400 if none).","requestBody": {@@ -6576,6 +6679,60 @@],"x-fern-sdk-method-name": "list"},+ "post": {+ "description": "Creates a provider (models included). Fails if `name` is already taken. Well-known types use `type` as `name` (one each); `custom` is named by the caller. `auth.api_key`: real value required; redacted with no stored secret returns 400.",+ "requestBody": {+ "content": {+ "application/json": {+ "schema": {+ "$ref": "#/components/schemas/ModelProvider"+ }+ }+ },+ "required": true+ },+ "responses": {+ "200": {+ "content": {+ "application/json": {+ "schema": {+ "$ref": "#/components/schemas/PutModelProviderResponse"+ }+ }+ },+ "description": "The created provider"+ },+ "400": {+ "content": {+ "application/json": {+ "schema": {+ "$ref": "#/components/schemas/RequestErrorResponse"+ }+ }+ },+ "description": "Invalid request body, or redacted API key with no stored secret to keep."+ },+ "409": {+ "content": {+ "application/json": {+ "schema": {+ "$ref": "#/components/schemas/RequestErrorResponse"+ }+ }+ },+ "description": "A model provider with this name already exists."+ }+ },+ "summary": "Create a model provider",+ "tags": [+ "Model Providers"+ ],+ "x-fern-sdk-group-name": [+ "settings",+ "modelProviders"+ ],+ "x-fern-sdk-method-name": "create"+ },"put": {"description": "Create or replace a provider (models included). Well-known types use `type` as `name` (one each); `custom` is named by the caller. `auth.api_key`: real value sets/rotates; redacted keeps existing (400 if none).","requestBody": {@@ -6746,6 +6903,60 @@],"x-fern-sdk-method-name": "list"},+ "post": {+ "description": "Creates a skill keyed by `name`. Fails if `name` is already taken.",+ "requestBody": {+ "content": {+ "application/json": {+ "schema": {+ "$ref": "#/components/schemas/SkillManifest"+ }+ }+ },+ "required": true+ },+ "responses": {+ "200": {+ "content": {+ "application/json": {+ "schema": {+ "$ref": "#/components/schemas/PutSkillResponse"+ }+ }+ },+ "description": "The created skill."+ },+ "400": {+ "content": {+ "application/json": {+ "schema": {+ "$ref": "#/components/schemas/RequestErrorResponse"+ }+ }+ },+ "description": "Invalid request body."+ },+ "409": {+ "content": {+ "application/json": {+ "schema": {+ "$ref": "#/components/schemas/RequestErrorResponse"+ }+ }+ },+ "description": "A skill with this name already exists."+ }+ },+ "summary": "Create a skill",+ "tags": [+ "Skills"+ ],+ "x-fern-sdk-group-name": [+ "settings",+ "skills"+ ],+ "x-fern-sdk-method-name": "create"+ },"put": {"description": "Full upsert keyed by `name`: creates the skill or replaces its entire manifest.","requestBody": {@@ -6826,5 +7037,11 @@"x-fern-sdk-method-name": "list"}}- }+ },+ "security": [+ {+ "BearerAuth": []+ }+ ],+ "webhooks": {}}diff --git a/docs/quickstart.mdx b/docs/quickstart.mdxindex c479d7dc4..5df07464d 100644--- a/docs/quickstart.mdx+++ b/docs/quickstart.mdx@@ -42,7 +42,7 @@ TrueForge runs in [two modes](/introduction#two-ways-to-run-it): **local mode**```bash# TODO: replace <HELM_REPO> with the published Helm repo URL- helm install truefoundry-utils oci://<HELM_REPO>/truefoundry-utils \+ helm install trueforge oci://<HELM_REPO>/trueforge \--version <x.y.z>```diff --git a/package.json b/package.jsonindex 393c63bf8..14e5a04dc 100644--- a/package.json+++ b/package.json@@ -7,10 +7,12 @@},"scripts": {"build": "pnpm --filter @truefoundry/trueforge-core build && pnpm --filter @truefoundry/trueforge-sdk build && pnpm --filter @truefoundry/trueforge-ui build && pnpm --filter frontend build && pnpm --filter @truefoundry/trueforge build",- "chart:deps": "helm dependency build charts/truefoundry-utils",- "chart:lint": "helm lint charts/truefoundry-utils --values charts/truefoundry-utils/ci/lint-values.yaml",- "chart:package": "helm package charts/truefoundry-utils --destination dist",- "chart:template": "helm template truefoundry-utils charts/truefoundry-utils --values charts/truefoundry-utils/ci/lint-values.yaml",+ "chart:deps": "helm dependency build charts/trueforge",+ "chart:lint": "helm lint charts/trueforge --values charts/trueforge/ci/lint-values.yaml",+ "chart:package": "helm package charts/trueforge --destination dist",+ "chart:template": "helm template trueforge charts/trueforge --values charts/trueforge/ci/lint-values.yaml",+ "changeset": "changeset",+ "changeset:sdk-regen": "bash scripts/changeset-sdk-regen.sh","clean:all": "node scripts/clean.mjs --dependencies","clean": "node scripts/clean.mjs","dev:infra": "docker compose -f docker-compose.dev.yml up",@@ -36,6 +38,7 @@"standalone:start": "STANDALONE=true NODE_ENV=production pnpm --filter @truefoundry/trueforge start","start": "STANDALONE=false NODE_ENV=production pnpm --filter @truefoundry/trueforge start","push-sandbox-image-to-daytona": "pnpm --filter @truefoundry/trueforge push-sandbox-image-to-daytona",+ "release": "pnpm build && changeset publish","test:frontend": "pnpm --filter frontend test","test:harness": "pnpm --filter @truefoundry/trueforge-core test","test:server": "pnpm --filter @truefoundry/trueforge test",@@ -44,9 +47,11 @@"test:store:sqlite": "pnpm --filter @truefoundry/trueforge test:store:sqlite","test:trueforge-ui": "pnpm --filter @truefoundry/trueforge-ui test","test": "pnpm test:harness && pnpm test:trueforge-ui && pnpm test:server && pnpm test:frontend",- "typecheck": "pnpm --filter @truefoundry/trueforge-core typecheck && pnpm --filter @truefoundry/trueforge-ui typecheck && pnpm --filter @truefoundry/trueforge typecheck && pnpm --filter frontend typecheck"+ "typecheck": "pnpm --filter @truefoundry/trueforge-core typecheck && pnpm --filter @truefoundry/trueforge-ui typecheck && pnpm --filter @truefoundry/trueforge typecheck && pnpm --filter frontend typecheck",+ "version": "node scripts/version.mjs"},"devDependencies": {+ "@changesets/cli": "^3.0.0","@eslint-react/eslint-plugin": "^5.18.0","@eslint/js": "^10.0.1","eslint": "^10.7.0",diff --git a/packages/frontend/package.json b/packages/frontend/package.jsonindex c892c273a..40b9c25b0 100644--- a/packages/frontend/package.json+++ b/packages/frontend/package.json@@ -1,8 +1,8 @@{"name": "frontend","version": "0.0.0",- "description": "TrueFoundry agent chat frontend. Private app — not published to npm.",- "author": "Truefoundry",+ "description": "TrueForge agent chat frontend. Private app — not published to npm.",+ "author": "TrueFoundry","license": "MIT","private": true,"type": "module",diff --git a/packages/harness/package.json b/packages/harness/package.jsonindex 7a5c204ae..8a2133912 100644--- a/packages/harness/package.json+++ b/packages/harness/package.json@@ -1,9 +1,22 @@{"name": "@truefoundry/trueforge-core",- "version": "0.1.10-rc.1",+ "version": "0.0.0","description": "TrueForge core library","author": "TrueFoundry","license": "MIT",+ "repository": {+ "type": "git",+ "url": "git+https://github.com/truefoundry/trueforge.git",+ "directory": "packages/harness"+ },+ "homepage": "https://github.com/truefoundry/trueforge/tree/main/packages/harness#readme",+ "bugs": {+ "url": "https://github.com/truefoundry/trueforge/issues"+ },+ "publishConfig": {+ "access": "public",+ "provenance": false+ },"private": false,"type": "module","main": "./dist/index.js",diff --git a/packages/sdk/.fern/metadata.json b/packages/sdk/.fern/metadata.jsondeleted file mode 100644index b34d398d8..000000000--- a/packages/sdk/.fern/metadata.json+++ /dev/null@@ -1,37 +0,0 @@-{- "cliVersion": "5.89.6",- "generatorName": "fernapi/fern-typescript-node-sdk",- "generatorVersion": "3.87.1",- "generatorConfig": {- "packageJson": {- "name": "@truefoundry/trueforge-sdk"- },- "allowExtraFields": true,- "allowCustomFetcher": true,- "enableInlineTypes": false,- "fetchSupport": "native",- "fileResponseType": "binary-response",- "formDataSupport": "Node18",- "includeApiReference": true,- "inlineFileProperties": true,- "inlinePathParameters": true,- "naming": {- "namespace": "TrueForge",- "client": "TrueForge"- },- "noSerdeLayer": false,- "omitUndefined": true,- "optional-auth": true,- "requireBaseUrl": true,- "retainOriginalCasing": false,- "skipResponseValidation": true,- "streamType": "web",- "useDefaultRequestParameterValues": true- },- "originGitCommit": "b7b953cb306817c8fe24d0ee94b33b990580d481",- "originGitCommitIsDirty": true,- "invokedBy": "ci",- "requestedVersion": "0.0.0",- "ciProvider": "github",- "sdkVersion": "0.0.0"-}diff --git a/packages/sdk/.fernignore b/packages/sdk/.fernignoreindex 2565b8b99..aa1ff12a0 100644--- a/packages/sdk/.fernignore+++ b/packages/sdk/.fernignore@@ -2,3 +2,4 @@ pnpm-workspace.yamlpnpm-lock.yamlsrc/index.tssrc/events.ts+.fern/metadata.json\ No newline at end of filediff --git a/packages/sdk/README.md b/packages/sdk/README.mdindex 8e8012610..12f6cd22a 100644--- a/packages/sdk/README.md+++ b/packages/sdk/README.md@@ -3,7 +3,7 @@[](https://buildwithfern.com?utm_source=github&utm_medium=github&utm_campaign=readme&utm_source=Truefoundry%2FTypeScript)[](https://www.npmjs.com/package/@truefoundry/trueforge-sdk)-TypeScript client for the TrueFoundry agent harness server: a self-hosted runtime that executes agent turns and streams them over Server-Sent Events.+TypeScript client for the TrueForge agent harness server: a self-hosted runtime that executes agent turns and streams them over Server-Sent Events.When auth is enabled on the server, pass an ID token via the optional `token` client option (`Authorization: Bearer`).diff --git a/packages/sdk/package.json b/packages/sdk/package.jsonindex 9bd5e0695..7114556f7 100644--- a/packages/sdk/package.json+++ b/packages/sdk/package.json@@ -259,5 +259,20 @@"engines": {"node": ">=18.0.0"},- "sideEffects": false+ "sideEffects": false,+ "license": "MIT",+ "author": "TrueForge",+ "repository": {+ "type": "git",+ "url": "git+https://github.com/truefoundry/trueforge.git",+ "directory": "packages/sdk"+ },+ "homepage": "https://github.com/truefoundry/trueforge/tree/main/packages/sdk#readme",+ "bugs": {+ "url": "https://github.com/truefoundry/trueforge/issues"+ },+ "publishConfig": {+ "access": "public",+ "provenance": false+ }}diff --git a/packages/server/package.json b/packages/server/package.jsonindex 2dee40fec..533c3a830 100644--- a/packages/server/package.json+++ b/packages/server/package.json@@ -1,9 +1,22 @@{"name": "@truefoundry/trueforge",- "version": "0.2.0-rc.2",- "description": "TrueFoundry agent server + UI (npx @truefoundry/trueforge)",- "author": "Truefoundry",+ "version": "0.0.0",+ "description": "TrueForge agent server + UI (npx @truefoundry/trueforge)",+ "author": "TrueFoundry","license": "MIT",+ "repository": {+ "type": "git",+ "url": "git+https://github.com/truefoundry/trueforge.git",+ "directory": "packages/server"+ },+ "homepage": "https://github.com/truefoundry/trueforge/tree/main/packages/server#readme",+ "bugs": {+ "url": "https://github.com/truefoundry/trueforge/issues"+ },+ "publishConfig": {+ "access": "public",+ "provenance": false+ },"private": false,"type": "module","bin": "./dist/cli.js",diff --git a/packages/trueforge-ui-sdk/package.json b/packages/trueforge-ui-sdk/package.jsonindex a9ea31e22..e76df4089 100644--- a/packages/trueforge-ui-sdk/package.json+++ b/packages/trueforge-ui-sdk/package.json@@ -1,19 +1,20 @@{"name": "@truefoundry/trueforge-ui",- "version": "0.1.4",- "description": "TrueFoundry agent chat UI (atoms + containers) built on assistant-ui, with owned theming, presets, and swappable slots.",+ "version": "0.0.0",+ "description": "TrueForge Agent Chat UI (atoms + containers) built on assistant-ui, with owned theming, presets, and swappable slots.",+ "author": "TrueFoundry","license": "MIT","repository": {"type": "git",- "url": "git+https://github.com/truefoundry/harness.git",+ "url": "git+https://github.com/truefoundry/trueforge.git","directory": "packages/trueforge-ui-sdk"},- "homepage": "https://github.com/truefoundry/harness/tree/main/packages/trueforge-ui-sdk#readme",+ "homepage": "https://github.com/truefoundry/trueforge/tree/main/packages/trueforge-ui-sdk#readme","bugs": {- "url": "https://github.com/truefoundry/harness/issues"+ "url": "https://github.com/truefoundry/trueforge/issues"},"keywords": [- "truefoundry",+ "trueforge","assistant-ui","react","chat",diff --git a/pnpm-lock.yaml b/pnpm-lock.yamlindex a2b678742..01ceee1d6 100644--- a/pnpm-lock.yaml+++ b/pnpm-lock.yaml@@ -15,6 +15,9 @@ importers:.:devDependencies:+ '@changesets/cli':+ specifier: ^3.0.0+ version: 3.0.0'@eslint-react/eslint-plugin':specifier: ^5.18.0version: 5.18.0([email protected]([email protected])([email protected]))([email protected])([email protected])@@ -888,6 +891,75 @@ packages:'@bundled-es-modules/[email protected]':resolution: {integrity: sha512-yn7BklA5acgcBr+7w064fGV+SGIFySjCKpqjcWgBAIfrAkY+4GQTJJHQMeT3V/sgz23VTEVV8TtOmkvJAhFVfg==}+ '@changesets/[email protected]':+ resolution: {integrity: sha512-kUd2pbf1w5/AYmBMb0Tt+rkIPCjFJdT0SZMrkOjJT/WV/QbtmvkyB5jkV0oaNPheavprZk+SfUiozUti7TIL2w==}+ engines: {node: ^22.11 || ^24 || >=26}++ '@changesets/[email protected]':+ resolution: {integrity: sha512-oEW8BxdA604kGGtDSCiHr5w9Tv4UWe9I2k61IBNZzCOE1kbYaJj4v+lFQNgcEZFkUc2pV/+hASErGDvpJOZCTg==}+ engines: {node: ^22.11 || ^24 || >=26}++ '@changesets/[email protected]':+ resolution: {integrity: sha512-3Dst2Ime2Op5nd4XmWJLPIgp11ZFqJqSkVug9izK6TDcIV4YlhPS4ECbEVR+eGI0bk0r1ItogD4j2Oli87bJrA==}+ engines: {node: ^22.11 || ^24 || >=26}++ '@changesets/[email protected]':+ resolution: {integrity: sha512-V7Gm+GP5OT3mJinMI2YcJD/JyO/a4WChnaMCCzTRhWHgu1zhtsyY7zCjP6n5W6zsgSjJKs+yPmvtREvE0F2g8A==}+ engines: {node: ^22.11 || ^24 || >=26, npm: '>=10.9.0', pnpm: '>=10.0.0', yarn: '>=4.5.2'}+ hasBin: true++ '@changesets/[email protected]':+ resolution: {integrity: sha512-mw95/YrkOuhZZxfnVAA4bSXOFUi+KlhzOBTM8C4x777NhUU6HWIl9Z+K+nME+E4PVsv5NQVQwTfiHihAS1A/ow==}+ engines: {node: ^22.11 || ^24 || >=26}++ '@changesets/[email protected]':+ resolution: {integrity: sha512-ElN/mEzn6zmETgjwf5MclCMa9ef59sAR0lfO8VSYIsiRvbC2FbLB/92EoYw10Sl0kGixxHFiJZUSv7dA+YpR8g==}+ engines: {node: ^22.11 || ^24 || >=26}++ '@changesets/[email protected]':+ resolution: {integrity: sha512-OBN/xfe+lcNWCv8P4Ogop9EOTi5QRKd1c2JJfZRBT9AT3AybzDYDfHeX4Y7j20Q4e16BPu3XvcdOe9sPZmTEig==}+ engines: {node: ^22.11 || ^24 || >=26}++ '@changesets/[email protected]':+ resolution: {integrity: sha512-ji/t5wFA1zREKXRUePE6Qi+Qu2UgxCeSSGQrphezwvQZrp49B7sJ+8+wvM0tA7zPeSxYKCojDy3WWgrl+s+awg==}+ engines: {node: ^22.11 || ^24 || >=26}++ '@changesets/[email protected]':+ resolution: {integrity: sha512-uIEswpPUgzBBqrC0qg13byNaPorzhf05LE2T+gRizEKCXvMsJC6NPJp5iNDSV/gYj4Viqh09UiOF5E7XWeH5lQ==}+ engines: {node: ^22.11 || ^24 || >=26}++ '@changesets/[email protected]':+ resolution: {integrity: sha512-P0iaMb9p9CRYZiTgAllEIF9AUMQHIy1G72tKlcIqJp61icZSsKQNiOPdxAMZG8m/DvZwt/oz5xEbTpike//dWg==}+ engines: {node: ^22.11 || ^24 || >=26}++ '@changesets/[email protected]':+ resolution: {integrity: sha512-Zm/6YliV/a2oeWTqHJf6KxLrQwgcK1i/BRDl2m0EKZvbnxV5fG9QRhwJJGshjsZTUTS6dkfURQ2K6aAvgNw/3Q==}+ engines: {node: ^22.11 || ^24 || >=26}++ '@changesets/[email protected]':+ resolution: {integrity: sha512-8TdE2PwG6yArPt5Ozej83Z6iHz1G8BDBKvIEKZ455MccR4K3GNbLR2XqjBxa+5yLFnEd3xAOPXYboBg1pt8stQ==}+ engines: {node: ^22.11 || ^24 || >=26}++ '@changesets/[email protected]':+ resolution: {integrity: sha512-pwqoJmbONn1XgXmZXPEExgAaT+HdZLjALFTDgIm+PnS5KeO2nLtzA2/Q+4aMFY14kFMuXKG30MObhvDzWgzDgg==}+ engines: {node: ^22.11 || ^24 || >=26}++ '@changesets/[email protected]':+ resolution: {integrity: sha512-c5GoiQyt3pxiXjrWSNoP8/GRf4kG+VnKzovx1OQM8dYYALlSwgedmkPmJ+ZqGxqwg9D3Bkj85Uo4KLd5BN3A0w==}+ engines: {node: ^22.11 || ^24 || >=26}++ '@changesets/[email protected]':+ resolution: {integrity: sha512-xCK3/4C7Z7muQB/wguE6HcbjtY9iOtaK9orZKE+7xi573cMGD8rLZz7qlo6IvK7s+SIUIKajzj1l+F1QuP97tw==}+ engines: {node: ^22.11 || ^24 || >=26}++ '@clack/[email protected]':+ resolution: {integrity: sha512-/kr3UWNtdJfxZtPgDqUOmG2pvwlmcLGheex5yiZKdwbzZJxhV+HMNR9QNmyY5cGwTNV6LrR7Jtp+KjhUAP1qBQ==}+ engines: {node: '>= 20.12.0'}++ '@clack/[email protected]':+ resolution: {integrity: sha512-y7/yvZ2TPAnR9+jnc00klvNNLkJiXFFrQA/hlLCcxA9a2A4zQIOimyFQ9XfwYKiGD1fb5GY8vbKIIgO8d5Tb2A==}+ engines: {node: '>= 20.12.0'}+'@colors/[email protected]':resolution: {integrity: sha512-Ir+AOibqzrIsL6ajt3Rz3LskB7OiMVHqltZmspbW/TJuTVuyOMirVqAkjfY6JISiLHgyNqicAC8AyHHGzNd/dA==}engines: {node: '>=0.1.90'}@@ -1750,6 +1822,18 @@ packages:'@js-sdsl/[email protected]':resolution: {integrity: sha512-iUKgm52T8HOE/makSxjqoWhe95ZJA1/G1sYsGev2JDKUSS14KAgg1LHb+Ba+IPow0xflbnSkOsZcO08C7w1gYw==}+ '@manypkg/[email protected]':+ resolution: {integrity: sha512-BcSqCyKhBVZ5YkSzOiheMCV41kqAFptW6xGqYSTjkVTl9XQpr+pqHhwgGCOHQtjDCv7Is6EFyA14Sm5GVbVABA==}+ engines: {node: '>=20.0.0'}++ '@manypkg/[email protected]':+ resolution: {integrity: sha512-0TbBVyvPrP7xGYBI/cP8UP+yl/z+HtbTttAD7FMAJgn/kXOTwh5/60TsqP9ZYY710forNfyV0N8P/IE/ujGZJg==}+ engines: {node: '>=20.0.0'}++ '@manypkg/[email protected]':+ resolution: {integrity: sha512-6QEf6yqFbETdwGITKq57aYoPfX/3K8XFNwsAlx0C1M7o8cb79sv1M3w+tWuWvIcSbNqrLF7OD7YpZMVVz335hQ==}+ engines: {node: '>=20.0.0'}+'@modelcontextprotocol/[email protected]':resolution: {integrity: sha512-zo37mZA9hJWpULgkRpowewez1y6ML5GsXJPY8FI0tBBCd77HEvza4jDqRKOXgHNn867PVGCyTdzqpz0izu5ZjQ==}engines: {node: '>=18'}@@ -2102,6 +2186,10 @@ packages:resolution: {integrity: sha512-dfUnCxiN9H4ap84DvD2ubjw+3vUNpstxa0TneY/Paat8a3R4uQZDLSvWjmznAY/DoahqTHl9V46HF/Zs3F29pg==}engines: {node: '>= 10.0.0'}+ '@pnpm/[email protected]':+ resolution: {integrity: sha512-pOr5+q1fLYKwFN3LAJuGZEnfXDcQ73zqgDHMtGy+K+uIoUqyY+6MeDCWFwfu+4EFuq76I5EPFofoNAI+Bmmq4A==}+ engines: {node: '>=22.13'}+'@protobufjs/[email protected]':resolution: {integrity: sha512-j+gKExEuLmKwvz3OgROXtrJ2UG2x8Ch2YZUxahh+s1F2HZ+wAceUNLkvy6zKCPVRkU++ZWQrdxsUeQXmcg4uoQ==}@@ -4048,6 +4136,10 @@ packages:resolution: {integrity: sha512-b6Ilus+c3RrdDk+JhLKUAQfzzgLEPy6wcXqS7f/xe1EETvsDP6GORG7SFuOs6cID5YkqchW/LXZbX5bc8j7ZcQ==}engines: {node: '>=8'}+ resolution: {integrity: sha512-tixWYgm5ZoOD+3g6UTea91eow5z6AAHaho3g0V9CNSNb45gM8SmflpAc+GRd1InC4AqN/07Unrgp56Y94N9hJQ==}+ engines: {node: '>=20.19.0'}+resolution: {integrity: sha512-Sp1ablJ0ivDkSzjcaJdxEunN5/XvksFJ2sMBFfq6x0ryhQV/2b/KwFe21cMpmHtPOSij8K99/wSfoEuTObmuMQ==}engines: {node: '>= 0.4'}@@ -4743,9 +4835,18 @@ packages:resolution: {integrity: sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw==}+ resolution: {integrity: sha512-0jjjIEL6+0jag3l2XWWizO64/aZVtpiGE3t0Zgqxv0DPuxiMjvB3M24fCyhZUO4KomJQPj3LTSUnDP3GpdwC0g==}++ resolution: {integrity: sha512-gX8LrtNEI5hq8DVUfRQMbr5lpaS4nMIWV+7XEbXk2b8kiQIizgnlr12B4dA3ZEx3308ze0O4Q1R+cHts8kyUJg==}+resolution: {integrity: sha512-8JnbkQ4juDyvYs4mgFGQqg4yCYtFDtUtmp2QIQq11ZZe5CFQ5wcqm1rqDgAh/QdMySuBnPzMUiJUNZG5N/AiQw==}+ resolution: {integrity: sha512-7F2Fl+TjRSenLqlU3UjSH0iyqopqoZIu7eZVpEirP2g1GtWa2G/ecEmBdgz31+Mxr+ELclgg6sokpSFIQiZ02Q==}+resolution: {integrity: sha512-GGToxJ/w1x32s/D2EKND7kTil4n8OVk/9mycTc4VDza13lOvpUZTGX3mFSCtV9ksdGBVzvsyAVLM6mHFThxXxw==}@@ -5001,6 +5102,10 @@ packages:resolution: {integrity: sha512-vK9P5/iUfdl95AI+JVyUuIcVtd4ofvtrOr3HNtM2yxC9bnMbEdp3x01OhQNnjb8IJYi38VlTE3mBXwcfvywuSw==}engines: {node: '>= 14'}+ resolution: {integrity: sha512-K3GbkIWqyvvlpfhBPlbEvD97TtqBpAYA4kt+cn2lD2x2HuohzZCibcA2nOlnJT6exqvJLggoB5nv2dNf192nEA==}+ hasBin: true+resolution: {integrity: sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==}engines: {node: '>=10.17.0'}@@ -5042,6 +5147,9 @@ packages:engines: {node: '>=8'}hasBin: true+ resolution: {integrity: sha512-Iqv2fzaTQN28s/FwZAoFq0ZSs/7hMAHJVX+w8PZl3cY19Pxk6jFFalxQoIfW2826i/fDLXv8IiEZRIT0lDuWcg==}+resolution: {integrity: sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA==}engines: {node: '>=0.8.19'}@@ -5309,6 +5417,9 @@ packages:resolution: {integrity: sha512-AC/7JofJvZGrrneWNaEnJeOLUx+JlGt7tNa0wZiRPT4MY1wmfKjt2+6O2p2uz2+skll8OZZmJMNqeke7kKbNgQ==}hasBin: true+ resolution: {integrity: sha512-8wb9Yw966OSxApiCt0K3yNJL8pnNeIv+OEq2YMidz4FKP6nonSRoOXc80iXY4JaN2FC11B9qsNmDsm+ZOfMROA==}+resolution: {integrity: sha512-Bsdjwm3Qsd/P0jR+BHDe3LytDfY7WBq2HmCCLIwuVRHMuEC9ae7/R474GIUdF1NgCyZjzVo/A9DOiOBtXq8ZoQ==}@@ -5391,6 +5502,9 @@ packages:resolution: {integrity: sha512-y5mVgQNkMbs1eK9Xyc0pmNdabN2wHhRYY/5r4W5HrUT1rYCEPeVNSj1RUJeSDKT3U0p+mXCvLgkrFuIafYI6BA==}engines: {node: '>=22.0.0'}+ resolution: {integrity: sha512-QWBrQsMpH7gPr965dsKD/3cKWiNoTjpATQf++Xq63N6sKRGMwlVXz41O1IZTMfZQgBctD/K5Zt06+/I6pP6+HA==}+resolution: {integrity: sha512-qsda+H8jTaUaN/x5vzW2rzc+8Rw4TAQ/4KjB46IwK5VH+IlVeeeje/EoZRpiXvIqjFgK84QffqPztGI3VBLG1A==}engines: {node: '>=6'}@@ -5995,6 +6109,9 @@ packages:resolution: {integrity: sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==}engines: {node: '>=6'}+ resolution: {integrity: sha512-yQA4H19AmPEoMUeavPMDIe1higySl/gH/yaQrkT/s07Qp+7pp2hYz30N3z2l5BkjVkF9Ow6o0wjJamm2y7Sn0A==}+resolution: {integrity: sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==}engines: {node: '>=6'}@@ -6752,6 +6869,10 @@ packages:resolution: {integrity: sha512-SHf/r48b7vOrjve9PxJo3MN5v5yuyjHvdUcrQffT3WXMUfnGmHDVbC4k3sHJaJTgZCwpUplIaAo5ANtMyp3YHg==}engines: {node: '>=18'}+ resolution: {integrity: sha512-QKAl9m8gWWGHV8jZcPeym6j+XULi6tOf1mT83WYJ4Lk2ytW/uwAWkrP0uFsdoYMdueVJ0qs26wZ+23xeB4ibNQ==}+ engines: {node: '>=18'}+resolution: {integrity: sha512-wXR/dYpcqKmfWpEdZjiKJOwCNFndD0DMnrW/cYjVGttEkBfVgcLFHoNrlj47mjOVic9yyNu65alsgF4NQyTa2g==}engines: {node: '>=12.0.0'}@@ -7897,6 +8018,122 @@ snapshots:dependencies:statuses: 2.0.2+ '@changesets/[email protected]':+ dependencies:+ '@changesets/config': 4.0.0+ '@changesets/format': 0.1.1+ '@changesets/git': 4.0.0+ '@changesets/should-skip-package': 1.0.0+ '@changesets/types': 7.0.0+ import-meta-resolve: 4.2.0+ jsonc-parser: 3.3.1+ semver: 7.8.5++ '@changesets/[email protected]':+ dependencies:+ '@changesets/errors': 1.0.0+ '@changesets/get-dependents-graph': 3.0.0+ '@changesets/should-skip-package': 1.0.0+ '@changesets/types': 7.0.0+ semver: 7.8.5++ '@changesets/[email protected]':+ dependencies:+ '@changesets/types': 7.0.0++ '@changesets/[email protected]':+ dependencies:+ '@changesets/apply-release-plan': 8.0.0+ '@changesets/assemble-release-plan': 7.0.0+ '@changesets/changelog-git': 1.0.0+ '@changesets/config': 4.0.0+ '@changesets/errors': 1.0.0+ '@changesets/get-dependents-graph': 3.0.0+ '@changesets/git': 4.0.0+ '@changesets/pre': 3.0.0+ '@changesets/read': 1.0.0+ '@changesets/should-skip-package': 1.0.0+ '@changesets/types': 7.0.0+ '@changesets/write': 1.0.0+ '@clack/prompts': 1.7.0+ '@manypkg/get-packages': 3.1.0+ '@pnpm/deps.graph-sequencer': 1100.0.1+ cac: 7.0.0+ import-meta-resolve: 4.2.0+ launch-editor: 2.14.1+ package-manager-detector: 1.8.0+ semver: 7.8.5+ tinyexec: 1.3.0++ '@changesets/[email protected]':+ dependencies:+ '@changesets/get-dependents-graph': 3.0.0+ '@changesets/should-skip-package': 1.0.0+ '@changesets/types': 7.0.0+ '@manypkg/get-packages': 3.1.0+ picomatch: 4.0.5++ '@changesets/[email protected]': {}++ '@changesets/[email protected]':+ dependencies:+ package-manager-detector: 1.8.0+ tinyexec: 1.2.4++ '@changesets/[email protected]':+ dependencies:+ '@changesets/types': 7.0.0+ semver: 7.8.5++ '@changesets/[email protected]':+ dependencies:+ '@changesets/errors': 1.0.0+ '@changesets/types': 7.0.0+ '@manypkg/get-packages': 3.1.0+ picomatch: 4.0.5+ tinyexec: 1.3.0++ '@changesets/[email protected]':+ dependencies:+ '@changesets/types': 7.0.0+ yaml: 2.9.0++ '@changesets/[email protected]':+ dependencies:+ '@changesets/errors': 1.0.0+ '@changesets/types': 7.0.0+ '@manypkg/get-packages': 3.1.0++ '@changesets/[email protected]':+ dependencies:+ '@changesets/git': 4.0.0+ '@changesets/parse': 1.0.0+ '@changesets/types': 7.0.0++ '@changesets/[email protected]':+ dependencies:+ '@changesets/types': 7.0.0++ '@changesets/[email protected]': {}++ '@changesets/[email protected]':+ dependencies:+ '@changesets/format': 0.1.1+ '@changesets/types': 7.0.0+ human-id: 4.2.0++ '@clack/[email protected]':+ dependencies:+ fast-wrap-ansi: 0.2.2+ sisteransi: 1.0.5++ '@clack/[email protected]':+ dependencies:+ '@clack/core': 1.4.3+ fast-string-width: 3.0.2+ fast-wrap-ansi: 0.2.2+ sisteransi: 1.0.5+'@colors/[email protected]': {}'@csstools/[email protected]': {}@@ -8706,6 +8943,21 @@ snapshots:'@js-sdsl/[email protected]': {}+ '@manypkg/[email protected]':+ dependencies:+ '@manypkg/tools': 2.1.2++ '@manypkg/[email protected]':+ dependencies:+ '@manypkg/find-root': 3.1.0+ '@manypkg/tools': 2.1.2++ '@manypkg/[email protected]':+ dependencies:+ jju: 1.4.0+ tinyglobby: 0.2.17+ yaml: 2.9.0+dependencies:'@hono/node-server': 1.19.14([email protected])@@ -9129,6 +9381,8 @@ snapshots:'@parcel/watcher-win32-ia32': 2.5.1'@parcel/watcher-win32-x64': 2.5.1+ '@pnpm/[email protected]': {}+'@protobufjs/[email protected]': {}'@protobufjs/[email protected]': {}@@ -11126,6 +11380,8 @@ snapshots:+ [email protected]: {}+dependencies:es-errors: 1.3.0@@ -11958,8 +12214,18 @@ snapshots:+ [email protected]: {}++ dependencies:+ fast-string-truncated-width: 3.0.3++ dependencies:+ fast-string-width: 3.0.2+dependencies:reusify: 1.1.0@@ -12255,6 +12521,8 @@ snapshots:transitivePeerDependencies:- supports-color+ [email protected]: {}+@@ -12289,6 +12557,8 @@ snapshots:pkg-dir: 4.2.0resolve-cwd: 3.0.0+ [email protected]: {}+@@ -12748,6 +13018,8 @@ snapshots:+ [email protected]: {}+@@ -12827,6 +13099,11 @@ snapshots:+ dependencies:+ picocolors: 1.1.1+ shell-quote: 1.10.0+@@ -13587,6 +13864,8 @@ snapshots:+ [email protected]: {}+dependencies:callsites: 3.1.0@@ -14480,6 +14759,8 @@ snapshots:+ [email protected]: {}+dependencies:fdir: 6.5.0([email protected])diff --git a/scripts/changeset-sdk-regen.sh b/scripts/changeset-sdk-regen.shnew file mode 100755index 000000000..669dba96f--- /dev/null+++ b/scripts/changeset-sdk-regen.sh@@ -0,0 +1,18 @@+#!/usr/bin/env bash+# Patch-changeset @truefoundry/trueforge-sdk for a Fern regen, unless a pending+# changeset already names that package (so repeated regens do not pile files).+set -euo pipefail+cd "$(dirname "$0")/.."++shopt -s nullglob+for file in .changeset/*.md; do+ if [[ "$(basename "$file")" == "README.md" ]]; then+ continue+ fi+ if grep -Eq "^['\"]@truefoundry/trueforge-sdk['\"]:" "$file"; then+ echo "Pending changeset already names @truefoundry/trueforge-sdk ($(basename "$file")); skipping."+ exit 0+ fi+done++pnpm change --bump patch --summary "Regenerate SDK from updated OpenAPI spec." @truefoundry/trueforge-sdkdiff --git a/scripts/version.mjs b/scripts/version.mjsnew file mode 100644index 000000000..379a4a055--- /dev/null+++ b/scripts/version.mjs@@ -0,0 +1,70 @@+/**+ * Root `pnpm version` entry for changesets/action.+ *+ * `changeset version` only patches package.json (+ CHANGELOG). Fern also bakes the+ * SDK version into generated TS, so if `@truefoundry/trueforge-sdk` actually moved,+ * re-run `pnpm sdk:generate` and stage that output.+ */+import { spawn } from 'node:child_process';+import { readFile } from 'node:fs/promises';+import path from 'node:path';+import { fileURLToPath } from 'node:url';++const rootDir = path.resolve(path.dirname(fileURLToPath(import.meta.url)), '..');+const sdkPackageJsonPath = path.join(rootDir, 'packages/sdk/package.json');++function run(command, args) {+ return new Promise((resolve, reject) => {+ const child = spawn(command, args, {+ cwd: rootDir,+ stdio: 'inherit',+ env: process.env,+ });+ child.on('error', error => {+ reject(new Error(`Failed to spawn ${command} ${args.join(' ')}`, { cause: error }));+ });+ child.on('close', code => {+ if (code === 0) {+ resolve();+ return;+ }+ reject(new Error(`${command} ${args.join(' ')} exited with code ${String(code)}`));+ });+ });+}++async function readSdkVersion() {+ let raw;+ try {+ raw = await readFile(sdkPackageJsonPath, 'utf8');+ } catch (error) {+ throw new Error('Failed to read packages/sdk/package.json', { cause: error });+ }++ let parsed;+ try {+ parsed = JSON.parse(raw);+ } catch (error) {+ throw new Error('Failed to parse packages/sdk/package.json', { cause: error });+ }++ if (typeof parsed !== 'object' || parsed === null || Array.isArray(parsed)) {+ throw new Error('packages/sdk/package.json must be a JSON object');+ }+ if (!('version' in parsed) || typeof parsed.version !== 'string' || parsed.version.length === 0) {+ throw new Error('packages/sdk/package.json is missing a non-empty string version');+ }+ return parsed.version;+}++const before = await readSdkVersion();+await run('pnpm', ['changeset', 'version']);+const after = await readSdkVersion();++if (before === after) {+ console.log(`SDK version unchanged (${before}); skipping sdk:generate`);+} else {+ console.log(`SDK version ${before} → ${after}; regenerating SDK so Fern rebakes version literals`);+ await run('pnpm', ['sdk:generate']);+ await run('git', ['add', '.github/fern/openapi', 'docs/openapi.json', 'packages/sdk', 'pnpm-lock.yaml']);+}