Skip to content

feat(configAPI): Robot kind, with ghost robots for demos - #185

Merged
herchu merged 2 commits into
mainfrom
b-herchu/robot-config-kind
Oct 15, 2026
Merged

herchu merged 2 commits into
mainfrom
b-herchu/robot-config-kind

Conversation

@herchu

@herchu herchu commented Oct 15, 2026 •

Copy link
Copy Markdown
Member

Summary

  • New Robot configuration kind (POST /api/configuration/apply): declares a robot by id with a label. Pre-registers a real robot offline before its agent connects; re-apply touches only the name, ingest owns the rest.
  • ghost: true makes a static demo placeholder: online, marked with the existing ghost sentinel (updateStamp / ts = HACK_GHOST_UPDATE_STAMP_VALUE), with optional pose, attributes and statuses written once into attr_values, robot_key_values, robot_status and localization. Those three fields are a SchemaError without ghost: true, so this is not a live-data path.
  • clear removes a ghost and its derived documents; removes an offline real robot; refuses an online one. list flags ghosts.
  • No schema changes. Docs in docs/ghost-robots.md, row in README-dev.md.

Motivation: demo instances with one or two real robots need a fleet to show. Used first on the Brickmart instance (ghosts picker-3..picker-8 in that config repo).

Test plan

  • app: new configAPI:Robot kind suite, 12 tests (auth, create, re-apply, schema rejections, ghost writes, clear, re-apply after clear, list)
  • app: full suite green
  • Six ghosts imported on a local instance; Fleet Status chips show once the dashboard's status ids match the ghosts' statuses keys

Note: new suite adds after(resetDatabase); isoMqttConfig.test asserts an absolute robot count and failed when run after a suite that left robots behind.

🤖 Generated with Claude Code

Adds a `Robot` configuration kind that declares a robot by id with its
identity fields (label, tags). A real robot can be pre-registered before
its agent connects; ingest owns everything else from then on.

With `ghost: true` the robot is a static demo placeholder: it is marked
with the existing ghost sentinel (updateStamp / ts = 12, which the UI
treats as never stale), reads as online, and the spec may carry a pose,
datasource values and statuses, written once into attr_values,
robot_key_values, robot_status and localization. Those fields are
rejected on non-ghost robots, so the kind cannot be used to feed live
data. Clearing a ghost removes all of it; clearing a real robot is
refused while it is online.

`tags` is a new optional field on the robot schema; nothing consumes it
yet. The new test suite resets the DB after itself, since
isoMqttConfig.test asserts an absolute robot count.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>

@claude claude Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Claude Code Review

Claude Code Review is paused for this repository because its GitHub organization is not linked to your Claude organization.

To turn it back on, one person needs both roles: owner of the GitHub organization (or the account owner, for a personal repository) and admin or owner of your Claude organization. If that is not you, pass this on to someone who is.

Open Organization settings, Git providers and click Link next to the GitHub organization's name. If it is not listed, click Enable GitHub integration or Connect your GitHub first, whichever the page shows.

New pull requests are then reviewed as before. To get a review on one that is already open, someone with write access can comment @claude review.

Tip: disable this comment in your organization's Code Review settings.

@netlify

netlify Bot commented Oct 15, 2026 •

Copy link
Copy Markdown

✅ Deploy Preview for ornate-croquembouche-cc5482 canceled.

Name Link
🔨 Latest commit 095204c
🔍 Latest deploy log https://app.netlify.com/projects/ornate-croquembouche-cc5482/deploys/6ad1109e1af51b2bef43b10d

Nothing in ORO consumes a tags field yet, so the kind declares only label
(plus the ghost fields). No robot schema change.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
@herchu
herchu merged commit 0b8ee04 into main Oct 15, 2026
8 checks passed
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