Skip to main content

Interface: IUserMemoryStoreConfig

Defined in: internal/user-memory-store/types.ts:10

Configuration of the UserMemoryStore. Lands in IAIGatewayConfig.userMemoryStore.

Properties​

enabled​

enabled: boolean

Defined in: internal/user-memory-store/types.ts:14

The switch of the extraction. Off: nothing is due, the model is never called for it; stored facts are still read and editable. No default.


extractEveryTurns?​

optional extractEveryTurns?: number

Defined in: internal/user-memory-store/types.ts:47

Run extraction every time a thread crosses a multiple of N turns (IThread.turnCount).

Default​

10

maxFactChars?​

optional maxFactChars?: number

Defined in: internal/user-memory-store/types.ts:28

Cap of the characters of a fact's key and of its value. Every fact goes into every prompt of the user, so an unbounded fact costs on every call. A fact set by hand (upsertFact, the dyna_aigw_remember_user_fact tool) over the cap is a 400; a fact the extractor writes is cut to it.

Default​

500

maxFacts?​

optional maxFacts?: number

Defined in: internal/user-memory-store/types.ts:20

Cap of facts per user; over it, the facts updated longest ago are dropped.

Default​

50

rememberNeedsApproval?​

optional rememberNeedsApproval?: boolean

Defined in: internal/user-memory-store/types.ts:41

The model's dyna_aigw_remember_user_fact waits for the user's approval before it stores the fact (D116).

A fact enters every prompt of the user: text the model only read (a tool result, a knowledge-base excerpt, a file) must not be able to write one unasked.

The run pauses with a TOOL_APPROVAL card whose input is the fact ({key, value}). Switch it off for an app that accepts the risk and wants "remember this" stored at once. The facts the extractor writes and upsertUserFact are not affected; dyna_aigw_forget_user_fact never pauses (it only removes).

Default​

true

repository​

repository: IUserMemoryRepository

Defined in: internal/user-memory-store/types.ts:12

Persistence of the facts: the host's adapter; InMemoryUserMemoryRepository ships with the gateway.