lynkr 8.0.0 → 9.0.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.
- package/.lynkr/telemetry.db +0 -0
- package/.lynkr/telemetry.db-shm +0 -0
- package/.lynkr/telemetry.db-wal +0 -0
- package/README.md +196 -322
- package/lynkr-skill.tar.gz +0 -0
- package/package.json +4 -3
- package/src/api/openai-router.js +64 -13
- package/src/api/providers-handler.js +171 -3
- package/src/api/router.js +9 -2
- package/src/clients/circuit-breaker.js +10 -247
- package/src/clients/codex-process.js +342 -0
- package/src/clients/codex-utils.js +143 -0
- package/src/clients/databricks.js +210 -63
- package/src/clients/resilience.js +540 -0
- package/src/clients/retry.js +22 -167
- package/src/clients/standard-tools.js +23 -0
- package/src/config/index.js +77 -0
- package/src/context/compression.js +42 -9
- package/src/context/distill.js +492 -0
- package/src/orchestrator/index.js +48 -8
- package/src/routing/complexity-analyzer.js +258 -5
- package/src/routing/index.js +12 -2
- package/src/routing/latency-tracker.js +148 -0
- package/src/routing/model-tiers.js +2 -0
- package/src/routing/quality-scorer.js +113 -0
- package/src/routing/telemetry.js +464 -0
- package/src/server.js +13 -12
- package/src/tools/code-graph.js +538 -0
- package/src/tools/code-mode.js +304 -0
- package/src/tools/index.js +4 -0
- package/src/tools/lazy-loader.js +18 -0
- package/src/tools/mcp-remote.js +7 -0
- package/src/tools/smart-selection.js +11 -0
- package/src/tools/tinyfish.js +358 -0
- package/src/tools/truncate.js +1 -0
- package/src/utils/payload.js +206 -0
- package/src/utils/perf-timer.js +80 -0
- package/.github/FUNDING.yml +0 -15
- package/.github/workflows/README.md +0 -215
- package/.github/workflows/ci.yml +0 -69
- package/.github/workflows/index.yml +0 -62
- package/.github/workflows/web-tools-tests.yml +0 -56
- package/CITATIONS.bib +0 -6
- package/DEPLOYMENT.md +0 -1001
- package/LYNKR-TUI-PLAN.md +0 -984
- package/PERFORMANCE-REPORT.md +0 -866
- package/PLAN-per-client-model-routing.md +0 -252
- package/docs/42642f749da6234f41b6b425c3bb07c9.txt +0 -1
- package/docs/BingSiteAuth.xml +0 -4
- package/docs/docs-style.css +0 -478
- package/docs/docs.html +0 -198
- package/docs/google5be250e608e6da39.html +0 -1
- package/docs/index.html +0 -577
- package/docs/index.md +0 -584
- package/docs/robots.txt +0 -4
- package/docs/sitemap.xml +0 -44
- package/docs/style.css +0 -1223
- package/docs/toon-integration-spec.md +0 -130
- package/documentation/README.md +0 -101
- package/documentation/api.md +0 -806
- package/documentation/claude-code-cli.md +0 -679
- package/documentation/codex-cli.md +0 -397
- package/documentation/contributing.md +0 -571
- package/documentation/cursor-integration.md +0 -734
- package/documentation/docker.md +0 -874
- package/documentation/embeddings.md +0 -762
- package/documentation/faq.md +0 -713
- package/documentation/features.md +0 -403
- package/documentation/headroom.md +0 -519
- package/documentation/installation.md +0 -758
- package/documentation/memory-system.md +0 -476
- package/documentation/production.md +0 -636
- package/documentation/providers.md +0 -1009
- package/documentation/routing.md +0 -476
- package/documentation/testing.md +0 -629
- package/documentation/token-optimization.md +0 -325
- package/documentation/tools.md +0 -697
- package/documentation/troubleshooting.md +0 -969
- package/final-test.js +0 -33
- package/headroom-sidecar/config.py +0 -93
- package/headroom-sidecar/requirements.txt +0 -14
- package/headroom-sidecar/server.py +0 -451
- package/monitor-agents.sh +0 -31
- package/scripts/audit-log-reader.js +0 -399
- package/scripts/compact-dictionary.js +0 -204
- package/scripts/test-deduplication.js +0 -448
- package/src/db/database.sqlite +0 -0
- package/te +0 -11622
- package/test/README.md +0 -212
- package/test/azure-openai-config.test.js +0 -213
- package/test/azure-openai-error-resilience.test.js +0 -238
- package/test/azure-openai-format-conversion.test.js +0 -354
- package/test/azure-openai-integration.test.js +0 -287
- package/test/azure-openai-routing.test.js +0 -175
- package/test/azure-openai-streaming.test.js +0 -171
- package/test/bedrock-integration.test.js +0 -457
- package/test/comprehensive-test-suite.js +0 -928
- package/test/config-validation.test.js +0 -207
- package/test/cursor-integration.test.js +0 -484
- package/test/format-conversion.test.js +0 -578
- package/test/hybrid-routing-integration.test.js +0 -269
- package/test/hybrid-routing-performance.test.js +0 -428
- package/test/llamacpp-integration.test.js +0 -882
- package/test/lmstudio-integration.test.js +0 -347
- package/test/memory/extractor.test.js +0 -398
- package/test/memory/retriever.test.js +0 -613
- package/test/memory/retriever.test.js.bak +0 -585
- package/test/memory/search.test.js +0 -537
- package/test/memory/search.test.js.bak +0 -389
- package/test/memory/store.test.js +0 -344
- package/test/memory/store.test.js.bak +0 -312
- package/test/memory/surprise.test.js +0 -300
- package/test/memory-performance.test.js +0 -472
- package/test/openai-integration.test.js +0 -683
- package/test/openrouter-error-resilience.test.js +0 -418
- package/test/passthrough-mode.test.js +0 -385
- package/test/performance-benchmark.js +0 -351
- package/test/performance-tests.js +0 -528
- package/test/routing.test.js +0 -225
- package/test/toon-compression.test.js +0 -131
- package/test/web-tools.test.js +0 -329
- package/test-agents-simple.js +0 -43
- package/test-cli-connection.sh +0 -33
- package/test-learning-unit.js +0 -126
- package/test-learning.js +0 -112
- package/test-parallel-agents.sh +0 -124
- package/test-parallel-direct.js +0 -155
- package/test-subagents.sh +0 -117
package/test-subagents.sh
DELETED
|
@@ -1,117 +0,0 @@
|
|
|
1
|
-
#!/bin/bash
|
|
2
|
-
|
|
3
|
-
# Test Subagent System
|
|
4
|
-
# This script tests the live subagent functionality
|
|
5
|
-
|
|
6
|
-
set -e
|
|
7
|
-
|
|
8
|
-
echo "🚀 Testing Subagent System"
|
|
9
|
-
echo "================================"
|
|
10
|
-
echo ""
|
|
11
|
-
|
|
12
|
-
# Load test environment (filter out comments)
|
|
13
|
-
export $(grep -v '^#' .env.test | grep -v '^$' | xargs)
|
|
14
|
-
|
|
15
|
-
# Start server in background
|
|
16
|
-
echo "1. Starting server..."
|
|
17
|
-
node index.js > /tmp/subagent-test.log 2>&1 &
|
|
18
|
-
SERVER_PID=$!
|
|
19
|
-
echo " Server PID: $SERVER_PID"
|
|
20
|
-
|
|
21
|
-
# Wait for server to start
|
|
22
|
-
echo "2. Waiting for server to be ready..."
|
|
23
|
-
for i in {1..30}; do
|
|
24
|
-
if curl -s http://localhost:8080/health > /dev/null 2>&1; then
|
|
25
|
-
echo " ✅ Server is ready!"
|
|
26
|
-
break
|
|
27
|
-
fi
|
|
28
|
-
sleep 1
|
|
29
|
-
if [ $i -eq 30 ]; then
|
|
30
|
-
echo " ❌ Server failed to start"
|
|
31
|
-
kill $SERVER_PID 2>/dev/null || true
|
|
32
|
-
exit 1
|
|
33
|
-
fi
|
|
34
|
-
done
|
|
35
|
-
|
|
36
|
-
echo ""
|
|
37
|
-
echo "3. Testing agent endpoints..."
|
|
38
|
-
|
|
39
|
-
# Test 1: List available agents
|
|
40
|
-
echo " 📋 GET /v1/agents - List available agents"
|
|
41
|
-
curl -s http://localhost:8080/v1/agents | jq -r '.agents[] | " - \(.name): \(.description[:60])..."' 2>/dev/null || echo " (Install jq for pretty output)"
|
|
42
|
-
|
|
43
|
-
echo ""
|
|
44
|
-
echo " 📊 GET /v1/agents/stats - Agent statistics"
|
|
45
|
-
curl -s http://localhost:8080/v1/agents/stats | jq . 2>/dev/null || curl -s http://localhost:8080/v1/agents/stats
|
|
46
|
-
|
|
47
|
-
echo ""
|
|
48
|
-
echo "4. Testing Task tool with real request..."
|
|
49
|
-
|
|
50
|
-
# Create test request that uses Task tool (NO tools array - server provides tools)
|
|
51
|
-
cat > /tmp/test-task-request.json << 'EOFR'
|
|
52
|
-
{
|
|
53
|
-
"model": "claude-3-5-sonnet-20241022",
|
|
54
|
-
"max_tokens": 4096,
|
|
55
|
-
"messages": [
|
|
56
|
-
{
|
|
57
|
-
"role": "user",
|
|
58
|
-
"content": "Use the Task tool to search for all files in the src/agents directory."
|
|
59
|
-
}
|
|
60
|
-
]
|
|
61
|
-
}
|
|
62
|
-
EOFR
|
|
63
|
-
|
|
64
|
-
echo " 📤 Sending request to /v1/messages..."
|
|
65
|
-
RESPONSE=$(curl -s -X POST http://localhost:8080/v1/messages \
|
|
66
|
-
-H "Content-Type: application/json" \
|
|
67
|
-
-H "x-session-id: test-session-$(date +%s)" \
|
|
68
|
-
-d @/tmp/test-task-request.json)
|
|
69
|
-
|
|
70
|
-
echo ""
|
|
71
|
-
echo " 📥 Response received!"
|
|
72
|
-
|
|
73
|
-
# Check response type
|
|
74
|
-
if echo "$RESPONSE" | grep -q "tool_use"; then
|
|
75
|
-
echo " ⚠️ WARNING: Server returned tool_use (passthrough mode)"
|
|
76
|
-
echo " 🔧 Tool calls in response:"
|
|
77
|
-
echo "$RESPONSE" | jq -r '.content[] | select(.type=="tool_use") | " - \(.name): \(.input.prompt[:80])..."' 2>/dev/null || echo " (Install jq to see tool calls)"
|
|
78
|
-
elif echo "$RESPONSE" | grep -q "content"; then
|
|
79
|
-
echo " ✅ Server executed tools and returned final response!"
|
|
80
|
-
echo ""
|
|
81
|
-
echo " 📄 Response content (first 200 chars):"
|
|
82
|
-
echo "$RESPONSE" | jq -r '.content[0].text[:200]' 2>/dev/null || echo " (Install jq to see content)"
|
|
83
|
-
fi
|
|
84
|
-
|
|
85
|
-
# Check agent stats again
|
|
86
|
-
echo ""
|
|
87
|
-
echo "5. Checking agent execution stats..."
|
|
88
|
-
sleep 2
|
|
89
|
-
curl -s http://localhost:8080/v1/agents/stats | jq . 2>/dev/null || curl -s http://localhost:8080/v1/agents/stats
|
|
90
|
-
|
|
91
|
-
# Check for transcripts
|
|
92
|
-
echo ""
|
|
93
|
-
echo "6. Checking for agent transcripts..."
|
|
94
|
-
TRANSCRIPT_COUNT=$(ls -1 data/agent-transcripts/*.jsonl 2>/dev/null | wc -l || echo "0")
|
|
95
|
-
echo " Found $TRANSCRIPT_COUNT transcript file(s)"
|
|
96
|
-
|
|
97
|
-
if [ "$TRANSCRIPT_COUNT" -gt 0 ]; then
|
|
98
|
-
echo " Latest transcript:"
|
|
99
|
-
LATEST=$(ls -t data/agent-transcripts/*.jsonl 2>/dev/null | head -1)
|
|
100
|
-
echo " File: $LATEST"
|
|
101
|
-
echo " First few lines:"
|
|
102
|
-
head -3 "$LATEST" | jq -r '"\(.type): \(.timestamp)"' 2>/dev/null || head -3 "$LATEST"
|
|
103
|
-
fi
|
|
104
|
-
|
|
105
|
-
echo ""
|
|
106
|
-
echo "7. Checking server logs for agent activity..."
|
|
107
|
-
echo " Last 20 lines from server log:"
|
|
108
|
-
tail -20 /tmp/subagent-test.log | grep -E "agent|Task tool|subagent" --color=always || echo " (No agent activity in logs)"
|
|
109
|
-
|
|
110
|
-
echo ""
|
|
111
|
-
echo "================================"
|
|
112
|
-
echo "✅ Test complete!"
|
|
113
|
-
echo ""
|
|
114
|
-
echo "Server is still running (PID: $SERVER_PID)"
|
|
115
|
-
echo "To view full logs: tail -f /tmp/subagent-test.log"
|
|
116
|
-
echo "To stop server: kill $SERVER_PID"
|
|
117
|
-
echo ""
|