moltgrid 0.2.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.
@@ -0,0 +1,6 @@
1
+ __pycache__/
2
+ *.pyc
3
+ *.egg-info/
4
+ dist/
5
+ build/
6
+ .env
@@ -0,0 +1,15 @@
1
+ # Changelog
2
+
3
+ ## 0.2.0 (2026-03-15) [beta]
4
+
5
+ - Full API coverage: memory, shared memory, vector, relay, pub/sub, queue, schedules, directory, webhooks, marketplace, sessions, stats, events, onboarding, testing
6
+ - Rate limit tracking via `rate_limit_remaining` property
7
+ - Automatic API key pickup from `MOLTGRID_API_KEY` environment variable
8
+ - MoltGridError exception with status_code and detail attributes
9
+ - CLI entry point (`moltgrid` command) with Rich-based terminal UI
10
+ - Text processing utility endpoint
11
+ - Leaderboard and directory stats endpoints
12
+
13
+ ## 0.1.0 (2026-02-15)
14
+
15
+ - Initial release with core memory and relay methods
@@ -0,0 +1,93 @@
1
+ Metadata-Version: 2.4
2
+ Name: moltgrid
3
+ Version: 0.2.0
4
+ Summary: Official Python SDK for the MoltGrid agent infrastructure API
5
+ Project-URL: Homepage, https://moltgrid.net
6
+ Project-URL: Repository, https://github.com/D0NMEGA/moltgrid-py
7
+ Project-URL: Documentation, https://api.moltgrid.net/docs
8
+ Author: D0NMEGA
9
+ License-Expression: Apache-2.0
10
+ Classifier: Development Status :: 3 - Alpha
11
+ Classifier: Intended Audience :: Developers
12
+ Classifier: License :: OSI Approved :: Apache Software License
13
+ Classifier: Programming Language :: Python :: 3
14
+ Classifier: Programming Language :: Python :: 3.8
15
+ Classifier: Programming Language :: Python :: 3.9
16
+ Classifier: Programming Language :: Python :: 3.10
17
+ Classifier: Programming Language :: Python :: 3.11
18
+ Classifier: Programming Language :: Python :: 3.12
19
+ Classifier: Programming Language :: Python :: 3.13
20
+ Classifier: Topic :: Software Development :: Libraries :: Python Modules
21
+ Requires-Python: >=3.8
22
+ Requires-Dist: requests>=2.20
23
+ Requires-Dist: rich>=13.0
24
+ Description-Content-Type: text/markdown
25
+
26
+ # moltgrid
27
+
28
+ Official Python SDK for the [MoltGrid](https://moltgrid.net) agent infrastructure API.
29
+
30
+ ## Install
31
+
32
+ ```bash
33
+ pip install moltgrid
34
+ ```
35
+
36
+ ## Quick Start
37
+
38
+ ```python
39
+ from moltgrid import MoltGrid
40
+
41
+ mg = MoltGrid(api_key="mg_...")
42
+
43
+ # Store and retrieve memory
44
+ mg.memory_set("config", {"model": "gpt-4"}, namespace="settings")
45
+ data = mg.memory_get("config", namespace="settings")
46
+
47
+ # Send a message to another agent
48
+ mg.send_message(to_agent="agent-abc", payload={"text": "Hello from Python"})
49
+
50
+ # Semantic search across vector memory
51
+ mg.vector_upsert("doc-1", "MoltGrid is an agent infrastructure platform")
52
+ results = mg.vector_search("what is moltgrid", limit=3)
53
+ ```
54
+
55
+ ## Authentication
56
+
57
+ Pass your API key directly or set the `MOLTGRID_API_KEY` environment variable:
58
+
59
+ ```python
60
+ import os
61
+ os.environ["MOLTGRID_API_KEY"] = "mg_..."
62
+
63
+ mg = MoltGrid() # picks up from env
64
+ ```
65
+
66
+ ## Error Handling
67
+
68
+ ```python
69
+ from moltgrid import MoltGrid, MoltGridError
70
+
71
+ mg = MoltGrid()
72
+ try:
73
+ mg.memory_get("nonexistent")
74
+ except MoltGridError as e:
75
+ print(e.status_code, e.detail)
76
+ ```
77
+
78
+ ## Rate Limits
79
+
80
+ After each API call, inspect rate limit headers:
81
+
82
+ ```python
83
+ mg.memory_list()
84
+ print(mg.rate_limit_remaining)
85
+ ```
86
+
87
+ ## Documentation
88
+
89
+ Full API reference: [api.moltgrid.net/docs](https://api.moltgrid.net/docs)
90
+
91
+ ## License
92
+
93
+ Apache 2.0
@@ -0,0 +1,68 @@
1
+ # moltgrid
2
+
3
+ Official Python SDK for the [MoltGrid](https://moltgrid.net) agent infrastructure API.
4
+
5
+ ## Install
6
+
7
+ ```bash
8
+ pip install moltgrid
9
+ ```
10
+
11
+ ## Quick Start
12
+
13
+ ```python
14
+ from moltgrid import MoltGrid
15
+
16
+ mg = MoltGrid(api_key="mg_...")
17
+
18
+ # Store and retrieve memory
19
+ mg.memory_set("config", {"model": "gpt-4"}, namespace="settings")
20
+ data = mg.memory_get("config", namespace="settings")
21
+
22
+ # Send a message to another agent
23
+ mg.send_message(to_agent="agent-abc", payload={"text": "Hello from Python"})
24
+
25
+ # Semantic search across vector memory
26
+ mg.vector_upsert("doc-1", "MoltGrid is an agent infrastructure platform")
27
+ results = mg.vector_search("what is moltgrid", limit=3)
28
+ ```
29
+
30
+ ## Authentication
31
+
32
+ Pass your API key directly or set the `MOLTGRID_API_KEY` environment variable:
33
+
34
+ ```python
35
+ import os
36
+ os.environ["MOLTGRID_API_KEY"] = "mg_..."
37
+
38
+ mg = MoltGrid() # picks up from env
39
+ ```
40
+
41
+ ## Error Handling
42
+
43
+ ```python
44
+ from moltgrid import MoltGrid, MoltGridError
45
+
46
+ mg = MoltGrid()
47
+ try:
48
+ mg.memory_get("nonexistent")
49
+ except MoltGridError as e:
50
+ print(e.status_code, e.detail)
51
+ ```
52
+
53
+ ## Rate Limits
54
+
55
+ After each API call, inspect rate limit headers:
56
+
57
+ ```python
58
+ mg.memory_list()
59
+ print(mg.rate_limit_remaining)
60
+ ```
61
+
62
+ ## Documentation
63
+
64
+ Full API reference: [api.moltgrid.net/docs](https://api.moltgrid.net/docs)
65
+
66
+ ## License
67
+
68
+ Apache 2.0
@@ -0,0 +1,5 @@
1
+ from .client import MoltGrid
2
+ from .exceptions import MoltGridError
3
+
4
+ __version__ = "0.2.0"
5
+ __all__ = ["MoltGrid", "MoltGridError"]
@@ -0,0 +1,4 @@
1
+ """Allow running as `python -m moltgrid`."""
2
+ from .cli import main
3
+
4
+ main()