@karmaniverous/jeeves-watcher-openclaw 0.15.4 → 0.15.5

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/dist/cli.js CHANGED
@@ -27068,12 +27068,12 @@ const vcsConfigSchema = object$1({
27068
27068
  author: vcsAuthorConfigSchema
27069
27069
  .optional()
27070
27070
  .describe('Git commit author identity. Set per-repo during init. Defaults: name="jeeves-watcher", email="watcher@localhost".'),
27071
- /** Debounce interval in milliseconds for batching commits. */
27072
- commitDebounceMs: number$2()
27071
+ /** Throttle interval in milliseconds for batching commits. */
27072
+ commitThrottleMs: number$2()
27073
27073
  .int()
27074
27074
  .min(1000)
27075
27075
  .default(30000)
27076
- .describe('Debounce interval in milliseconds for batching commits. Default: 30000.'),
27076
+ .describe('Throttle interval in milliseconds for batching commits. Default: 30000.'),
27077
27077
  /** Maximum number of files per commit batch. */
27078
27078
  maxBatchSize: number$2()
27079
27079
  .int()
package/dist/index.js CHANGED
@@ -27005,6 +27005,197 @@ const DEFAULT_PORT = DEFAULT_PORTS.watcher;
27005
27005
  ({
27006
27006
  port: DEFAULT_PORTS.watcher});
27007
27007
 
27008
+ /**
27009
+ * Shared endpoint catalog — single source of truth for the jeeves-watcher API.
27010
+ *
27011
+ * Both the CLI service and the OpenClaw plugin derive their registrations
27012
+ * from this declarative catalog, eliminating drift between the two.
27013
+ *
27014
+ */
27015
+ /**
27016
+ * Canonical endpoint catalog for the jeeves-watcher API.
27017
+ *
27018
+ * Every entry describes a single HTTP endpoint exposed by the service.
27019
+ * Route handlers, plugin tools, and HTTP clients should reference these
27020
+ * descriptors rather than hard-coding paths and descriptions.
27021
+ */
27022
+ const WATCHER_ENDPOINTS = [
27023
+ {
27024
+ name: 'status',
27025
+ method: 'GET',
27026
+ path: '/status',
27027
+ description: 'Service health and status overview.',
27028
+ },
27029
+ {
27030
+ name: 'metadata',
27031
+ method: 'POST',
27032
+ path: '/metadata',
27033
+ description: 'Set or update metadata on a document by file path.',
27034
+ },
27035
+ {
27036
+ name: 'render',
27037
+ method: 'POST',
27038
+ path: '/render',
27039
+ description: 'Render a document through the template pipeline.',
27040
+ },
27041
+ {
27042
+ name: 'searchFacets',
27043
+ method: 'GET',
27044
+ path: '/search/facets',
27045
+ description: 'List available search facets and their values.',
27046
+ },
27047
+ {
27048
+ name: 'scan',
27049
+ method: 'POST',
27050
+ path: '/scan',
27051
+ description: 'Filter-only point query without vector search. Returns metadata for points matching a Qdrant filter.',
27052
+ },
27053
+ {
27054
+ name: 'walk',
27055
+ method: 'POST',
27056
+ path: '/walk',
27057
+ description: 'Walk watched filesystem paths with glob intersection. Returns matching file paths.',
27058
+ },
27059
+ {
27060
+ name: 'search',
27061
+ method: 'POST',
27062
+ path: '/search',
27063
+ description: 'Semantic search over indexed documents. Supports Qdrant filters.',
27064
+ },
27065
+ {
27066
+ name: 'rebuildMetadata',
27067
+ method: 'POST',
27068
+ path: '/rebuild-metadata',
27069
+ description: 'Rebuild metadata from enrichment store into vector points.',
27070
+ },
27071
+ {
27072
+ name: 'reindex',
27073
+ method: 'POST',
27074
+ path: '/reindex',
27075
+ description: 'Trigger a scoped reindex of watched files.',
27076
+ },
27077
+ {
27078
+ name: 'issues',
27079
+ method: 'GET',
27080
+ path: '/issues',
27081
+ description: 'Get runtime embedding failures. Shows files that failed processing and why.',
27082
+ },
27083
+ {
27084
+ name: 'configSchema',
27085
+ method: 'GET',
27086
+ path: '/config/schema',
27087
+ description: 'Get the JSON Schema for the configuration file.',
27088
+ },
27089
+ {
27090
+ name: 'configMatch',
27091
+ method: 'POST',
27092
+ path: '/config/match',
27093
+ description: 'Test file paths against config inference rules.',
27094
+ },
27095
+ {
27096
+ name: 'config',
27097
+ method: 'GET',
27098
+ path: '/config',
27099
+ description: 'Query service configuration with optional JSONPath.',
27100
+ },
27101
+ {
27102
+ name: 'configValidate',
27103
+ method: 'POST',
27104
+ path: '/config/validate',
27105
+ description: 'Validate a candidate config. Optionally test file paths against the config.',
27106
+ },
27107
+ {
27108
+ name: 'configApply',
27109
+ method: 'POST',
27110
+ path: '/config/apply',
27111
+ description: 'Apply a configuration patch.',
27112
+ },
27113
+ {
27114
+ name: 'rulesRegister',
27115
+ method: 'POST',
27116
+ path: '/rules/register',
27117
+ description: 'Register external inference rules.',
27118
+ },
27119
+ {
27120
+ name: 'rulesUnregister',
27121
+ method: 'DELETE',
27122
+ path: '/rules/unregister',
27123
+ description: 'Unregister external inference rules.',
27124
+ },
27125
+ {
27126
+ name: 'rulesUnregisterBySource',
27127
+ method: 'DELETE',
27128
+ path: '/rules/unregister/:source',
27129
+ description: 'Unregister all external inference rules from a source.',
27130
+ },
27131
+ {
27132
+ name: 'pointsDelete',
27133
+ method: 'POST',
27134
+ path: '/points/delete',
27135
+ description: 'Delete points from the vector store by filter.',
27136
+ },
27137
+ {
27138
+ name: 'rulesReapply',
27139
+ method: 'POST',
27140
+ path: '/rules/reapply',
27141
+ description: 'Re-apply inference rules to existing vector points.',
27142
+ },
27143
+ {
27144
+ name: 'vcsStatus',
27145
+ method: 'GET',
27146
+ path: '/vcs/status',
27147
+ description: 'VCS state for all roots: enabled state, tracked files, last commit, remote status.',
27148
+ },
27149
+ {
27150
+ name: 'vcsHistory',
27151
+ method: 'GET',
27152
+ path: '/vcs/history',
27153
+ description: 'Query change history by path or glob with optional date range.',
27154
+ },
27155
+ {
27156
+ name: 'vcsShow',
27157
+ method: 'GET',
27158
+ path: '/vcs/show',
27159
+ description: 'Retrieve file content at a specific version.',
27160
+ },
27161
+ {
27162
+ name: 'vcsDiff',
27163
+ method: 'GET',
27164
+ path: '/vcs/diff',
27165
+ description: 'Show what changed between two versions, or between a version and current.',
27166
+ },
27167
+ {
27168
+ name: 'vcsCheckExclusion',
27169
+ method: 'GET',
27170
+ path: '/vcs/check-exclusion',
27171
+ description: 'Check whether a path is excluded from version tracking and why.',
27172
+ },
27173
+ {
27174
+ name: 'vcsRevert',
27175
+ method: 'POST',
27176
+ path: '/vcs/revert',
27177
+ description: 'Restore files from a historical commit (forward-only reversion).',
27178
+ },
27179
+ {
27180
+ name: 'vcsExclude',
27181
+ method: 'POST',
27182
+ path: '/vcs/exclude',
27183
+ description: 'Manage .gitignore entries for version tracking exclusion.',
27184
+ },
27185
+ ];
27186
+ /**
27187
+ * Look up an endpoint descriptor by name.
27188
+ *
27189
+ * @param name - The endpoint identifier.
27190
+ * @returns The matching {@link EndpointDescriptor}.
27191
+ */
27192
+ function getEndpoint(name) {
27193
+ const ep = WATCHER_ENDPOINTS.find((e) => e.name === name);
27194
+ if (!ep)
27195
+ throw new Error(`Unknown endpoint: ${name}`);
27196
+ return ep;
27197
+ }
27198
+
27008
27199
  /**
27009
27200
  * @module schemas/vcs
27010
27201
  * VCS (version control system) configuration schema for git-backed content versioning.
@@ -27078,12 +27269,12 @@ const vcsConfigSchema = object$1({
27078
27269
  author: vcsAuthorConfigSchema
27079
27270
  .optional()
27080
27271
  .describe('Git commit author identity. Set per-repo during init. Defaults: name="jeeves-watcher", email="watcher@localhost".'),
27081
- /** Debounce interval in milliseconds for batching commits. */
27082
- commitDebounceMs: number$2()
27272
+ /** Throttle interval in milliseconds for batching commits. */
27273
+ commitThrottleMs: number$2()
27083
27274
  .int()
27084
27275
  .min(1000)
27085
27276
  .default(30000)
27086
- .describe('Debounce interval in milliseconds for batching commits. Default: 30000.'),
27277
+ .describe('Throttle interval in milliseconds for batching commits. Default: 30000.'),
27087
27278
  /** Maximum number of files per commit batch. */
27088
27279
  maxBatchSize: number$2()
27089
27280
  .int()
@@ -27632,9 +27823,9 @@ async function generateWatcherMenu(apiUrl) {
27632
27823
  const scoreThresholds = { strong: 0.75, relevant: 0.5, noise: 0.25 };
27633
27824
  const fetchOpts = { signal: AbortSignal.timeout(MENU_FETCH_TIMEOUT_MS) };
27634
27825
  const [statusRes, thresholdsRes, vcsRes] = (await Promise.all([
27635
- fetchJson(`${apiUrl}/status`, fetchOpts),
27636
- fetchJson(`${apiUrl}/config?path=${encodeURIComponent('$.search.scoreThresholds')}`, fetchOpts),
27637
- fetchJson(`${apiUrl}/vcs/status`, fetchOpts).catch(() => ({
27826
+ fetchJson(`${apiUrl}${getEndpoint('status').path}`, fetchOpts),
27827
+ fetchJson(`${apiUrl}${getEndpoint('config').path}?path=${encodeURIComponent('$.search.scoreThresholds')}`, fetchOpts),
27828
+ fetchJson(`${apiUrl}${getEndpoint('vcsStatus').path}`, fetchOpts).catch(() => ({
27638
27829
  enabled: false,
27639
27830
  })),
27640
27831
  ]));
@@ -27801,7 +27992,7 @@ function registerWatcherTools(api, baseUrl) {
27801
27992
  'offset',
27802
27993
  'filter',
27803
27994
  ]);
27804
- return ['/search', body];
27995
+ return [getEndpoint('search').path, body];
27805
27996
  },
27806
27997
  },
27807
27998
  {
@@ -27822,7 +28013,7 @@ function registerWatcherTools(api, baseUrl) {
27822
28013
  },
27823
28014
  },
27824
28015
  buildRequest: (params) => [
27825
- '/metadata',
28016
+ getEndpoint('metadata').path,
27826
28017
  { path: params.path, metadata: params.metadata },
27827
28018
  ],
27828
28019
  },
@@ -27845,7 +28036,7 @@ function registerWatcherTools(api, baseUrl) {
27845
28036
  },
27846
28037
  buildRequest: (params) => {
27847
28038
  const body = pickDefined(params, ['config', 'testPaths']);
27848
- return ['/config/validate', body];
28039
+ return [getEndpoint('configValidate').path, body];
27849
28040
  },
27850
28041
  },
27851
28042
  {
@@ -27873,7 +28064,7 @@ function registerWatcherTools(api, baseUrl) {
27873
28064
  },
27874
28065
  },
27875
28066
  buildRequest: (params) => [
27876
- '/reindex',
28067
+ getEndpoint('reindex').path,
27877
28068
  {
27878
28069
  scope: params.scope ?? 'rules',
27879
28070
  ...(params.path ? { path: params.path } : {}),
@@ -27919,14 +28110,14 @@ function registerWatcherTools(api, baseUrl) {
27919
28110
  'fields',
27920
28111
  'countOnly',
27921
28112
  ]);
27922
- return ['/scan', body];
28113
+ return [getEndpoint('scan').path, body];
27923
28114
  },
27924
28115
  },
