@olane/os 0.7.12-alpha.57 → 0.7.12-alpha.59
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/dist/test/basic/playground.spec.js +26 -31
- package/package.json +14 -14
|
@@ -4,7 +4,6 @@ import { expect } from 'chai';
|
|
|
4
4
|
import { defaultOSInstance } from '../utils/os.default.js';
|
|
5
5
|
import { oNodeAddress, oNodeTransport } from '@olane/o-node';
|
|
6
6
|
import { tmpNode } from '../utils/tmp.node.js';
|
|
7
|
-
import { oLimitedTool } from '@olane/o-client-limited';
|
|
8
7
|
const network = defaultOSInstance;
|
|
9
8
|
const entryNode = tmpNode;
|
|
10
9
|
let humanNode;
|
|
@@ -18,13 +17,13 @@ describe('playground running', async () => {
|
|
|
18
17
|
// '/dns4/leader.olane.com/tcp/4000/tls/ws',
|
|
19
18
|
'/ip4/127.0.0.1/tcp/4000/ws/p2p/12D3KooWPHdsHhEdyBd9DS2zHJ1vRSyqSkZ97iT7F8ByYJ7U7bw8'),
|
|
20
19
|
]);
|
|
21
|
-
const joinedNode = new oLimitedTool({
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
});
|
|
27
|
-
await joinedNode.start(); // should join the network
|
|
20
|
+
// const joinedNode = new oLimitedTool({
|
|
21
|
+
// address: new oNodeAddress('o://joined'),
|
|
22
|
+
// leader: leader,
|
|
23
|
+
// parent: leader,
|
|
24
|
+
// joinToken: 'test',
|
|
25
|
+
// });
|
|
26
|
+
// await joinedNode.start(); // should join the network
|
|
28
27
|
// humanNode = new oHumanLoginTool({
|
|
29
28
|
// address: new oNodeAddress('o://human'),
|
|
30
29
|
// leader: leader,
|
|
@@ -40,32 +39,28 @@ describe('playground running', async () => {
|
|
|
40
39
|
// },
|
|
41
40
|
// });
|
|
42
41
|
// await humanNode.start();
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
42
|
+
const response = await entryNode.useStream(leader, {
|
|
43
|
+
method: 'intent',
|
|
44
|
+
params: {
|
|
45
|
+
_isStreaming: true,
|
|
46
|
+
intent: 'Use o://intelligence to generate the expo react native code for a new table view with example data populated',
|
|
47
|
+
_token: 'test',
|
|
48
|
+
},
|
|
49
|
+
}, {
|
|
50
|
+
abortSignal: AbortSignal.timeout(5000),
|
|
51
|
+
onChunk: (chunk) => {
|
|
52
|
+
console.log('Received chunk:', JSON.stringify(chunk.result.data, null, 2));
|
|
53
|
+
},
|
|
54
|
+
});
|
|
55
|
+
console.log('Response:', JSON.stringify(response, null, 2));
|
|
56
|
+
// const response = await entryNode.use(
|
|
57
|
+
// new oNodeAddress('o://leader/joined', leader.transports),
|
|
54
58
|
// {
|
|
55
|
-
//
|
|
56
|
-
//
|
|
57
|
-
// console.log(
|
|
58
|
-
// 'Received chunk:',
|
|
59
|
-
// JSON.stringify(chunk.result.data, null, 2),
|
|
60
|
-
// );
|
|
61
|
-
// },
|
|
59
|
+
// method: 'ping',
|
|
60
|
+
// params: {},
|
|
62
61
|
// },
|
|
63
62
|
// );
|
|
64
|
-
|
|
65
|
-
method: 'ping',
|
|
66
|
-
params: {},
|
|
67
|
-
});
|
|
68
|
-
console.log('Response:', response.result.data);
|
|
63
|
+
// console.log('Response:', response.result.data);
|
|
69
64
|
await entryNode.stop();
|
|
70
65
|
});
|
|
71
66
|
// it('should fail when action is not approved', async () => {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@olane/os",
|
|
3
|
-
"version": "0.7.12-alpha.
|
|
3
|
+
"version": "0.7.12-alpha.59",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "dist/src/index.js",
|
|
6
6
|
"types": "dist/src/index.d.ts",
|
|
@@ -57,23 +57,23 @@
|
|
|
57
57
|
"typescript": "5.4.5"
|
|
58
58
|
},
|
|
59
59
|
"dependencies": {
|
|
60
|
-
"@olane/o-client-limited": "0.7.12-alpha.
|
|
61
|
-
"@olane/o-config": "0.7.12-alpha.
|
|
62
|
-
"@olane/o-core": "0.7.12-alpha.
|
|
63
|
-
"@olane/o-intelligence": "0.7.12-alpha.
|
|
64
|
-
"@olane/o-lane": "0.7.12-alpha.
|
|
65
|
-
"@olane/o-leader": "0.7.12-alpha.
|
|
66
|
-
"@olane/o-login": "0.7.12-alpha.
|
|
67
|
-
"@olane/o-protocol": "0.7.12-alpha.
|
|
68
|
-
"@olane/o-storage": "0.7.12-alpha.
|
|
69
|
-
"@olane/o-tool": "0.7.12-alpha.
|
|
70
|
-
"@olane/o-tool-registry": "0.7.12-alpha.
|
|
71
|
-
"@olane/o-tools-common": "0.7.12-alpha.
|
|
60
|
+
"@olane/o-client-limited": "0.7.12-alpha.59",
|
|
61
|
+
"@olane/o-config": "0.7.12-alpha.59",
|
|
62
|
+
"@olane/o-core": "0.7.12-alpha.59",
|
|
63
|
+
"@olane/o-intelligence": "0.7.12-alpha.59",
|
|
64
|
+
"@olane/o-lane": "0.7.12-alpha.59",
|
|
65
|
+
"@olane/o-leader": "0.7.12-alpha.59",
|
|
66
|
+
"@olane/o-login": "0.7.12-alpha.59",
|
|
67
|
+
"@olane/o-protocol": "0.7.12-alpha.59",
|
|
68
|
+
"@olane/o-storage": "0.7.12-alpha.59",
|
|
69
|
+
"@olane/o-tool": "0.7.12-alpha.59",
|
|
70
|
+
"@olane/o-tool-registry": "0.7.12-alpha.59",
|
|
71
|
+
"@olane/o-tools-common": "0.7.12-alpha.59",
|
|
72
72
|
"chalk": "^5.4.1",
|
|
73
73
|
"debug": "^4.4.1",
|
|
74
74
|
"dotenv": "^16.5.0",
|
|
75
75
|
"fs-extra": "^11.3.0",
|
|
76
76
|
"touch": "^3.1.1"
|
|
77
77
|
},
|
|
78
|
-
"gitHead": "
|
|
78
|
+
"gitHead": "e444856d725e14b45e3ea8bf726fcb6eef021a79"
|
|
79
79
|
}
|