the-high-council 0.7.6 → 0.7.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (46) hide show
  1. package/.env.example +5 -0
  2. package/CONTRIBUTING.md +3 -3
  3. package/PERSONAS.md +4 -0
  4. package/README.md +290 -130
  5. package/TROUBLESHOOTING.md +68 -0
  6. package/chains/mock-criteria-kinds.json +19 -0
  7. package/chains/mock-tiered.json +43 -0
  8. package/chains/plan-highest-7.json +45 -0
  9. package/chains/verify.json +1 -1
  10. package/package.json +18 -3
  11. package/schemas/report-v1.json +815 -0
  12. package/schemas/verdict-diff.json +41 -0
  13. package/src/api.js +190 -0
  14. package/src/argued.js +286 -0
  15. package/src/chain-lint.js +180 -6
  16. package/src/chain-name.js +18 -0
  17. package/src/chain.js +491 -89
  18. package/src/cli.js +303 -87
  19. package/src/context-files.js +47 -0
  20. package/src/cost.js +128 -8
  21. package/src/council-replay.js +11 -2
  22. package/src/criteria-kinds.js +169 -0
  23. package/src/deep-dive.js +143 -0
  24. package/src/denied-models.js +9 -5
  25. package/src/fence.js +28 -1
  26. package/src/invocation.js +25 -0
  27. package/src/mcp/server.js +145 -30
  28. package/src/mock-demo.js +237 -0
  29. package/src/outcome.js +2 -1
  30. package/src/policy.js +6 -1
  31. package/src/pricing.json +42 -13
  32. package/src/providers.js +169 -6
  33. package/src/quote-check.js +27 -4
  34. package/src/rematch.js +45 -20
  35. package/src/report-shape.js +115 -9
  36. package/src/roles.js +199 -18
  37. package/src/run-state.js +4 -1
  38. package/src/run-status.js +5 -0
  39. package/src/stage-contract.js +12 -0
  40. package/src/terminal-safe.js +14 -0
  41. package/src/tools.js +8 -0
  42. package/src/ui/app.js +26 -22
  43. package/src/ui/server.js +40 -8
  44. package/src/version.js +10 -3
  45. package/types/index.d.ts +122 -0
  46. package/src/http-server.js +0 -349
package/.env.example CHANGED
@@ -16,3 +16,8 @@ ZAI_API_KEY=
16
16
  # resumes with a higher ceiling. Unset means $7. Use --max-usd none to run
17
17
  # without a ceiling.
18
18
  MAX_USD_PER_RUN=7
19
+
20
+ # Optional settings (README "Setup" lists them all): COUNCIL_WORKDIR and
21
+ # COUNCIL_MAX_USD_LIMIT for the MCP server, COUNCIL_ALLOW_LOOPBACK_KEY_HOST=1
22
+ # for a local proxy in front of a keyed provider, OLLAMA_API_KEY,
23
+ # COUNCIL_PERSONAS_FILE, AUDIT_HMAC_KEY_FILE.
package/CONTRIBUTING.md CHANGED
@@ -14,9 +14,9 @@ discussion first.
14
14
  in `node --test`, real calls are opt-in and cost real money.
15
15
 
16
16
  2. **A new chain config** (`chains/*.json`). A chain is data, not code - it names which seats run
17
- which stages. `council doctor` validates any chain you add against every shipped-provider's key
18
- presence and prices it worst-case with zero network calls; run that against your new file
19
- before opening a PR. Look at `chains/plan-debate.json` or `chains/verify.json` as a starting
17
+ which stages. `council doctor --chain chains/<yours>.json` lints it (the same rules every run
18
+ applies, including the denied-model and `key-host` rules), and `council doctor` prices it
19
+ worst-case, both with zero network calls; run both against your new file before opening a PR. Look at `chains/plan-debate.json` or `chains/verify.json` as a starting
20
20
  shape depending on whether you want a debate-and-panel chain or a single-critic chain.
21
21
 
22
22
  3. **A new mock fixture** (`src/providers.js`'s `callMock`, exercised from `test/*.test.js`). If
package/PERSONAS.md CHANGED
@@ -24,6 +24,10 @@ from the same public-domain legend and is not itself claimed as anyone's tradema
24
24
  here is a secondary association in a reader's mind, not a legal one - worth having on the record,
25
25
  not worth revisiting a decision already made.
26
26
 
27
+ A `role.persona` key that is not in the set in use is sent as a bare name, with no voice
28
+ directive. `plan-premium-7` seats two such keys, `hypatia` and `avicenna`, next to the five
29
+ defaults: without a persona file of your own they reach the debate prompt as those names alone.
30
+
27
31
  **You can replace the whole set.** `loadPersonas()` in `src/personas.js` reads an operator-supplied
28
32
  JSON file (path via the `COUNCIL_PERSONAS_FILE` environment variable, or passed directly) and uses
29
33
  it in place of the default five entirely - nothing in this repo needs editing to do that. A