27925
28116
  {
27926
28117
  name: 'watcher_issues',
27927
28118
  description: 'Get runtime embedding failures. Shows files that failed processing and why.',
27928
28119
  parameters: { type: 'object', properties: {} },
27929
- buildRequest: () => ['/issues'],
28120
+ buildRequest: () => [getEndpoint('issues').path],
27930
28121
  },
27931
28122
  {
27932
28123
  name: 'watcher_walk',
@@ -27942,14 +28133,17 @@ function registerWatcherTools(api, baseUrl) {
27942
28133
  },
27943
28134
  },
27944
28135
  },
27945
- buildRequest: (params) => ['/walk', { globs: params.globs }],
28136
+ buildRequest: (params) => [
28137
+ getEndpoint('walk').path,
28138
+ { globs: params.globs },
28139
+ ],
27946
28140
  },
27947
28141
  // ── VCS tools ──────────────────────────────────────────────────────
27948
28142
  {
27949
28143
  name: 'watcher_vcs_status',
27950
28144
  description: 'Get version tracking health: enabled state, tracked roots, remote status, last activity',
27951
28145
  parameters: { type: 'object', properties: {} },
27952
- buildRequest: () => ['/vcs/status'],
28146
+ buildRequest: () => [getEndpoint('vcsStatus').path],
27953
28147
  },
