Skip to content
Closed
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 apps/cloud/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"@executor/plugin-openapi": "workspace:*",
"@executor/react": "workspace:*",
"@executor/runtime-dynamic-worker": "workspace:*",
"@executor/sdk": "workspace:*",
"@executor-js/core": "workspace:*",
"@executor/storage-postgres": "workspace:*",
"@modelcontextprotocol/sdk": "^1.29.0",
"@tanstack/react-router": "catalog:",
Expand Down
3 changes: 2 additions & 1 deletion apps/cloud/src/services/executor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@

import { Effect } from "effect";

import { createExecutor } from "@executor/sdk";
import { createExecutor } from "@executor-js/core";
import type { DrizzleDb } from "@executor/storage-postgres";
import { makePgConfig, makePgKv } from "@executor/storage-postgres";
import {
openApiPlugin,
Expand Down
2 changes: 1 addition & 1 deletion apps/local/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
"@executor/plugin-onepassword": "workspace:*",
"@executor/plugin-openapi": "workspace:*",
"@executor/react": "workspace:*",
"@executor/sdk": "workspace:*",
"@executor-js/core": "workspace:*",
"@executor/storage-file": "workspace:*",
"@modelcontextprotocol/sdk": "^1.12.1",
"@tanstack/react-router": "catalog:",
Expand Down
2 changes: 1 addition & 1 deletion apps/local/src/server/executor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import * as fs from "node:fs";
import { homedir } from "node:os";
import { join } from "node:path";

import { createExecutor, scopeKv } from "@executor/sdk";
import { createExecutor, scopeKv } from "@executor-js/core";
import {
makeSqliteKv,
makeKvConfig,
Expand Down
2 changes: 1 addition & 1 deletion apps/marketing/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
},
"dependencies": {
"@astrojs/cloudflare": "^13.0.0",
"@executor/sdk": "workspace:*",
"@executor-js/core": "workspace:*",
"@executor/plugin-openapi": "workspace:*",
"@executor/plugin-graphql": "workspace:*",
"@executor/plugin-google-discovery": "workspace:*",
Expand Down
2 changes: 1 addition & 1 deletion apps/marketing/src/pages/api/detect.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import {
createExecutor,
makeTestConfig,
type ToolMetadata,
} from "@executor/sdk";
} from "@executor-js/core";
import { openApiPlugin } from "@executor/plugin-openapi";
import { graphqlPlugin } from "@executor/plugin-graphql";
import { googleDiscoveryPlugin } from "@executor/plugin-google-discovery";
Expand Down
848 changes: 257 additions & 591 deletions bun.lock

Large diffs are not rendered by default.

3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,8 @@
"typescript": "^5.9.3",
"tailwindcss": "^4.2.2",
"quickjs-emscripten": "^0.31.0",
"@jitl/quickjs-wasmfile-release-sync": "0.31.0"
"@jitl/quickjs-wasmfile-release-sync": "0.31.0",
"tsup": "^8.5.0"
},
"scripts": {
"dev": "turbo run dev --filter='!@executor/desktop' --filter='!@executor/cloud'",
Expand Down
2 changes: 1 addition & 1 deletion packages/core/api/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"dependencies": {
"@effect/platform": "catalog:",
"@executor/execution": "workspace:*",
"@executor/sdk": "workspace:*",
"@executor-js/core": "workspace:*",
"effect": "catalog:"
},
"devDependencies": {
Expand Down
2 changes: 1 addition & 1 deletion packages/core/api/src/handlers/secrets.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { HttpApiBuilder } from "@effect/platform";
import { Effect, Option } from "effect";
import type { SecretId, ScopeId } from "@executor/sdk";
import type { SecretId, ScopeId } from "@executor-js/core";

import { ExecutorApi } from "../api";
import { ExecutorService } from "../services";
Expand Down
2 changes: 1 addition & 1 deletion packages/core/api/src/scope/api.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { HttpApiEndpoint, HttpApiGroup } from "@effect/platform";
import { Schema } from "effect";
import { ScopeId } from "@executor/sdk";
import { ScopeId } from "@executor-js/core";

// ---------------------------------------------------------------------------
// Response schemas
Expand Down
2 changes: 1 addition & 1 deletion packages/core/api/src/secrets/api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import {
SecretId,
SecretNotFoundError,
SecretResolutionError,
} from "@executor/sdk";
} from "@executor-js/core";

// ---------------------------------------------------------------------------
// Params
Expand Down
2 changes: 1 addition & 1 deletion packages/core/api/src/services.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { Context } from "effect";
import type { Executor } from "@executor/sdk";
import type { Executor } from "@executor-js/core";
import type { ExecutionEngine } from "@executor/execution";

export class ExecutorService extends Context.Tag("ExecutorService")<
Expand Down
2 changes: 1 addition & 1 deletion packages/core/api/src/sources/api.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { HttpApiEndpoint, HttpApiGroup, HttpApiSchema } from "@effect/platform";
import { Schema } from "effect";
import { ScopeId, ToolId } from "@executor/sdk";
import { ScopeId, ToolId } from "@executor-js/core";

// ---------------------------------------------------------------------------
// Params
Expand Down
2 changes: 1 addition & 1 deletion packages/core/api/src/tools/api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import {
ScopeId,
ToolId,
ToolNotFoundError,
} from "@executor/sdk";
} from "@executor-js/core";

