Skip to content

Refactor: Rename agent to operator across client and console#144

Merged
jfrench9 merged 3 commits into
mainfrom
refactor/operator-agent-rename
May 17, 2026
Merged

Refactor: Rename agent to operator across client and console#144
jfrench9 merged 3 commits into
mainfrom
refactor/operator-agent-rename

Conversation

@jfrench9
Copy link
Copy Markdown
Member

Summary

This PR renames the "agent" concept to "operator" throughout the client library and console components, aligning the codebase with updated domain terminology. The refactor touches the core console UI component, its associated tests, mock definitions, and the upstream @robosystems/client-clients package dependency.

Changes

Terminology Rename (agent → operator)

  • ConsoleContent.tsx: Updated all references from "agent" to "operator" in props, state variables, event handlers, and rendered UI text. This includes renaming props/interfaces, internal logic, and any user-facing labels within the console component.
  • ConsoleContent.test.tsx: Updated test cases to reflect the new "operator" naming — adjusted mock data, assertions, and test descriptions to match the renamed component API.
  • src/__mocks__/@robosystems/client-clients.js: Updated mock implementations to use "operator" naming, ensuring test infrastructure stays consistent with the real module API.

Dependency Update

  • package.json / package-lock.json: Bumped @robosystems/client-clients to a version that reflects the same agent → operator rename upstream, keeping the client library and this application in sync.

Repository Structure

  • A subtree split was performed on src/lib/core/ to align with the upstream core library commit (2360f69), ensuring the refactored code is properly synced.

Key UI/UX Improvements

  • Console UI now consistently uses "operator" terminology, which better reflects the domain model and reduces confusion for end users who interact with operator-based workflows.
  • No visual or layout changes — this is a pure terminology/naming refactor.

Breaking Changes

⚠️ Yes — this is a breaking change for consumers of the ConsoleContent component API:

  • Any props previously named with agent (e.g., agentId, agentName, onAgentChange, etc.) are now renamed to their operator equivalents.
  • Parent components or external consumers passing agent-related props will need to update their prop names accordingly.
  • The @robosystems/client-clients dependency version has changed; downstream consumers must also update to the compatible version.

Testing Notes for Reviewers

  1. Unit tests updated: ConsoleContent.test.tsx has been revised to cover the renamed API. Run npm test or npx jest ConsoleContent to verify all pass.
  2. Mock alignment: Verify that @robosystems/client-clients mock exports match the new operator-based API surface — check src/__mocks__/@robosystems/client-clients.js for correctness.
  3. Integration check: Manually verify the console component renders correctly in the browser — confirm that:
    • Operator-related labels display properly.
    • Console interactions (connect, disconnect, messaging) function as before.
    • No residual "agent" references appear in the UI.
  4. Search for stragglers: Do a project-wide search for agent (case-insensitive) in component code to confirm no references were missed.

Browser Compatibility Considerations

  • No new browser APIs, CSS features, or polyfills are introduced in this change.
  • This is a pure rename/refactor with no DOM, styling, or runtime behavior changes — browser compatibility is unaffected.
  • All previously supported browsers (modern evergreen browsers for Next.js/React apps) remain fully compatible.

🤖 Generated with Claude Code

Branch Info:

  • Source: refactor/operator-agent-rename
  • Target: main
  • Type: feature

Co-Authored-By: Claude noreply@anthropic.com

@jfrench9 jfrench9 merged commit ab93e8f into main May 17, 2026
7 checks passed
@jfrench9 jfrench9 deleted the refactor/operator-agent-rename branch May 17, 2026 23:47
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