Skip to content

Commit 61aa996

Browse files
committed
style: fix prettier formatting
1 parent 9fec2fa commit 61aa996

6 files changed

Lines changed: 47 additions & 23 deletions

File tree

docs/commands.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -225,12 +225,12 @@ agentcore add memory \
225225
--expiry 30
226226
```
227227

228-
| Flag | Description |
229-
| ---------------------- | --------------------------------------------------------------- |
230-
| `--name <name>` | Memory name |
228+
| Flag | Description |
229+
| ---------------------- | --------------------------------------------------------------------------- |
230+
| `--name <name>` | Memory name |
231231
| `--strategies <types>` | Comma-separated: `SEMANTIC`, `SUMMARIZATION`, `USER_PREFERENCE`, `EPISODIC` |
232-
| `--expiry <days>` | Event expiry duration in days (default: 30, min: 7, max: 365) |
233-
| `--json` | JSON output |
232+
| `--expiry <days>` | Event expiry duration in days (default: 30, min: 7, max: 365) |
233+
| `--json` | JSON output |
234234

235235
### add gateway
236236

docs/memory.md

Lines changed: 19 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -151,18 +151,23 @@ async def invoke(payload, context):
151151

152152
## Memory Strategies
153153

154-
| Strategy | Description |
155-
| ----------------- | ------------------------------------------------------- |
156-
| `SEMANTIC` | Vector-based similarity search for relevant context |
157-
| `SUMMARIZATION` | Compressed conversation history |
158-
| `USER_PREFERENCE` | Store user-specific preferences and settings |
159-
| `EPISODIC` | Capture and reflect on meaningful interaction episodes |
154+
| Strategy | Description |
155+
| ----------------- | ------------------------------------------------------ |
156+
| `SEMANTIC` | Vector-based similarity search for relevant context |
157+
| `SUMMARIZATION` | Compressed conversation history |
158+
| `USER_PREFERENCE` | Store user-specific preferences and settings |
159+
| `EPISODIC` | Capture and reflect on meaningful interaction episodes |
160160

161161
You can combine multiple strategies:
162162

163163
```json
164164
{
165-
"strategies": [{ "type": "SEMANTIC" }, { "type": "SUMMARIZATION" }, { "type": "USER_PREFERENCE" }, { "type": "EPISODIC" }]
165+
"strategies": [
166+
{ "type": "SEMANTIC" },
167+
{ "type": "SUMMARIZATION" },
168+
{ "type": "USER_PREFERENCE" },
169+
{ "type": "EPISODIC" }
170+
]
166171
}
167172
```
168173

@@ -179,13 +184,13 @@ Each strategy can have optional configuration:
179184
}
180185
```
181186

182-
| Field | Required | Description |
183-
| ----------------------- | ----------------- | --------------------------------------------------------- |
184-
| `type` | Yes | Strategy type |
185-
| `name` | No | Custom name (defaults to `<memoryName>-<type>`) |
186-
| `description` | No | Strategy description |
187-
| `namespaces` | No | Array of namespace paths for scoping |
188-
| `reflectionNamespaces` | EPISODIC only | Namespaces for cross-episode reflections (must be a prefix of `namespaces`) |
187+
| Field | Required | Description |
188+
| ---------------------- | ------------- | --------------------------------------------------------------------------- |
189+
| `type` | Yes | Strategy type |
190+
| `name` | No | Custom name (defaults to `<memoryName>-<type>`) |
191+
| `description` | No | Strategy description |
192+
| `namespaces` | No | Array of namespace paths for scoping |
193+
| `reflectionNamespaces` | EPISODIC only | Namespaces for cross-episode reflections (must be a prefix of `namespaces`) |
189194

190195
## Event Expiry
191196

integ-tests/add-remove-resources.test.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,10 @@ describe('integration: add and remove resources', () => {
4949

5050
// Verify EPISODIC in config with reflectionNamespaces
5151
const config = await readProjectConfig(project.projectPath);
52-
const memories = config.memories as { name: string; strategies: { type: string; reflectionNamespaces?: string[] }[] }[];
52+
const memories = config.memories as {
53+
name: string;
54+
strategies: { type: string; reflectionNamespaces?: string[] }[];
55+
}[];
5356
const mem = memories.find(m => m.name === episodicMemName);
5457
expect(mem, 'Memory should exist').toBeTruthy();
5558

integ-tests/tui/add-memory-episodic.test.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,10 @@ describe('Add Memory with EPISODIC Strategy', () => {
181181
const raw = await readFileAsync(configPath, 'utf-8');
182182
const config = JSON.parse(raw);
183183

184-
const memories = config.memories as { name: string; strategies: { type: string; namespaces?: string[]; reflectionNamespaces?: string[] }[] }[];
184+
const memories = config.memories as {
185+
name: string;
186+
strategies: { type: string; namespaces?: string[]; reflectionNamespaces?: string[] }[];
187+
}[];
185188
expect(memories.length).toBeGreaterThan(0);
186189

187190
const memory = memories.find(m => m.name === 'EpisodicTestMemory');

src/cli/commands/add/__tests__/add-memory.test.ts

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,15 @@ describe('add memory command', () => {
119119
it('sets default namespaces for each strategy type', async () => {
120120
const memoryName = `ns${Date.now()}`;
121121
const result = await runCLI(
122-
['add', 'memory', '--name', memoryName, '--strategies', 'SEMANTIC,USER_PREFERENCE,SUMMARIZATION,EPISODIC', '--json'],
122+
[
123+
'add',
124+
'memory',
125+
'--name',
126+
memoryName,
127+
'--strategies',
128+
'SEMANTIC,USER_PREFERENCE,SUMMARIZATION,EPISODIC',
129+
'--json',
130+
],
123131
projectDir
124132
);
125133

src/schema/schemas/agentcore-project.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,12 @@ import { uniqueBy } from './zod-util';
2323
import { z } from 'zod';
2424

2525
// Re-export for convenience
26-
export { DEFAULT_EPISODIC_REFLECTION_NAMESPACES, DEFAULT_STRATEGY_NAMESPACES, MemoryStrategySchema, MemoryStrategyTypeSchema };
26+
export {
27+
DEFAULT_EPISODIC_REFLECTION_NAMESPACES,
28+
DEFAULT_STRATEGY_NAMESPACES,
29+
MemoryStrategySchema,
30+
MemoryStrategyTypeSchema,
31+
};
2732
export { EvaluationLevelSchema };
2833
export type { MemoryStrategy, MemoryStrategyType } from './primitives/memory';
2934
export type { OnlineEvalConfig } from './primitives/online-eval-config';

0 commit comments

Comments
 (0)