// ---------------------------------------------------------------------------
// Params
Expand Down
1 change: 1 addition & 0 deletions packages/core/config/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
},
"dependencies": {
"@effect/platform": "catalog:",
"@executor-js/core": "workspace:*",
"effect": "catalog:",
"jsonc-parser": "^3.3.1"
},
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# @executor/sdk changelog
# @executor-js/core changelog

This file exists for Changesets release workflow compatibility.
Canonical user-facing release notes are published on GitHub Releases.
36 changes: 36 additions & 0 deletions packages/core/core/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
{
"name": "@executor-js/core",
"version": "1.4.0",
"type": "module",
"exports": {
".": "./src/index.ts"
},
"publishConfig": {
"access": "public",
"exports": {
".": {
"import": {
"types": "./dist/index.d.ts",
"default": "./dist/index.js"
}
}
}
},
"files": [
"dist"
],
"scripts": {
"build": "tsup && (tsc --declaration --emitDeclarationOnly --outDir dist --rootDir src || true)",
"typecheck": "tsc --noEmit",
"test": "vitest run"
},
"dependencies": {
"effect": "catalog:"
},
"devDependencies": {
"@effect/vitest": "catalog:",
"tsup": "catalog:",
"vitest": "catalog:",
"typescript": "catalog:"
}
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ export class PolicyCheckInput extends Schema.Class<PolicyCheckInput>("PolicyChec
toolId: ToolId,
}) {}

