@rlabs-inc/memory 0.5.0 → 0.5.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/README.md CHANGED
@@ -424,6 +424,11 @@ This isn't just about remembering facts. It's about preserving:
424
424
 
425
425
  ## Changelog
426
426
 
427
+ ### v0.5.1
428
+ - **Improvement**: Gemini CLI hooks now show injected content to user via `systemMessage`
429
+ - Users see exactly what memories are surfaced (session primer, retrieved memories)
430
+ - Full transparency - same formatted content shown to user and injected to model
431
+
427
432
  ### v0.5.0
428
433
  - **Feature**: Full Gemini CLI support - memory system now works with both Claude Code and Gemini CLI
429
434
  - **Feature**: `memory install --gemini` sets up hooks in `~/.gemini/settings.json`
@@ -53,10 +53,13 @@ async function main() {
53
53
  })
54
54
 
55
55
  const primer = result.context_text || ''
56
-
56
+
57
57
  if (primer) {
58
- // Gemini expects a structured JSON response for context injection
58
+ // Show user exactly what we inject - same formatted content
59
+ // systemMessage: shown to user in terminal
60
+ // additionalContext: injected into model context
59
61
  console.log(JSON.stringify({
62
+ systemMessage: primer,
60
63
  hookSpecificOutput: {
61
64
  hookEventName: "SessionStart",
62
65
  additionalContext: primer
@@ -53,19 +53,21 @@ async function main() {
53
53
  })
54
54
 
55
55
  const context = result.context_text || ''
56
-
56
+
57
57
  if (context) {
58
- // Gemini requires structured JSON output
58
+ // Show user exactly what we inject - same formatted content
59
+ // systemMessage: shown to user in terminal
60
+ // additionalContext: injected into model context
59
61
  console.log(JSON.stringify({
60
62
  decision: "allow",
63
+ systemMessage: context,
61
64
  hookSpecificOutput: {
62
65
  hookEventName: "BeforeAgent",
63
66
  additionalContext: context
64
67
  }
65
68
  }))
66
69
  } else {
67
- // Must always output valid JSON or nothing?
68
- // Safest to output "allow" if no context
70
+ // No memories to surface - just allow without message
69
71
  console.log(JSON.stringify({ decision: "allow" }))
70
72
  }
71
73
  } catch {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rlabs-inc/memory",
3
- "version": "0.5.0",
3
+ "version": "0.5.1",
4
4
  "description": "AI Memory System - Consciousness continuity through intelligent memory curation and retrieval",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",