|
3 | 3 | {
|
4 | 4 | "cell_type": "code",
|
5 | 5 | "execution_count": 1,
|
6 |
| - "id": "incredible-yemen", |
| 6 | + "id": "voluntary-psychiatry", |
7 | 7 | "metadata": {},
|
8 | 8 | "outputs": [
|
9 | 9 | {
|
|
12 | 12 | "text": [
|
13 | 13 | "IPython autoawait is `on`, and set to use `asyncio`\n"
|
14 | 14 | ]
|
15 |
| - }, |
16 |
| - { |
17 |
| - "ename": "ModuleNotFoundError", |
18 |
| - "evalue": "No module named 'aries_basic_controller'", |
19 |
| - "output_type": "error", |
20 |
| - "traceback": [ |
21 |
| - "\u001b[0;31m---------------------------------------------------------------------------\u001b[0m", |
22 |
| - "\u001b[0;31mModuleNotFoundError\u001b[0m Traceback (most recent call last)", |
23 |
| - "\u001b[0;32m<ipython-input-1-cf8eac349ea5>\u001b[0m in \u001b[0;36m<module>\u001b[0;34m\u001b[0m\n\u001b[1;32m 2\u001b[0m \u001b[0;32mimport\u001b[0m \u001b[0mtime\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 3\u001b[0m \u001b[0;32mimport\u001b[0m \u001b[0masyncio\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m----> 4\u001b[0;31m \u001b[0;32mfrom\u001b[0m \u001b[0maries_basic_controller\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0maries_controller\u001b[0m \u001b[0;32mimport\u001b[0m \u001b[0mAriesAgentController\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m 5\u001b[0m \u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 6\u001b[0m \u001b[0mWEBHOOK_HOST\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0;34m\"0.0.0.0\"\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n", |
24 |
| - "\u001b[0;31mModuleNotFoundError\u001b[0m: No module named 'aries_basic_controller'" |
25 |
| - ] |
26 | 15 | }
|
27 | 16 | ],
|
28 | 17 | "source": [
|
|
34 | 23 | "WEBHOOK_HOST = \"0.0.0.0\"\n",
|
35 | 24 | "WEBHOOK_PORT = 8052\n",
|
36 | 25 | "WEBHOOK_BASE = \"\"\n",
|
37 |
| - "ADMIN_URL = \"http://hospital1-agent:8051\"\n", |
| 26 | + "# ADMIN_URL = \"http://hospital1-agent:8051\"\n", |
| 27 | + "ADMIN_URL = \"http://0.0.0.0:8051\"\n", |
38 | 28 | "\n",
|
39 | 29 | "agent_controller = AriesAgentController(webhook_host=WEBHOOK_HOST, webhook_port=WEBHOOK_PORT,\n",
|
40 | 30 | " webhook_base=WEBHOOK_BASE, admin_url=ADMIN_URL)"
|
41 | 31 | ]
|
42 | 32 | },
|
43 | 33 | {
|
44 | 34 | "cell_type": "code",
|
45 |
| - "execution_count": 4, |
46 |
| - "id": "adaptive-monte", |
| 35 | + "execution_count": 2, |
| 36 | + "id": "hairy-richardson", |
47 | 37 | "metadata": {},
|
48 | 38 | "outputs": [],
|
49 | 39 | "source": [
|
|
77 | 67 | },
|
78 | 68 | {
|
79 | 69 | "cell_type": "markdown",
|
80 |
| - "id": "quick-shanghai", |
| 70 | + "id": "potential-satellite", |
81 | 71 | "metadata": {},
|
82 | 72 | "source": [
|
83 | 73 | "## Copy Invite from Researcher"
|
84 | 74 | ]
|
85 | 75 | },
|
86 | 76 | {
|
87 | 77 | "cell_type": "code",
|
88 |
| - "execution_count": 5, |
89 |
| - "id": "rubber-thirty", |
| 78 | + "execution_count": 3, |
| 79 | + "id": "charming-newton", |
90 | 80 | "metadata": {},
|
91 | 81 | "outputs": [],
|
92 | 82 | "source": [
|
93 | 83 | "#Paste in invitation from researcher agent\n",
|
94 |
| - "invitation = {'@type': 'did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/connections/1.0/invitation', '@id': '31d22c96-b531-467a-8637-867f0e9199ac', 'label': 'Health Researcher', 'serviceEndpoint': 'http://172.17.0.1:8040', 'recipientKeys': ['Hu8va1kwBxycxKa731q6FeenAmhk5s3x2X3MXXR7CckE']}" |
| 84 | + "invitation = {'@type': 'did:sov:BzCbsNYhMrjHiqZDTUASHg;spec/connections/1.0/invitation', '@id': '0ffe0480-5b18-432e-869d-a8d0b44e1095', 'serviceEndpoint': 'http://192.168.65.3:8040', 'recipientKeys': ['9unc3yUPfSsTxM9FsrDmVwFWe3icW3qokVFwiNzNKbhs'], 'label': 'Health Researcher'}" |
95 | 85 | ]
|
96 | 86 | },
|
97 | 87 | {
|
98 | 88 | "cell_type": "code",
|
99 |
| - "execution_count": 6, |
100 |
| - "id": "micro-attraction", |
| 89 | + "execution_count": 4, |
| 90 | + "id": "religious-xerox", |
101 | 91 | "metadata": {},
|
102 | 92 | "outputs": [
|
103 | 93 | {
|
104 | 94 | "name": "stdout",
|
105 | 95 | "output_type": "stream",
|
106 | 96 | "text": [
|
107 |
| - "Connection Handler Called\n", |
108 |
| - "Connection ec35bfc5-68ef-45c4-87c6-5d9f63819c77 in State invitation\n", |
109 |
| - "Connection Handler Called\n", |
110 |
| - "Connection ec35bfc5-68ef-45c4-87c6-5d9f63819c77 in State request\n", |
111 |
| - "Connection {'invitation_key': 'Hu8va1kwBxycxKa731q6FeenAmhk5s3x2X3MXXR7CckE', 'state': 'request', 'connection_id': 'ec35bfc5-68ef-45c4-87c6-5d9f63819c77', 'routing_state': 'none', 'updated_at': '2021-01-23 14:22:15.871577Z', 'initiator': 'external', 'invitation_mode': 'once', 'created_at': '2021-01-23 14:22:15.851490Z', 'accept': 'manual', 'their_label': 'Health Researcher', 'my_did': 'ALrPXCqEuqa5wYFUDDkfeo', 'request_id': 'b9560178-dc00-4496-9a8c-2da146166b4d'}\n", |
112 |
| - "Connection Handler Called\n", |
113 |
| - "Connection ec35bfc5-68ef-45c4-87c6-5d9f63819c77 in State response\n", |
114 |
| - "Connection Handler Called\n", |
115 |
| - "Connection ec35bfc5-68ef-45c4-87c6-5d9f63819c77 in State active\n" |
| 97 | + "Connection {'routing_state': 'none', 'request_id': '4daeee1e-55f7-4595-abf3-9d3415c87062', 'their_label': 'Health Researcher', 'invitation_key': '9unc3yUPfSsTxM9FsrDmVwFWe3icW3qokVFwiNzNKbhs', 'accept': 'manual', 'initiator': 'external', 'invitation_mode': 'once', 'created_at': '2021-01-25 11:03:59.525988Z', 'connection_id': 'c10446d0-7783-4db2-8817-02162115162c', 'my_did': '7vWuaxg22g8mo7WBS1e8vn', 'state': 'request', 'updated_at': '2021-01-25 11:03:59.560705Z'}\n" |
116 | 98 | ]
|
117 | 99 | }
|
118 | 100 | ],
|
|
126 | 108 | },
|
127 | 109 | {
|
128 | 110 | "cell_type": "code",
|
129 |
| - "execution_count": null, |
130 |
| - "id": "civilian-exhibit", |
| 111 | + "execution_count": 5, |
| 112 | + "id": "boxed-scott", |
131 | 113 | "metadata": {},
|
132 |
| - "outputs": [], |
| 114 | + "outputs": [ |
| 115 | + { |
| 116 | + "name": "stdout", |
| 117 | + "output_type": "stream", |
| 118 | + "text": [ |
| 119 | + "Alice AGENT CONNECTION\n", |
| 120 | + "{'routing_state': 'none', 'request_id': '4daeee1e-55f7-4595-abf3-9d3415c87062', 'their_label': 'Health Researcher', 'invitation_key': '9unc3yUPfSsTxM9FsrDmVwFWe3icW3qokVFwiNzNKbhs', 'accept': 'manual', 'initiator': 'external', 'invitation_mode': 'once', 'created_at': '2021-01-25 11:03:59.525988Z', 'connection_id': 'c10446d0-7783-4db2-8817-02162115162c', 'my_did': '7vWuaxg22g8mo7WBS1e8vn', 'state': 'request', 'updated_at': '2021-01-25 11:03:59.560705Z'}\n", |
| 121 | + "State: request\n" |
| 122 | + ] |
| 123 | + } |
| 124 | + ], |
133 | 125 | "source": [
|
134 | 126 | "# Print connection list\n",
|
135 | 127 | "connection = await agent_controller.connections.get_connection(alice_id)\n",
|
|
141 | 133 | {
|
142 | 134 | "cell_type": "code",
|
143 | 135 | "execution_count": 6,
|
144 |
| - "id": "external-compact", |
| 136 | + "id": "considerable-consequence", |
145 | 137 | "metadata": {},
|
146 | 138 | "outputs": [
|
147 | 139 | {
|
|
297 | 289 | },
|
298 | 290 | {
|
299 | 291 | "cell_type": "markdown",
|
300 |
| - "id": "numerous-fruit", |
| 292 | + "id": "peaceful-thousand", |
301 | 293 | "metadata": {},
|
302 | 294 | "source": [
|
303 | 295 | "# For the Training follow the Number's Sequence"
|
304 | 296 | ]
|
305 | 297 | },
|
306 | 298 | {
|
307 | 299 | "cell_type": "markdown",
|
308 |
| - "id": "instructional-feelings", |
| 300 | + "id": "copyrighted-charger", |
309 | 301 | "metadata": {},
|
310 | 302 | "source": [
|
311 | 303 | "## 2. The Hospital receives the model from the Researcher, Trains it using its own dataset, and saves it as \"/../trained_model.pt\""
|
|
314 | 306 | {
|
315 | 307 | "cell_type": "code",
|
316 | 308 | "execution_count": 7,
|
317 |
| - "id": "black-boards", |
| 309 | + "id": "binary-indonesian", |
318 | 310 | "metadata": {
|
319 | 311 | "scrolled": true
|
320 | 312 | },
|
|
416 | 408 | {
|
417 | 409 | "cell_type": "code",
|
418 | 410 | "execution_count": null,
|
419 |
| - "id": "dependent-increase", |
| 411 | + "id": "familiar-conspiracy", |
420 | 412 | "metadata": {},
|
421 | 413 | "outputs": [],
|
422 | 414 | "source": [
|
|
428 | 420 | {
|
429 | 421 | "cell_type": "code",
|
430 | 422 | "execution_count": null,
|
431 |
| - "id": "nearby-advocate", |
| 423 | + "id": "medical-philosophy", |
432 | 424 | "metadata": {},
|
433 | 425 | "outputs": [],
|
434 | 426 | "source": [
|
|
0 commit comments