Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
50 changes: 43 additions & 7 deletions docs/claude-mod.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
# Claude mod entry point

UG's smart-routed Claude launcher loads `hooks/register.ts` through the existing
launch-scoped `ug-smart-router` plugin. Claude Code 2.1.290 or newer is required.
UG's Claude launcher loads `hooks/register.ts` through the existing launch-scoped
`ug-smart-router` plugin in sessions launched with smart routing. Claude Code 2.1.290 or
newer is required.

The existing `_write_routed_claude_plugin()` copies the packaged TypeScript entry point
from `src/ucode/agents/claude_mods/` and writes `hooks/hooks.json` into that plugin.
Expand Down Expand Up @@ -63,13 +64,48 @@ rollout setting or the user's explicit `1`/`0` or `true`/`false` override. As wi
boolean environment flags, `1`, `true`, `yes`, and `on` enable it (case-insensitive,
with surrounding whitespace ignored); other values disable it. It controls Isaac feedback
availability, so UG's routing presets and on/off toggles leave it unchanged.
The native form keeps routing on until Enter accepts a valid reason, then disables
routing and uploads the exact text in the background with `isaac feedback`. The
transcript shows the feedback ID the mod passes with `--feedback-id`; a toast reports
the result. Cancel or Escape leaves routing on and sends nothing. A missing
`isaac` CLI or an unavailable form leaves routing on. A feedback submission failure after a valid
The native form keeps routing on until Enter accepts a valid reason. It closes the
form and shows the sending message and feedback ID before starting Isaac. The existing
native background callback runs `isaac feedback --with-evidence` to capture and upload
the report while the user continues working. Routing is turned off independently of
that process. Delivery produces both a persistent message and a success toast;
a failed upload offers `/isaac-feedback retry <id>` when a local snapshot was saved.
Before submitting, Cancel or Escape leaves routing on and sends nothing. A missing
`isaac` executable at launch or an unavailable form leaves routing on. A feedback submission failure after a valid
reason leaves routing off and reports the failure in the transcript. The form makes no model requests.

In these sessions, with the same flag enabled, `/isaac-feedback` uses the same native
form, capture, and background uploader as `/smart-router off`. It remains available
after routing is turned off so users can report on an earlier routed task. It asks
for a category when none was supplied, and for feedback text when the invocation is empty.
`/isaac-feedback --category smart-routing <text>` submits directly. Smart-routing
reports pin the current session's most recent task by its native user-message ID.
The `session.append` hook remembers that ID; a session with no observed prompt uses
Isaac's existing target inspection before opening the form. Empty sessions use an
unmatched `no-prior-task` selector so subsequent work cannot become their target.
The native flow does not generate an agent note. Other reports retain their text-only
transport and do not receive an evidence feedback ID. `/isaac-feedback retry <id>` uploads the saved
snapshot in the background without capturing it again.

The submission and its sending/completion messages make no model requests and
need no updated Isaac skill instructions. Explicit inspection and local-preview
requests still use the existing skill. Earlier targets, agent notes, and additional
files remain available through the existing Isaac CLI options.

Claude sessions launched without smart routing use the existing feedback skill.

Each submission passes Claude's native session ID and the current routing controls
to Isaac. Valid session-file overrides are copied into that child process's environment,
so turning routing off or back on cannot change the report's recorded settings.
These settings describe submission time; subagent execution still requires routing-log
evidence. An invalid controls file remains unverified.

These uploads belong to the running Claude session. Keep it open until completion;
if interrupted, retry the saved evidence ID on the same machine. If capture did not
finish, submit the feedback again. No Isaac background worker or new CLI options are
required. Evidence is collected in the background: the selected task stays fixed,
while transcript and file snapshots reflect capture time and available file history.

`isaac-feedback.ts` owns this Databricks-specific policy, form, and submission.
`register.ts` binds the routing callbacks before Isaac's command guard, then
handles toggles the guard passes through. Claude's mod compiler requires engine
Expand Down
Loading
Loading