@vfarcic/dot-ai 0.128.0 → 0.129.0
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/dist/interfaces/mcp.d.ts.map +1 -1
- package/dist/interfaces/mcp.js +5 -0
- package/package.json +1 -5
- package/scripts/dot-ai.nu +65 -0
- package/scripts/jaeger.nu +33 -0
- package/scripts/openai.nu +20 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"mcp.d.ts","sourceRoot":"","sources":["../../src/interfaces/mcp.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAWH,OAAO,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AA0CtC,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,WAAW,EAAE,MAAM,CAAC;IACpB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,SAAS,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;IAC7B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,WAAW,CAAC,EAAE,UAAU,GAAG,WAAW,CAAC;CACxC;AAED,qBAAa,SAAS;IACpB,OAAO,CAAC,MAAM,CAAY;IAC1B,OAAO,CAAC,KAAK,CAAQ;IACrB,OAAO,CAAC,WAAW,CAAkB;IACrC,OAAO,CAAC,MAAM,CAAS;IACvB,OAAO,CAAC,gBAAgB,CAAa;IACrC,OAAO,CAAC,MAAM,CAAkB;IAChC,OAAO,CAAC,UAAU,CAAC,CAAkC;IACrD,OAAO,CAAC,aAAa,CAAC,CAAgC;IACtD,OAAO,CAAC,YAAY,CAAmB;IACvC,OAAO,CAAC,aAAa,CAAgB;gBAEzB,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,eAAe;IAsCjD;;OAEG;IACH,OAAO,CAAC,YAAY;IA2BpB;;OAEG;IACH,OAAO,CAAC,aAAa;IA2GrB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AAgB;IAexB,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;IAgB3B,OAAO,IAAI,OAAO;CAGnB"}
|
package/dist/interfaces/mcp.js
CHANGED
|
@@ -222,6 +222,8 @@ class MCPServer {
|
|
|
222
222
|
// Check if this is a REST API request
|
|
223
223
|
if (this.restApiRouter.isApiRequest(req.url || '')) {
|
|
224
224
|
this.logger.debug('Routing to REST API handler', { url: req.url });
|
|
225
|
+
// Mark span as REST API request
|
|
226
|
+
span.setAttribute('request.type', 'rest-api');
|
|
225
227
|
try {
|
|
226
228
|
await this.restApiRouter.handleRequest(req, res, body);
|
|
227
229
|
endSpan(res.statusCode || 200);
|
|
@@ -238,6 +240,9 @@ class MCPServer {
|
|
|
238
240
|
}
|
|
239
241
|
}
|
|
240
242
|
// Handle MCP protocol requests using the transport
|
|
243
|
+
// Mark span as MCP protocol request
|
|
244
|
+
span.setAttribute('request.type', 'mcp-protocol');
|
|
245
|
+
span.updateName('MCP ' + (req.url || '/'));
|
|
241
246
|
try {
|
|
242
247
|
await this.httpTransport.handleRequest(req, res, body);
|
|
243
248
|
endSpan(res.statusCode || 200);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vfarcic/dot-ai",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.129.0",
|
|
4
4
|
"description": "AI-powered development productivity platform that enhances software development workflows through intelligent automation and AI-driven assistance",
|
|
5
5
|
"mcpName": "io.github.vfarcic/dot-ai",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -109,18 +109,14 @@
|
|
|
109
109
|
"@modelcontextprotocol/sdk": "^1.13.2",
|
|
110
110
|
"@openrouter/ai-sdk-provider": "^1.2.0",
|
|
111
111
|
"@opentelemetry/api": "^1.9.0",
|
|
112
|
-
"@opentelemetry/auto-instrumentations-node": "^0.66.0",
|
|
113
112
|
"@opentelemetry/exporter-trace-otlp-http": "^0.207.0",
|
|
114
113
|
"@opentelemetry/resources": "^2.2.0",
|
|
115
114
|
"@opentelemetry/sdk-node": "^0.207.0",
|
|
116
|
-
"@opentelemetry/sdk-trace-base": "^2.2.0",
|
|
117
115
|
"@opentelemetry/sdk-trace-node": "^2.2.0",
|
|
118
116
|
"@opentelemetry/semantic-conventions": "^1.37.0",
|
|
119
117
|
"@qdrant/js-client-rest": "^1.15.0",
|
|
120
118
|
"ai": "^5.0.60",
|
|
121
|
-
"glob": "^11.0.3",
|
|
122
119
|
"handlebars": "^4.7.8",
|
|
123
|
-
"openai": "^5.11.0",
|
|
124
120
|
"yaml": "^2.8.0",
|
|
125
121
|
"zod-to-json-schema": "^3.24.6"
|
|
126
122
|
},
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
#!/usr/bin/env nu
|
|
2
|
+
|
|
3
|
+
# Installs DevOps AI Toolkit with MCP server support
|
|
4
|
+
#
|
|
5
|
+
# Examples:
|
|
6
|
+
# > main apply dot-ai --host dot-ai.127.0.0.1.nip.io
|
|
7
|
+
# > main apply dot-ai --provider openai --model gpt-4o
|
|
8
|
+
# > main apply dot-ai --enable-tracing true
|
|
9
|
+
def "main apply dot-ai" [
|
|
10
|
+
--anthropic-api-key = "",
|
|
11
|
+
--openai-api-key = "",
|
|
12
|
+
--provider = "anthropic",
|
|
13
|
+
--model = "claude-haiku-4-5-20251001",
|
|
14
|
+
--ingress-enabled = true,
|
|
15
|
+
--host = "dot-ai.127.0.0.1.nip.io",
|
|
16
|
+
--version = "0.128.0",
|
|
17
|
+
--enable-tracing = false
|
|
18
|
+
] {
|
|
19
|
+
|
|
20
|
+
let anthropic_key = if ($anthropic_api_key | is-empty) {
|
|
21
|
+
$env.ANTHROPIC_API_KEY? | default ""
|
|
22
|
+
} else {
|
|
23
|
+
$anthropic_api_key
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
let openai_key = if ($openai_api_key | is-empty) {
|
|
27
|
+
$env.OPENAI_API_KEY? | default ""
|
|
28
|
+
} else {
|
|
29
|
+
$openai_api_key
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
let tracing_flags = if $enable_tracing {
|
|
33
|
+
[
|
|
34
|
+
--set 'extraEnv[0].name=OTEL_TRACING_ENABLED'
|
|
35
|
+
--set-string 'extraEnv[0].value=true'
|
|
36
|
+
--set 'extraEnv[1].name=OTEL_EXPORTER_OTLP_ENDPOINT'
|
|
37
|
+
--set 'extraEnv[1].value=http://jaeger-collector.observability.svc.cluster.local:4318/v1/traces'
|
|
38
|
+
--set 'extraEnv[2].name=OTEL_SERVICE_NAME'
|
|
39
|
+
--set 'extraEnv[2].value=dot-ai-mcp'
|
|
40
|
+
]
|
|
41
|
+
} else {
|
|
42
|
+
[]
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
(
|
|
46
|
+
helm upgrade --install dot-ai-mcp
|
|
47
|
+
$"oci://ghcr.io/vfarcic/dot-ai/charts/dot-ai:($version)"
|
|
48
|
+
--set $"secrets.anthropic.apiKey=($anthropic_key)"
|
|
49
|
+
--set $"secrets.openai.apiKey=($openai_key)"
|
|
50
|
+
--set $"ai.provider=($provider)"
|
|
51
|
+
--set $"ai.model=($model)"
|
|
52
|
+
--set $"ingress.enabled=($ingress_enabled)"
|
|
53
|
+
--set $"ingress.host=($host)"
|
|
54
|
+
...$tracing_flags
|
|
55
|
+
--namespace dot-ai --create-namespace
|
|
56
|
+
--wait
|
|
57
|
+
)
|
|
58
|
+
|
|
59
|
+
print $"DevOps AI Toolkit is available at (ansi yellow_bold)http://($host)(ansi reset)"
|
|
60
|
+
|
|
61
|
+
if $enable_tracing {
|
|
62
|
+
print $"Tracing enabled: Traces will be sent to (ansi yellow_bold)Jaeger in observability namespace(ansi reset)"
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
#!/usr/bin/env nu
|
|
2
|
+
|
|
3
|
+
# Installs Jaeger with ingress configuration
|
|
4
|
+
#
|
|
5
|
+
# Examples:
|
|
6
|
+
# > main apply jaeger nginx jaeger.example.com
|
|
7
|
+
def "main apply jaeger" [
|
|
8
|
+
ingress_class: string,
|
|
9
|
+
ingress_host: string
|
|
10
|
+
] {
|
|
11
|
+
|
|
12
|
+
helm repo add jaegertracing https://jaegertracing.github.io/helm-charts
|
|
13
|
+
|
|
14
|
+
helm repo update
|
|
15
|
+
|
|
16
|
+
(
|
|
17
|
+
helm upgrade --install jaeger jaegertracing/jaeger
|
|
18
|
+
--namespace observability --create-namespace
|
|
19
|
+
--set provisionDataStore.cassandra=false
|
|
20
|
+
--set allInOne.enabled=true
|
|
21
|
+
--set allInOne.ingress.enabled=true
|
|
22
|
+
--set $"allInOne.ingress.ingressClassName=($ingress_class)"
|
|
23
|
+
--set $"allInOne.ingress.hosts[0]=($ingress_host)"
|
|
24
|
+
--set storage.type=memory
|
|
25
|
+
--set agent.enabled=false
|
|
26
|
+
--set collector.enabled=false
|
|
27
|
+
--set query.enabled=false
|
|
28
|
+
--wait
|
|
29
|
+
)
|
|
30
|
+
|
|
31
|
+
print $"Jaeger is available at (ansi yellow_bold)http://($ingress_host)(ansi reset)"
|
|
32
|
+
|
|
33
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
#!/usr/bin/env nu
|
|
2
|
+
|
|
3
|
+
# Retrieves OpenAI token
|
|
4
|
+
#
|
|
5
|
+
# Returns:
|
|
6
|
+
# A record with token, and saves values to .env file
|
|
7
|
+
def --env "main get openai" [] {
|
|
8
|
+
|
|
9
|
+
mut openai_api_key = ""
|
|
10
|
+
if "OPENAI_API_KEY" in $env {
|
|
11
|
+
$openai_api_key = $env.OPENAI_API_KEY
|
|
12
|
+
} else {
|
|
13
|
+
let value = input $"(ansi green_bold)Enter OpenAI token:(ansi reset) "
|
|
14
|
+
$openai_api_key = $value
|
|
15
|
+
}
|
|
16
|
+
$"export OPENAI_API_KEY=($openai_api_key)\n" | save --append .env
|
|
17
|
+
|
|
18
|
+
{token: $openai_api_key}
|
|
19
|
+
|
|
20
|
+
}
|