@axiom-lattice/gateway 2.1.11 → 2.1.13
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/.turbo/turbo-build.log +8 -8
- package/CHANGELOG.md +16 -0
- package/README.md +53 -0
- package/dist/index.js +798 -68
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +794 -64
- package/dist/index.mjs.map +1 -1
- package/package.json +4 -4
- package/src/config.ts +124 -0
- package/src/controllers/assistant.ts +274 -3
- package/src/controllers/config.ts +126 -0
- package/src/controllers/models.ts +152 -0
- package/src/controllers/threads.ts +189 -0
- package/src/routes/index.ts +80 -1
- package/src/schemas/index.ts +74 -0
- package/src/services/supabase.ts +44 -10
- package/src/stores/assistant_store.ts +82 -0
- package/src/stores/thread_store.ts +115 -0
- package/src/types/index.ts +14 -0
package/.turbo/turbo-build.log
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
|
|
2
|
-
> @axiom-lattice/gateway@2.1.
|
|
2
|
+
> @axiom-lattice/gateway@2.1.13 build /home/runner/work/agentic/agentic/packages/gateway
|
|
3
3
|
> tsup src/index.ts --format cjs,esm --dts --clean --sourcemap
|
|
4
4
|
|
|
5
5
|
[34mCLI[39m Building entry: src/index.ts
|
|
@@ -9,13 +9,13 @@
|
|
|
9
9
|
[34mCLI[39m Cleaning output folder
|
|
10
10
|
[34mCJS[39m Build start
|
|
11
11
|
[34mESM[39m Build start
|
|
12
|
-
[32mCJS[39m [1mdist/index.js [22m[
|
|
13
|
-
[32mCJS[39m [1mdist/index.js.map [22m[
|
|
14
|
-
[32mCJS[39m ⚡️ Build success in
|
|
15
|
-
[32mESM[39m [1mdist/index.mjs [22m[
|
|
16
|
-
[32mESM[39m [1mdist/index.mjs.map [22m[
|
|
17
|
-
[32mESM[39m ⚡️ Build success in
|
|
12
|
+
[32mCJS[39m [1mdist/index.js [22m[32m58.53 KB[39m
|
|
13
|
+
[32mCJS[39m [1mdist/index.js.map [22m[32m121.16 KB[39m
|
|
14
|
+
[32mCJS[39m ⚡️ Build success in 156ms
|
|
15
|
+
[32mESM[39m [1mdist/index.mjs [22m[32m56.17 KB[39m
|
|
16
|
+
[32mESM[39m [1mdist/index.mjs.map [22m[32m121.06 KB[39m
|
|
17
|
+
[32mESM[39m ⚡️ Build success in 156ms
|
|
18
18
|
[34mDTS[39m Build start
|
|
19
|
-
[32mDTS[39m ⚡️ Build success in
|
|
19
|
+
[32mDTS[39m ⚡️ Build success in 6271ms
|
|
20
20
|
[32mDTS[39m [1mdist/index.d.ts [22m[32m3.32 KB[39m
|
|
21
21
|
[32mDTS[39m [1mdist/index.d.mts [22m[32m3.32 KB[39m
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,21 @@
|
|
|
1
1
|
# @axiom-lattice/gateway
|
|
2
2
|
|
|
3
|
+
## 2.1.13
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- d9beb3a: update setting
|
|
8
|
+
- Updated dependencies [d9beb3a]
|
|
9
|
+
- @axiom-lattice/core@2.1.9
|
|
10
|
+
- @axiom-lattice/protocols@2.1.4
|
|
11
|
+
- @axiom-lattice/queue-redis@1.0.3
|
|
12
|
+
|
|
13
|
+
## 2.1.12
|
|
14
|
+
|
|
15
|
+
### Patch Changes
|
|
16
|
+
|
|
17
|
+
- 2d9f075: lattice app
|
|
18
|
+
|
|
3
19
|
## 2.1.11
|
|
4
20
|
|
|
5
21
|
### Patch Changes
|
package/README.md
CHANGED
|
@@ -29,6 +29,59 @@ pnpm start
|
|
|
29
29
|
|
|
30
30
|
## API 接口
|
|
31
31
|
|
|
32
|
+
### Configuration API
|
|
33
|
+
|
|
34
|
+
The gateway supports dynamic configuration updates via JSON. You can update environment variables at runtime without restarting the server.
|
|
35
|
+
|
|
36
|
+
#### Get Configuration
|
|
37
|
+
|
|
38
|
+
```bash
|
|
39
|
+
GET /api/config
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
Returns the current configuration (sensitive values are masked).
|
|
43
|
+
|
|
44
|
+
#### Update Configuration
|
|
45
|
+
|
|
46
|
+
```bash
|
|
47
|
+
PUT /api/config
|
|
48
|
+
Content-Type: application/json
|
|
49
|
+
|
|
50
|
+
{
|
|
51
|
+
"config": {
|
|
52
|
+
"port": 4001,
|
|
53
|
+
"queueServiceType": "redis",
|
|
54
|
+
"redisUrl": "redis://localhost:6379",
|
|
55
|
+
"redisPassword": "your-password",
|
|
56
|
+
"queueName": "tasks"
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
**Note**: When updating `queueServiceType`, the queue service will be automatically reconfigured.
|
|
62
|
+
|
|
63
|
+
**Example**:
|
|
64
|
+
|
|
65
|
+
```typescript
|
|
66
|
+
// Update configuration from frontend
|
|
67
|
+
const response = await fetch("http://localhost:4001/api/config", {
|
|
68
|
+
method: "PUT",
|
|
69
|
+
headers: {
|
|
70
|
+
"Content-Type": "application/json",
|
|
71
|
+
},
|
|
72
|
+
body: JSON.stringify({
|
|
73
|
+
config: {
|
|
74
|
+
queueServiceType: "redis",
|
|
75
|
+
redisUrl: "redis://localhost:6379",
|
|
76
|
+
redisPassword: "your-password",
|
|
77
|
+
},
|
|
78
|
+
}),
|
|
79
|
+
});
|
|
80
|
+
|
|
81
|
+
const result = await response.json();
|
|
82
|
+
console.log(result); // { success: true, message: "Configuration updated successfully", data: {...} }
|
|
83
|
+
```
|
|
84
|
+
|
|
32
85
|
### 代理调用
|
|
33
86
|
|
|
34
87
|
- `POST /api/v1/run`: 运行代理
|