Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion blog-post-generator/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
"build": "bun run build:server"
},
"dependencies": {
"@decocms/runtime": "1.1.3",
"@decocms/runtime": "1.2.7",
"zod": "^4.0.0"
},
"devDependencies": {
Expand Down
8 changes: 7 additions & 1 deletion bun.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion deco-llm/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
"@ai-sdk/provider": "^3.0.2",
"@ai-sdk/provider-utils": "^4.0.4",
"@decocms/bindings": "^1.1.1",
"@decocms/runtime": "1.1.3",
"@decocms/runtime": "1.2.7",
"@openrouter/ai-sdk-provider": "^1.5.4",
"@openrouter/sdk": "^0.3.11",
"ai": "^6.0.3",
Expand Down
1 change: 0 additions & 1 deletion deco-llm/server/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,6 @@ const runtime = withRuntime<
Registry
>({
tools: (env) => {
// @ts-expect-error: TODO: fix this later
return tools(env, {
start: async (modelInfo, params) => {
const amount = calculatePreAuthAmount(modelInfo, params);
Expand Down
2 changes: 1 addition & 1 deletion deco-news-weekly-digest/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
"build": "bun run build:server"
},
"dependencies": {
"@decocms/runtime": "1.1.3",
"@decocms/runtime": "1.2.7",
"@supabase/supabase-js": "^2.49.0",
"zod": "^4.0.0"
},
Expand Down
2 changes: 1 addition & 1 deletion github/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
},
"dependencies": {
"@decocms/bindings": "1.0.7",
"@decocms/runtime": "1.1.3",
"@decocms/runtime": "1.2.6",
"@octokit/rest": "^21.0.0",
"hono": "^4.7.4",
"zod": "^4.0.0"
Expand Down
2 changes: 1 addition & 1 deletion hyperdx/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
},
"dependencies": {
"@decocms/bindings": "^1.0.8",
"@decocms/runtime": "1.1.3",
"@decocms/runtime": "1.2.7",
"@modelcontextprotocol/sdk": "^1.20.0",
"zod": "^3.24.3"
},
Expand Down
2 changes: 1 addition & 1 deletion mcp-studio/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
},
"dependencies": {
"@decocms/bindings": "^1.1.3",
"@decocms/runtime": "1.1.3",
"@decocms/runtime": "1.2.7",
"@jitl/quickjs-singlefile-cjs-release-sync": "^0.31.0",
"@modelcontextprotocol/sdk": "^1.25.1",
"@types/prettier": "^3.0.0",
Expand Down
2 changes: 1 addition & 1 deletion meta-ads/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"dev:tunnel": "deco link -p 3003 -- PORT=3003 bun run dev"
},
"dependencies": {
"@decocms/runtime": "1.1.3",
"@decocms/runtime": "1.2.7",
"zod": "^4.0.0"
},
"devDependencies": {
Expand Down
6 changes: 4 additions & 2 deletions meta-ads/server/lib/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -73,13 +73,15 @@ export interface AdSet {
}

export interface Targeting {
[x: string]: unknown;
age_min?: number;
age_max?: number;
genders?: number[];
geo_locations?: {
[x: string]: unknown;
countries?: string[];
regions?: Array<{ key: string; name: string }>;
cities?: Array<{ key: string; name: string }>;
regions?: Array<{ [x: string]: unknown; key: string; name: string }>;
cities?: Array<{ [x: string]: unknown; key: string; name: string }>;
};
interests?: Array<{ id: string; name: string }>;
behaviors?: Array<{ id: string; name: string }>;
Expand Down
2 changes: 1 addition & 1 deletion object-storage/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"dependencies": {
"@aws-sdk/client-s3": "^3.716.0",
"@aws-sdk/s3-request-presigner": "^3.716.0",
"@decocms/runtime": "1.1.3",
"@decocms/runtime": "1.2.7",
"zod": "^4.0.0"
},
"devDependencies": {
Expand Down
2 changes: 1 addition & 1 deletion openrouter/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
"@ai-sdk/provider": "^3.0.2",
"@ai-sdk/provider-utils": "^4.0.4",
"@decocms/bindings": "^1.1.1",
"@decocms/runtime": "1.1.3",
"@decocms/runtime": "1.2.7",
"@openrouter/ai-sdk-provider": "^1.5.4",
"@openrouter/sdk": "^0.3.11",
"ai": "^6.0.3",
Expand Down
2 changes: 1 addition & 1 deletion openrouter/server/tools/hooks.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import type { LanguageModelV2Usage } from "@ai-sdk/provider";
import type { LanguageModelInputSchema } from "@decocms/bindings/llm";
import type { ModelInfo } from "server/lib/types";
import type { ModelInfo } from "../lib/types.ts";
import type { z } from "zod";

export interface UsageHooks {
Expand Down
2 changes: 1 addition & 1 deletion openrouter/server/tools/llm-binding.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import {
createStreamableTool,
} from "@decocms/runtime/tools";
import { createOpenRouter } from "@openrouter/ai-sdk-provider";
import { getOpenRouterApiKey } from "server/lib/env.ts";
import { getOpenRouterApiKey } from "../lib/env.ts";
import type { z } from "zod";
import { OpenRouterClient } from "../lib/openrouter-client.ts";
import type { Env } from "../main.ts";
Expand Down
2 changes: 1 addition & 1 deletion openrouter/server/tools/models/compare.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
*/

import { createPrivateTool } from "@decocms/runtime/tools";
import { getOpenRouterApiKey } from "server/lib/env.ts";
import { getOpenRouterApiKey } from "../../lib/env.ts";
import { z } from "zod";
import { OpenRouterClient } from "../../lib/openrouter-client.ts";
import type { Env } from "../../main.ts";
Expand Down
2 changes: 1 addition & 1 deletion openrouter/server/tools/models/recommend.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
*/

import { createPrivateTool } from "@decocms/runtime/tools";
import { getOpenRouterApiKey } from "server/lib/env.ts";
import { getOpenRouterApiKey } from "../../lib/env.ts";
import { z } from "zod";
import { OpenRouterClient } from "../../lib/openrouter-client.ts";
import type { Env } from "../../main.ts";
Expand Down
4 changes: 3 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,9 @@
"new": "bun scripts/new.ts",
"fmt": "oxfmt",
"lint": "oxlint",
"check": "bun run --filter=* check",
"check": "bun scripts/check-parallel.ts",
"check:changed": "bun scripts/check-parallel.ts --changed",
"check:all": "bun run --filter=* check",
"clean": "rm -rf node_modules */node_modules */dist */.vite */.wrangler */.deco",
"prepare": "sh scripts/setup-hooks.sh",
"build": "bun run ./scripts/build-mcp.ts"
Expand Down
2 changes: 1 addition & 1 deletion registry/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
},
"dependencies": {
"@decocms/bindings": "^1.0.4",
"@decocms/runtime": "1.1.3",
"@decocms/runtime": "1.2.7",
"@supabase/supabase-js": "^2.89.0",
"zod": "^4.0.0"
},
Expand Down
1 change: 0 additions & 1 deletion registry/server/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,6 @@ const runtime = withRuntime<Env, typeof StateSchema>({
state: StateSchema,
},
tools: (env: Env) => tools.map((createTool) => createTool(env)),
bindings: [],
cors: {
origin: (origin) => {
// Allow localhost and configured origins
Expand Down
137 changes: 137 additions & 0 deletions scripts/check-parallel.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,137 @@
#!/usr/bin/env bun
/**
* Optimized TypeScript check script
* Runs checks in parallel with concurrency limit to avoid overwhelming the system
*/

import { $ } from "bun";
import { join } from "node:path";

const MAX_CONCURRENT = 8; // Run 4 checks at a time
const ROOT_DIR = import.meta.dir.replace("/scripts", "");

async function getWorkspaces(): Promise<string[]> {
const pkg = await Bun.file(join(ROOT_DIR, "package.json")).json();
return pkg.workspaces || [];
}

async function hasTypeScriptConfig(dir: string): Promise<boolean> {
const tsConfigPath = join(ROOT_DIR, dir, "tsconfig.json");
const file = Bun.file(tsConfigPath);
return await file.exists();
}

async function runCheck(workspace: string): Promise<{
workspace: string;
success: boolean;
error?: string;
}> {
try {
const cwd = join(ROOT_DIR, workspace);
await $`cd ${cwd} && bun run check`.quiet();
return { workspace, success: true };
} catch (error) {
return {
workspace,
success: false,
error: error instanceof Error ? error.message : String(error),
};
}
}

async function runChecksInBatches(
workspaces: string[],
concurrency: number,
): Promise<void> {
const results: Array<{
workspace: string;
success: boolean;
error?: string;
}> = [];
let completed = 0;

console.log(
`🔍 Running TypeScript checks on ${workspaces.length} workspaces (${concurrency} concurrent)...\n`,
);

// Process workspaces in batches
for (let i = 0; i < workspaces.length; i += concurrency) {
const batch = workspaces.slice(i, i + concurrency);
const batchPromises = batch.map((ws) => runCheck(ws));

const batchResults = await Promise.all(batchPromises);
results.push(...batchResults);

completed += batch.length;
const progress = Math.round((completed / workspaces.length) * 100);
console.log(`Progress: ${completed}/${workspaces.length} (${progress}%)`);
}

// Print results
console.log("\n" + "=".repeat(60));
const failed = results.filter((r) => !r.success);
const passed = results.filter((r) => r.success);

console.log(`✅ Passed: ${passed.length}`);
console.log(`❌ Failed: ${failed.length}`);

if (failed.length > 0) {
console.log("\nFailed workspaces:");
for (const result of failed) {
console.log(` - ${result.workspace}`);
}
process.exit(1);
} else {
console.log("\n🎉 All checks passed!");
}
}

// Main
async function main() {
const args = process.argv.slice(2);
const changedOnly = args.includes("--changed");

let workspaces = await getWorkspaces();

// Filter to only workspaces with tsconfig.json
const workspacesWithTS = [];
for (const ws of workspaces) {
if (await hasTypeScriptConfig(ws)) {
workspacesWithTS.push(ws);
}
}

if (changedOnly) {
// Get changed files
try {
const output = await $`git diff --name-only origin/main...HEAD`.text();
const changedFiles = output.trim().split("\n");
const changedWorkspaces = new Set<string>();

for (const file of changedFiles) {
const ws = workspacesWithTS.find((w) => file.startsWith(`${w}/`));
if (ws) {
changedWorkspaces.add(ws);
}
}

if (changedWorkspaces.size === 0) {
console.log("No changed workspaces found. Checking all...");
} else {
workspacesWithTS.length = 0;
workspacesWithTS.push(...changedWorkspaces);
console.log(
`Checking ${changedWorkspaces.size} changed workspaces only\n`,
);
}
} catch (error) {
console.log(
"Could not detect changed files. Checking all workspaces...\n",
);
}
}

await runChecksInBatches(workspacesWithTS, MAX_CONCURRENT);
}

main();
2 changes: 1 addition & 1 deletion shared/audio-transcribers/base.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { createPrivateTool } from "@decocms/runtime/mastra";
import { createPrivateTool } from "@decocms/runtime/tools";
import {
applyMiddlewares,
Contract,
Expand Down
2 changes: 1 addition & 1 deletion shared/image-analyzers/base.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { createPrivateTool } from "@decocms/runtime/mastra";
import { createPrivateTool } from "@decocms/runtime/tools";
import {
applyMiddlewares,
withLogging,
Expand Down
2 changes: 1 addition & 1 deletion shared/image-generators/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ const { mimeType, imageData } = extractImageData(inlineData);

```typescript
import { S3Client } from "@aws-sdk/client-s3";
import { createTool } from "@decocms/runtime/mastra";
import { createTool } from "@decocms/runtime/tools";
import {
S3StorageAdapter,
saveImage,
Expand Down
2 changes: 1 addition & 1 deletion shared/image-generators/base.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { z } from "zod";
import { createPrivateTool } from "@decocms/runtime/mastra";
import { createPrivateTool } from "@decocms/runtime/tools";
import { saveImage } from "./storage";
import { ObjectStorage } from "../storage";
import {
Expand Down
2 changes: 1 addition & 1 deletion shared/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
},
"devDependencies": {
"@decocms/bindings": "1.0.7",
"@decocms/runtime": "1.1.3",
"@decocms/runtime": "1.2.7",
"@types/bun": "^1.2.14",
"vite": "7.2.0",
"zod": "^4.0.0"
Expand Down
2 changes: 1 addition & 1 deletion shared/search-ai/base.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* search AI providers like Perplexity, ChatGPT Search, Google Gemini, etc.
*/

import { createPrivateTool } from "@decocms/runtime/mastra";
import { createPrivateTool } from "@decocms/runtime/tools";
import {
AskInputSchema,
ChatInputSchema,
Expand Down
4 changes: 2 additions & 2 deletions shared/storage/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Storage - Shared Module

Unified storage module for all MCPs. Provides a consistent interface for working with different object storage providers.
Unified storage module for all MCPs. Provides a consistent interface for working with different object storage providers.
Copy link
Contributor

@cubic-dev-ai cubic-dev-ai bot Feb 5, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P3: Remove the extra space between “storage” and “providers” to avoid a typo in the README.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At shared/storage/README.md, line 3:

<comment>Remove the extra space between “storage” and “providers” to avoid a typo in the README.</comment>

<file context>
@@ -1,6 +1,6 @@
 # Storage - Shared Module
 
-Unified storage module for all MCPs. Provides a consistent interface for working with different object storage providers.
+Unified storage module for all MCPs. Provides a consistent interface for working with different object storage  providers.
 
 ## 🚀 Quick Start
</file context>
Suggested change
Unified storage module for all MCPs. Provides a consistent interface for working with different object storage providers.
Unified storage module for all MCPs. Provides a consistent interface for working with different object storage providers.
Fix with Cubic


## 🚀 Quick Start

Expand Down Expand Up @@ -177,7 +177,7 @@ const { url } = await saveImage(storage, {
### Example 3: New MCP with Storage

```typescript
import { createPrivateTool } from "@decocms/runtime/mastra";
import { createPrivateTool } from "@decocms/runtime/tools";
import { createStorageFromEnv } from "@decocms/mcps-shared/storage";
import { z } from "zod";

Expand Down
Loading
Loading