27954
28148
  {
27955
28149
  name: 'watcher_vcs_history',
@@ -27977,7 +28171,7 @@ function registerWatcherTools(api, baseUrl) {
27977
28171
  },
27978
28172
  },
27979
28173
  buildRequest: (params) => [
27980
- `/vcs/history${buildQuery(params, ['glob', 'since', 'until', 'limit'])}`,
28174
+ `${getEndpoint('vcsHistory').path}${buildQuery(params, ['glob', 'since', 'until', 'limit'])}`,
27981
28175
  ],
27982
28176
  },
27983
28177
  {
@@ -27998,7 +28192,7 @@ function registerWatcherTools(api, baseUrl) {
27998
28192
  },
27999
28193
  },
28000
28194
  buildRequest: (params) => [
28001
- `/vcs/show${buildQuery(params, ['path', 'commit'])}`,
28195
+ `${getEndpoint('vcsShow').path}${buildQuery(params, ['path', 'commit'])}`,
28002
28196
  ],
28003
28197
  },
28004
28198
  {
@@ -28023,7 +28217,7 @@ function registerWatcherTools(api, baseUrl) {
28023
28217
  },
28024
28218
  },
28025
28219
  buildRequest: (params) => [
28026
- `/vcs/diff${buildQuery(params, ['glob', 'commit', 'commitEnd'])}`,
28220
+ `${getEndpoint('vcsDiff').path}${buildQuery(params, ['glob', 'commit', 'commitEnd'])}`,
28027
28221
  ],
