@ai.ntellect/core 1.1.0 → 1.1.2
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.
- package/README.md +25 -71
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -75,15 +75,14 @@ pnpm add @ai.ntellect/core zod
|
|
|
75
75
|
## Table of Contents
|
|
76
76
|
|
|
77
77
|
- [Core Thesis](#core-thesis)
|
|
78
|
-
- [
|
|
79
|
-
- [
|
|
80
|
-
- [
|
|
81
|
-
- [
|
|
82
|
-
- [
|
|
83
|
-
- [Persistence — Memory & Checkpoints](#persistence--memory--checkpoints)
|
|
78
|
+
- [GraphFlow](#graphflow)
|
|
79
|
+
- [CortexFlow](#cortexflow)
|
|
80
|
+
- [Agent](#agent)
|
|
81
|
+
- [Pipelines](#pipelines)
|
|
82
|
+
- [Persistence](#persistence)
|
|
84
83
|
- [Planner & Compiler](#planner--compiler)
|
|
85
|
-
- [CLI
|
|
86
|
-
- [
|
|
84
|
+
- [CLI](#cli)
|
|
85
|
+
- [GraphController](#graphcontroller)
|
|
87
86
|
|
|
88
87
|
---
|
|
89
88
|
|
|
@@ -101,31 +100,6 @@ This split means the LLM is called exactly **once per turn** for intent classifi
|
|
|
101
100
|
|
|
102
101
|
---
|
|
103
102
|
|
|
104
|
-
## Source Structure
|
|
105
|
-
|
|
106
|
-
```
|
|
107
|
-
@ai.ntellect/core
|
|
108
|
-
├── execution/ # GraphFlow engine (typed nodes, events, checkpoints, planner, compiler)
|
|
109
|
-
├── routing/ # PetriNet, CortexFlowOrchestrator, IntentClassifier
|
|
110
|
-
├── agent/ # Agent, GenericExecutor, handlers, tools
|
|
111
|
-
├── persistence/ # Barrel: Memory + checkpoint adapters
|
|
112
|
-
├── pipeline/ # AgentPipeline (trigger → stages → gate)
|
|
113
|
-
├── modules/ # Plugins: agenda, cli, embedding, memory, nlp
|
|
114
|
-
├── interfaces/ # Contract interfaces
|
|
115
|
-
├── types/ # Zod schemas
|
|
116
|
-
└── index.ts # Barrel: all public API exports
|
|
117
|
-
```
|
|
118
|
-
|
|
119
|
-
### Path Aliases
|
|
120
|
-
|
|
121
|
-
- `@ai.ntellect/core` — root barrel (all major exports)
|
|
122
|
-
- `@ai.ntellect/core/execution/...` — deep imports for GraphFlow internals
|
|
123
|
-
- `@ai.ntellect/core/routing/...` — deep imports for PetriNet / CortexFlow
|
|
124
|
-
- `@ai.ntellect/core/agent/...` — deep imports for Agent module
|
|
125
|
-
- `@ai.ntellect/core/pipeline/...` — deep imports for AgentPipeline
|
|
126
|
-
|
|
127
|
-
---
|
|
128
|
-
|
|
129
103
|
## GraphFlow — Typed Execution
|
|
130
104
|
|
|
131
105
|
A `GraphFlow` is a **typed state machine** where each node is a discrete unit of logic.
|
|
@@ -227,12 +201,12 @@ const result = await orchestrator.orchestrate("Summarise my last 5 emails", sess
|
|
|
227
201
|
|
|
228
202
|
### Key Components
|
|
229
203
|
|
|
230
|
-
|
|
|
231
|
-
|
|
232
|
-
| `PetriNet` |
|
|
233
|
-
| `CortexFlowOrchestrator` |
|
|
234
|
-
| `IntentClassifier` |
|
|
235
|
-
| `HybridIntentClassifier` |
|
|
204
|
+
| Component | Description |
|
|
205
|
+
|--------|-------------|
|
|
206
|
+
| `PetriNet` | Core Petri Net engine |
|
|
207
|
+
| `CortexFlowOrchestrator` | Intent → routing → execution |
|
|
208
|
+
| `IntentClassifier` | LLM-based intent classification |
|
|
209
|
+
| `HybridIntentClassifier` | Keyword + LLM fallback |
|
|
236
210
|
|
|
237
211
|
### Advanced Features
|
|
238
212
|
|
|
@@ -265,15 +239,14 @@ const result = await agent.process("What is 25 + 7?");
|
|
|
265
239
|
|
|
266
240
|
### Cognitive Loop Components
|
|
267
241
|
|
|
268
|
-
| Component |
|
|
269
|
-
|
|
270
|
-
| `Agent` |
|
|
271
|
-
| `GenericExecutor` |
|
|
272
|
-
| `
|
|
273
|
-
| `
|
|
274
|
-
| `
|
|
275
|
-
|
|
|
276
|
-
| Tools (`file-system`, etc.) | `agent/tools/` | Prebuilt agent tools |
|
|
242
|
+
| Component | Description |
|
|
243
|
+
|-----------|-------------|
|
|
244
|
+
| `Agent` | Public API: orchestrates the cognitive loop |
|
|
245
|
+
| `GenericExecutor` | Decision-making + action execution |
|
|
246
|
+
| `CognitiveHandler` | Context-aware goal computation and next-state routing |
|
|
247
|
+
| `LLMFactory` | Multi-provider LLM client (OpenAI, Groq, Ollama, etc.) |
|
|
248
|
+
| `PromptBuilder` | Structured prompt construction |
|
|
249
|
+
| Tools | Prebuilt agent utilities (`file-system`, `shell`, etc.) |
|
|
277
250
|
|
|
278
251
|
### Built-in Agent Tools
|
|
279
252
|
|
|
@@ -290,7 +263,7 @@ import {
|
|
|
290
263
|
|
|
291
264
|
---
|
|
292
265
|
|
|
293
|
-
##
|
|
266
|
+
## Pipelines
|
|
294
267
|
|
|
295
268
|
Declarative pipelines with triggers, typed stages, and human gates.
|
|
296
269
|
|
|
@@ -435,28 +408,9 @@ await controller.sequential("workflow_a", "workflow_b");
|
|
|
435
408
|
|
|
436
409
|
---
|
|
437
410
|
|
|
438
|
-
## Testing & Build
|
|
439
|
-
|
|
440
|
-
```sh
|
|
441
|
-
pnpm run build # tsc → dist/
|
|
442
|
-
pnpm test # Mocha via ts-node (5s timeout)
|
|
443
|
-
pnpm run test:all # Full suite (test/**/*.test.ts)
|
|
444
|
-
pnpm test --grep "suite name" # Focused suite
|
|
445
|
-
pnpm run test:watch # Watch mode
|
|
446
|
-
```
|
|
447
|
-
|
|
448
|
-
**Real LLM tests**: `pnpm test --grep "CortexFlow Real LLM"` (requires Ollama `llama3:latest` on `localhost:11434`).
|
|
449
|
-
|
|
450
|
-
**Examples**:
|
|
451
|
-
|
|
452
|
-
```sh
|
|
453
|
-
pnpm run example:hello
|
|
454
|
-
pnpm run example:agent
|
|
455
|
-
pnpm run example:onchain
|
|
456
|
-
```
|
|
457
|
-
|
|
458
|
-
---
|
|
459
|
-
|
|
460
411
|
## License
|
|
461
412
|
|
|
462
413
|
MIT
|
|
414
|
+
cense
|
|
415
|
+
|
|
416
|
+
MIT
|