@openthink/team 0.0.6 → 0.0.8

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/index.js CHANGED
@@ -2867,8 +2867,9 @@ async function assignTicket(opts) {
2867
2867
  sessionId: randomUUID(),
2868
2868
  startedAt: (/* @__PURE__ */ new Date()).toISOString()
2869
2869
  } : null;
2870
- const kittyPath = !opts.workInline && isMacOS() ? findKittyBinary() : null;
2871
- if (!kittyPath) {
2870
+ const wantsKitty = !opts.workInline && isMacOS();
2871
+ if (!wantsKitty) {
2872
+ process.stdout.write(inlineStartLine(ticket.id) + "\n");
2872
2873
  runInline(
2873
2874
  claudePath,
2874
2875
  ticketPath,
@@ -2880,24 +2881,22 @@ async function assignTicket(opts) {
2880
2881
  );
2881
2882
  return;
2882
2883
  }
2884
+ const kittyPath = findKittyBinary();
2885
+ if (!kittyPath) {
2886
+ process.stderr.write(
2887
+ "oteam assign: kitty not installed (or not on PATH); pass --inline to run in this terminal\n"
2888
+ );
2889
+ process.exit(1);
2890
+ }
2883
2891
  const monitored = opts.monitoredOrgs ?? readMonitoredOrgsFromEnv();
2884
2892
  const preferring = preferredKittyContext(ticket.repo, monitored);
2885
2893
  const socket = findKittySocket(kittyPath, preferring);
2886
2894
  if (!socket) {
2887
2895
  process.stderr.write(
2888
- `oteam assign: no kitty socket reachable (preferring "${preferring}"); falling back to inline run.
2896
+ `oteam assign: no kitty socket reachable (preferring "${preferring}"); pass --inline to run in this terminal
2889
2897
  `
2890
2898
  );
2891
- runInline(
2892
- claudePath,
2893
- ticketPath,
2894
- resolvedVault.path,
2895
- systemPrompt,
2896
- workspace,
2897
- model,
2898
- telemetry
2899
- );
2900
- return;
2899
+ process.exit(1);
2901
2900
  }
2902
2901
  const cwd = workspace?.path ?? dirname2(ticketPath);
2903
2902
  const title = `Vault \xB7 ${basename5(ticketPath)}`;
@@ -2934,6 +2933,14 @@ async function assignTicket(opts) {
2934
2933
  `kitty @ launch exited ${result.exitCode}: ${result.stderr || "(no stderr)"}`
2935
2934
  );
2936
2935
  }
2936
+ process.stdout.write(kittySpawnLine(ticket.id, workspace?.path ?? null) + "\n");
2937
+ }
2938
+ function kittySpawnLine(ticketId, workspacePath) {
2939
+ const suffix = workspacePath ? ` (worktree at ${workspacePath})` : "";
2940
+ return `oteam assign: spawned kitty window for ${ticketId}${suffix}`;
2941
+ }
2942
+ function inlineStartLine(ticketId) {
2943
+ return `oteam assign: running inline for ${ticketId}; agent starting\u2026`;
2937
2944
  }
2938
2945
  function buildTelemetryTail(input) {
2939
2946
  const oteam = `'${shellEscape(input.oteamPath)}'`;
@@ -3048,11 +3055,59 @@ function readMonitoredOrgsFromEnv() {
3048
3055
  return raw.split(",").map((s) => s.trim()).filter((s) => s.length > 0);
3049
3056
  }
3050
3057
 
3058
+ // package.json
3059
+ var package_default = {
3060
+ name: "@openthink/team",
3061
+ version: "0.0.8",
3062
+ type: "module",
3063
+ description: "Source-agnostic vault-driven role pipeline for spawning Claude agents against tickets",
3064
+ bin: {
3065
+ oteam: "dist/index.js"
3066
+ },
3067
+ files: [
3068
+ "dist"
3069
+ ],
3070
+ scripts: {
3071
+ build: "tsup && cp src/role-pipeline/assign-ticket.md dist/assign-ticket.md",
3072
+ dev: "tsx src/index.ts",
3073
+ typecheck: "tsc --noEmit",
3074
+ test: "node --test --import tsx 'tests/**/*.test.ts'",
3075
+ prepublishOnly: "npm run build"
3076
+ },
3077
+ homepage: "https://openthink.dev",
3078
+ repository: {
3079
+ type: "git",
3080
+ url: "git+https://github.com/OpenThinkAi/open-team.git"
3081
+ },
3082
+ keywords: [
3083
+ "cli",
3084
+ "agents",
3085
+ "vault",
3086
+ "role-pipeline",
3087
+ "ai",
3088
+ "local-first"
3089
+ ],
3090
+ license: "MIT",
3091
+ engines: {
3092
+ node: ">=22.5.0"
3093
+ },
3094
+ dependencies: {
3095
+ "@anthropic-ai/claude-agent-sdk": "^0.2.114",
3096
+ commander: "^13.1.0"
3097
+ },
3098
+ devDependencies: {
3099
+ "@types/node": "^22.14.1",
3100
+ tsup: "^8.4.0",
3101
+ tsx: "^4.19.3",
3102
+ typescript: "^5.8.3"
3103
+ }
3104
+ };
3105
+
3051
3106
  // src/index.ts
3052
3107
  var program = new Command6();
3053
3108
  program.name("oteam").description(
3054
3109
  "Source-agnostic vault-driven role pipeline for spawning Claude agents against tickets"
3055
- ).version("0.0.1");
3110
+ ).version(package_default.version);
3056
3111
  async function handlePull(source, ref, opts) {
3057
3112
  const result = await runPull({
3058
3113
  source,