Skip to content

SMOODEV-1787: consume published smooth-operator-core; delete in-tree copy (PR 1/4)#92

Merged
brentrager merged 1 commit into
mainfrom
SMOODEV-1787-consume-operator-core
Jun 9, 2026
Merged

SMOODEV-1787: consume published smooth-operator-core; delete in-tree copy (PR 1/4)#92
brentrager merged 1 commit into
mainfrom
SMOODEV-1787-consume-operator-core

Conversation

@brentrager

Copy link
Copy Markdown
Contributor

Problem

PR 1 of 4 in the program to decouple the `th code` coding harness from the public agent engine.

`smooth` was building against an in-tree copy of the agent engine at `crates/smooth-operator` (`smooai-smooth-operator`), which had diverged from the published public engine `smooai-smooth-operator-core` (`github.com/SmooAI/smooth-operator-core`). Two copies of the same engine is the root problem this program removes.

Solution

`smooth` now consumes the published `smooth-operator-core` engine; the in-tree copy is deleted. The ~12 consumers compile unchanged — this is the dual-engine collapse only. No functional change, no module removal (that lands in later PRs).

Divergence analysis (full diff of both `src/` trees + Cargo.toml)

The two engines differed in only two ways, neither of which smooth depends on:

  1. Dormant BigSmooth coupling — the public core gates its `bigsmooth_client` (`BigSmoothReporter`/`ReporterEvent`/`ControlEvent`) behind a `bigsmooth` cargo feature, with a no-op `report_to_bigsmooth` stub + stand-in `ReporterEvent` enum when disabled. The in-tree copy wired the reporter unconditionally. smooth never enables the `bigsmooth` feature and never sets a reporter (verified: zero consumers reference `BigSmoothReporter` / `with_reporter` / `.reporter` / `ReporterEvent` / `ControlEvent`), so these calls were dormant no-ops. Nothing is lost.
  2. Cosmetic public-sanitization — doc-comment rewording (removing internal names like "Big Smooth"/"Wonk"/"microVM" and pearl IDs), `smooth_operator` → `smooth_operator_core` in doc examples, neutralized example hosts in tests (`llm.smoo.ai` → `gateway.example.com`), a provider-agnostic `ModelRouting::default()` (consumers load routing from file / pick presets explicitly — no consumer depends on the default alias strings), a redacting `Debug` for `ProviderConfig`/`LlmConfig` (a strict improvement), and a wider retry-status set. All public API signatures the consumers use are identical; the public core still exports `Preset::SmoaiGateway`, `Preset::ALL`, `Preset::from_name`, `ProviderConfig::smooai_gateway`, etc.

No port into the core was needed — there was no in-tree-only code that smooth's consumers use and the public core lacks.

Wiring

  • Workspace `smooth-operator` dep repointed to the published engine, package-aliased so `use smooth_operator::…` keeps resolving:
    `smooth-operator = { git = "https://github.com/SmooAI/smooth-operator-core.git", rev = "bb9a256…", package = "smooai-smooth-operator-core" }`
  • Pinned as a rev-locked git dep, not a sibling `../` path dep — a path dep only resolves on a dev laptop and breaks CI's `cargo metadata` step, the exact failure SMOODEV-1464 hit with `client-shared`.
  • The two crate-level path-dep overrides (`smooth-bigsmooth`, `smooth-operative`) converted to `smooth-operator.workspace = true`.
  • `crates/smooth-operator/` deleted (38 files, ~20k lines); removed from the workspace via the `crates/*` glob.

Verification (real output)

  • `smooth-operator-core`: nothing ported — no core change in this PR.
  • `smooth`: `cargo build --workspace` → clean (all ~12 consumers compile unchanged: th/smooth-cli, smooth-bigsmooth, smooth-operative, smooth-code, smooth-narc, smooth-pearls, smooth-scribe, smooth-wonk, smooth-plugin, smooth-bench). `cargo test --workspace` → all suites green except a pre-existing concurrency flake (`smooth-bench` `current_commit_sha_returns_something_non_empty` shells out to `git rev-parse HEAD` and races other subprocess-spawning bench tests under parallel load; passes in isolation, and is in `sweep.rs` which this PR never touches).
  • `cargo metadata` resolves cleanly (the SMOODEV-1464 failure mode); `Cargo.lock` now sources the engine from `git+…?rev=bb9a256…`; old `smooai-smooth-operator` is gone from the lockfile; no remaining `path = ".../smooth-operator"` dep references.

🤖 Generated with Claude Code

…te the in-tree crates/smooth-operator copy (PR 1/4: dual-engine collapse, no functional change)

The in-tree engine (smooai-smooth-operator) and the public
smooth-operator-core (smooai-smooth-operator-core) were the same engine
but had diverged. The only differences were the public core's dormant
`bigsmooth`-feature gating of the BigSmooth reporter (with a no-op stub
when disabled) plus cosmetic public-sanitization edits. smooth never
enables the `bigsmooth` feature and never sets a reporter, so the gated
reporter calls were dormant no-ops — the cutover loses nothing.

Repoint the workspace `smooth-operator` dep to the published
`smooai-smooth-operator-core` (rev-pinned git dep), package-aliased so the
~12 consumers' `use smooth_operator::…` imports compile unchanged. Convert
the two crate-level path-dep overrides (smooth-bigsmooth, smooth-operative)
to `smooth-operator.workspace = true`. Delete crates/smooth-operator/.

Git dep (not a sibling path dep) to avoid the CI `cargo metadata` failure
SMOODEV-1464 hit with a `../`-style path dep. No functional change, no
module removal — later PRs.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@changeset-bot

changeset-bot Bot commented Jun 9, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 0dfa72b

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@smooai/smooth Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@brentrager brentrager merged commit 890d604 into main Jun 9, 2026
2 checks passed
@brentrager brentrager deleted the SMOODEV-1787-consume-operator-core branch June 9, 2026 17:38
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