@smartmemory/sdk-js 0.6.0 → 0.6.7

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
@@ -1,5 +1,7 @@
1
1
  # @smartmemory/sdk-js
2
2
 
3
+ **Version:** 0.6.0
4
+
3
5
  Unified JavaScript SDK for [SmartMemory](https://smartmemory.ai) — consolidates authentication and API client logic across all SmartMemory frontend applications.
4
6
 
5
7
  ## Features
@@ -117,6 +119,27 @@ const client = new SmartMemoryClient({
117
119
 
118
120
  ## Domain APIs
119
121
 
122
+ ### Expertise Layer
123
+
124
+ SmartMemory's [expertise layer](https://docs.smartmemory.ai/smartmemory/concepts/expertise-vs-knowledge) — `decision`, `constraint`, `learned`, `opinion`, `reasoning`, `observation` — surfaces in this SDK via `client.decisions.create()` (with structured `rejectedAlternatives` / `rationale` / `constraints`) for capture and via `client.memories.search(query, { expertise: true })` for partitioned recall.
125
+
126
+ ```javascript
127
+ // Capture
128
+ await client.decisions.create({
129
+ title: 'Adopt FalkorDB',
130
+ rejectedAlternatives: ['Neo4j', 'Memgraph'],
131
+ rationale: 'Smallest ops surface; vector-native; permissive license.',
132
+ constraints: ['Must support Cypher subset'],
133
+ });
134
+
135
+ // Recall — typed-dict, partitioned by expertise type
136
+ const results = await client.memories.search('graph db choice', { expertise: true });
137
+ // { decision: [...], constraint: [...], learned: [...],
138
+ // opinion: [...], reasoning: [...], observation: [...] }
139
+ ```
140
+
141
+ Default `client.memories.search(query)` returns the flat list — no breaking change. The `{ expertise: true }` option switches the response shape; the SDK passes it through verbatim.
142
+
120
143
  ### Memories
121
144
 
122
145
  ```javascript
@@ -264,3 +287,7 @@ npm run build # production build
264
287
  ## License
265
288
 
266
289
  MIT
290
+
291
+ ## Documentation
292
+
293
+ Full SmartMemory documentation: https://docs.smartmemory.ai