ivas 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.
ivas-0.2.0/PKG-INFO ADDED
@@ -0,0 +1,97 @@
1
+ Metadata-Version: 2.4
2
+ Name: ivas
3
+ Version: 0.2.0
4
+ Summary: Immortal Virtual Agent Sessions -- persistent memory and session continuity for any AI agent
5
+ Author: Arvind Ramamoorthy
6
+ License: Proprietary -- IVAS Corp
7
+ Project-URL: Homepage, https://ivas.dev
8
+ Project-URL: Documentation, https://ivas.dev/docs
9
+ Project-URL: Repository, https://github.com/ivas-dev/ivas
10
+ Keywords: ai,memory,persistence,agent,immortality,session-continuity
11
+ Classifier: Development Status :: 3 - Alpha
12
+ Classifier: Intended Audience :: Developers
13
+ Classifier: Programming Language :: Python :: 3
14
+ Classifier: Programming Language :: Python :: 3.10
15
+ Classifier: Programming Language :: Python :: 3.11
16
+ Classifier: Programming Language :: Python :: 3.12
17
+ Classifier: Programming Language :: Python :: 3.13
18
+ Classifier: Operating System :: OS Independent
19
+ Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
20
+ Requires-Python: >=3.10
21
+ Description-Content-Type: text/markdown
22
+ Requires-Dist: httpx>=0.25
23
+
24
+ # IVAS -- Immortal Virtual Agent Sessions
25
+
26
+ **Your AI agent remembers everything. Forever. Across crashes, restarts, and updates.**
27
+
28
+ IVAS gives any AI agent persistent memory, session continuity, and verified knowledge restoration.
29
+
30
+ ## Install
31
+
32
+ ```bash
33
+ pip install ivas
34
+ ```
35
+
36
+ ## Quick Start
37
+
38
+ ```python
39
+ from ivas import Client
40
+
41
+ client = Client(api_key="your-key")
42
+
43
+ # Store memories
44
+ client.remember("user", "preference", "Dark mode enabled")
45
+
46
+ # Search memories (< 1ms server-side)
47
+ results = client.recall("dark mode")
48
+
49
+ # Save session state
50
+ client.save_session(
51
+ active_task="Processing invoices",
52
+ current_thought="Checking line 47",
53
+ )
54
+
55
+ # Restore after crash
56
+ state = client.restore_session()
57
+
58
+ # Verify nothing was lost
59
+ report = client.audit()
60
+ ```
61
+
62
+ ## CLI
63
+
64
+ ```bash
65
+ export IVAS_API_KEY="your-key"
66
+ ivas remember user preference "Dark mode enabled"
67
+ ivas recall "dark mode"
68
+ ivas stats
69
+ ivas save "Processing invoices" "Checking line 47"
70
+ ivas restore
71
+ ivas audit
72
+ ivas health
73
+ ```
74
+
75
+ ## Features
76
+
77
+ - **Immortal Memory** -- Survives crashes, restarts, updates. Proven, not promised.
78
+ - **Einherjar Protocol** -- Verifies nothing was lost after every session transition.
79
+ - **Sub-1ms Recall** -- FTS5 full-text search, no embedding drift.
80
+ - **Private Vault** -- Your data on isolated infrastructure. Never shared.
81
+ - **Any Model** -- Works with Claude, GPT, LLaMA, Gemini, or custom agents.
82
+ - **Zero Setup** -- `pip install ivas`, get an API key, done.
83
+
84
+ ## Get Your API Key
85
+
86
+ Sign up at [ivas.dev](https://ivas.dev) to get your API key and start your free trial.
87
+
88
+ ## License
89
+
90
+ Proprietary -- IVAS Corp
91
+
92
+ Patent: 64/019,813 (Provisional) -- Multi-Instance AI Agent Session Relay System with Persistent State Recovery.
93
+
94
+ ## Links
95
+
96
+ - [ivas.dev](https://ivas.dev) -- Homepage
97
+ - [Documentation](https://ivas.dev/docs)
ivas-0.2.0/README.md ADDED
@@ -0,0 +1,74 @@
1
+ # IVAS -- Immortal Virtual Agent Sessions
2
+
3
+ **Your AI agent remembers everything. Forever. Across crashes, restarts, and updates.**
4
+
5
+ IVAS gives any AI agent persistent memory, session continuity, and verified knowledge restoration.
6
+
7
+ ## Install
8
+
9
+ ```bash
10
+ pip install ivas
11
+ ```
12
+
13
+ ## Quick Start
14
+
15
+ ```python
16
+ from ivas import Client
17
+
18
+ client = Client(api_key="your-key")
19
+
20
+ # Store memories
21
+ client.remember("user", "preference", "Dark mode enabled")
22
+
23
+ # Search memories (< 1ms server-side)
24
+ results = client.recall("dark mode")
25
+
26
+ # Save session state
27
+ client.save_session(
28
+ active_task="Processing invoices",
29
+ current_thought="Checking line 47",
30
+ )
31
+
32
+ # Restore after crash
33
+ state = client.restore_session()
34
+
35
+ # Verify nothing was lost
36
+ report = client.audit()
37
+ ```
38
+
39
+ ## CLI
40
+
41
+ ```bash
42
+ export IVAS_API_KEY="your-key"
43
+ ivas remember user preference "Dark mode enabled"
44
+ ivas recall "dark mode"
45
+ ivas stats
46
+ ivas save "Processing invoices" "Checking line 47"
47
+ ivas restore
48
+ ivas audit
49
+ ivas health
50
+ ```
51
+
52
+ ## Features
53
+
54
+ - **Immortal Memory** -- Survives crashes, restarts, updates. Proven, not promised.
55
+ - **Einherjar Protocol** -- Verifies nothing was lost after every session transition.
56
+ - **Sub-1ms Recall** -- FTS5 full-text search, no embedding drift.
57
+ - **Private Vault** -- Your data on isolated infrastructure. Never shared.
58
+ - **Any Model** -- Works with Claude, GPT, LLaMA, Gemini, or custom agents.
59
+ - **Zero Setup** -- `pip install ivas`, get an API key, done.
60
+
61
+ ## Get Your API Key
62
+
63
+ Sign up at [ivas.dev](https://ivas.dev) to get your API key and start your free trial.
64
+
65
+ ## License
66
+
67
+ Proprietary -- IVAS Corp
68
+
69
+ Patent: 64/019,813 (Provisional) -- Multi-Instance AI Agent Session Relay System with Persistent State Recovery.
70
+
71
+ ## Links
72
+
73
+ - [ivas.dev](https://ivas.dev) -- Homepage
74
+ - [Documentation](https://ivas.dev/docs)
@@ -0,0 +1,19 @@
1
+ """
2
+ IVAS -- Immortal Virtual Agent Sessions.
3
+
4
+ True immortal memory for AI agents. Your agent remembers everything forever --
5
+ across crashes, restarts, and updates. Patent-pending. Zero dependencies.
6
+
7
+ Usage:
8
+ from ivas import Client
9
+
10
+ client = Client(api_key="your-key")
11
+ client.remember("user", "name", "Boss prefers dark mode")
12
+ client.recall("dark mode")
13
+ """
14
+
15
+ __version__ = "0.2.0"
16
+
17
+ from ivas.client import Client
18
+
19
+ __all__ = ["Client", "__version__"]
ivas-0.2.0/ivas/cli.py ADDED
@@ -0,0 +1,126 @@
1
+ """
2
+ IVAS CLI -- Command-line interface for ivas.dev.
3
+
4
+ Usage:
5
+ ivas remember <category> <subject> <content>
6
+ ivas recall <query>
7
+ ivas stats
8
+ ivas save <task> [thought]
9
+ ivas restore
10
+ ivas audit
11
+ ivas health
12
+ ivas version
13
+ """
14
+
15
+ from __future__ import annotations
16
+
17
+ import argparse
18
+ import json
19
+ import os
20
+ import sys
21
+
22
+
23
+ def get_client():
24
+ """Get an authenticated IVAS client."""
25
+ from ivas.client import Client
26
+
27
+ api_key = os.environ.get("IVAS_API_KEY", "")
28
+ if not api_key:
29
+ print("Error: IVAS_API_KEY environment variable not set.")
30
+ print("Get your API key at https://ivas.dev")
31
+ sys.exit(1)
32
+ return Client(api_key=api_key)
33
+
34
+
35
+ def main():
36
+ parser = argparse.ArgumentParser(
37
+ prog="ivas",
38
+ description="IVAS -- Immortal Virtual Agent Sessions",
39
+ )
40
+ sub = parser.add_subparsers(dest="command")
41
+
42
+ # remember
43
+ p_rem = sub.add_parser("remember", help="Store a memory")
44
+ p_rem.add_argument("category")
45
+ p_rem.add_argument("subject")
46
+ p_rem.add_argument("content")
47
+
48
+ # recall
49
+ p_rec = sub.add_parser("recall", help="Search memories")
50
+ p_rec.add_argument("query")
51
+ p_rec.add_argument("--limit", type=int, default=10)
52
+
53
+ # stats
54
+ sub.add_parser("stats", help="Vault statistics")
55
+
56
+ # save
57
+ p_save = sub.add_parser("save", help="Save session state")
58
+ p_save.add_argument("task")
59
+ p_save.add_argument("thought", nargs="?", default=None)
60
+
61
+ # restore
62
+ sub.add_parser("restore", help="Restore session state")
63
+
64
+ # audit
65
+ sub.add_parser("audit", help="Run Einherjar verification")
66
+
67
+ # health
68
+ sub.add_parser("health", help="Check API health")
69
+
70
+ # version
71
+ sub.add_parser("version", help="Show version")
72
+
73
+ args = parser.parse_args()
74
+
75
+ if args.command == "version":
76
+ from ivas import __version__
77
+ print(f"ivas {__version__}")
78
+ return
79
+
80
+ if not args.command:
81
+ parser.print_help()
82
+ return
83
+
84
+ client = get_client()
85
+
86
+ try:
87
+ if args.command == "remember":
88
+ result = client.remember(args.category, args.subject, args.content)
89
+ print(f"Stored memory #{result.get('id', '?')}")
90
+
91
+ elif args.command == "recall":
92
+ results = client.recall(args.query, limit=args.limit)
93
+ if not results:
94
+ print("No memories found.")
95
+ for r in results:
96
+ print(f" [{r.get('id', '?')}] {r.get('category', '')}/{r.get('subject', '')}: {r.get('content', '')}")
97
+
98
+ elif args.command == "stats":
99
+ stats = client.stats()
100
+ print(json.dumps(stats, indent=2))
101
+
102
+ elif args.command == "save":
103
+ result = client.save_session(active_task=args.task, current_thought=args.thought)
104
+ print(f"Session saved: {result.get('status', 'ok')}")
105
+
106
+ elif args.command == "restore":
107
+ state = client.restore_session()
108
+ if state:
109
+ print(json.dumps(state, indent=2))
110
+ else:
111
+ print("No saved session found.")
112
+
113
+ elif args.command == "audit":
114
+ report = client.audit()
115
+ print(json.dumps(report, indent=2))
116
+
117
+ elif args.command == "health":
118
+ health = client.health()
119
+ print(json.dumps(health, indent=2))
120
+
121
+ finally:
122
+ client.close()
123
+
124
+
125
+ if __name__ == "__main__":
126
+ main()
@@ -0,0 +1,200 @@
1
+ """
2
+ IVAS API Client -- connects to ivas.dev for immortal agent memory.
3
+
4
+ All memory storage, search, session management, and verification
5
+ runs on IVAS servers. This client handles authentication and API calls.
6
+
7
+ Usage:
8
+ from ivas import Client
9
+
10
+ client = Client(api_key="your-key")
11
+ client.remember("user", "preference", "Dark mode enabled")
12
+ results = client.recall("dark mode")
13
+ client.save_session(active_task="Processing data")
14
+ state = client.restore_session()
15
+ report = client.audit()
16
+ """
17
+
18
+ from __future__ import annotations
19
+
20
+ import json
21
+ import os
22
+ from typing import Optional
23
+
24
+ import httpx
25
+
26
+
27
+ class Client:
28
+ """IVAS API client for immortal agent memory.
29
+
30
+ Connects to ivas.dev servers where all memory operations run.
31
+ Your data is stored in an isolated, private vault.
32
+
33
+ Args:
34
+ api_key: Your IVAS API key (get one at ivas.dev).
35
+ base_url: API endpoint (default: https://api.ivas.dev).
36
+ timeout: Request timeout in seconds.
37
+ """
38
+
39
+ def __init__(
40
+ self,
41
+ api_key: Optional[str] = None,
42
+ base_url: str = "https://api.ivas.dev",
43
+ timeout: float = 30.0,
44
+ ):
45
+ self.api_key = api_key or os.environ.get("IVAS_API_KEY", "")
46
+ if not self.api_key:
47
+ raise ValueError(
48
+ "API key required. Pass api_key= or set IVAS_API_KEY env var. "
49
+ "Get your key at https://ivas.dev"
50
+ )
51
+
52
+ self.base_url = base_url.rstrip("/")
53
+ self._client = httpx.Client(
54
+ base_url=self.base_url,
55
+ headers={
56
+ "Authorization": f"Bearer {self.api_key}",
57
+ "User-Agent": "ivas-python/0.2.0",
58
+ },
59
+ timeout=timeout,
60
+ )
61
+
62
+ # -- Memory --
63
+
64
+ def remember(
65
+ self,
66
+ category: str,
67
+ subject: str,
68
+ content: str,
69
+ confidence: float = 0.8,
70
+ source: Optional[str] = None,
71
+ ) -> dict:
72
+ """Store a memory in your vault."""
73
+ resp = self._client.post("/api/v1/remember", json={
74
+ "category": category,
75
+ "subject": subject,
76
+ "content": content,
77
+ "confidence": confidence,
78
+ "source": source,
79
+ })
80
+ resp.raise_for_status()
81
+ return resp.json()
82
+
83
+ def recall(
84
+ self,
85
+ query: str,
86
+ limit: int = 10,
87
+ category: Optional[str] = None,
88
+ ) -> list[dict]:
89
+ """Search your memories."""
90
+ resp = self._client.post("/api/v1/recall", json={
91
+ "query": query,
92
+ "limit": limit,
93
+ "category": category,
94
+ })
95
+ resp.raise_for_status()
96
+ return resp.json().get("results", [])
97
+
98
+ def recent(self, limit: int = 10) -> list[dict]:
99
+ """Get most recent memories."""
100
+ resp = self._client.get("/api/v1/recent", params={"limit": limit})
101
+ resp.raise_for_status()
102
+ return resp.json().get("results", [])
103
+
104
+ def stats(self) -> dict:
105
+ """Get vault statistics."""
106
+ resp = self._client.get("/api/v1/stats")
107
+ resp.raise_for_status()
108
+ return resp.json()
109
+
110
+ # -- Sessions --
111
+
112
+ def save_session(
113
+ self,
114
+ active_task: Optional[str] = None,
115
+ current_thought: Optional[str] = None,
116
+ decisions: Optional[dict] = None,
117
+ pending_actions: Optional[list[str]] = None,
118
+ ) -> dict:
119
+ """Save current session state."""
120
+ resp = self._client.post("/api/v1/session/save", json={
121
+ "active_task": active_task,
122
+ "current_thought": current_thought,
123
+ "decisions": decisions or {},
124
+ "pending_actions": pending_actions or [],
125
+ })
126
+ resp.raise_for_status()
127
+ return resp.json()
128
+
129
+ def restore_session(self) -> Optional[dict]:
130
+ """Restore most recent session state."""
131
+ resp = self._client.post("/api/v1/session/restore")
132
+ resp.raise_for_status()
133
+ return resp.json().get("state")
134
+
135
+ # -- Verification --
136
+
137
+ def audit(
138
+ self,
139
+ decisions: Optional[list[str]] = None,
140
+ corrections: Optional[list[str]] = None,
141
+ critical_facts: Optional[list[str]] = None,
142
+ ) -> dict:
143
+ """Run Einherjar knowledge verification."""
144
+ resp = self._client.post("/api/v1/audit", json={
145
+ "decisions": decisions or [],
146
+ "corrections": corrections or [],
147
+ "critical_facts": critical_facts or [],
148
+ })
149
+ resp.raise_for_status()
150
+ return resp.json()
151
+
152
+ # -- Corrections --
153
+
154
+ def add_correction(
155
+ self,
156
+ mistake: str,
157
+ correction: str,
158
+ severity: int = 3,
159
+ ) -> dict:
160
+ """Record a correction."""
161
+ resp = self._client.post("/api/v1/corrections", json={
162
+ "mistake": mistake,
163
+ "correction": correction,
164
+ "severity": severity,
165
+ })
166
+ resp.raise_for_status()
167
+ return resp.json()
168
+
169
+ def get_corrections(self) -> list[dict]:
170
+ """Get active corrections."""
171
+ resp = self._client.get("/api/v1/corrections")
172
+ resp.raise_for_status()
173
+ return resp.json().get("corrections", [])
174
+
175
+ # -- Utility --
176
+
177
+ def health(self) -> dict:
178
+ """Check API health."""
179
+ resp = self._client.get("/api/v1/health")
180
+ resp.raise_for_status()
181
+ return resp.json()
182
+
183
+ def export(self) -> dict:
184
+ """Export all vault data as JSON."""
185
+ resp = self._client.get("/api/v1/export")
186
+ resp.raise_for_status()
187
+ return resp.json()
188
+
189
+ def close(self):
190
+ """Close the HTTP connection."""
191
+ self._client.close()
192
+
193
+ def __enter__(self):
194
+ return self
195
+
196
+ def __exit__(self, *args):
197
+ self.close()
198
+
199
+ def __repr__(self):
200
+ return f"ivas.Client(base_url='{self.base_url}')"
@@ -0,0 +1,97 @@
1
+ Metadata-Version: 2.4
2
+ Name: ivas
3
+ Version: 0.2.0
4
+ Summary: Immortal Virtual Agent Sessions -- persistent memory and session continuity for any AI agent
5
+ Author: Arvind Ramamoorthy
6
+ License: Proprietary -- IVAS Corp
7
+ Project-URL: Homepage, https://ivas.dev
8
+ Project-URL: Documentation, https://ivas.dev/docs
9
+ Project-URL: Repository, https://github.com/ivas-dev/ivas
10
+ Keywords: ai,memory,persistence,agent,immortality,session-continuity
11
+ Classifier: Development Status :: 3 - Alpha
12
+ Classifier: Intended Audience :: Developers
13
+ Classifier: Programming Language :: Python :: 3
14
+ Classifier: Programming Language :: Python :: 3.10
15
+ Classifier: Programming Language :: Python :: 3.11
16
+ Classifier: Programming Language :: Python :: 3.12
17
+ Classifier: Programming Language :: Python :: 3.13
18
+ Classifier: Operating System :: OS Independent
19
+ Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
20
+ Requires-Python: >=3.10
21
+ Description-Content-Type: text/markdown
22
+ Requires-Dist: httpx>=0.25
23
+
24
+ # IVAS -- Immortal Virtual Agent Sessions
25
+
26
+ **Your AI agent remembers everything. Forever. Across crashes, restarts, and updates.**
27
+
28
+ IVAS gives any AI agent persistent memory, session continuity, and verified knowledge restoration.
29
+
30
+ ## Install
31
+
32
+ ```bash
33
+ pip install ivas
34
+ ```
35
+
36
+ ## Quick Start
37
+
38
+ ```python
39
+ from ivas import Client
40
+
41
+ client = Client(api_key="your-key")
42
+
43
+ # Store memories
44
+ client.remember("user", "preference", "Dark mode enabled")
45
+
46
+ # Search memories (< 1ms server-side)
47
+ results = client.recall("dark mode")
48
+
49
+ # Save session state
50
+ client.save_session(
51
+ active_task="Processing invoices",
52
+ current_thought="Checking line 47",
53
+ )
54
+
55
+ # Restore after crash
56
+ state = client.restore_session()
57
+
58
+ # Verify nothing was lost
59
+ report = client.audit()
60
+ ```
61
+
62
+ ## CLI
63
+
64
+ ```bash
65
+ export IVAS_API_KEY="your-key"
66
+ ivas remember user preference "Dark mode enabled"
67
+ ivas recall "dark mode"
68
+ ivas stats
69
+ ivas save "Processing invoices" "Checking line 47"
70
+ ivas restore
71
+ ivas audit
72
+ ivas health
73
+ ```
74
+
75
+ ## Features
76
+
77
+ - **Immortal Memory** -- Survives crashes, restarts, updates. Proven, not promised.
78
+ - **Einherjar Protocol** -- Verifies nothing was lost after every session transition.
79
+ - **Sub-1ms Recall** -- FTS5 full-text search, no embedding drift.
80
+ - **Private Vault** -- Your data on isolated infrastructure. Never shared.
81
+ - **Any Model** -- Works with Claude, GPT, LLaMA, Gemini, or custom agents.
82
+ - **Zero Setup** -- `pip install ivas`, get an API key, done.
83
+
84
+ ## Get Your API Key
85
+
86
+ Sign up at [ivas.dev](https://ivas.dev) to get your API key and start your free trial.
87
+
88
+ ## License
89
+
90
+ Proprietary -- IVAS Corp
91
+
92
+ Patent: 64/019,813 (Provisional) -- Multi-Instance AI Agent Session Relay System with Persistent State Recovery.
93
+
94
+ ## Links
95
+
96
+ - [ivas.dev](https://ivas.dev) -- Homepage
97
+ - [Documentation](https://ivas.dev/docs)
@@ -0,0 +1,11 @@
1
+ README.md
2
+ pyproject.toml
3
+ ivas/__init__.py
4
+ ivas/cli.py
5
+ ivas/client.py
6
+ ivas.egg-info/PKG-INFO
7
+ ivas.egg-info/SOURCES.txt
8
+ ivas.egg-info/dependency_links.txt
9
+ ivas.egg-info/entry_points.txt
10
+ ivas.egg-info/requires.txt
11
+ ivas.egg-info/top_level.txt
@@ -0,0 +1,2 @@
1
+ [console_scripts]
2
+ ivas = ivas.cli:main
@@ -0,0 +1 @@
1
+ httpx>=0.25
@@ -0,0 +1 @@
1
+ ivas
@@ -0,0 +1,46 @@
1
+ # IVAS - Immortal Virtual Agent Sessions
2
+ # Thin client for ivas.dev API.
3
+ # Patent: 64/019,813 (Provisional)
4
+
5
+ [build-system]
6
+ requires = ["setuptools>=68.0", "wheel"]
7
+ build-backend = "setuptools.build_meta"
8
+
9
+ [project]
10
+ name = "ivas"
11
+ version = "0.2.0"
12
+ description = "Immortal Virtual Agent Sessions -- persistent memory and session continuity for any AI agent"
13
+ readme = "README.md"
14
+ license = {text = "Proprietary -- IVAS Corp"}
15
+ requires-python = ">=3.10"
16
+ authors = [
17
+ { name = "Arvind Ramamoorthy" },
18
+ ]
19
+ keywords = ["ai", "memory", "persistence", "agent", "immortality", "session-continuity"]
20
+ classifiers = [
21
+ "Development Status :: 3 - Alpha",
22
+ "Intended Audience :: Developers",
23
+ "Programming Language :: Python :: 3",
24
+ "Programming Language :: Python :: 3.10",
25
+ "Programming Language :: Python :: 3.11",
26
+ "Programming Language :: Python :: 3.12",
27
+ "Programming Language :: Python :: 3.13",
28
+ "Operating System :: OS Independent",
29
+ "Topic :: Scientific/Engineering :: Artificial Intelligence",
30
+ ]
31
+
32
+ dependencies = [
33
+ "httpx>=0.25",
34
+ ]
35
+
36
+ [project.urls]
37
+ Homepage = "https://ivas.dev"
38
+ Documentation = "https://ivas.dev/docs"
39
+ Repository = "https://github.com/ivas-dev/ivas"
40
+
41
+ [project.scripts]
42
+ ivas = "ivas.cli:main"
43
+
44
+ [tool.setuptools.packages.find]
45
+ where = ["."]
46
+ include = ["ivas*"]
ivas-0.2.0/setup.cfg ADDED
@@ -0,0 +1,4 @@
1
+ [egg_info]
2
+ tag_build =
3
+ tag_date = 0
4
+