@mrciphersmith/keryx 0.2.156 → 0.2.159
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.
- package/README.md +104 -43
- package/dist/cli.js +3285 -2349
- package/dist/core.js +632 -0
- package/package.json +1 -1
package/dist/core.js
CHANGED
|
@@ -26434,6 +26434,23 @@ init_service();
|
|
|
26434
26434
|
init_fs();
|
|
26435
26435
|
var exports_service10 = {};
|
|
26436
26436
|
__export(exports_service10, {
|
|
26437
|
+
HELP_DEFAULT_COLUMNS: () => HELP_DEFAULT_COLUMNS,
|
|
26438
|
+
HELP_GROUPS: () => HELP_GROUPS,
|
|
26439
|
+
HELP_GROUP_ORDER: () => HELP_GROUP_ORDER,
|
|
26440
|
+
HIDDEN_FROM_HELP: () => HIDDEN_FROM_HELP,
|
|
26441
|
+
allHelpTokens: () => allHelpTokens,
|
|
26442
|
+
closestHelpTopics: () => closestHelpTopics,
|
|
26443
|
+
entriesInGroup: () => entriesInGroup,
|
|
26444
|
+
findCliEntry: () => findCliEntry,
|
|
26445
|
+
findEntry: () => findEntry,
|
|
26446
|
+
findSlashEntry: () => findSlashEntry,
|
|
26447
|
+
groupBySlug: () => groupBySlug,
|
|
26448
|
+
renderCliGroupHelp: () => renderCliGroupHelp,
|
|
26449
|
+
renderCommandsByTaskMarkdown: () => renderCommandsByTaskMarkdown,
|
|
26450
|
+
renderEntryDetail: () => renderEntryDetail,
|
|
26451
|
+
renderGroupedCliHelp: () => renderGroupedCliHelp,
|
|
26452
|
+
renderGroupedNamedHelp: () => renderGroupedNamedHelp,
|
|
26453
|
+
renderGroupedSlashHelp: () => renderGroupedSlashHelp,
|
|
26437
26454
|
runCapabilities: () => runCapabilities,
|
|
26438
26455
|
runDoctor: () => runDoctor,
|
|
26439
26456
|
runValidate: () => runValidate
|
|
@@ -26918,6 +26935,621 @@ function extractCapabilities(manifest) {
|
|
|
26918
26935
|
};
|
|
26919
26936
|
}
|
|
26920
26937
|
|
|
26938
|
+
// src/standard/help-groups.ts
|
|
26939
|
+
var HELP_GROUP_ORDER = [
|
|
26940
|
+
{ name: "Start here", slug: "start-here" },
|
|
26941
|
+
{ name: "Connect a model provider", slug: "connect" },
|
|
26942
|
+
{ name: "Look and feel", slug: "look-and-feel" },
|
|
26943
|
+
{ name: "Working in keryx shell", slug: "shell-work" },
|
|
26944
|
+
{ name: "Project knowledge", slug: "project-knowledge" },
|
|
26945
|
+
{ name: "Managed work", slug: "managed-work" },
|
|
26946
|
+
{ name: "Automation", slug: "automation" },
|
|
26947
|
+
{ name: "External agents, ACP and MCP", slug: "external-agents" },
|
|
26948
|
+
{ name: "Maintenance and diagnostics", slug: "maintenance" }
|
|
26949
|
+
];
|
|
26950
|
+
var HELP_GROUPS = [
|
|
26951
|
+
{ kind: "cli", name: "init", group: "Start here", summary: "Initialize .metaproject in the current project." },
|
|
26952
|
+
{ kind: "cli", name: "status", group: "Start here", summary: "Show local Metaproject status." },
|
|
26953
|
+
{
|
|
26954
|
+
kind: "cli",
|
|
26955
|
+
name: "shell",
|
|
26956
|
+
group: "Start here",
|
|
26957
|
+
summary: "Start the interactive TUI agent harness (--no-tui or --chat to opt out)."
|
|
26958
|
+
},
|
|
26959
|
+
{
|
|
26960
|
+
kind: "cli",
|
|
26961
|
+
name: "help",
|
|
26962
|
+
group: "Start here",
|
|
26963
|
+
summary: "Grouped command help by task \u2014 keryx help [group|command]."
|
|
26964
|
+
},
|
|
26965
|
+
{ kind: "slash", name: "/help", group: "Start here", summary: "Show available commands, grouped by task." },
|
|
26966
|
+
{
|
|
26967
|
+
kind: "cli",
|
|
26968
|
+
name: "auth",
|
|
26969
|
+
group: "Connect a model provider",
|
|
26970
|
+
summary: "Subscription login (SuperGrok, ChatGPT Plus/Pro, GitHub Copilot) and API-key status."
|
|
26971
|
+
},
|
|
26972
|
+
{
|
|
26973
|
+
kind: "cli",
|
|
26974
|
+
name: "providers",
|
|
26975
|
+
group: "Connect a model provider",
|
|
26976
|
+
summary: "Providers this operator has configured, and cross-family review eligibility."
|
|
26977
|
+
},
|
|
26978
|
+
{ kind: "slash", name: "/connect", group: "Connect a model provider", summary: "Switch provider / API key." },
|
|
26979
|
+
{
|
|
26980
|
+
kind: "slash",
|
|
26981
|
+
name: "/search-provider",
|
|
26982
|
+
group: "Connect a model provider",
|
|
26983
|
+
summary: "Configure and test a web search provider."
|
|
26984
|
+
},
|
|
26985
|
+
{
|
|
26986
|
+
kind: "slash",
|
|
26987
|
+
name: "/search-connect",
|
|
26988
|
+
group: "Connect a model provider",
|
|
26989
|
+
summary: "Select a connected web search provider."
|
|
26990
|
+
},
|
|
26991
|
+
{
|
|
26992
|
+
kind: "slash",
|
|
26993
|
+
name: "/provider",
|
|
26994
|
+
group: "Connect a model provider",
|
|
26995
|
+
summary: "Switch provider \u2014 /provider <name>, or no arg to re-select."
|
|
26996
|
+
},
|
|
26997
|
+
{
|
|
26998
|
+
kind: "slash",
|
|
26999
|
+
name: "/theme",
|
|
27000
|
+
group: "Look and feel",
|
|
27001
|
+
summary: "Open the theme picker \u2014 /theme [name] applies immediately."
|
|
27002
|
+
},
|
|
27003
|
+
{ kind: "slash", name: "/model", group: "Look and feel", summary: "Switch the model." },
|
|
27004
|
+
{
|
|
27005
|
+
kind: "slash",
|
|
27006
|
+
name: "/models",
|
|
27007
|
+
group: "Look and feel",
|
|
27008
|
+
summary: "Pick a model for the current provider (numbered menu)."
|
|
27009
|
+
},
|
|
27010
|
+
{
|
|
27011
|
+
kind: "slash",
|
|
27012
|
+
name: "/mode",
|
|
27013
|
+
group: "Look and feel",
|
|
27014
|
+
summary: "Show or switch the permission mode \u2014 /mode [ask|trust|auto]."
|
|
27015
|
+
},
|
|
27016
|
+
{
|
|
27017
|
+
kind: "slash",
|
|
27018
|
+
name: "/think",
|
|
27019
|
+
group: "Look and feel",
|
|
27020
|
+
summary: "Expand the last reasoning block \u2014 /think [auto|expand|hide|collapse]."
|
|
27021
|
+
},
|
|
27022
|
+
{
|
|
27023
|
+
kind: "slash",
|
|
27024
|
+
name: "/reasoning",
|
|
27025
|
+
group: "Look and feel",
|
|
27026
|
+
summary: "Show or set reasoning effort \u2014 /reasoning [off|minimal|low|medium|high|xhigh|max]."
|
|
27027
|
+
},
|
|
27028
|
+
{ kind: "cli", name: "sessions", group: "Working in keryx shell", summary: "List or export per-project shell sessions." },
|
|
27029
|
+
{
|
|
27030
|
+
kind: "slash",
|
|
27031
|
+
name: "/sessions",
|
|
27032
|
+
group: "Working in keryx shell",
|
|
27033
|
+
summary: "Open the session list and switch to one."
|
|
27034
|
+
},
|
|
27035
|
+
{ kind: "slash", name: "/resume", group: "Working in keryx shell", summary: "Resume a prior session in this project." },
|
|
27036
|
+
{ kind: "slash", name: "/new", group: "Working in keryx shell", summary: "Start a new session (old kept on disk)." },
|
|
27037
|
+
{ kind: "slash", name: "/clear", group: "Working in keryx shell", summary: "New session (alias of /new)." },
|
|
27038
|
+
{
|
|
27039
|
+
kind: "slash",
|
|
27040
|
+
name: "/compact",
|
|
27041
|
+
group: "Working in keryx shell",
|
|
27042
|
+
summary: "Compact model context \u2014 /compact [focus] (archive kept)."
|
|
27043
|
+
},
|
|
27044
|
+
{
|
|
27045
|
+
kind: "slash",
|
|
27046
|
+
name: "/copy",
|
|
27047
|
+
group: "Working in keryx shell",
|
|
27048
|
+
summary: "Copy the newest transcript block to the clipboard."
|
|
27049
|
+
},
|
|
27050
|
+
{ kind: "slash", name: "/expand", group: "Working in keryx shell", summary: "Expand the last tool output block." },
|
|
27051
|
+
{
|
|
27052
|
+
kind: "slash",
|
|
27053
|
+
name: "/status",
|
|
27054
|
+
group: "Working in keryx shell",
|
|
27055
|
+
summary: "Show session identity, context window, limits, workspaces, and flows."
|
|
27056
|
+
},
|
|
27057
|
+
{
|
|
27058
|
+
kind: "slash",
|
|
27059
|
+
name: "/queue",
|
|
27060
|
+
group: "Working in keryx shell",
|
|
27061
|
+
summary: "Manage the main queue \u2014 /queue <remove|edit|force> [N] (N = qN position, default 1)."
|
|
27062
|
+
},
|
|
27063
|
+
{
|
|
27064
|
+
kind: "slash",
|
|
27065
|
+
name: "/interrupt",
|
|
27066
|
+
group: "Working in keryx shell",
|
|
27067
|
+
summary: "Interrupt the running main agent turn."
|
|
27068
|
+
},
|
|
27069
|
+
{ kind: "slash", name: "/exit", group: "Working in keryx shell", summary: "Leave the shell (/quit works too)." },
|
|
27070
|
+
{
|
|
27071
|
+
kind: "slash",
|
|
27072
|
+
name: "/game",
|
|
27073
|
+
group: "Working in keryx shell",
|
|
27074
|
+
summary: "Games against the model \u2014 /game [seconds] raises the model-turn deadline."
|
|
27075
|
+
},
|
|
27076
|
+
{ kind: "cli", name: "gdgraph", group: "Project knowledge", summary: "Build and query the code dependency graph." },
|
|
27077
|
+
{ kind: "cli", name: "ctx", group: "Project knowledge", summary: "Run compact context commands and save raw output." },
|
|
27078
|
+
{ kind: "cli", name: "wiki", group: "Project knowledge", summary: "Manage the local project knowledge base." },
|
|
27079
|
+
{ kind: "cli", name: "memory", group: "Project knowledge", summary: "Store and search long-term project memory." },
|
|
27080
|
+
{
|
|
27081
|
+
kind: "cli",
|
|
27082
|
+
name: "orient",
|
|
27083
|
+
group: "Project knowledge",
|
|
27084
|
+
summary: "Emit a bounded graph + wiki startup block, or install it as a turn-start hook."
|
|
27085
|
+
},
|
|
27086
|
+
{ kind: "cli", name: "skills", group: "Project knowledge", summary: "Manage bundled Metaproject working skills." },
|
|
27087
|
+
{ kind: "cli", name: "flow", group: "Managed work", summary: "Agent-first flow lifecycle (Task Manager)." },
|
|
27088
|
+
{
|
|
27089
|
+
kind: "cli",
|
|
27090
|
+
name: "job",
|
|
27091
|
+
group: "Managed work",
|
|
27092
|
+
summary: "Agent-first job packages (job-orchestrator state, steps, documents)."
|
|
27093
|
+
},
|
|
27094
|
+
{
|
|
27095
|
+
kind: "cli",
|
|
27096
|
+
name: "review",
|
|
27097
|
+
group: "Managed work",
|
|
27098
|
+
summary: "Managed review packages and lightweight report-only review mode."
|
|
27099
|
+
},
|
|
27100
|
+
{ kind: "slash", name: "/flows", group: "Managed work", summary: "Browse project flows and inspect one." },
|
|
27101
|
+
{
|
|
27102
|
+
kind: "slash",
|
|
27103
|
+
name: "/review",
|
|
27104
|
+
group: "Managed work",
|
|
27105
|
+
summary: "Show project-wide items needing review (proposals, blocked sessions)."
|
|
27106
|
+
},
|
|
27107
|
+
{ kind: "slash", name: "/plan", group: "Managed work", summary: "Toggle read-only mode \u2014 /plan [on|off]." },
|
|
27108
|
+
{
|
|
27109
|
+
kind: "slash",
|
|
27110
|
+
name: "/goal",
|
|
27111
|
+
group: "Managed work",
|
|
27112
|
+
summary: "Deterministically start a goal \u2014 /goal <text> [--workspace <id>] [--auto [N]]."
|
|
27113
|
+
},
|
|
27114
|
+
{
|
|
27115
|
+
kind: "cli",
|
|
27116
|
+
name: "trigger",
|
|
27117
|
+
group: "Automation",
|
|
27118
|
+
summary: "Fire one declared project trigger (git hook, cron line, CI job) \u2014 one pass, one exit code."
|
|
27119
|
+
},
|
|
27120
|
+
{
|
|
27121
|
+
kind: "cli",
|
|
27122
|
+
name: "schedule",
|
|
27123
|
+
group: "Automation",
|
|
27124
|
+
summary: "Scheduled agent tasks in the background: create (with confirmation), list, pause, resume, remove."
|
|
27125
|
+
},
|
|
27126
|
+
{
|
|
27127
|
+
kind: "cli",
|
|
27128
|
+
name: "governance",
|
|
27129
|
+
group: "Automation",
|
|
27130
|
+
summary: "Read-only report over already-recorded spend, confirmations, signatures and gate outcomes."
|
|
27131
|
+
},
|
|
27132
|
+
{
|
|
27133
|
+
kind: "slash",
|
|
27134
|
+
name: "/triggers",
|
|
27135
|
+
group: "Automation",
|
|
27136
|
+
summary: "Declared triggers: last outcome, spend, reservations \u2014 run one now."
|
|
27137
|
+
},
|
|
27138
|
+
{
|
|
27139
|
+
kind: "slash",
|
|
27140
|
+
name: "/schedule",
|
|
27141
|
+
group: "Automation",
|
|
27142
|
+
summary: "Schedule a background agent task \u2014 shows a confirmation card first (keryx schedule add)."
|
|
27143
|
+
},
|
|
27144
|
+
{
|
|
27145
|
+
kind: "slash",
|
|
27146
|
+
name: "/schedules",
|
|
27147
|
+
group: "Automation",
|
|
27148
|
+
summary: "Scheduled tasks: next run, last outcome, report \u2014 pause, resume, run now, delete."
|
|
27149
|
+
},
|
|
27150
|
+
{
|
|
27151
|
+
kind: "slash",
|
|
27152
|
+
name: "/governance",
|
|
27153
|
+
group: "Automation",
|
|
27154
|
+
summary: "Show the last governance report, or run one in the background."
|
|
27155
|
+
},
|
|
27156
|
+
{
|
|
27157
|
+
kind: "cli",
|
|
27158
|
+
name: "acp",
|
|
27159
|
+
group: "External agents, ACP and MCP",
|
|
27160
|
+
summary: "Speak ACP v1 (newline-delimited JSON-RPC) over stdio, for an ACP client (e.g. an editor)."
|
|
27161
|
+
},
|
|
27162
|
+
{
|
|
27163
|
+
kind: "cli",
|
|
27164
|
+
name: "agents",
|
|
27165
|
+
group: "External agents, ACP and MCP",
|
|
27166
|
+
summary: "Manage optional global agent bootstrap instructions."
|
|
27167
|
+
},
|
|
27168
|
+
{
|
|
27169
|
+
kind: "cli",
|
|
27170
|
+
name: "mcp",
|
|
27171
|
+
group: "External agents, ACP and MCP",
|
|
27172
|
+
summary: "Retired spelling of serve-mcp / integrate; still works, names its replacement."
|
|
27173
|
+
},
|
|
27174
|
+
{
|
|
27175
|
+
kind: "cli",
|
|
27176
|
+
name: "integrate",
|
|
27177
|
+
group: "External agents, ACP and MCP",
|
|
27178
|
+
summary: "Wire this project into an editor or agent as an MCP server."
|
|
27179
|
+
},
|
|
27180
|
+
{
|
|
27181
|
+
kind: "cli",
|
|
27182
|
+
name: "serve-mcp",
|
|
27183
|
+
group: "External agents, ACP and MCP",
|
|
27184
|
+
summary: "Expose Metaproject services over the Model Context Protocol (opt-in)."
|
|
27185
|
+
},
|
|
27186
|
+
{
|
|
27187
|
+
kind: "cli",
|
|
27188
|
+
name: "bus",
|
|
27189
|
+
group: "External agents, ACP and MCP",
|
|
27190
|
+
summary: "Agent bus: list peers and leases, read the log, send a message, prune."
|
|
27191
|
+
},
|
|
27192
|
+
{
|
|
27193
|
+
kind: "cli",
|
|
27194
|
+
name: "workspace",
|
|
27195
|
+
group: "External agents, ACP and MCP",
|
|
27196
|
+
summary: "Shared Agent Context: workspaces, FWK reads, propose/review (module sac)."
|
|
27197
|
+
},
|
|
27198
|
+
{
|
|
27199
|
+
kind: "slash",
|
|
27200
|
+
name: "/delegate",
|
|
27201
|
+
group: "External agents, ACP and MCP",
|
|
27202
|
+
summary: "Hand a task to an external agent CLI \u2014 /delegate <agent> <task>."
|
|
27203
|
+
},
|
|
27204
|
+
{
|
|
27205
|
+
kind: "slash",
|
|
27206
|
+
name: "/demote",
|
|
27207
|
+
group: "External agents, ACP and MCP",
|
|
27208
|
+
summary: "Move a running foreground task to the background \u2014 /demote <task_id>."
|
|
27209
|
+
},
|
|
27210
|
+
{
|
|
27211
|
+
kind: "slash",
|
|
27212
|
+
name: "/mcp",
|
|
27213
|
+
group: "External agents, ACP and MCP",
|
|
27214
|
+
summary: "MCP servers keryx is connected to \u2014 status, connect/disconnect."
|
|
27215
|
+
},
|
|
27216
|
+
{
|
|
27217
|
+
kind: "slash",
|
|
27218
|
+
name: "/integrations",
|
|
27219
|
+
group: "External agents, ACP and MCP",
|
|
27220
|
+
summary: "Wire this project into an editor over MCP (keryx integrate)."
|
|
27221
|
+
},
|
|
27222
|
+
{
|
|
27223
|
+
kind: "slash",
|
|
27224
|
+
name: "/bus",
|
|
27225
|
+
group: "External agents, ACP and MCP",
|
|
27226
|
+
summary: "Message or view peers on the project agent bus \u2014 /bus @<name> <text>."
|
|
27227
|
+
},
|
|
27228
|
+
{
|
|
27229
|
+
kind: "slash",
|
|
27230
|
+
name: "/workspace",
|
|
27231
|
+
group: "External agents, ACP and MCP",
|
|
27232
|
+
summary: "Show this session's SAC workspace and its slates."
|
|
27233
|
+
},
|
|
27234
|
+
{
|
|
27235
|
+
kind: "cli",
|
|
27236
|
+
name: "health",
|
|
27237
|
+
group: "Maintenance and diagnostics",
|
|
27238
|
+
summary: "Aggregate code quality signals and run the quality gate."
|
|
27239
|
+
},
|
|
27240
|
+
{
|
|
27241
|
+
kind: "cli",
|
|
27242
|
+
name: "test",
|
|
27243
|
+
group: "Maintenance and diagnostics",
|
|
27244
|
+
summary: "Analyze testing context and normalize test reports."
|
|
27245
|
+
},
|
|
27246
|
+
{
|
|
27247
|
+
kind: "cli",
|
|
27248
|
+
name: "standard",
|
|
27249
|
+
group: "Maintenance and diagnostics",
|
|
27250
|
+
summary: "Validate the workspace against the Metaproject Standard."
|
|
27251
|
+
},
|
|
27252
|
+
{
|
|
27253
|
+
kind: "cli",
|
|
27254
|
+
name: "update",
|
|
27255
|
+
group: "Maintenance and diagnostics",
|
|
27256
|
+
summary: "Refresh managed service files without touching data artifacts."
|
|
27257
|
+
},
|
|
27258
|
+
{
|
|
27259
|
+
kind: "cli",
|
|
27260
|
+
name: "sync",
|
|
27261
|
+
group: "Maintenance and diagnostics",
|
|
27262
|
+
summary: "Reconcile graph/wiki/memory with the current code, and wire the git hooks."
|
|
27263
|
+
},
|
|
27264
|
+
{
|
|
27265
|
+
kind: "cli",
|
|
27266
|
+
name: "security",
|
|
27267
|
+
group: "Maintenance and diagnostics",
|
|
27268
|
+
summary: "Policy-based scanning, redaction, guardrails and audit reports."
|
|
27269
|
+
},
|
|
27270
|
+
{
|
|
27271
|
+
kind: "cli",
|
|
27272
|
+
name: "dashboard",
|
|
27273
|
+
group: "Maintenance and diagnostics",
|
|
27274
|
+
summary: "Build or open the project admin dashboard."
|
|
27275
|
+
},
|
|
27276
|
+
{
|
|
27277
|
+
kind: "cli",
|
|
27278
|
+
name: "dash",
|
|
27279
|
+
group: "Maintenance and diagnostics",
|
|
27280
|
+
summary: "Rebuild and open .metaproject/keryx-dashboard.html."
|
|
27281
|
+
},
|
|
27282
|
+
{
|
|
27283
|
+
kind: "cli",
|
|
27284
|
+
name: "metrics",
|
|
27285
|
+
group: "Maintenance and diagnostics",
|
|
27286
|
+
summary: "Provenance-aware execution observability: run records, baselines, benchmarks."
|
|
27287
|
+
},
|
|
27288
|
+
{
|
|
27289
|
+
kind: "cli",
|
|
27290
|
+
name: "sandbox",
|
|
27291
|
+
group: "Maintenance and diagnostics",
|
|
27292
|
+
summary: "Report OS sandbox launcher availability and the per-capability containment matrix."
|
|
27293
|
+
},
|
|
27294
|
+
{
|
|
27295
|
+
kind: "cli",
|
|
27296
|
+
name: "modules",
|
|
27297
|
+
group: "Maintenance and diagnostics",
|
|
27298
|
+
summary: "View and toggle Metaproject modules (interactive)."
|
|
27299
|
+
},
|
|
27300
|
+
{
|
|
27301
|
+
kind: "cli",
|
|
27302
|
+
name: "projects",
|
|
27303
|
+
group: "Maintenance and diagnostics",
|
|
27304
|
+
summary: "Inspect the user-global registry of initialized projects."
|
|
27305
|
+
},
|
|
27306
|
+
{
|
|
27307
|
+
kind: "cli",
|
|
27308
|
+
name: "serve",
|
|
27309
|
+
group: "Maintenance and diagnostics",
|
|
27310
|
+
summary: "Loopback-bound authenticated HTTP entry (off by default; read-only routes)."
|
|
27311
|
+
},
|
|
27312
|
+
{
|
|
27313
|
+
kind: "cli",
|
|
27314
|
+
name: "rules",
|
|
27315
|
+
group: "Maintenance and diagnostics",
|
|
27316
|
+
summary: "Sync root AGENTS.md/CLAUDE.md into high-priority project rules."
|
|
27317
|
+
},
|
|
27318
|
+
{
|
|
27319
|
+
kind: "cli",
|
|
27320
|
+
name: "harness",
|
|
27321
|
+
group: "Maintenance and diagnostics",
|
|
27322
|
+
summary: "Run a single provider turn (harness run) and print structured events."
|
|
27323
|
+
},
|
|
27324
|
+
{
|
|
27325
|
+
kind: "cli",
|
|
27326
|
+
name: "version",
|
|
27327
|
+
group: "Maintenance and diagnostics",
|
|
27328
|
+
summary: "Check whether a newer npm release is available."
|
|
27329
|
+
},
|
|
27330
|
+
{
|
|
27331
|
+
kind: "cli",
|
|
27332
|
+
name: "retention",
|
|
27333
|
+
group: "Maintenance and diagnostics",
|
|
27334
|
+
summary: "Bound stores that grow without bound (gdctx raw/artifacts, owner write-conflict sidecars)."
|
|
27335
|
+
},
|
|
27336
|
+
{
|
|
27337
|
+
kind: "cli",
|
|
27338
|
+
name: "forgetting",
|
|
27339
|
+
group: "Maintenance and diagnostics",
|
|
27340
|
+
summary: "Read the deletion trail \u2014 was this removed, or did it never exist?"
|
|
27341
|
+
},
|
|
27342
|
+
{
|
|
27343
|
+
kind: "cli",
|
|
27344
|
+
name: "commands",
|
|
27345
|
+
group: "Maintenance and diagnostics",
|
|
27346
|
+
summary: "Agent-callable command registry (intents, args, output, model usage)."
|
|
27347
|
+
}
|
|
27348
|
+
];
|
|
27349
|
+
var HIDDEN_FROM_HELP = [
|
|
27350
|
+
{
|
|
27351
|
+
verb: "__sandbox-net-forward",
|
|
27352
|
+
reason: "internal helper keryx starts inside the unattended sandbox to bridge a local port to the allowlist proxy's socket; never typed by an operator (see the file header on src/commands/sandbox-net-forward.ts and its DOCUMENTED_ELSEWHERE entry in cli-reference-coverage.test.ts)"
|
|
27353
|
+
},
|
|
27354
|
+
{
|
|
27355
|
+
verb: "session",
|
|
27356
|
+
reason: "alias of `sessions`; cli.ts's own flat `Commands:` block omits it too (only `sessions` is listed there, with no inline alias mention)"
|
|
27357
|
+
},
|
|
27358
|
+
{
|
|
27359
|
+
verb: "skill-verify-skill",
|
|
27360
|
+
reason: "standalone alias of `skills verify`; cli.ts's own flat `Commands:` block omits it too (only `skills` is listed there), matching command-registry.coverage.test.ts's EXCLUSIONS reason for the same verb (\"standalone alias of skills verify; not part of the agent surface\")"
|
|
27361
|
+
}
|
|
27362
|
+
];
|
|
27363
|
+
function groupBySlug(token) {
|
|
27364
|
+
const lower = token.trim().toLowerCase();
|
|
27365
|
+
return HELP_GROUP_ORDER.find((g) => g.slug === lower);
|
|
27366
|
+
}
|
|
27367
|
+
function entriesInGroup(group, kind) {
|
|
27368
|
+
return HELP_GROUPS.filter((e) => e.group === group && (kind === undefined || e.kind === kind));
|
|
27369
|
+
}
|
|
27370
|
+
function findEntry(kind, name) {
|
|
27371
|
+
return HELP_GROUPS.find((e) => e.kind === kind && e.name === name);
|
|
27372
|
+
}
|
|
27373
|
+
function findCliEntry(name) {
|
|
27374
|
+
return findEntry("cli", name);
|
|
27375
|
+
}
|
|
27376
|
+
function findSlashEntry(name) {
|
|
27377
|
+
return findEntry("slash", name);
|
|
27378
|
+
}
|
|
27379
|
+
var HELP_DEFAULT_COLUMNS = 80;
|
|
27380
|
+
var MIN_WRAP_COLUMNS = 10;
|
|
27381
|
+
function wrapWords(line, budget) {
|
|
27382
|
+
const out = [];
|
|
27383
|
+
let cur = "";
|
|
27384
|
+
for (const word of line.split(/\s+/).filter(Boolean)) {
|
|
27385
|
+
if (cur.length > 0 && cur.length + 1 + word.length > budget) {
|
|
27386
|
+
out.push(cur);
|
|
27387
|
+
cur = word;
|
|
27388
|
+
} else {
|
|
27389
|
+
cur = cur.length > 0 ? `${cur} ${word}` : word;
|
|
27390
|
+
}
|
|
27391
|
+
}
|
|
27392
|
+
out.push(cur);
|
|
27393
|
+
return out.length > 0 ? out : [""];
|
|
27394
|
+
}
|
|
27395
|
+
function renderEntryRows(entries, maxColumns) {
|
|
27396
|
+
if (entries.length === 0) {
|
|
27397
|
+
return [];
|
|
27398
|
+
}
|
|
27399
|
+
const width = entries.reduce((w, e) => Math.max(w, e.name.length), 0);
|
|
27400
|
+
const descColumn = width + 4;
|
|
27401
|
+
const wrapBudget = maxColumns === undefined ? undefined : Math.max(MIN_WRAP_COLUMNS, maxColumns - descColumn);
|
|
27402
|
+
const rows = [];
|
|
27403
|
+
for (const entry of entries) {
|
|
27404
|
+
const wrapped = wrapBudget === undefined ? [entry.summary] : wrapWords(entry.summary, wrapBudget);
|
|
27405
|
+
wrapped.forEach((line, i) => {
|
|
27406
|
+
rows.push(i === 0 ? ` ${entry.name.padEnd(width)} ${line}`.trimEnd() : `${" ".repeat(descColumn)}${line}`.trimEnd());
|
|
27407
|
+
});
|
|
27408
|
+
}
|
|
27409
|
+
return rows;
|
|
27410
|
+
}
|
|
27411
|
+
function renderGroupedCliHelp(maxColumns = HELP_DEFAULT_COLUMNS) {
|
|
27412
|
+
const lines = [];
|
|
27413
|
+
for (const group of HELP_GROUP_ORDER) {
|
|
27414
|
+
const entries = entriesInGroup(group.name, "cli");
|
|
27415
|
+
if (entries.length === 0) {
|
|
27416
|
+
continue;
|
|
27417
|
+
}
|
|
27418
|
+
lines.push(`${group.name}:`);
|
|
27419
|
+
lines.push(...renderEntryRows(entries, maxColumns));
|
|
27420
|
+
lines.push("");
|
|
27421
|
+
}
|
|
27422
|
+
return lines.join(`
|
|
27423
|
+
`).replace(/\n+$/, `
|
|
27424
|
+
`);
|
|
27425
|
+
}
|
|
27426
|
+
function renderCliGroupHelp(group, maxColumns = HELP_DEFAULT_COLUMNS) {
|
|
27427
|
+
const entries = entriesInGroup(group.name, "cli");
|
|
27428
|
+
const lines = [`${group.name}:`, ...renderEntryRows(entries, maxColumns)];
|
|
27429
|
+
return lines.join(`
|
|
27430
|
+
`) + `
|
|
27431
|
+
`;
|
|
27432
|
+
}
|
|
27433
|
+
function renderGroupedSlashHelp(allow, maxColumns) {
|
|
27434
|
+
const allowed = new Set(allow);
|
|
27435
|
+
const lines = ["Commands:"];
|
|
27436
|
+
for (const group of HELP_GROUP_ORDER) {
|
|
27437
|
+
const entries = entriesInGroup(group.name, "slash").filter((e) => allowed.has(e.name));
|
|
27438
|
+
if (entries.length === 0) {
|
|
27439
|
+
continue;
|
|
27440
|
+
}
|
|
27441
|
+
lines.push("", `${group.name}:`);
|
|
27442
|
+
lines.push(...renderEntryRows(entries, maxColumns));
|
|
27443
|
+
}
|
|
27444
|
+
return lines.join(`
|
|
27445
|
+
`) + `
|
|
27446
|
+
`;
|
|
27447
|
+
}
|
|
27448
|
+
function renderGroupedNamedHelp(options, maxColumns) {
|
|
27449
|
+
const lines = ["Commands:"];
|
|
27450
|
+
for (const group of HELP_GROUP_ORDER) {
|
|
27451
|
+
const rows = options.filter((o) => findEntry("slash", o.name)?.group === group.name).map((o) => ({ kind: "slash", name: o.name, group: group.name, summary: o.description }));
|
|
27452
|
+
if (rows.length === 0) {
|
|
27453
|
+
continue;
|
|
27454
|
+
}
|
|
27455
|
+
lines.push("", `${group.name}:`);
|
|
27456
|
+
lines.push(...renderEntryRows(rows, maxColumns));
|
|
27457
|
+
}
|
|
27458
|
+
return lines.join(`
|
|
27459
|
+
`) + `
|
|
27460
|
+
`;
|
|
27461
|
+
}
|
|
27462
|
+
function renderEntryDetail(entry) {
|
|
27463
|
+
const lines = [`${entry.name}`, "", entry.summary, ""];
|
|
27464
|
+
if (entry.kind === "slash") {
|
|
27465
|
+
lines.push("This is a keryx shell command \u2014 type it inside `keryx shell` (readline chat/agent mode, or the", "TUI's `/`-menu). It has no standalone CLI form.");
|
|
27466
|
+
} else {
|
|
27467
|
+
lines.push(`Run \`keryx ${entry.name} --help\` (or \`keryx help ${entry.name}\`) for its full usage.`);
|
|
27468
|
+
}
|
|
27469
|
+
return lines.join(`
|
|
27470
|
+
`) + `
|
|
27471
|
+
`;
|
|
27472
|
+
}
|
|
27473
|
+
function mdCell(text) {
|
|
27474
|
+
return text.replace(/\|/g, "\\|");
|
|
27475
|
+
}
|
|
27476
|
+
function renderCommandsByTaskMarkdown() {
|
|
27477
|
+
const lines = [
|
|
27478
|
+
"# Commands by task",
|
|
27479
|
+
"",
|
|
27480
|
+
"Every `keryx` CLI verb and every `keryx shell` command, grouped by task \u2014 " + "the same grouping `keryx help` and the OpenTUI shell's `/help` modal use " + "(`src/standard/help-groups.ts`, flow 303).",
|
|
27481
|
+
"",
|
|
27482
|
+
"Generated. Do not hand-edit: regenerate with " + "`bun scripts/generate-commands-by-task.ts`, and " + "`src/standard/commands-by-task.test.ts` fails when this page drifts from " + "the table it is generated from.",
|
|
27483
|
+
""
|
|
27484
|
+
];
|
|
27485
|
+
for (const group of HELP_GROUP_ORDER) {
|
|
27486
|
+
const cli = entriesInGroup(group.name, "cli");
|
|
27487
|
+
const slash = entriesInGroup(group.name, "slash");
|
|
27488
|
+
if (cli.length === 0 && slash.length === 0) {
|
|
27489
|
+
continue;
|
|
27490
|
+
}
|
|
27491
|
+
lines.push(`## ${group.name}`, "");
|
|
27492
|
+
if (cli.length > 0) {
|
|
27493
|
+
lines.push("| CLI command | Summary |", "|---|---|");
|
|
27494
|
+
for (const entry of cli) {
|
|
27495
|
+
lines.push(`| \`keryx ${mdCell(entry.name)}\` | ${mdCell(entry.summary)} |`);
|
|
27496
|
+
}
|
|
27497
|
+
lines.push("");
|
|
27498
|
+
}
|
|
27499
|
+
if (slash.length > 0) {
|
|
27500
|
+
lines.push("| Shell command | Summary |", "|---|---|");
|
|
27501
|
+
for (const entry of slash) {
|
|
27502
|
+
lines.push(`| \`${mdCell(entry.name)}\` | ${mdCell(entry.summary)} |`);
|
|
27503
|
+
}
|
|
27504
|
+
lines.push("");
|
|
27505
|
+
}
|
|
27506
|
+
}
|
|
27507
|
+
return lines.join(`
|
|
27508
|
+
`).replace(/\n+$/, `
|
|
27509
|
+
`);
|
|
27510
|
+
}
|
|
27511
|
+
function levenshtein(a, b) {
|
|
27512
|
+
const rows = a.length + 1;
|
|
27513
|
+
const cols = b.length + 1;
|
|
27514
|
+
const dp = Array.from({ length: rows }, () => new Array(cols).fill(0));
|
|
27515
|
+
for (let i = 0;i < rows; i += 1) {
|
|
27516
|
+
const row = dp[i];
|
|
27517
|
+
if (row !== undefined)
|
|
27518
|
+
row[0] = i;
|
|
27519
|
+
}
|
|
27520
|
+
const first = dp[0];
|
|
27521
|
+
if (first !== undefined) {
|
|
27522
|
+
for (let j = 0;j < cols; j += 1)
|
|
27523
|
+
first[j] = j;
|
|
27524
|
+
}
|
|
27525
|
+
for (let i = 1;i < rows; i += 1) {
|
|
27526
|
+
for (let j = 1;j < cols; j += 1) {
|
|
27527
|
+
const same = a[i - 1] === b[j - 1];
|
|
27528
|
+
const up = dp[i - 1]?.[j] ?? 0;
|
|
27529
|
+
const left = dp[i]?.[j - 1] ?? 0;
|
|
27530
|
+
const diag = dp[i - 1]?.[j - 1] ?? 0;
|
|
27531
|
+
const row = dp[i];
|
|
27532
|
+
if (row !== undefined)
|
|
27533
|
+
row[j] = same ? diag : 1 + Math.min(up, left, diag);
|
|
27534
|
+
}
|
|
27535
|
+
}
|
|
27536
|
+
return dp[rows - 1]?.[cols - 1] ?? Math.max(a.length, b.length);
|
|
27537
|
+
}
|
|
27538
|
+
function allHelpTokens() {
|
|
27539
|
+
return [
|
|
27540
|
+
...HELP_GROUP_ORDER.map((g) => g.slug),
|
|
27541
|
+
...HELP_GROUPS.map((e) => e.name)
|
|
27542
|
+
];
|
|
27543
|
+
}
|
|
27544
|
+
function closestHelpTopics(query, limit = 3) {
|
|
27545
|
+
const needle = query.trim().toLowerCase();
|
|
27546
|
+
if (needle.length === 0) {
|
|
27547
|
+
return [];
|
|
27548
|
+
}
|
|
27549
|
+
const threshold = Math.max(2, Math.ceil(needle.length / 2));
|
|
27550
|
+
return [...new Set(allHelpTokens())].map((candidate) => ({ candidate, distance: levenshtein(needle, candidate.toLowerCase()) })).filter((entry) => entry.distance <= threshold).sort((a, b) => a.distance - b.distance || a.candidate.localeCompare(b.candidate)).slice(0, limit).map((entry) => entry.candidate);
|
|
27551
|
+
}
|
|
27552
|
+
|
|
26921
27553
|
// src/standard/service.ts
|
|
26922
27554
|
async function runValidate(cwd) {
|
|
26923
27555
|
return validateWorkspace2(cwd);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mrciphersmith/keryx",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.159",
|
|
4
4
|
"description": "Version-controlled project context for AI coding agents: code graph, architecture wiki, project memory, relevant tests, quality signals, and task flows.",
|
|
5
5
|
"private": false,
|
|
6
6
|
"publishConfig": {
|