flowscript-agents 0.2.2__tar.gz → 0.2.4__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.
- flowscript_agents-0.2.4/.github/workflows/test.yml +86 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/PKG-INFO +27 -5
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/README.md +25 -3
- flowscript_agents-0.2.4/docs/brand/logo-512.png +0 -0
- flowscript_agents-0.2.4/docs/brand/social-preview.png +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/flowscript_agents/__init__.py +1 -1
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/pyproject.toml +2 -2
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/.gitignore +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/AUDIT_TRAIL_DESIGN.md +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/docs/adapters.md +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/docs/api-reference.md +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/docs/audit-trail.md +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/docs/flowscript-demo.png +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/docs/lifecycle.md +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/examples/CLAUDE.md.example +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/examples/langgraph_live_test.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/examples/temporal_e2e_test.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/flowscript_agents/audit.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/flowscript_agents/camel_ai.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/flowscript_agents/crewai.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/flowscript_agents/embeddings/__init__.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/flowscript_agents/embeddings/_utils.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/flowscript_agents/embeddings/consolidate.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/flowscript_agents/embeddings/extract.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/flowscript_agents/embeddings/index.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/flowscript_agents/embeddings/providers.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/flowscript_agents/embeddings/search.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/flowscript_agents/google_adk.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/flowscript_agents/haystack.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/flowscript_agents/langgraph.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/flowscript_agents/llamaindex.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/flowscript_agents/mcp.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/flowscript_agents/memory.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/flowscript_agents/openai_agents.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/flowscript_agents/pydantic_ai.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/flowscript_agents/query.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/flowscript_agents/smolagents.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/flowscript_agents/types.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/flowscript_agents/unified.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/scripts/validate_dedup_threshold.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/tests/conftest.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/tests/test_audit.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/tests/test_camel_ai.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/tests/test_consolidation.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/tests/test_crewai.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/tests/test_embeddings.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/tests/test_google_adk.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/tests/test_haystack.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/tests/test_langgraph.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/tests/test_llamaindex.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/tests/test_mcp.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/tests/test_memory.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/tests/test_openai_agents.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/tests/test_pydantic_ai.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/tests/test_smolagents.py +0 -0
- {flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/tests/test_temporal.py +0 -0
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
name: Tests
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: [main]
|
|
6
|
+
pull_request:
|
|
7
|
+
branches: [main]
|
|
8
|
+
workflow_dispatch:
|
|
9
|
+
|
|
10
|
+
jobs:
|
|
11
|
+
test-core:
|
|
12
|
+
strategy:
|
|
13
|
+
matrix:
|
|
14
|
+
os: [ubuntu-latest, windows-latest]
|
|
15
|
+
python-version: ['3.11', '3.12']
|
|
16
|
+
runs-on: ${{ matrix.os }}
|
|
17
|
+
steps:
|
|
18
|
+
- uses: actions/checkout@v4
|
|
19
|
+
- uses: actions/setup-python@v5
|
|
20
|
+
with:
|
|
21
|
+
python-version: ${{ matrix.python-version }}
|
|
22
|
+
|
|
23
|
+
- name: Install dependencies
|
|
24
|
+
run: |
|
|
25
|
+
pip install -e ".[dev]"
|
|
26
|
+
|
|
27
|
+
- name: Run core tests
|
|
28
|
+
run: |
|
|
29
|
+
pytest tests/test_memory.py tests/test_audit.py tests/test_consolidation.py tests/test_embeddings.py tests/test_mcp.py -v --tb=short
|
|
30
|
+
|
|
31
|
+
test-mcp-smoke:
|
|
32
|
+
strategy:
|
|
33
|
+
matrix:
|
|
34
|
+
os: [ubuntu-latest, windows-latest]
|
|
35
|
+
runs-on: ${{ matrix.os }}
|
|
36
|
+
steps:
|
|
37
|
+
- uses: actions/checkout@v4
|
|
38
|
+
- uses: actions/setup-python@v5
|
|
39
|
+
with:
|
|
40
|
+
python-version: '3.11'
|
|
41
|
+
|
|
42
|
+
- name: Install from PyPI (simulates real user)
|
|
43
|
+
run: pip install flowscript-agents
|
|
44
|
+
|
|
45
|
+
- name: Verify import
|
|
46
|
+
run: python -c "from flowscript_agents import Memory, UnifiedMemory; print('Import OK')"
|
|
47
|
+
|
|
48
|
+
- name: MCP server stdio handshake
|
|
49
|
+
shell: python
|
|
50
|
+
run: |
|
|
51
|
+
import subprocess, json, sys, time
|
|
52
|
+
|
|
53
|
+
proc = subprocess.Popen(
|
|
54
|
+
[sys.executable, '-m', 'flowscript_agents.mcp', '--memory', './test-memory.json'],
|
|
55
|
+
stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subprocess.PIPE,
|
|
56
|
+
text=True
|
|
57
|
+
)
|
|
58
|
+
time.sleep(2)
|
|
59
|
+
|
|
60
|
+
# Send initialize
|
|
61
|
+
msg = json.dumps({
|
|
62
|
+
'jsonrpc': '2.0', 'id': 1, 'method': 'initialize',
|
|
63
|
+
'params': {
|
|
64
|
+
'protocolVersion': '2025-03-26',
|
|
65
|
+
'capabilities': {},
|
|
66
|
+
'clientInfo': {'name': 'ci-test', 'version': '1.0'}
|
|
67
|
+
}
|
|
68
|
+
})
|
|
69
|
+
proc.stdin.write(msg + '\n')
|
|
70
|
+
proc.stdin.flush()
|
|
71
|
+
time.sleep(1)
|
|
72
|
+
|
|
73
|
+
response = proc.stdout.readline()
|
|
74
|
+
assert response, 'No response from MCP server'
|
|
75
|
+
data = json.loads(response)
|
|
76
|
+
assert 'result' in data, f'Bad response: {data}'
|
|
77
|
+
|
|
78
|
+
info = data['result'].get('serverInfo', {})
|
|
79
|
+
print(f"MCP server OK: {info.get('name')} v{info.get('version')}")
|
|
80
|
+
|
|
81
|
+
tools_count = len(data['result'].get('capabilities', {}).get('tools', {}))
|
|
82
|
+
print(f"Platform: {sys.platform}")
|
|
83
|
+
print(f"Python: {sys.version}")
|
|
84
|
+
|
|
85
|
+
proc.terminate()
|
|
86
|
+
print('PASS: MCP stdio handshake works')
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: flowscript-agents
|
|
3
|
-
Version: 0.2.
|
|
4
|
-
Summary: Complete agent memory: reasoning queries + vector search + auto-extraction. Decision intelligence for LangGraph, CrewAI, Google ADK, OpenAI Agents SDK, Pydantic AI, smolagents, LlamaIndex, Haystack, CAMEL-AI
|
|
3
|
+
Version: 0.2.4
|
|
4
|
+
Summary: Complete agent memory: reasoning queries + vector search + auto-extraction. Decision intelligence for LangGraph, CrewAI, Google ADK, OpenAI Agents SDK, Pydantic AI, smolagents, LlamaIndex, Haystack, and CAMEL-AI.
|
|
5
5
|
Project-URL: Homepage, https://flowscript.org
|
|
6
6
|
Project-URL: Repository, https://github.com/phillipclapham/flowscript-agents
|
|
7
7
|
Project-URL: Issues, https://github.com/phillipclapham/flowscript-agents/issues
|
|
@@ -62,9 +62,13 @@ Provides-Extra: smolagents
|
|
|
62
62
|
Requires-Dist: smolagents>=1.0.0; extra == 'smolagents'
|
|
63
63
|
Description-Content-Type: text/markdown
|
|
64
64
|
|
|
65
|
-
|
|
65
|
+
<p align="center">
|
|
66
|
+
<img src="docs/brand/logo-512.png" alt="FlowScript" width="120" />
|
|
67
|
+
</p>
|
|
66
68
|
|
|
67
|
-
|
|
69
|
+
<h1 align="center">flowscript-agents</h1>
|
|
70
|
+
|
|
71
|
+
<p align="center"><strong>Agent memory that tracks why you decided, what conflicts, and what's blocked. Not just what was said.</strong></p>
|
|
68
72
|
|
|
69
73
|
[](https://github.com/phillipclapham/flowscript-agents) [](https://pypi.org/project/flowscript-agents/) [](LICENSE) [](https://pypi.org/project/flowscript-agents/)
|
|
70
74
|
|
|
@@ -107,6 +111,16 @@ Five queries that no vector store can answer — `why()`, `tensions()`, `blocked
|
|
|
107
111
|
|
|
108
112
|
---
|
|
109
113
|
|
|
114
|
+
## Why FlowScript
|
|
115
|
+
|
|
116
|
+
Agent memory stores what happened. FlowScript stores why.
|
|
117
|
+
|
|
118
|
+
Most agent infrastructure is converging on authorization — identity, access control, audit trails for *who did what*. That's necessary. But it leaves a gap: your agent can prove it was *allowed* to make a decision, but not *why* it made it. Researchers call this "[strategic blindness](https://arxiv.org/abs/2603.18718)" — memory that tracks content without tracking reasoning.
|
|
119
|
+
|
|
120
|
+
FlowScript sits above your memory store, not instead of it. Google Memory Bank, LangGraph checkpointers, Mem0 — they remember what your agent stored. FlowScript remembers why it decided, what it traded off, and what breaks if you change your mind.
|
|
121
|
+
|
|
122
|
+
---
|
|
123
|
+
|
|
110
124
|
## Get Started
|
|
111
125
|
|
|
112
126
|
### MCP Server (Claude Code / Cursor — zero code)
|
|
@@ -191,6 +205,14 @@ The default is OpenAI `text-embedding-3-small`. To use a different provider, pas
|
|
|
191
205
|
|
|
192
206
|
You still need an LLM API key (`OPENAI_API_KEY` or `ANTHROPIC_API_KEY`) for typed extraction and consolidation, even when using local embeddings.
|
|
193
207
|
|
|
208
|
+
**Using Anthropic instead of OpenAI:**
|
|
209
|
+
|
|
210
|
+
With `ANTHROPIC_API_KEY` set, the server auto-configures extraction and consolidation using Claude Haiku. No vector search (Anthropic has no embedding API), but keyword + temporal search works well. To use a different Anthropic model:
|
|
211
|
+
|
|
212
|
+
```json
|
|
213
|
+
"args": ["--memory", "./project-memory.json", "--llm-model", "claude-sonnet-4-6"]
|
|
214
|
+
```
|
|
215
|
+
|
|
194
216
|
**Then add the [CLAUDE.md snippet](examples/CLAUDE.md.example) to your project.** This is what turns tools into a workflow. It tells your agent *when* to record decisions, surface tensions before new choices, and check blockers at session start. Without it, the tools are available but passive. With it, your agent proactively tracks your project's reasoning.
|
|
195
217
|
|
|
196
218
|
### Python SDK
|
|
@@ -353,7 +375,7 @@ Under the hood: a local semantic graph with typed nodes, typed relationships, an
|
|
|
353
375
|
| [flowscript-core](https://www.npmjs.com/package/flowscript-core) | TypeScript SDK — Memory class, 15 tools, token budgeting, audit trail | `npm install flowscript-core` |
|
|
354
376
|
| [flowscript.org](https://flowscript.org) | Web editor, D3 visualization, live query panel | Browser |
|
|
355
377
|
|
|
356
|
-
**1,
|
|
378
|
+
**1,312 tests** across Python (581) and TypeScript (731). Same audit trail format and canonical JSON serialization across both languages.
|
|
357
379
|
|
|
358
380
|
### Docs
|
|
359
381
|
|
|
@@ -1,6 +1,10 @@
|
|
|
1
|
-
|
|
1
|
+
<p align="center">
|
|
2
|
+
<img src="docs/brand/logo-512.png" alt="FlowScript" width="120" />
|
|
3
|
+
</p>
|
|
2
4
|
|
|
3
|
-
|
|
5
|
+
<h1 align="center">flowscript-agents</h1>
|
|
6
|
+
|
|
7
|
+
<p align="center"><strong>Agent memory that tracks why you decided, what conflicts, and what's blocked. Not just what was said.</strong></p>
|
|
4
8
|
|
|
5
9
|
[](https://github.com/phillipclapham/flowscript-agents) [](https://pypi.org/project/flowscript-agents/) [](LICENSE) [](https://pypi.org/project/flowscript-agents/)
|
|
6
10
|
|
|
@@ -43,6 +47,16 @@ Five queries that no vector store can answer — `why()`, `tensions()`, `blocked
|
|
|
43
47
|
|
|
44
48
|
---
|
|
45
49
|
|
|
50
|
+
## Why FlowScript
|
|
51
|
+
|
|
52
|
+
Agent memory stores what happened. FlowScript stores why.
|
|
53
|
+
|
|
54
|
+
Most agent infrastructure is converging on authorization — identity, access control, audit trails for *who did what*. That's necessary. But it leaves a gap: your agent can prove it was *allowed* to make a decision, but not *why* it made it. Researchers call this "[strategic blindness](https://arxiv.org/abs/2603.18718)" — memory that tracks content without tracking reasoning.
|
|
55
|
+
|
|
56
|
+
FlowScript sits above your memory store, not instead of it. Google Memory Bank, LangGraph checkpointers, Mem0 — they remember what your agent stored. FlowScript remembers why it decided, what it traded off, and what breaks if you change your mind.
|
|
57
|
+
|
|
58
|
+
---
|
|
59
|
+
|
|
46
60
|
## Get Started
|
|
47
61
|
|
|
48
62
|
### MCP Server (Claude Code / Cursor — zero code)
|
|
@@ -127,6 +141,14 @@ The default is OpenAI `text-embedding-3-small`. To use a different provider, pas
|
|
|
127
141
|
|
|
128
142
|
You still need an LLM API key (`OPENAI_API_KEY` or `ANTHROPIC_API_KEY`) for typed extraction and consolidation, even when using local embeddings.
|
|
129
143
|
|
|
144
|
+
**Using Anthropic instead of OpenAI:**
|
|
145
|
+
|
|
146
|
+
With `ANTHROPIC_API_KEY` set, the server auto-configures extraction and consolidation using Claude Haiku. No vector search (Anthropic has no embedding API), but keyword + temporal search works well. To use a different Anthropic model:
|
|
147
|
+
|
|
148
|
+
```json
|
|
149
|
+
"args": ["--memory", "./project-memory.json", "--llm-model", "claude-sonnet-4-6"]
|
|
150
|
+
```
|
|
151
|
+
|
|
130
152
|
**Then add the [CLAUDE.md snippet](examples/CLAUDE.md.example) to your project.** This is what turns tools into a workflow. It tells your agent *when* to record decisions, surface tensions before new choices, and check blockers at session start. Without it, the tools are available but passive. With it, your agent proactively tracks your project's reasoning.
|
|
131
153
|
|
|
132
154
|
### Python SDK
|
|
@@ -289,7 +311,7 @@ Under the hood: a local semantic graph with typed nodes, typed relationships, an
|
|
|
289
311
|
| [flowscript-core](https://www.npmjs.com/package/flowscript-core) | TypeScript SDK — Memory class, 15 tools, token budgeting, audit trail | `npm install flowscript-core` |
|
|
290
312
|
| [flowscript.org](https://flowscript.org) | Web editor, D3 visualization, live query panel | Browser |
|
|
291
313
|
|
|
292
|
-
**1,
|
|
314
|
+
**1,312 tests** across Python (581) and TypeScript (731). Same audit trail format and canonical JSON serialization across both languages.
|
|
293
315
|
|
|
294
316
|
### Docs
|
|
295
317
|
|
|
Binary file
|
|
Binary file
|
|
@@ -3,7 +3,7 @@ FlowScript Agents — Complete agent memory: reasoning + vector + auto-extractio
|
|
|
3
3
|
|
|
4
4
|
Decision intelligence memory for AI agent frameworks. Drop-in provider for
|
|
5
5
|
LangGraph, CrewAI, Google ADK, OpenAI Agents SDK, Pydantic AI, smolagents,
|
|
6
|
-
LlamaIndex, Haystack, CAMEL-AI
|
|
6
|
+
LlamaIndex, Haystack, and CAMEL-AI.
|
|
7
7
|
|
|
8
8
|
What Mem0 does, plus what Mem0 can't: typed semantic queries (why, tensions,
|
|
9
9
|
blocked, alternatives, whatIf) over agent reasoning with temporal intelligence.
|
|
@@ -4,8 +4,8 @@ build-backend = "hatchling.build"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "flowscript-agents"
|
|
7
|
-
version = "0.2.
|
|
8
|
-
description = "Complete agent memory: reasoning queries + vector search + auto-extraction. Decision intelligence for LangGraph, CrewAI, Google ADK, OpenAI Agents SDK, Pydantic AI, smolagents, LlamaIndex, Haystack, CAMEL-AI
|
|
7
|
+
version = "0.2.4"
|
|
8
|
+
description = "Complete agent memory: reasoning queries + vector search + auto-extraction. Decision intelligence for LangGraph, CrewAI, Google ADK, OpenAI Agents SDK, Pydantic AI, smolagents, LlamaIndex, Haystack, and CAMEL-AI."
|
|
9
9
|
readme = "README.md"
|
|
10
10
|
license = "MIT"
|
|
11
11
|
requires-python = ">=3.10"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/flowscript_agents/embeddings/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
{flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/flowscript_agents/embeddings/consolidate.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{flowscript_agents-0.2.2 → flowscript_agents-0.2.4}/flowscript_agents/embeddings/providers.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|