@miller-tech/uap 1.40.0 → 1.40.1

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.
Files changed (92) hide show
  1. package/README.md +109 -642
  2. package/docs/INDEX.md +48 -286
  3. package/docs/architecture/OVERVIEW.md +328 -0
  4. package/docs/architecture/PROTOCOL.md +204 -0
  5. package/docs/benchmarks/README.md +17 -192
  6. package/docs/getting-started/CONFIGURATION.md +237 -0
  7. package/docs/getting-started/INSTALLATION.md +125 -0
  8. package/docs/getting-started/QUICKSTART.md +115 -0
  9. package/docs/guides/COORDINATION.md +162 -0
  10. package/docs/guides/DELIVER.md +115 -0
  11. package/docs/guides/DEPLOY_BATCHING.md +212 -0
  12. package/docs/guides/DROIDS_AND_SKILLS.md +202 -0
  13. package/docs/guides/LOCAL_MODELS.md +148 -0
  14. package/docs/guides/MCP_ROUTER.md +195 -0
  15. package/docs/guides/MEMORY.md +235 -0
  16. package/docs/guides/MULTI_MODEL.md +223 -0
  17. package/docs/guides/POLICIES.md +190 -0
  18. package/docs/guides/WORKTREE_WORKFLOW.md +185 -0
  19. package/docs/integrations/MCP_ROUTER.md +147 -0
  20. package/docs/integrations/RTK.md +102 -0
  21. package/docs/reference/API.md +485 -0
  22. package/docs/reference/CLI.md +719 -0
  23. package/docs/reference/CONFIGURATION.md +90 -193
  24. package/docs/reference/DATABASE_SCHEMA.md +110 -344
  25. package/docs/reference/FEATURES.md +176 -472
  26. package/docs/reference/PATTERNS.md +102 -0
  27. package/docs/reference/PLATFORMS.md +83 -0
  28. package/package.json +1 -1
  29. package/docs/AGENTS.md +0 -423
  30. package/docs/DOCUMENTATION_AUDIT_REPORT.md +0 -131
  31. package/docs/GETTING_STARTED.md +0 -288
  32. package/docs/PROJECT_ANALYSIS_REPORT.md +0 -510
  33. package/docs/architecture/COMPLETE_ARCHITECTURE.md +0 -748
  34. package/docs/architecture/EXPERT_STACK.md +0 -137
  35. package/docs/architecture/MULTI_MODEL.md +0 -224
  36. package/docs/architecture/PLATFORM_GATING.md +0 -68
  37. package/docs/architecture/SYSTEM_ANALYSIS.md +0 -334
  38. package/docs/architecture/UAP_COMPLIANCE.md +0 -217
  39. package/docs/architecture/UAP_PROTOCOL.md +0 -339
  40. package/docs/architecture/UAP_STRICT_DROIDS.md +0 -172
  41. package/docs/archive/BALLS_MODE_SELF_ANALYSIS.md +0 -260
  42. package/docs/archive/BENCHMARK_GAPS_AND_PLAN.md +0 -146
  43. package/docs/archive/FAILING_TASKS_SOLUTION_PLAN.md +0 -668
  44. package/docs/archive/JINJA2-SYSTEM-MESSAGE-FIX.md +0 -209
  45. package/docs/archive/MODEL_ROUTING_IMPLEMENTATION_SUMMARY.md +0 -281
  46. package/docs/archive/MODEL_ROUTING_OPTIMIZATION_PLAN.md +0 -320
  47. package/docs/archive/NPM-PUBLISH-V0.9.1.md +0 -240
  48. package/docs/archive/OPTIMIZATION_OPTIONS.md +0 -334
  49. package/docs/archive/PARALLELISM_GAPS_AND_OPTIONS.md +0 -422
  50. package/docs/archive/POLICY_GATE_IMPLEMENTATION.md +0 -245
  51. package/docs/archive/SETUP_IMPROVEMENTS.md +0 -213
  52. package/docs/archive/UAP_GENERIC_OPTIMIZATION_PLAN.md +0 -270
  53. package/docs/archive/UAP_OPTIMIZATION_PLAN.md +0 -701
  54. package/docs/archive/UAP_V103_PATTERN_DESIGN.md +0 -315
  55. package/docs/archive/UAP_V104_COMPLIANCE_DESIGN.md +0 -223
  56. package/docs/archive/changelog/2026-03-10_uap-100-compliance.md +0 -77
  57. package/docs/archive/changelog/2026-03-10_uap-full-system-verification.md +0 -109
  58. package/docs/archive/opencode-integration-guide.md +0 -740
  59. package/docs/archive/opencode-integration-quickref.md +0 -180
  60. package/docs/benchmarks/OVERNIGHT_RUNNER.md +0 -341
  61. package/docs/benchmarks/SPECULATIVE_DECODING_JOURNEY_2026-03.md +0 -221
  62. package/docs/benchmarks/VALIDATION_PLAN.md +0 -568
  63. package/docs/blog/SPECULATIVE_DECODING_PRODUCTION_PLAYBOOK.md +0 -139
  64. package/docs/blog/local-coding-agents.md +0 -266
  65. package/docs/blog/x-thread.md +0 -254
  66. package/docs/deployment/DEPLOYMENT.md +0 -895
  67. package/docs/deployment/DEPLOYMENT_STRATEGIES.md +0 -518
  68. package/docs/deployment/DEPLOY_BATCHER_ANALYSIS.md +0 -224
  69. package/docs/deployment/DEPLOY_BATCHING.md +0 -273
  70. package/docs/deployment/DEPLOY_BUCKETING_ANALYSIS.md +0 -420
  71. package/docs/deployment/QWEN35_LLAMA_CPP.md +0 -426
  72. package/docs/deployment/UAP_LLAMA_ANTHROPIC_PROXY_BOOTSTRAP.md +0 -279
  73. package/docs/getting-started/INTEGRATION.md +0 -628
  74. package/docs/getting-started/OVERVIEW.md +0 -324
  75. package/docs/getting-started/SETUP.md +0 -377
  76. package/docs/integrations/MCP_ROUTER_SETUP.md +0 -445
  77. package/docs/integrations/RTK_INTEGRATION.md +0 -468
  78. package/docs/operations/TROUBLESHOOTING.md +0 -660
  79. package/docs/pr/PR_SPECULATIVE_DOCS_TEMPLATE.md +0 -146
  80. package/docs/pr/UPSTREAM_PRS.md +0 -424
  81. package/docs/reference/API_REFERENCE.md +0 -903
  82. package/docs/reference/EXPERT_DROIDS.md +0 -219
  83. package/docs/reference/HARNESS-MATRIX.md +0 -318
  84. package/docs/reference/PATTERN_LIBRARY.md +0 -636
  85. package/docs/reference/UAP_CLI_REFERENCE.md +0 -620
  86. package/docs/research/BEHAVIORAL_PATTERNS.md +0 -228
  87. package/docs/research/DOMAIN_STRATEGIES.md +0 -316
  88. package/docs/research/MEMORY_SYSTEMS_COMPARISON.md +0 -812
  89. package/docs/research/PATTERN_ANALYSIS_2026-01-18.md +0 -436
  90. package/docs/research/PERFORMANCE_ANALYSIS_2026-01-18.md +0 -209
  91. package/docs/research/PERFORMANCE_TEST_PLAN.md +0 -383
  92. package/docs/research/TERMINAL_BENCH_LEARNINGS.md +0 -217
