ai-hist-native 0.9.2 → 0.11.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.
package/index.d.ts CHANGED
@@ -181,6 +181,7 @@ export interface SourceExemption {
181
181
  export interface DiscoverResult {
182
182
  contractVersion: number
183
183
  scope: string
184
+ locationsRun: Array<string>
184
185
  sessions: Array<CatalogSession>
185
186
  discovered: number
186
187
  skippedUnchanged: number
@@ -191,6 +192,44 @@ export interface DiscoverResult {
191
192
  }
192
193
  /** Explicit bounded provider discovery. It updates only the session catalog. */
193
194
  export declare function discoverSessions(options?: DiscoverOptions | undefined | null): Promise<DiscoverResult>
195
+ export interface HydrateSessionOptions {
196
+ source: string
197
+ sessionId: string
198
+ scope?: string
199
+ dbPath?: string
200
+ includeRelated?: boolean
201
+ }
202
+ export interface HydrationIndexedThrough {
203
+ sourceStamp?: string
204
+ lastEventAtMs?: number
205
+ }
206
+ export interface HydrationEvidence {
207
+ prompts: number
208
+ events: number
209
+ toolCalls: number
210
+ relatedSessions: number
211
+ }
212
+ export interface HydrationDiagnostic {
213
+ code: string
214
+ message: string
215
+ durationMs?: number
216
+ sourceBytes?: number
217
+ recordsParsed?: number
218
+ }
219
+ export interface HydrateSessionResult {
220
+ contractVersion: number
221
+ source: string
222
+ sessionId: string
223
+ status: string
224
+ discoveryState: string
225
+ presence: string
226
+ indexedThrough: HydrationIndexedThrough
227
+ evidence: HydrationEvidence
228
+ relatedSessionIds: Array<string>
229
+ diagnostics: Array<HydrationDiagnostic>
230
+ }
231
+ /** Fully index one cataloged session without enumerating unrelated sessions. */
232
+ export declare function hydrateSession(options: HydrateSessionOptions): Promise<HydrateSessionResult>
194
233
  export interface SyncOptions {
195
234
  dbPath?: string
196
235
  scope?: string
package/index.js CHANGED
@@ -310,7 +310,7 @@ if (!nativeBinding) {
310
310
  throw new Error(`Failed to load native binding`)
311
311
  }
312
312
 
313
- const { nativeContractVersion, nativeBuildProfile, search, recent, getSession, getSessionEventsPage, stats, listSessionCatalogPage, listSessionCatalog, discoverSessions, sync, syncLocal, syncAndPush } = nativeBinding
313
+ const { nativeContractVersion, nativeBuildProfile, search, recent, getSession, getSessionEventsPage, stats, listSessionCatalogPage, listSessionCatalog, discoverSessions, hydrateSession, sync, syncLocal, syncAndPush } = nativeBinding
314
314
 
315
315
  module.exports.nativeContractVersion = nativeContractVersion
316
316
  module.exports.nativeBuildProfile = nativeBuildProfile
@@ -322,6 +322,7 @@ module.exports.stats = stats
322
322
  module.exports.listSessionCatalogPage = listSessionCatalogPage
323
323
  module.exports.listSessionCatalog = listSessionCatalog
324
324
  module.exports.discoverSessions = discoverSessions
325
+ module.exports.hydrateSession = hydrateSession
325
326
  module.exports.sync = sync
326
327
  module.exports.syncLocal = syncLocal
327
328
  module.exports.syncAndPush = syncAndPush
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ai-hist-native-darwin-arm64",
3
- "version": "0.9.2",
3
+ "version": "0.11.0",
4
4
  "os": [
5
5
  "darwin"
6
6
  ],
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ai-hist-native-darwin-x64",
3
- "version": "0.9.2",
3
+ "version": "0.11.0",
4
4
  "os": [
5
5
  "darwin"
6
6
  ],
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ai-hist-native-linux-arm64-gnu",
3
- "version": "0.9.2",
3
+ "version": "0.11.0",
4
4
  "os": [
5
5
  "linux"
6
6
  ],
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ai-hist-native-linux-arm64-musl",
3
- "version": "0.9.2",
3
+ "version": "0.11.0",
4
4
  "os": [
5
5
  "linux"
6
6
  ],
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ai-hist-native-linux-x64-gnu",
3
- "version": "0.9.2",
3
+ "version": "0.11.0",
4
4
  "os": [
5
5
  "linux"
6
6
  ],
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ai-hist-native-linux-x64-musl",
3
- "version": "0.9.2",
3
+ "version": "0.11.0",
4
4
  "os": [
5
5
  "linux"
6
6
  ],
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ai-hist-native-win32-x64-msvc",
3
- "version": "0.9.2",
3
+ "version": "0.11.0",
4
4
  "os": [
5
5
  "win32"
6
6
  ],
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ai-hist-native",
3
- "version": "0.9.2",
3
+ "version": "0.11.0",
4
4
  "description": "Mandatory Node-API engine for RelayHistory.",
5
5
  "main": "index.js",
6
6
  "types": "index.d.ts",
@@ -44,12 +44,12 @@
44
44
  "@napi-rs/cli": "^2.18.4"
45
45
  },
46
46
  "optionalDependencies": {
47
- "ai-hist-native-darwin-arm64": "0.9.2",
48
- "ai-hist-native-darwin-x64": "0.9.2",
49
- "ai-hist-native-linux-x64-gnu": "0.9.2",
50
- "ai-hist-native-linux-arm64-gnu": "0.9.2",
51
- "ai-hist-native-linux-x64-musl": "0.9.2",
52
- "ai-hist-native-linux-arm64-musl": "0.9.2",
53
- "ai-hist-native-win32-x64-msvc": "0.9.2"
47
+ "ai-hist-native-darwin-arm64": "0.11.0",
48
+ "ai-hist-native-darwin-x64": "0.11.0",
49
+ "ai-hist-native-linux-x64-gnu": "0.11.0",
50
+ "ai-hist-native-linux-arm64-gnu": "0.11.0",
51
+ "ai-hist-native-linux-x64-musl": "0.11.0",
52
+ "ai-hist-native-linux-arm64-musl": "0.11.0",
53
+ "ai-hist-native-win32-x64-msvc": "0.11.0"
54
54
  }
55
55
  }