@sjawhar/pi-legion-envoy 5.22.0 → 5.22.1

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/envoy.js CHANGED
@@ -30069,6 +30069,8 @@ var SPEC_SECTIONS = [
30069
30069
  var SPEC_WRITING_GUIDANCE = `When writing a spec, use these sections in order: ${SPEC_SECTIONS.join(", ")}. ` + "Write for a reader who has not seen the code: plain sentences, every identifier expanded on " + "first use, no coined shorthand; see skills/dispatch Writing for the human and Writing a spec.";
30070
30070
  var ASK_URGENCIES = ["low", "med", "high", "blocking"];
30071
30071
  var ASK_QUESTION_MAX = 800;
30072
+ var SEARCH_QUERY_MAX = 1000;
30073
+ var SEARCH_QUERY_HINT = "search with a short phrase of a few words, not a passage";
30072
30074
  var ISSUE_STATUSES = [
30073
30075
  "triage",
30074
30076
  "icebox",
@@ -30384,7 +30386,11 @@ var dispatchToolSpecs = [
30384
30386
  example: { query: "astrolabe" },
30385
30387
  description: "Search every issue, document, comment, ask, and message for a keyword or phrase and get deep links. " + "Use it before creating an issue or a design document, and to find where a word was written. " + 'Websearch syntax: "quoted phrase", -excluded, OR.',
30386
30388
  arguments: (z2) => ({
30387
- query: z2.string({ min: 2 }).describe("Keyword, phrase, or websearch expression; at least 2 characters."),
30389
+ query: z2.string({
30390
+ min: 2,
30391
+ max: SEARCH_QUERY_MAX,
30392
+ maxHint: SEARCH_QUERY_HINT
30393
+ }).describe(`Keyword, phrase, or websearch expression; 2 to ${SEARCH_QUERY_MAX} characters.`),
30388
30394
  project: z2.string().describe("Optional project key to search within.").optional(),
30389
30395
  limit: z2.number({ int: true, min: 1, max: 50 }).describe("Maximum results, 1-50; default 20.").optional()
30390
30396
  })
@@ -30903,8 +30909,9 @@ function zodSchemaApi(zod) {
30903
30909
  schema = schema.min(opts.min);
30904
30910
  if (opts.max !== undefined) {
30905
30911
  const max = opts.max;
30912
+ const hint = opts.maxHint === undefined ? "" : `; ${opts.maxHint}`;
30906
30913
  schema = schema.max(max, {
30907
- error: (issue2) => overCapMessage(typeof issue2.input === "string" ? issue2.input.length : max + 1, max)
30914
+ error: (issue2) => overCapMessage(typeof issue2.input === "string" ? issue2.input.length : max + 1, max) + hint
30908
30915
  });
30909
30916
  }
30910
30917
  return schema;
package/dist/legion.js CHANGED
@@ -30238,6 +30238,8 @@ var SPEC_SECTIONS = [
30238
30238
  var SPEC_WRITING_GUIDANCE = `When writing a spec, use these sections in order: ${SPEC_SECTIONS.join(", ")}. ` + "Write for a reader who has not seen the code: plain sentences, every identifier expanded on " + "first use, no coined shorthand; see skills/dispatch Writing for the human and Writing a spec.";
30239
30239
  var ASK_URGENCIES = ["low", "med", "high", "blocking"];
30240
30240
  var ASK_QUESTION_MAX = 800;
30241
+ var SEARCH_QUERY_MAX = 1000;
30242
+ var SEARCH_QUERY_HINT = "search with a short phrase of a few words, not a passage";
30241
30243
  var ISSUE_STATUSES = [
30242
30244
  "triage",
30243
30245
  "icebox",
@@ -30553,7 +30555,11 @@ var dispatchToolSpecs = [
30553
30555
  example: { query: "astrolabe" },
30554
30556
  description: "Search every issue, document, comment, ask, and message for a keyword or phrase and get deep links. " + "Use it before creating an issue or a design document, and to find where a word was written. " + 'Websearch syntax: "quoted phrase", -excluded, OR.',
30555
30557
  arguments: (z2) => ({
30556
- query: z2.string({ min: 2 }).describe("Keyword, phrase, or websearch expression; at least 2 characters."),
30558
+ query: z2.string({
30559
+ min: 2,
30560
+ max: SEARCH_QUERY_MAX,
30561
+ maxHint: SEARCH_QUERY_HINT
30562
+ }).describe(`Keyword, phrase, or websearch expression; 2 to ${SEARCH_QUERY_MAX} characters.`),
30557
30563
  project: z2.string().describe("Optional project key to search within.").optional(),
30558
30564
  limit: z2.number({ int: true, min: 1, max: 50 }).describe("Maximum results, 1-50; default 20.").optional()
30559
30565
  })
@@ -31072,8 +31078,9 @@ function zodSchemaApi(zod) {
31072
31078
  schema = schema.min(opts.min);
31073
31079
  if (opts.max !== undefined) {
31074
31080
  const max = opts.max;
31081
+ const hint = opts.maxHint === undefined ? "" : `; ${opts.maxHint}`;
31075
31082
  schema = schema.max(max, {
31076
- error: (issue2) => overCapMessage(typeof issue2.input === "string" ? issue2.input.length : max + 1, max)
31083
+ error: (issue2) => overCapMessage(typeof issue2.input === "string" ? issue2.input.length : max + 1, max) + hint
31077
31084
  });
31078
31085
  }
31079
31086
  return schema;
@@ -33495,7 +33502,7 @@ import { logger } from "@oh-my-pi/pi-utils";
33495
33502
  // package.json
33496
33503
  var package_default = {
33497
33504
  name: "@sjawhar/pi-legion-envoy",
33498
- version: "5.22.0",
33505
+ version: "5.22.1",
33499
33506
  type: "module",
33500
33507
  omp: {
33501
33508
  extensions: [
@@ -165,10 +165,12 @@ do with each hit. What it leaves out:
165
165
  dispatch_search({ query, project?, limit? })
166
166
  ```
167
167
  Websearch syntax applies: `"merge queue"`, `-daemon`, `OR`. It returns the best `limit` hits (20
168
- by default, 50 at most) across issues, documents, comments, asks, and messages. Issue-owned hit
169
- lines start with the issue key; standalone project-document hit lines start with
170
- `dispatch://PROJECT/artifact/<slug>`, followed by the absolute link. Cite the hit you build on
171
- (`dispatch://KEY` or the document reference), or state "no prior issue" in the spec.
168
+ by default, 50 at most) across issues, documents, comments, asks, and messages. A query over
169
+ 1,000 characters is refused before it is sent: search with the few words `skill://dispatch-first`
170
+ describes, never a pasted passage. Issue-owned hit lines start with the issue key; standalone
171
+ project-document hit lines start with `dispatch://PROJECT/artifact/<slug>`, followed by the
172
+ absolute link. Cite the hit you build on (`dispatch://KEY` or the document reference), or state
173
+ "no prior issue" in the spec.
172
174
 
173
175
  `dispatch_issue` refuses a title that near-duplicates an issue in the same project and returns the candidates (`POSSIBLE_DUPLICATE`).
174
176
  Read them; reference the existing issue, or repeat the call with `force: true` when it is genuinely new work.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sjawhar/pi-legion-envoy",
3
- "version": "5.22.0",
3
+ "version": "5.22.1",
4
4
  "type": "module",
5
5
  "omp": {
6
6
  "extensions": [