neuronum 2.0.4__tar.gz → 12.0.0__tar.gz

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.
@@ -1,21 +1,47 @@
1
- MIT License
2
-
3
- Copyright (c) [2025] [Neuronum Cybernetics UG (limited liability)]
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy
6
- of this software and associated documentation files (the "Software"), to deal
7
- in the Software without restriction, including without limitation the rights
8
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- copies of the Software, and to permit persons to whom the Software is
10
- furnished to do so, subject to the following conditions:
11
-
12
- The above copyright notice and this permission notice shall be included in all
13
- copies or substantial portions of the Software.
14
-
15
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
- SOFTWARE.
1
+ <h1 align="center">
2
+ <img src="https://neuronum.net/static/neuronum.svg" alt="Neuronum" width="80">
3
+ </h1>
4
+ <h4 align="center">LICENSE of the Neuronum library</h4>
5
+
6
+ <p align="center">
7
+ <a href="https://neuronum.net">
8
+ <img src="https://img.shields.io/badge/Website-Neuronum-blue" alt="Website">
9
+ </a>
10
+ <a href="https://github.com/neuronumcybernetics/neuronum">
11
+ <img src="https://img.shields.io/badge/Docs-Read%20now-green" alt="Documentation">
12
+ </a>
13
+ <a href="https://pypi.org/project/neuronum/">
14
+ <img src="https://img.shields.io/pypi/v/neuronum.svg" alt="PyPI Version">
15
+ </a>
16
+ <img src="https://img.shields.io/badge/Python-3.8%2B-yellow" alt="Python Version">
17
+ <a href="https://github.com/neuronumcybernetics/neuronum/blob/main/LICENSE.md">
18
+ <img src="https://img.shields.io/badge/License-MIT-blue.svg" alt="License">
19
+ </a>
20
+ </p>
21
+
22
+ ---
23
+
24
+ MIT License
25
+
26
+ Copyright (c) 2025 Neuronum Cybernetics UG (limited liability)
27
+
28
+ Permission is hereby granted, free of charge, to any person obtaining a copy
29
+ of this software and associated documentation files (the "Software"), to deal
30
+ in the Software without restriction, including without limitation the rights
31
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
32
+ copies of the Software, and to permit persons to whom the Software is
33
+ furnished to do so, subject to the following conditions:
34
+
35
+ The above copyright notice and this permission notice shall be included in all
36
+ copies or substantial portions of the Software.
37
+
38
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
39
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
40
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
41
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
42
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
43
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
44
+ SOFTWARE.
45
+
46
+
47
+
@@ -0,0 +1,206 @@
1
+ Metadata-Version: 2.4
2
+ Name: neuronum
3
+ Version: 12.0.0
4
+ Summary: Official Neuronum Tools Library
5
+ Home-page: https://neuronum.net
6
+ Author: Neuronum Cybernetics
7
+ Author-email: welcome@neuronum.net
8
+ Project-URL: GitHub, https://github.com/neuronumcybernetics/neuronum
9
+ Classifier: Programming Language :: Python :: 3
10
+ Classifier: License :: OSI Approved :: MIT License
11
+ Classifier: Operating System :: OS Independent
12
+ Requires-Python: >=3.8
13
+ Description-Content-Type: text/markdown
14
+ License-File: LICENSE.md
15
+ Requires-Dist: aiohttp
16
+ Requires-Dist: aiofiles
17
+ Requires-Dist: websockets
18
+ Requires-Dist: click
19
+ Requires-Dist: questionary
20
+ Requires-Dist: python-dotenv
21
+ Requires-Dist: requests
22
+ Requires-Dist: cryptography
23
+ Requires-Dist: bip_utils
24
+ Dynamic: author
25
+ Dynamic: author-email
26
+ Dynamic: classifier
27
+ Dynamic: description
28
+ Dynamic: description-content-type
29
+ Dynamic: home-page
30
+ Dynamic: license-file
31
+ Dynamic: project-url
32
+ Dynamic: requires-dist
33
+ Dynamic: requires-python
34
+ Dynamic: summary
35
+
36
+ <h1 align="center">
37
+ <img src="https://neuronum.net/static/neuronum.svg" alt="Neuronum" width="80">
38
+ </h1>
39
+ <h4 align="center">Neuronum Tools Library</h4>
40
+
41
+ <p align="center">
42
+ <a href="https://neuronum.net">
43
+ <img src="https://img.shields.io/badge/Website-Neuronum-blue" alt="Website">
44
+ </a>
45
+ <a href="https://github.com/neuronumcybernetics/neuronum">
46
+ <img src="https://img.shields.io/badge/Docs-Read%20now-green" alt="Documentation">
47
+ </a>
48
+ <a href="https://pypi.org/project/neuronum/">
49
+ <img src="https://img.shields.io/pypi/v/neuronum.svg" alt="PyPI Version">
50
+ </a><br>
51
+ <img src="https://img.shields.io/badge/Python-3.8%2B-yellow" alt="Python Version">
52
+ <a href="https://github.com/neuronumcybernetics/neuronum/blob/main/LICENSE.md">
53
+ <img src="https://img.shields.io/badge/License-MIT-blue.svg" alt="License">
54
+ </a>
55
+ </p>
56
+
57
+ ------------------
58
+
59
+ ### **Getting Started**
60
+ In this brief getting started guide, you will:
61
+ - [Learn about Neuronum Tools](#about-neuronum-tools)
62
+ - [Connect to Neuronum](#connect-to-neuronum)
63
+ - [Initialize a Tool](#initialize-a-tool)
64
+ - [Update a Tool](#update-a-tool)
65
+ - [Delete a Tool](#delete-a-tool)
66
+
67
+ ------------------
68
+
69
+ ### **About Neuronum Tools**
70
+ Neuronum Tools serve as plug and play Servers/Applications that allow ceLLai to connect to external data sources and systems. Neuronum Tools follow standardized MCP (Model Context Protocol) guidelines.
71
+
72
+ ### Requirements
73
+ - Python >= 3.8
74
+
75
+ ------------------
76
+
77
+ ### **Connect To Neuronum**
78
+ **Installation** (optional but recommended: create a virtual environment)
79
+ ```sh
80
+ pip install neuronum
81
+ ```
82
+
83
+ Create your Cell (your secure identity):
84
+ ```sh
85
+ neuronum create-cell
86
+ ```
87
+
88
+ or
89
+
90
+ Connect an existing Cell (your secure identity):
91
+ ```sh
92
+ neuronum connect-cell
93
+ ```
94
+
95
+ ------------------
96
+
97
+
98
+ ### **Initialize a Tool**
99
+ ```sh
100
+ neuronum init-tool
101
+ ```
102
+ You will be prompted to enter a tool name and description (e.g., "Test Tool" and "A simple test tool"). This will create a new folder named using the format: `Tool Name_ToolID` (e.g., `Test Tool_019ac60e-cccc-7af5-b087-f6fcf1ba1299`)
103
+
104
+ This folder will contain 2 files:
105
+ 1. **tool.config** - Configuration and metadata for your tool
106
+ 2. **tool.py** - Your Tool/MCP server implementation
107
+
108
+ **Example tool.config:**
109
+ ```config
110
+ {
111
+ "tool_meta": {
112
+ "tool_id": "019ac60e-cccc-7af5-b087-f6fcf1ba1299",
113
+ "version": "1.0.0",
114
+ "name": "Test Tool",
115
+ "description": "A simple test tool",
116
+ "audience": "private",
117
+ "logo": "https://neuronum.net/static/logo_new.png"
118
+ },
119
+ "legals": {
120
+ "terms": "https://url_to_your/terms",
121
+ "privacy_policy": "https://url_to_your/privacy_policy"
122
+ },
123
+ "requirements": [],
124
+ "variables": []
125
+ }
126
+ ```
127
+
128
+ **Example tool.py:**
129
+ ```python
130
+ """
131
+ Simple Standardized MCP Server Example
132
+ Demonstrates the official MCP protocol with stdio transport.
133
+ """
134
+
135
+ import asyncio
136
+ import json
137
+ from mcp.server import Server
138
+ from mcp.server.stdio import stdio_server
139
+ from mcp.types import Tool, TextContent
140
+
141
+ # Create server instance
142
+ app = Server("simple-example")
143
+
144
+
145
+ @app.list_tools()
146
+ async def list_tools() -> list[Tool]:
147
+ """List available tools using standard MCP protocol."""
148
+ return [
149
+ Tool(
150
+ name="echo",
151
+ description="Echo back a message",
152
+ inputSchema={
153
+ "type": "object",
154
+ "properties": {
155
+ "message": {
156
+ "type": "string",
157
+ "description": "Message to echo back"
158
+ }
159
+ },
160
+ "required": ["message"]
161
+ }
162
+ )
163
+ ]
164
+
165
+
166
+ @app.call_tool()
167
+ async def call_tool(name: str, arguments: dict) -> list[TextContent]:
168
+ """Handle tool calls using standard MCP protocol."""
169
+
170
+ if name == "echo":
171
+ message = arguments.get("message", "")
172
+ return [TextContent(
173
+ type="text",
174
+ text=f"Echo: {message}"
175
+ )]
176
+
177
+ else:
178
+ raise ValueError(f"Unknown tool: {name}")
179
+
180
+
181
+ async def main():
182
+ """Run the MCP server with stdio transport."""
183
+ async with stdio_server() as (read_stream, write_stream):
184
+ await app.run(
185
+ read_stream,
186
+ write_stream,
187
+ app.create_initialization_options()
188
+ )
189
+
190
+
191
+ if __name__ == "__main__":
192
+ asyncio.run(main())
193
+ ```
194
+
195
+
196
+ ### **Update a Tool**
197
+ After modifying your `tool.config` or `tool.py` files, submit the updates using:
198
+ ```sh
199
+ neuronum update-tool
200
+ ```
201
+
202
+ ### **Delete a Tool**
203
+ To remove a tool from Neuronum:
204
+ ```sh
205
+ neuronum delete-tool
206
+ ```
@@ -0,0 +1,171 @@
1
+ <h1 align="center">
2
+ <img src="https://neuronum.net/static/neuronum.svg" alt="Neuronum" width="80">
3
+ </h1>
4
+ <h4 align="center">Neuronum Tools Library</h4>
5
+
6
+ <p align="center">
7
+ <a href="https://neuronum.net">
8
+ <img src="https://img.shields.io/badge/Website-Neuronum-blue" alt="Website">
9
+ </a>
10
+ <a href="https://github.com/neuronumcybernetics/neuronum">
11
+ <img src="https://img.shields.io/badge/Docs-Read%20now-green" alt="Documentation">
12
+ </a>
13
+ <a href="https://pypi.org/project/neuronum/">
14
+ <img src="https://img.shields.io/pypi/v/neuronum.svg" alt="PyPI Version">
15
+ </a><br>
16
+ <img src="https://img.shields.io/badge/Python-3.8%2B-yellow" alt="Python Version">
17
+ <a href="https://github.com/neuronumcybernetics/neuronum/blob/main/LICENSE.md">
18
+ <img src="https://img.shields.io/badge/License-MIT-blue.svg" alt="License">
19
+ </a>
20
+ </p>
21
+
22
+ ------------------
23
+
24
+ ### **Getting Started**
25
+ In this brief getting started guide, you will:
26
+ - [Learn about Neuronum Tools](#about-neuronum-tools)
27
+ - [Connect to Neuronum](#connect-to-neuronum)
28
+ - [Initialize a Tool](#initialize-a-tool)
29
+ - [Update a Tool](#update-a-tool)
30
+ - [Delete a Tool](#delete-a-tool)
31
+
32
+ ------------------
33
+
34
+ ### **About Neuronum Tools**
35
+ Neuronum Tools serve as plug and play Servers/Applications that allow ceLLai to connect to external data sources and systems. Neuronum Tools follow standardized MCP (Model Context Protocol) guidelines.
36
+
37
+ ### Requirements
38
+ - Python >= 3.8
39
+
40
+ ------------------
41
+
42
+ ### **Connect To Neuronum**
43
+ **Installation** (optional but recommended: create a virtual environment)
44
+ ```sh
45
+ pip install neuronum
46
+ ```
47
+
48
+ Create your Cell (your secure identity):
49
+ ```sh
50
+ neuronum create-cell
51
+ ```
52
+
53
+ or
54
+
55
+ Connect an existing Cell (your secure identity):
56
+ ```sh
57
+ neuronum connect-cell
58
+ ```
59
+
60
+ ------------------
61
+
62
+
63
+ ### **Initialize a Tool**
64
+ ```sh
65
+ neuronum init-tool
66
+ ```
67
+ You will be prompted to enter a tool name and description (e.g., "Test Tool" and "A simple test tool"). This will create a new folder named using the format: `Tool Name_ToolID` (e.g., `Test Tool_019ac60e-cccc-7af5-b087-f6fcf1ba1299`)
68
+
69
+ This folder will contain 2 files:
70
+ 1. **tool.config** - Configuration and metadata for your tool
71
+ 2. **tool.py** - Your Tool/MCP server implementation
72
+
73
+ **Example tool.config:**
74
+ ```config
75
+ {
76
+ "tool_meta": {
77
+ "tool_id": "019ac60e-cccc-7af5-b087-f6fcf1ba1299",
78
+ "version": "1.0.0",
79
+ "name": "Test Tool",
80
+ "description": "A simple test tool",
81
+ "audience": "private",
82
+ "logo": "https://neuronum.net/static/logo_new.png"
83
+ },
84
+ "legals": {
85
+ "terms": "https://url_to_your/terms",
86
+ "privacy_policy": "https://url_to_your/privacy_policy"
87
+ },
88
+ "requirements": [],
89
+ "variables": []
90
+ }
91
+ ```
92
+
93
+ **Example tool.py:**
94
+ ```python
95
+ """
96
+ Simple Standardized MCP Server Example
97
+ Demonstrates the official MCP protocol with stdio transport.
98
+ """
99
+
100
+ import asyncio
101
+ import json
102
+ from mcp.server import Server
103
+ from mcp.server.stdio import stdio_server
104
+ from mcp.types import Tool, TextContent
105
+
106
+ # Create server instance
107
+ app = Server("simple-example")
108
+
109
+
110
+ @app.list_tools()
111
+ async def list_tools() -> list[Tool]:
112
+ """List available tools using standard MCP protocol."""
113
+ return [
114
+ Tool(
115
+ name="echo",
116
+ description="Echo back a message",
117
+ inputSchema={
118
+ "type": "object",
119
+ "properties": {
120
+ "message": {
121
+ "type": "string",
122
+ "description": "Message to echo back"
123
+ }
124
+ },
125
+ "required": ["message"]
126
+ }
127
+ )
128
+ ]
129
+
130
+
131
+ @app.call_tool()
132
+ async def call_tool(name: str, arguments: dict) -> list[TextContent]:
133
+ """Handle tool calls using standard MCP protocol."""
134
+
135
+ if name == "echo":
136
+ message = arguments.get("message", "")
137
+ return [TextContent(
138
+ type="text",
139
+ text=f"Echo: {message}"
140
+ )]
141
+
142
+ else:
143
+ raise ValueError(f"Unknown tool: {name}")
144
+
145
+
146
+ async def main():
147
+ """Run the MCP server with stdio transport."""
148
+ async with stdio_server() as (read_stream, write_stream):
149
+ await app.run(
150
+ read_stream,
151
+ write_stream,
152
+ app.create_initialization_options()
153
+ )
154
+
155
+
156
+ if __name__ == "__main__":
157
+ asyncio.run(main())
158
+ ```
159
+
160
+
161
+ ### **Update a Tool**
162
+ After modifying your `tool.config` or `tool.py` files, submit the updates using:
163
+ ```sh
164
+ neuronum update-tool
165
+ ```
166
+
167
+ ### **Delete a Tool**
168
+ To remove a tool from Neuronum:
169
+ ```sh
170
+ neuronum delete-tool
171
+ ```