@yuihub/core 1.0.0-beta.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.
@@ -0,0 +1,3 @@
1
+ export * from './types.js';
2
+ export * from './sync.js';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,YAAY,CAAC;AAC3B,cAAc,WAAW,CAAC"}
package/dist/index.js ADDED
@@ -0,0 +1,3 @@
1
+ export * from './types.js';
2
+ export * from './sync.js';
3
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,YAAY,CAAC;AAC3B,cAAc,WAAW,CAAC"}
package/dist/sync.d.ts ADDED
@@ -0,0 +1,28 @@
1
+ /**
2
+ * Define specific provider names for better type safety
3
+ */
4
+ export type SyncProviderName = 'github' | 's3' | 'local';
5
+ export interface ISyncProvider {
6
+ /**
7
+ * Name of the provider (e.g. 'github')
8
+ */
9
+ name: SyncProviderName;
10
+ /**
11
+ * Push changes to remote
12
+ * @param message Commit message or sync context
13
+ */
14
+ push(message: string): Promise<void>;
15
+ /**
16
+ * Pull changes from remote
17
+ */
18
+ pull(): Promise<void>;
19
+ /**
20
+ * Check status (is dirty?)
21
+ */
22
+ status(): Promise<{
23
+ dirty: boolean;
24
+ ahead: number;
25
+ behind: number;
26
+ }>;
27
+ }
28
+ //# sourceMappingURL=sync.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sync.d.ts","sourceRoot":"","sources":["../src/sync.ts"],"names":[],"mappings":"AAGA;;GAEG;AACH,MAAM,MAAM,gBAAgB,GAAG,QAAQ,GAAG,IAAI,GAAG,OAAO,CAAC;AAEzD,MAAM,WAAW,aAAa;IAC5B;;OAEG;IACH,IAAI,EAAE,gBAAgB,CAAC;IAEvB;;;OAGG;IACH,IAAI,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAErC;;OAEG;IACH,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC;IAEtB;;OAEG;IACH,MAAM,IAAI,OAAO,CAAC;QAAE,KAAK,EAAE,OAAO,CAAC;QAAC,KAAK,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;CACtE"}
package/dist/sync.js ADDED
@@ -0,0 +1,4 @@
1
+ // Interface for Sync Layer
2
+ // Pluggable provider for syncing local memory/data to external storage (e.g. GitHub, S3, etc.)
3
+ export {};
4
+ //# sourceMappingURL=sync.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sync.js","sourceRoot":"","sources":["../src/sync.ts"],"names":[],"mappings":"AAAA,2BAA2B;AAC3B,+FAA+F"}
@@ -0,0 +1,32 @@
1
+ /**
2
+ * YuiHub V1 Core Types
3
+ * Based on docs/specs/glossary.md and docs/specs/schemas/context_packet.yaml
4
+ */
5
+ export type YuiHubMode = 'private' | 'public';
6
+ export interface Entry {
7
+ id: string;
8
+ date: string;
9
+ text: string;
10
+ mode: YuiHubMode;
11
+ tags?: string[];
12
+ session_id?: string;
13
+ source?: string;
14
+ metadata?: Record<string, unknown>;
15
+ }
16
+ export interface Checkpoint {
17
+ id: string;
18
+ entry_id: string;
19
+ snapshot: {
20
+ working_memory: string;
21
+ decision_rationale: string;
22
+ };
23
+ created_at: string;
24
+ }
25
+ export interface Session {
26
+ id: string;
27
+ title: string;
28
+ created_at: string;
29
+ last_updated: string;
30
+ entries_count: number;
31
+ }
32
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,MAAM,MAAM,UAAU,GAAG,SAAS,GAAG,QAAQ,CAAC;AAG9C,MAAM,WAAW,KAAK;IACpB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,UAAU,CAAC;IACjB,IAAI,CAAC,EAAE,MAAM,EAAE,CAAC;IAChB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CACpC;AAGD,MAAM,WAAW,UAAU;IACzB,EAAE,EAAE,MAAM,CAAC;IACX,QAAQ,EAAE,MAAM,CAAC;IACjB,QAAQ,EAAE;QACR,cAAc,EAAE,MAAM,CAAC;QACvB,kBAAkB,EAAE,MAAM,CAAC;KAC5B,CAAC;IACF,UAAU,EAAE,MAAM,CAAC;CACpB;AAGD,MAAM,WAAW,OAAO;IACtB,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,UAAU,EAAE,MAAM,CAAC;IACnB,YAAY,EAAE,MAAM,CAAC;IACrB,aAAa,EAAE,MAAM,CAAC;CACvB"}
package/dist/types.js ADDED
@@ -0,0 +1,6 @@
1
+ /**
2
+ * YuiHub V1 Core Types
3
+ * Based on docs/specs/glossary.md and docs/specs/schemas/context_packet.yaml
4
+ */
5
+ export {};
6
+ //# sourceMappingURL=types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.js","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA;;;GAGG"}
package/package.json ADDED
@@ -0,0 +1,39 @@
1
+ {
2
+ "name": "@yuihub/core",
3
+ "version": "1.0.0-beta.1",
4
+ "description": "YuiHub Core - Semantic Memory Types and Utilities",
5
+ "type": "module",
6
+ "license": "MIT",
7
+ "repository": {
8
+ "type": "git",
9
+ "url": "https://github.com/vemikrs/yuihub.git",
10
+ "directory": "packages/core"
11
+ },
12
+ "keywords": [
13
+ "yuihub",
14
+ "semantic-memory",
15
+ "ai",
16
+ "agent",
17
+ "types"
18
+ ],
19
+ "main": "./dist/index.js",
20
+ "types": "./dist/index.d.ts",
21
+ "exports": {
22
+ ".": {
23
+ "types": "./dist/index.d.ts",
24
+ "import": "./dist/index.js"
25
+ }
26
+ },
27
+ "files": [
28
+ "dist"
29
+ ],
30
+ "scripts": {
31
+ "build": "npx tsc -b",
32
+ "dev": "npx tsc -b -w",
33
+ "clean": "rm -rf dist tsconfig.tsbuildinfo",
34
+ "prepublishOnly": "npm run build"
35
+ },
36
+ "devDependencies": {
37
+ "typescript": "^5.0.0"
38
+ }
39
+ }