Commit Graph
11 Commits
Author SHA1 Message Date
mozempk 154e456d4c refactor(agents): remove interrogator, merge design Q&A into conductor
Confirmed via official Copilot CLI docs: there is no ask_user/elicitation
tool available to custom agents (only execute/read/edit/search/agent/web/
todo aliases exist). Subagent calls made through the 'agent' tool are
stateless — they run to completion and return one final result, with no
mechanism to pause mid-task for a live human reply.

This means conductor invoking interrogator via the agent tool could never
work: interrogator would run as a subagent regardless of whether conductor
itself was foreground or backgrounded, and subagents can't get real user
answers. That's why it was silently writing fabricated decisions.md/
questionnaire.md content instead of actually asking anything.

Fix: delete the interrogator agent entirely and fold its full Q&A
procedure directly into conductor's own DESIGN PHASE, run inline in
conductor's own foreground turn — never delegated. Updated the design
skill/prompt, AGENTS.md, README, QUICKSTART, and role-tier config to
match. Single entry point, no subagent path for anything that needs a
live human answer.
2026-09-10 02:40:07 +02:00
mozempkandCopilot 981cbceecf fix(conductor): self-heal missing harness config via lh init --yes
conductor previously jumped straight to lh host, which succeeds even
without .agents/harness.config.json, then silently hit a hard failure
later reading .agents/memory/INDEX.md (lh doctor confirms: config not
initialised). New projects had no automatic recovery path — lh init
was documented as a manual step users had to remember.

- conductor now runs lh doctor first; if config is missing it runs
  lh init --yes (non-interactive defaults) and re-checks, before lh host
- still stops and reports the exact failing check if lh doctor finds
  something it can't self-heal (e.g. no verify commands configured)
- README/QUICKSTART updated: lh init/lh doctor documented as optional
  manual pre-flight, not a required step, since conductor self-heals

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-09-10 01:57:05 +02:00
mozempk cf13066baa feat(setup-npm-registry): browser-assisted classic PAT creation
When no token is found via --token/env/gh CLI, the script now opens
github.com/settings/tokens/new pre-scoped to read:packages with clear
instructions on Note/Expiration/Scopes, falling back to printing the
URL when a browser can't be launched (SSH, containers, CI). Add
--no-open to skip the launch attempt outright.

Also document the flow in README (new 'Generating a GitHub token'
section) and QUICKSTART troubleshooting, and add a hermetic test
covering the --no-open + piped-token path.
2026-09-10 01:44:28 +02:00
mozempk 66219525ba docs: fix wrong @agent mention syntax; @ only mentions files in Copilot CLI
Per official docs, agents are invoked via /agent, naming them in a prompt
("Use the conductor agent to..."), or --agent=NAME — never @name. Replaced
all @conductor-style examples. Also documented an observed limitation:
plugin-sourced agents are launchable (by name or --agent flag, both
verified live) but copilot's own 'plugins list' explicitly says custom-agent
introspection isn't finished yet, which likely explains why they aren't
proactively suggested/listed even though they work when named explicitly.
2026-09-10 01:37:47 +02:00
mozempk d74cb58821 docs: verify and clarify agent-namespacing vs skill-namespacing, add stale-session note 2026-09-10 01:34:26 +02:00
mozempk 5896213780 docs: clarify plugin agents are namespaced (redsen-lean-harness:conductor) outside this repo 2026-09-10 01:27:47 +02:00
mozempkandCopilot 58471c286f feat: zero-dependency npm registry setup script
scripts/setup-npm-registry.mjs configures npm to pull @redsentech
packages (e.g. @redsentech/lean-harness) from GitHub Packages:

- Discovers a token: --token flag > env (NPM_REGISTRY_TOKEN/
  GITHUB_TOKEN/GH_TOKEN) > `gh auth token` > interactive masked prompt
  (raw-mode stdin, no echo, no external deps).
- Verifies the token against the GitHub API, reports the authenticated
  login, and warns if the OAuth scopes are missing read:packages/
  write:packages.
- Writes/updates only its own two lines in .npmrc (scope registry +
  auth token), preserving every other line; idempotent on rerun.
- Never prints the full token (masked in all output).
- --dry-run, --unset (clean removal), --local, --scope, --registry,
  --skip-verify, --npmrc <path> flags.
- Confirms the result with `npm whoami --registry ...`.

Verified live end-to-end: real GitHub PAT via `gh auth token` ->
verified against api.github.com -> written to a scratch .npmrc ->
`npm whoami` succeeded. Also confirmed the scope-warning is accurate:
installing @redsentech/lean-harness with a token lacking read:packages
correctly 403s, exactly as the script warns it will.

Adds tests/setup-npm-registry.test.mjs (7 hermetic tests: dry-run,
write+preserve, token never printed, idempotent rerun, --unset,
custom scope/registry, clean failure with no token). Adds
"setup-npm-registry" npm script. Documents the script in README (The
`lh` CLI section) and docs/QUICKSTART.md (install + troubleshooting).

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-09-10 00:56:30 +02:00
mozempkandCopilot 8330cf7900 ci: publish @redsentech/lean-harness to GitHub Packages
- Rename npm package scope @redsen -> @redsentech (GitHub Packages
  requires the scope to match the owning org/user login).
- Add publishConfig.registry pointing at npm.pkg.github.com.
- Add .github/workflows/publish.yml: on push of a vX.Y.Z tag (or manual
  dispatch), runs validate + test, checks the tag matches
  package.json's version, then npm publish using the auto-issued
  GITHUB_TOKEN (packages: write permission, no secret to manage).
- Update README/QUICKSTART lh-CLI install instructions for the private,
  org-scoped registry (.npmrc scope + auth token setup).
- Verified locally with npm publish --dry-run: 68 files, correct
  registry target, correct tarball contents.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-09-10 00:51:06 +02:00
mozempkandCopilot cadbec5797 docs: clarify manual vs automatic lh usage; lead with plugin install
- Add exhaustive table of every lh subcommand: who runs it automatically
  (agents, per their own instructions) vs what you run yourself (init,
  doctor, report).
- Reorder quickstart to lead with copilot plugin install (marketplace
  path, verified end-to-end on this machine), with onboarding script and
  clone+link as alternatives and explicit guidance on when to use each.
- Clarify the two-layer install model: plugin install only adds the
  behaviour layer; lh CLI (determinism layer) is a separate step until
  published to npm.
- README install section and troubleshooting table updated to match.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-09-10 00:46:17 +02:00
mozempkandCopilot 5ab8b59861 docs: add standalone quick start guide
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-09-10 00:11:30 +02:00
mozempkandCopilot 383129f571 feat: scaffold redsen-lean-harness v0.1.0
Recovered from crashed session (Node OOM). Repo contains full P0-P6
scaffold: plugin.json/marketplace.json, AGENTS.md, ADRs 0001-0006,
lh CLI (init/index/graph/lane/run/memory/host/report/doctor), 10
.github/agents, 12 CLI skills, instructions, context7 mcp.json, and
unit/e2e test suite.

Fixed: run.mjs read --in-tokens/--out-tokens but tests and CLI docs
use --input-tokens/--output-tokens, so telemetry totals were always 0.
Now accepts both forms.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-09-09 22:44:15 +02:00