@hung319/opencode-hive 1.3.9 → 1.4.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/index.js +1160 -117
- package/dist/tools/memory.d.ts +35 -0
- package/package.json +1 -1
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { type ToolDefinition } from "@opencode-ai/plugin";
|
|
2
|
+
/**
|
|
3
|
+
* Hive Memory System
|
|
4
|
+
*
|
|
5
|
+
* Persistent memory blocks similar to Letta's memory blocks.
|
|
6
|
+
* - global: Shared across all projects (stored in ~/.config/opencode/hive/memory/)
|
|
7
|
+
* - project: Project-scoped memory (stored in .hive/memory/)
|
|
8
|
+
*/
|
|
9
|
+
export interface MemoryBlock {
|
|
10
|
+
scope: 'global' | 'project';
|
|
11
|
+
label: string;
|
|
12
|
+
description: string;
|
|
13
|
+
limit: number;
|
|
14
|
+
readOnly: boolean;
|
|
15
|
+
value: string;
|
|
16
|
+
filePath: string;
|
|
17
|
+
lastModified: string;
|
|
18
|
+
charsCurrent: number;
|
|
19
|
+
}
|
|
20
|
+
export interface JournalEntry {
|
|
21
|
+
id: string;
|
|
22
|
+
title: string;
|
|
23
|
+
body: string;
|
|
24
|
+
project?: string;
|
|
25
|
+
tags: string[];
|
|
26
|
+
created: string;
|
|
27
|
+
filePath: string;
|
|
28
|
+
}
|
|
29
|
+
export declare function ensureMemorySeeded(projectRoot: string): Promise<void>;
|
|
30
|
+
export declare const hiveMemoryListTool: ToolDefinition;
|
|
31
|
+
export declare const hiveMemorySetTool: ToolDefinition;
|
|
32
|
+
export declare const hiveMemoryReplaceTool: ToolDefinition;
|
|
33
|
+
export declare const hiveJournalWriteTool: ToolDefinition;
|
|
34
|
+
export declare const hiveJournalSearchTool: ToolDefinition;
|
|
35
|
+
export declare function buildMemoryInjection(projectRoot: string): Promise<string>;
|