@memgrafter/flatagents 2.2.0 → 2.2.2

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/MACHINES.md CHANGED
@@ -22,7 +22,7 @@
22
22
  ```yaml
23
23
  # profiles.yml — agents reference by name
24
24
  spec: flatprofiles
25
- spec_version: "2.2.0"
25
+ spec_version: "2.2.2"
26
26
  data:
27
27
  model_profiles:
28
28
  fast: { provider: cerebras, name: zai-glm-4.6, temperature: 0.6 }
@@ -166,8 +166,18 @@ class MyHooks(MachineHooks):
166
166
  ## Persistence
167
167
 
168
168
  ```yaml
169
- persistence: { enabled: true, backend: local } # local | memory
169
+ persistence: { enabled: true, backend: local } # local | memory | sqlite
170
170
  ```
171
+
172
+ SQLite backend (durable, single-file, no external dependencies):
173
+ ```yaml
174
+ persistence:
175
+ enabled: true
176
+ backend: sqlite
177
+ db_path: ./flatmachines.sqlite # optional, defaults to flatmachines.sqlite
178
+ ```
179
+ Auto-selects `SQLiteLeaseLock` and `SQLiteConfigStore` — no runner injection needed.
180
+
171
181
  Resume: `machine.execute(resume_from=execution_id)`
172
182
 
173
183
  ## SDKs
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@memgrafter/flatagents",
3
- "version": "2.2.0",
3
+ "version": "2.2.2",
4
4
  "description": "TypeScript SDK for FlatAgents - Declarative LLM orchestration with YAML",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",
@@ -149,7 +149,7 @@
149
149
  * The profile field specifies which profile name to use as base.
150
150
  */
151
151
 
152
- export const SPEC_VERSION = "2.2.0";
152
+ export const SPEC_VERSION = "2.2.2";
153
153
 
154
154
  export interface AgentWrapper {
155
155
  spec: "flatagent";
@@ -1,4 +1,4 @@
1
- export const SPEC_VERSION = "2.2.0";
1
+ export const SPEC_VERSION = "2.2.2";
2
2
  export interface AgentWrapper {
3
3
  spec: "flatagent";
4
4
  spec_version: string;
@@ -800,7 +800,7 @@ export interface BackendConfig {
800
800
  aws_region?: string;
801
801
  }
802
802
 
803
- export const SPEC_VERSION = "2.2.0";
803
+ export const SPEC_VERSION = "2.2.2";
804
804
 
805
805
  export interface SDKRuntimeWrapper {
806
806
  spec: "flatagents-runtime";
@@ -11,7 +11,7 @@
11
11
  },
12
12
  "spec_version": {
13
13
  "type": "string",
14
- "const": "2.2.0"
14
+ "const": "2.2.2"
15
15
  },
16
16
  "execution_lock": {
17
17
  "$ref": "#/definitions/ExecutionLock"
@@ -252,7 +252,7 @@ export interface BackendConfig {
252
252
  dynamodb_table?: string;
253
253
  aws_region?: string;
254
254
  }
255
- export const SPEC_VERSION = "2.2.0";
255
+ export const SPEC_VERSION = "2.2.2";
256
256
  export interface SDKRuntimeWrapper {
257
257
  spec: "flatagents-runtime";
258
258
  spec_version: typeof SPEC_VERSION;
@@ -240,7 +240,7 @@
240
240
  * PERSISTENCE (v0.2.0):
241
241
  * --------------------
242
242
  * MachineSnapshot - Wire format for checkpoints (execution_id, state, context, step)
243
- * PersistenceConfig - Backend config: {enabled: true, backend: "local"|"memory"}
243
+ * PersistenceConfig - Backend config: {enabled: true, backend: "local"|"memory"|"sqlite"}
244
244
  * checkpoint_on - Events to checkpoint: ["machine_start", "execute", "machine_end"]
245
245
  *
246
246
  * MACHINE LAUNCHING:
@@ -319,7 +319,7 @@
319
319
  * config_hash - Content-addressed machine config key for cross-SDK resume (v2.1.0)
320
320
  */
321
321
 
322
- export const SPEC_VERSION = "2.2.0";
322
+ export const SPEC_VERSION = "2.2.2";
323
323
 
324
324
  export interface MachineWrapper {
325
325
  spec: "flatmachine";
@@ -467,7 +467,9 @@ export interface MachineSnapshot {
467
467
 
468
468
  export interface PersistenceConfig {
469
469
  enabled: boolean;
470
- backend: "local" | "redis" | "memory" | string;
470
+ backend: "local" | "sqlite" | "memory";
471
+ /** Database file path for sqlite backend. Defaults to "flatmachines.sqlite". */
472
+ db_path?: string;
471
473
  checkpoint_on?: string[];
472
474
  [key: string]: any;
473
475
  }
@@ -707,7 +707,16 @@
707
707
  "type": "boolean"
708
708
  },
709
709
  "backend": {
710
- "type": "string"
710
+ "type": "string",
711
+ "enum": [
712
+ "local",
713
+ "sqlite",
714
+ "memory"
715
+ ]
716
+ },
717
+ "db_path": {
718
+ "type": "string",
719
+ "description": "Database file path for sqlite backend. Defaults to \"flatmachines.sqlite\"."
711
720
  },
712
721
  "checkpoint_on": {
713
722
  "type": "array",
@@ -1,4 +1,4 @@
1
- export const SPEC_VERSION = "2.2.0";
1
+ export const SPEC_VERSION = "2.2.2";
2
2
  export interface MachineWrapper {
3
3
  spec: "flatmachine";
4
4
  spec_version: string;
@@ -127,7 +127,8 @@ export interface MachineSnapshot {
127
127
  }
128
128
  export interface PersistenceConfig {
129
129
  enabled: boolean;
130
- backend: "local" | "redis" | "memory" | string;
130
+ backend: "local" | "sqlite" | "memory";
131
+ db_path?: string;
131
132
  checkpoint_on?: string[];
132
133
  [key: string]: any;
133
134
  }
@@ -108,7 +108,7 @@
108
108
  * stream - Enable streaming responses (default: false)
109
109
  */
110
110
 
111
- export const SPEC_VERSION = "2.2.0";
111
+ export const SPEC_VERSION = "2.2.2";
112
112
 
113
113
  export interface ProfilesWrapper {
114
114
  spec: "flatprofiles";
@@ -1,4 +1,4 @@
1
- export const SPEC_VERSION = "2.2.0";
1
+ export const SPEC_VERSION = "2.2.2";
2
2
  export interface ProfilesWrapper {
3
3
  spec: "flatprofiles";
4
4
  spec_version: string;