28028
28222
  },
28029
28223
  {
@@ -28049,7 +28243,7 @@ function registerWatcherTools(api, baseUrl) {
28049
28243
  },
28050
28244
  buildRequest: (params) => {
28051
28245
  const body = pickDefined(params, ['glob', 'commit', 'existingOnly']);
28052
- return ['/vcs/revert', body];
28246
+ return [getEndpoint('vcsRevert').path, body];
28053
28247
  },
28054
28248
  },
28055
28249
  {
@@ -28075,7 +28269,7 @@ function registerWatcherTools(api, baseUrl) {
28075
28269
  },
28076
28270
  buildRequest: (params) => {
28077
28271
  const body = pickDefined(params, ['glob', 'root', 'remove']);
28078
- return ['/vcs/exclude', body];
28272
+ return [getEndpoint('vcsExclude').path, body];
28079
28273
  },
28080
28274
  },
28081
28275
  {
@@ -28092,7 +28286,7 @@ function registerWatcherTools(api, baseUrl) {
28092
28286
  },
28093
28287
  },
28094
28288
  buildRequest: (params) => [
28095
- `/vcs/check-exclusion${buildQuery(params, ['path'])}`,
28289
+ `${getEndpoint('vcsCheckExclusion').path}${buildQuery(params, ['path'])}`,
28096
28290
  ],
28097
28291
  },
28098
28292
  ];
@@ -2,7 +2,7 @@
2
2
  "id": "jeeves-watcher-openclaw",
3
3
  "name": "Jeeves Watcher",
4
4
  "description": "Semantic search, metadata enrichment, and instance administration for a jeeves-watcher deployment.",
5
- "version": "0.15.4",
5
+ "version": "0.15.5",
6
6
  "skills": [
7
7
  "dist/skills/jeeves-watcher"
8
8
  ],
package/package.json CHANGED
@@ -8,7 +8,7 @@
8
8
  },
9
9
  "dependencies": {
10
10
  "@karmaniverous/jeeves": "^0.5.12",
11
- "@karmaniverous/jeeves-watcher-core": "^0.2.3"
11
+ "@karmaniverous/jeeves-watcher-core": "^0.2.4"
12
12
  },
13
13
  "description": "OpenClaw plugin for jeeves-watcher — semantic search and metadata enrichment tools",
14
14
  "devDependencies": {
@@ -112,5 +112,5 @@
112
112
  },
113
113
  "type": "module",
114
114
  "types": "dist/index.d.ts",
115
- "version": "0.15.4"
115
+ "version": "0.15.5"
116
116
  }