adaptive-memory-multi-model-router 2.13.1 → 2.13.3
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/LANDING.md +23 -26
- package/MANIFESTO.md +21 -34
- package/README.md +886 -243
- package/dist/tui/dashboard.d.ts +9 -7
- package/dist/tui/dashboard.js +228 -454
- package/dist/tui/dashboard.js.map +1 -1
- package/package.json +2 -2
- package/src/tui/dashboard.ts +223 -490
- package/tmlpd-pi-extension/README.md +29 -29
|
@@ -1,47 +1,47 @@
|
|
|
1
|
-
# TMLPD
|
|
1
|
+
# TMLPD — Parallel Multi-LLM Execution Module
|
|
2
2
|
|
|
3
3
|
> **Part of the [A3M Router](https://github.com/Das-rebel/adaptive-memory-multi-model-router) ecosystem.**
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
Parallel multi-LLM execution with confidence-weighted ensemble merging. Runs providers simultaneously, scores each result, and returns the best answer with transparent reasoning.
|
|
6
6
|
|
|
7
7
|
## What This Is
|
|
8
8
|
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
- **Execute prompts across multiple LLMs in parallel** and pick the best result
|
|
12
|
-
- **Smart-route** single queries to the optimal provider based on task type
|
|
13
|
-
- **Track costs** across all providers and sessions
|
|
14
|
-
- **Persist agent memory** across CLI sessions
|
|
9
|
+
A TypeScript library for executing prompts across multiple LLM providers **in parallel** — not sequentially. Every provider runs at the same time, results are scored on quality, and the best answer is selected with a clear explanation of why it won.
|
|
15
10
|
|
|
16
11
|
## Core Features
|
|
17
12
|
|
|
18
|
-
|
|
|
19
|
-
|
|
20
|
-
|
|
|
21
|
-
|
|
|
22
|
-
|
|
|
23
|
-
| Cost tracking | Per-query cost display
|
|
24
|
-
| Persistent memory | Cross-session `.memory.json` with keyword indexing |
|
|
25
|
-
|
|
26
|
-
|
|
13
|
+
| Feature | Description |
|
|
14
|
+
|:--------|:------------|
|
|
15
|
+
| **Parallel execution** | Run N providers simultaneously, not sequentially |
|
|
16
|
+
| **Ensemble scoring** | Score results on specificity, structure, and relevance |
|
|
17
|
+
| **Query-type presets** | Auto-configure provider + temp per task type |
|
|
18
|
+
| **Cost tracking** | Per-query cost display with provider breakdown |
|
|
19
|
+
| **Persistent memory** | Cross-session `.memory.json` with keyword indexing |
|
|
20
|
+
| **Prefix caching** | RadixAttention-style caching for repeated prefixes |
|
|
21
|
+
| **Speculative decoding** | Medusa/EAGLE-style multi-token prediction |
|
|
22
|
+
| **Token compression** | ISON encoding for ~40% token reduction |
|
|
27
23
|
|
|
28
|
-
|
|
29
|
-
npm install tmlpd-pi
|
|
30
|
-
```
|
|
24
|
+
## Usage
|
|
31
25
|
|
|
32
26
|
```typescript
|
|
33
|
-
import {
|
|
34
|
-
|
|
35
|
-
const tmlpd = createTMLPD({ cache: { ttl_seconds: 3600 } });
|
|
27
|
+
import { executeEnsemble, createPresetRouter, EpisodicMemoryStore } from "tmlpd-pi";
|
|
36
28
|
|
|
37
|
-
// Parallel
|
|
38
|
-
const result = await
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
prompt, systemPrompt, context,
|
|
29
|
+
// Parallel ensemble: run all providers simultaneously, pick best
|
|
30
|
+
const result = await executeEnsemble(
|
|
31
|
+
"Explain vector databases",
|
|
32
|
+
systemPrompt,
|
|
33
|
+
context,
|
|
43
34
|
{ nvidia: callNvidia, groq: callGroq }
|
|
44
35
|
);
|
|
36
|
+
console.log(`Winner: ${result.winner} (score: ${result.scores[result.winner]})`);
|
|
37
|
+
|
|
38
|
+
// Query-type presets: auto-configure per task
|
|
39
|
+
const router = createPresetRouter();
|
|
40
|
+
const preset = router.classify("Write a Python sort function"); // → 'code'
|
|
41
|
+
|
|
42
|
+
// Persistent memory
|
|
43
|
+
const memory = new EpisodicMemoryStore(1000, './memory.json');
|
|
44
|
+
const similar = memory.getSimilarTasks("Python async API", 5);
|
|
45
45
|
```
|
|
46
46
|
|
|
47
47
|
## Exports
|