package/docs/INDEX.md CHANGED
@@ -1,306 +1,68 @@
1
1
  # UAP Documentation
2
2
 
3
- > **Version:** 1.18.0
4
- > **Last Updated:** 2026-03-28
5
- > **License:** MIT
3
+ The complete documentation for the **Universal Agent Protocol** (`@miller-tech/uap` v1.40.0) — a layer that gives AI coding agents memory, judgment, and the discipline to finish the job.
6
4
 
7
- ---
8
-
9
- ## Quick Links
10
-
11
- | Section | Description |
12
- |---------|-------------|
13
- | [Getting Started](#getting-started) | Installation and quick start |
14
- | [Architecture](#architecture) | System design and components |
15
- | [Reference](#reference) | API documentation and CLI commands |
16
- | [Deployment](#deployment) | Production deployment guides |
17
- | [Benchmarks](#benchmarks) | Performance results and validation |
18
- | [Operations](#operations) | Troubleshooting and maintenance |
5
+ New here? Start with the [project README](../README.md), then [Getting Started](getting-started/).
19
6
 
20
7
  ---
21
8
 
22
- ## Getting Started
23
-
24
- ### What is UAP?
25
-
26
- **Universal Agent Protocol (UAP)** is an open protocol that enables AI agents to maintain persistent context, learn from past interactions, and apply proven patterns across tasks.
27
-
28
- ### Core Capabilities
29
-
30
- 1. **Persistent Memory**: Store and retrieve information across sessions with 4-layer architecture
31
- 2. **Pattern Application**: Leverage 58+ battle-tested workflows and decision frameworks
32
- 3. **Multi-Agent Coordination**: Coordinate work between agents to prevent conflicts
33
- 4. **CI/CD Optimization**: Reduce pipeline costs by 50-80% through intelligent batching
34
- 5. **MCP Integration**: Achieve 98% token reduction via meta-tool routing
35
-
36
- ### Quick Start
37
-
38
- ```bash
39
- # Install UAP CLI
40
- npm install -g universal-agent-protocol
41
-
42
- # Initialize in your project
43
- uap init
44
-
45
- # Create a tracked task
46
- uap task create "Implement feature X"
47
-
48
- # Use worktree for safe development
49
- uap worktree create feature-name
50
- cd .worktrees/NNN-feature-name/
51
- # Make changes...
52
- uap worktree pr <id>
53
- ```
54
-
55
- ### Prerequisites
56
-
57
- - Node.js >= 18.0.0
58
- - npm or yarn
59
- - Optional: Docker (for Qdrant semantic search)
60
-
61
- ---
9
+ ## Getting started
10
+
11
+ | Doc | What it covers |
12
+ |---|---|
13
+ | [Installation](getting-started/INSTALLATION.md) | Prerequisites, `npm install -g @miller-tech/uap`, what `uap setup` does, per-harness hook install |
14
+ | [Quickstart](getting-started/QUICKSTART.md) | 5-minute path: setup → memory → `uap deliver` → dashboard |
15
+ | [Configuration](getting-started/CONFIGURATION.md) | `.uap.json`, environment variables, Qdrant, model profiles |
16
+
17
+ ## Guides
18
+
19
+ | Doc | What it covers |
20
+ |---|---|
21
+ | [**`uap deliver`**](guides/DELIVER.md) | The delivery harness convergence loop to verified completion ⭐ |
22
+ | [Memory](guides/MEMORY.md) | The 4-tier memory system, write-gates, semantic recall |
23
+ | [MCP Router](guides/MCP_ROUTER.md) | Token-optimizing tool proxy + FTS5 output compression |
24
+ | [Worktree Workflow](guides/WORKTREE_WORKFLOW.md) | Branch-per-feature isolation, auto-PR, enforcement |
25
+ | [Policies](guides/POLICIES.md) | Executable policy gates that block non-compliant tool calls |
26
+ | [Multi-Model Routing](guides/MULTI_MODEL.md) | Plan → route → execute across 7 model profiles |
27
+ | [Droids & Skills](guides/DROIDS_AND_SKILLS.md) | 38 expert droids, 32 skills, the expert router |
28
+ | [Deploy Batching](guides/DEPLOY_BATCHING.md) | Conflict-free batched git/deploy actions |
29
+ | [Coordination](guides/COORDINATION.md) | Multi-agent overlap detection |
30
+ | [Local Models](guides/LOCAL_MODELS.md) | Running agents against local llama.cpp / Qwen models |
62
31
 
63
32
  ## Architecture
64
33
 
65
- ### System Overview
66
-
67
- UAP implements a **4-layer memory architecture** combined with multi-agent coordination:
68
-
69
- ```
70
- ┌─────────────────────────────────────────────────────────────┐
71
- │ AI Agent Layer │
72
- │ (Claude, Factory.AI, OpenCode, etc.) │
73
- └──────────────────────┬──────────────────────────────────────┘
74
-
75
- ┌──────────────────────▼──────────────────────────────────────┐
76
- │ UAP Core Layer │
77
- │ CLI │ Memory │ Coordination │ Task │ Deploy Batcher │
78
- └──────────────────────┬──────────────────────────────────────┘
79
-
80
- ┌──────────────────────▼──────────────────────────────────────┐
81
- │ │ CLI │ Memory │ Coordination │ Task │ Deploy Batcher │
82
- └──────────────────────┬──────────────────────────────────────┘
83
-
84
- ┌──────────────────────▼──────────────────────────────────────┐
85
- │ │ CLI │ Memory │ Coordination │ Task │ Deploy Batcher │
86
- └──────────────────────┬──────────────────────────────────────┘
87
-
88
- ┌──────────────────────▼──────────────────────────────────────┐
89
- │ Storage Layer │
90
- │ SQLite (Working) │ Qdrant (Semantic) │ Git (History) │
91
- └─────────────────────────────────────────────────────────────┘
92
- ```
93
-
94
- ### Key Components
95
-
96
- | Component | Purpose | Impact |
97
- |-----------|---------|--------|
98
- | **Memory System** | 4-layer persistent context | 10x retention |
99
- | **Coordination** | Multi-agent sync via SQLite | Zero conflicts |
100
- | **Task Management** | Structured workflow tracking | Full lifecycle |
101
- | **Deploy Batcher** | CI/CD optimization | 50-80% savings |
102
- | **MCP Router** | Meta-tool routing | 98% token reduction |
103
- | **Worktrees** | Safe isolated development | No main branch pollution |
104
-
105
- ---
34
+ | Doc | What it covers |
35
+ |---|---|
36
+ | [Overview](architecture/OVERVIEW.md) | System architecture, subsystems, tool-call flow |
37
+ | [Protocol](architecture/PROTOCOL.md) | The harness↔UAP contract, hook lifecycle, decision loop |
106
38
 
107
39
  ## Reference
108
40
 
109
- ### CLI Commands
110
-
111
- #### Task Management
112
-
113
- ```bash
114
- # Create and track tasks
115
- uap task create "Fix bug" --priority high
116
- uap task list --active
117
- uap task complete --reason "Fixed"
118
- ```
119
-
120
- #### Memory Operations
121
-
122
- ```bash
123
- # Store and query memories
124
- uap memory store "Best practice: validate inputs"
125
- uap memory query "authentication" --top-k 5
126
- uap memory status
127
- ```
128
-
129
- #### Worktree Workflow
130
-
131
- ```bash
132
- # Safe isolated development
133
- uap worktree create feature-name
134
- cd .worktrees/NNN-feature-name/
135
- g changes...
136
- uap worktree pr <id>
137
- uap worktree cleanup <id> # After merge
138
- ```
139
-
140
- #### Compliance
141
-
142
- ```bash
143
- # Verify protocol compliance
144
- uap compliance check
145
- uap hooks install all
146
- ```
147
-
148
- ### Database Schema
149
-
150
- UAP uses SQLite for structured data and Qdrant for semantic search:
151
-
152
- **SQLite Tables:**
153
- - `memories` - Short-term working memory (50 entries)
154
- - `session_memories` - Current session state
155
- - `entities/relationships` - Knowledge graph
156
- - `agent_registry` - Multi-agent coordination
157
- - `deploy_queue` - CI/CD batching queue
158
-
159
- **Qdrant Collections:**
160
- - `agent_memory` - Semantic embeddings (384-dim vectors)
161
- - `agent_patterns` - Pattern library indexing
162
-
163
- ---
164
-
165
- ## Deployment
166
-
167
- ### Production Setup
168
-
169
- ```bash
170
- # Start Qdrant for semantic search
171
- cd agents && docker-compose up -d
172
-
173
- # Install hooks
174
- uap hooks install all
41
+ | Doc | What it covers |
42
+ |---|---|
43
+ | [CLI](reference/CLI.md) | Every `uap` command and flag |
44
+ | [API](reference/API.md) | Programmatic API surface |
45
+ | [Features](reference/FEATURES.md) | Full feature catalog by subsystem |
46
+ | [Patterns](reference/PATTERNS.md) | The 23 Terminal-Bench patterns |
47
+ | [Platforms](reference/PLATFORMS.md) | The 9 supported harnesses + support matrix |
48
+ | [Configuration](reference/CONFIGURATION.md) | All config files and env vars |
49
+ | [Database Schema](reference/DATABASE_SCHEMA.md) | SQLite databases + Qdrant collections |
175
50
 
176
- # Verify setup
177
- uap task ready
178
- ```
51
+ ## Integrations
179
52
 
180
- ### CI/CD Integration
181
-
182
- UAP integrates with GitHub Actions via the DeployBatcher:
183
-
184
- ```yaml
185
- name: UAP CI
186
- on: [push, pull_request]
187
- jobs:
188
- build:
189
- runs-on: ubuntu-latest
190
- steps:
191
- - uses: actions/checkout@v4
192
- - name: Run UAP benchmarks
193
- run: npm run benchmark:full
194
- ```
195
-
196
- ### Model Providers
197
-
198
- | Provider | Use Case | Configuration |
199
- |----------|----------|---------------|
200
- | **Qwen3.5** | General tasks | Default, cost-effective |
201
- | **Claude Opus** | Complex reasoning | High-accuracy scenarios |
202
- | **GPT-4** | Analysis tasks | Code generation |
203
- | **Local (llama.cpp)** | Privacy-focused | Self-hosted deployments |
204
-
205
- ---
53
+ | Doc | What it covers |
54
+ |---|---|
55
+ | [MCP Router](integrations/MCP_ROUTER.md) | Setting up the MCP router across harnesses |
56
+ | [RTK](integrations/RTK.md) | Rust Token Killer integration |
206
57
 
207
58
  ## Benchmarks
208
59
 
209
- ### Performance Summary
210
-
211
- | Metric | Baseline | UAP v1.18 | Improvement |
212
- |--------|----------|-----------|-------------|
213
- | **Success Rate** | 75% | **100%** | +25pp |
214
- | **Tokens/Task** | 52K | **23.4K** | -55% |
215
- | **Time/Task** | 45s | **32s** | -29% |
216
- | **Error Rate** | 12% | **0%** | -100% |
217
-
218
- ### Full Benchmark Suite
219
-
220
- Run the complete benchmark suite:
221
-
222
- ```bash
223
- # Quick test (10 tasks)
224
- npm run benchmark:short
225
-
226
- # Full validation (14 tasks)
227
- npm run benchmark:full
228
-
229
- # Overnight extended run
230
- npm run benchmark:overnight
231
- ```
232
-
233
- Results are documented in [COMPREHENSIVE_BENCHMARKS.md](benchmarks/COMPREHENSIVE_BENCHMARKS.md).
234
-
235
- ---
236
-
237
- ## Operations
238
-
239
- ### Troubleshooting
240
-
241
- | Issue | Solution |
242
- |-------|----------|
243
- | `Qdrant connection failed` | `cd agents && docker-compose up -d` |
244
- | `Worktree already exists` | `uap worktree cleanup <id>` |
245
- | `Memory DB locked` | Close other processes using the DB |
246
- | `Compliance check failed` | Review specific gate failure in output |
247
-
248
- ### Debug Mode
249
-
250
- ```bash
251
- # Enable verbose logging
252
- export UAP_VERBOSE=true
253
-
254
- # Check memory queries
255
- uap task ready --verbose
256
-
257
- # Inspect database directly
258
- sqlite3 ./agents/data/memory/short_term.db ".tables"
259
- ```
260
-
261
- ---
60
+ | Doc | What it covers |
61
+ |---|---|
62
+ | [Validation Results](benchmarks/VALIDATION_RESULTS.md) | Terminal-Bench 2.0 results (−49.7% tokens, +33pp success) |
63
+ | [Token Optimization](benchmarks/TOKEN_OPTIMIZATION.md) | Where the token savings come from |
64
+ | [Accuracy Analysis](benchmarks/ACCURACY_ANALYSIS.md) | Success-rate and error analysis |
262
65
 
263
66
  ## Contributing
264
67
 
265
- ### Development Setup
266
-
267
- ```bash
268
- git clone https://github.com/DammianMiller/universal-agent-protocol.git
269
- cd universal-agent-protocol
270
- npm install
271
- npm run build
272
- npm test
273
- ```
274
-
275
- ### Worktree Workflow
276
-
277
- All changes must be made in a worktree:
278
-
279
- ```bash
280
- # Create worktree for your feature
281
- uap worktree create feature-description
282
-
283
- # Make changes, commit, create PR
284
- cd .worktrees/NNN-feature-description/
285
- git add -A && git commit -m "feat: description"
286
- uap worktree pr <id>
287
-
288
- # After merge, cleanup is mandatory
289
- uap worktree cleanup <id>
290
- ```
291
-
292
- ---
293
-
294
- ## License
295
-
296
- MIT License - See [LICENSE](../LICENSE) file
297
-
298
- ---
299
-
300
- <div align="center">
301
-
302
- **Maintained by:** UAP Team
303
- **Repository:** https://github.com/DammianMiller/universal-agent-protocol
304
- **Issues:** https://github.com/DammianMiller/universal-agent-protocol/issues
305
-
306
- </div>
68
+ See [CONTRIBUTING.md](../CONTRIBUTING.md) for dev setup, the worktree workflow, completion gates, and PR conventions.