pi-byterover 0.3.0 → 0.4.0

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 (2) hide show
  1. package/package.json +1 -1
  2. package/src/tools.ts +7 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pi-byterover",
3
- "version": "0.3.0",
3
+ "version": "0.4.0",
4
4
  "private": false,
5
5
  "description": "Pi extension that recalls and persists ByteRover memory.",
6
6
  "keywords": [
package/src/tools.ts CHANGED
@@ -90,11 +90,14 @@ const PersistParameters = Type.Object(
90
90
 
91
91
  type PersistParameters = Static<typeof PersistParameters>;
92
92
 
93
+ const ManualToolOutputSchema = Type.Undefined();
94
+
93
95
  type ManualToolDefinition<TName extends string, TParams extends TSchema> = Omit<
94
96
  ToolDefinition<TParams, undefined>,
95
97
  "name" | "execute"
96
98
  > & {
97
99
  name: TName;
100
+ outputSchema: typeof ManualToolOutputSchema;
98
101
  execute(
99
102
  toolCallId: string,
100
103
  params: Static<TParams>,
@@ -123,7 +126,7 @@ export const isByteRoverManualToolDefinition = (tool: {
123
126
  /** Registers ByteRover manual tools with Pi or a faithful recording host. */
124
127
  export interface ByteRoverManualToolHost {
125
128
  registerTool<TParams extends TSchema = TSchema, TDetails = unknown, TState = unknown>(
126
- tool: ToolDefinition<TParams, TDetails, TState>,
129
+ tool: ToolDefinition<TParams, TDetails, TState> & { outputSchema?: TSchema },
127
130
  ): void;
128
131
  }
129
132
 
@@ -172,6 +175,7 @@ export const registerManualTools = ({
172
175
  label: "ByteRover Recall",
173
176
  description: "Recall relevant context from ByteRover memory for a raw query.",
174
177
  parameters: RecallParameters,
178
+ outputSchema: ManualToolOutputSchema,
175
179
  execute: async (_toolCallId, params: RecallParameters, signal, _onUpdate, ctx) => {
176
180
  const query = params.query.trim();
177
181
 
@@ -199,6 +203,7 @@ export const registerManualTools = ({
199
203
  label: "ByteRover Search",
200
204
  description: "Search ByteRover memory for ranked file-level context results.",
201
205
  parameters: SearchParameters,
206
+ outputSchema: ManualToolOutputSchema,
202
207
  execute: async (_toolCallId, params: SearchParameters, _signal, _onUpdate, ctx) => {
203
208
  const query = params.query.trim();
204
209
 
@@ -228,6 +233,7 @@ export const registerManualTools = ({
228
233
  label: "ByteRover Persist",
229
234
  description: "Persist raw memory text into ByteRover without automatic curation wrapping.",
230
235
  parameters: PersistParameters,
236
+ outputSchema: ManualToolOutputSchema,
231
237
  execute: async (_toolCallId, params: PersistParameters, _signal, _onUpdate, ctx) => {
232
238
  const memory = params.context.trim();
233
239