export class PolicyEngine extends Context.Tag("@executor/sdk/PolicyEngine")<
export class PolicyEngine extends Context.Tag("@executor-js/core/PolicyEngine")<
PolicyEngine,
{
readonly list: (scopeId: ScopeId) => Effect.Effect<readonly Policy[]>;
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ export class SetSecretInput extends Schema.Class<SetSecretInput>("SetSecretInput
// SecretStore — manages refs + delegates resolution to providers
// ---------------------------------------------------------------------------

export class SecretStore extends Context.Tag("@executor/sdk/SecretStore")<
export class SecretStore extends Context.Tag("@executor-js/core/SecretStore")<
SecretStore,
{
/** List all secret refs for a scope */
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ export interface SourceManager {
// ---------------------------------------------------------------------------

export class SourceRegistry extends Context.Tag(
"@executor/sdk/SourceRegistry",
"@executor-js/core/SourceRegistry",
)<
SourceRegistry,
{
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ export interface InvokeOptions {
// ToolRegistry — stores and invokes tools
// ---------------------------------------------------------------------------

export class ToolRegistry extends Context.Tag("@executor/sdk/ToolRegistry")<
export class ToolRegistry extends Context.Tag("@executor-js/core/ToolRegistry")<
ToolRegistry,
{
readonly list: (filter?: ToolListFilter) => Effect.Effect<readonly ToolMetadata[]>;
Expand Down
File renamed without changes.
10 changes: 10 additions & 0 deletions packages/core/core/tsup.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
import { defineConfig } from "tsup";

export default defineConfig({
entry: { index: "src/index.ts" },
format: ["esm"],
dts: false,
sourcemap: true,
clean: true,
external: [/^effect/, /^@effect\//],
});
File renamed without changes.
2 changes: 1 addition & 1 deletion packages/core/execution/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"test": "vitest run"
},
"dependencies": {
"@executor/sdk": "workspace:*",
"@executor-js/core": "workspace:*",
"@executor/codemode-core": "workspace:*",
"@executor/runtime-quickjs": "workspace:*",
"effect": "catalog:"
Expand Down
2 changes: 1 addition & 1 deletion packages/core/execution/src/description.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { Effect } from "effect";
import type { Executor, ToolMetadata, Source } from "@executor/sdk";
import type { Executor, ToolMetadata, Source } from "@executor-js/core";

/**
* Builds a tool description dynamically.
Expand Down
2 changes: 1 addition & 1 deletion packages/core/execution/src/engine.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import type {
ElicitationResponse,
ElicitationHandler,
ElicitationContext,
} from "@executor/sdk";
} from "@executor-js/core";
import type { CodeExecutor, ExecuteResult, SandboxToolInvoker } from "@executor/codemode-core";
import { makeQuickJsExecutor } from "@executor/runtime-quickjs";

Expand Down
4 changes: 2 additions & 2 deletions packages/core/execution/src/tool-invoker.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import {
makeTestConfig,
tool,
type ToolId,
} from "@executor/sdk";
} from "@executor-js/core";
import { createExecutionEngine } from "./engine";
import { describeTool, searchTools } from "./tool-invoker";

Expand All @@ -23,7 +23,7 @@ const ContactInput = Schema.Struct({
});

import type { ExecutionResult } from "./engine";
import { FormElicitation } from "@executor/sdk";
import { FormElicitation } from "@executor-js/core";

const acceptAll = () => Effect.succeed(new ElicitationResponse({ action: "accept" }));

Expand Down
2 changes: 1 addition & 1 deletion packages/core/execution/src/tool-invoker.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { Effect } from "effect";
import type { Executor, ToolId, ToolMetadata, ToolSchema, InvokeOptions, Source } from "@executor/sdk";
import type { Executor, ToolId, ToolMetadata, ToolSchema, InvokeOptions, Source } from "@executor-js/core";
import type { SandboxToolInvoker } from "@executor/codemode-core";
import { ExecutionToolError } from "./errors";

Expand Down
21 changes: 0 additions & 21 deletions packages/core/sdk/package.json

This file was deleted.

2 changes: 1 addition & 1 deletion packages/core/storage-file/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
},
"dependencies": {
"@effect/sql": "catalog:",
"@executor/sdk": "workspace:*",
"@executor-js/core": "workspace:*",
"effect": "catalog:"
},
"devDependencies": {
Expand Down
4 changes: 2 additions & 2 deletions packages/core/storage-file/src/index.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ import { Effect } from "effect";
import { SqliteClient } from "@effect/sql-sqlite-node";
import * as SqlClient from "@effect/sql/SqlClient";

import { ScopeId, ToolId, SecretId, makeInMemorySecretProvider, scopeKv } from "@executor/sdk";
import type { Kv } from "@executor/sdk";
import { ScopeId, ToolId, SecretId, makeInMemorySecretProvider, scopeKv } from "@executor-js/core";
import type { Kv } from "@executor-js/core";
import { migrate } from "./schema";
import { makeSqliteKv } from "./plugin-kv";
import { makeKvToolRegistry } from "./tool-registry";
Expand Down
4 changes: 2 additions & 2 deletions packages/core/storage-file/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@
import { createHash } from "node:crypto";
import { basename } from "node:path";

import { scopeKv, ScopeId, makeInMemorySourceRegistry } from "@executor/sdk";
import type { Kv, Scope, ExecutorConfig, ExecutorPlugin } from "@executor/sdk";
import { scopeKv, ScopeId, makeInMemorySourceRegistry } from "@executor-js/core";
import type { Kv, Scope, ExecutorConfig, ExecutorPlugin } from "@executor-js/core";

import { makeKvToolRegistry } from "./tool-registry";
import { makeKvSecretStore } from "./secret-store";
Expand Down
2 changes: 1 addition & 1 deletion packages/core/storage-file/src/plugin-kv.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

import { Effect, Exit } from "effect";
import type * as SqlClient from "@effect/sql/SqlClient";
import type { Kv } from "@executor/sdk";
import type { Kv } from "@executor-js/core";

import { absorbSql } from "./sql-utils";

Expand Down
4 changes: 2 additions & 2 deletions packages/core/storage-file/src/policy-engine.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@

import { Effect, Schema } from "effect";

import { Policy, PolicyId, ScopeId } from "@executor/sdk";
import type { ScopedKv, PolicyCheckInput } from "@executor/sdk";
import { Policy, PolicyId, ScopeId } from "@executor-js/core";
import type { ScopedKv, PolicyCheckInput } from "@executor-js/core";

// ---------------------------------------------------------------------------
// Serialization — leverage Policy Schema.Class directly
Expand Down
6 changes: 3 additions & 3 deletions packages/core/storage-file/src/secret-store.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@

import { Effect, Option, Schema } from "effect";

import { SecretRef, SecretId, ScopeId } from "@executor/sdk";
import { SecretNotFoundError, SecretResolutionError } from "@executor/sdk";
import type { SecretProvider, ScopedKv, SetSecretInput } from "@executor/sdk";
import { SecretRef, SecretId, ScopeId } from "@executor-js/core";
import { SecretNotFoundError, SecretResolutionError } from "@executor-js/core";
import type { SecretProvider, ScopedKv, SetSecretInput } from "@executor-js/core";

// ---------------------------------------------------------------------------
// Serialization — leverage SecretRef Schema.Class directly
Expand Down
8 changes: 4 additions & 4 deletions packages/core/storage-file/src/tool-registry.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,15 @@

import { Effect, Schema } from "effect";

import type { ToolId, ScopedKv } from "@executor/sdk";
import { ToolNotFoundError, ToolInvocationError, ToolRegistration } from "@executor/sdk";
import type { ToolId, ScopedKv } from "@executor-js/core";
import { ToolNotFoundError, ToolInvocationError, ToolRegistration } from "@executor-js/core";
import type {
ToolInvoker,
ToolListFilter,
InvokeOptions,
RuntimeToolHandler,
} from "@executor/sdk";
import { buildToolTypeScriptPreview, reattachDefs } from "@executor/sdk";
} from "@executor-js/core";
import { buildToolTypeScriptPreview, reattachDefs } from "@executor-js/core";

// ---------------------------------------------------------------------------
// Serialization — leverage ToolRegistration Schema.Class directly
Expand Down
4 changes: 3 additions & 1 deletion packages/core/storage-postgres/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,9 @@
"./schema": "./src/schema.ts"
},
"dependencies": {
"@executor/sdk": "workspace:*",
"@effect/sql": "catalog:",
"@effect/sql-pg": "^0.28.0",
"@executor-js/core": "workspace:*",
"drizzle-orm": "catalog:",
"effect": "catalog:",
"pg": "^8.16.0"
Expand Down
2 changes: 1 addition & 1 deletion packages/core/storage-postgres/src/index.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import {
ToolRegistration,
scopeKv,
type Executor,
} from "@executor/sdk";
} from "@executor-js/core";

import { makePgConfig } from "./index";
import { makePgKv } from "./pg-kv";
Expand Down
Loading