oh-my-opencode-slim 0.7.0 → 0.8.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/README.md CHANGED
@@ -1,7 +1,8 @@
1
1
  <div align="center">
2
2
  <img src="img/team.png" alt="Pantheon agents" width="420">
3
3
  <p><i>Six divine beings emerged from the dawn of code, each an immortal master of their craft await your command to forge order from chaos and build what was once thought impossible.</i></p>
4
- <p><b>Multi Agent Suite</b> · Mix any models · Auto delegate tasks · Antigravity + Chutes ready</p>
4
+ <p><b>Open Multi Agent Suite</b> · Mix any models · Auto delegate tasks</p>
5
+ <p><a href="https://moltfounders.com/project/0f5874c7-9291-415b-9622-7509d96a2c73"><img src="https://moltfounders.com/badges/4.png" alt="MoltFounders" height="30"></a></p>
5
6
  </div>
6
7
 
7
8
  ---
@@ -254,3 +255,10 @@ https://raw.githubusercontent.com/alvinunreal/oh-my-opencode-slim/refs/heads/mas
254
255
  ## 📄 License
255
256
 
256
257
  MIT
258
+
259
+ ---
260
+
261
+ <!-- MoltFounders Banner -->
262
+ <a href="https://moltfounders.com/project/0f5874c7-9291-415b-9622-7509d96a2c73">
263
+ <img src="img/moltfounders-banner.png" alt="MoltFounders - The Agent Co-Founder Network">
264
+ </a>
@@ -1,4 +1,4 @@
1
- import type { AgentConfig as SDKAgentConfig } from '@opencode-ai/sdk';
1
+ import type { AgentConfig as SDKAgentConfig } from '@opencode-ai/sdk/v2';
2
2
  import { type PluginConfig, SUBAGENT_NAMES } from '../config';
3
3
  import { type AgentDefinition } from './orchestrator';
4
4
  export type { AgentDefinition } from './orchestrator';
@@ -1,4 +1,4 @@
1
- import type { AgentConfig } from '@opencode-ai/sdk';
1
+ import type { AgentConfig } from '@opencode-ai/sdk/v2';
2
2
  export interface AgentDefinition {
3
3
  name: string;
4
4
  description?: string;
@@ -45,6 +45,7 @@ export interface LaunchOptions {
45
45
  export declare class BackgroundTaskManager {
46
46
  private tasks;
47
47
  private tasksBySessionId;
48
+ private agentBySessionId;
48
49
  private client;
49
50
  private directory;
50
51
  private tmuxEnabled;
@@ -55,6 +56,25 @@ export declare class BackgroundTaskManager {
55
56
  private maxConcurrentStarts;
56
57
  private completionResolvers;
57
58
  constructor(ctx: PluginInput, tmuxConfig?: TmuxConfig, config?: PluginConfig);
59
+ /**
60
+ * Look up the delegation rules for an agent type.
61
+ * Unknown agent types default to explorer-only access, making it easy
62
+ * to add new background agent types without updating SUBAGENT_DELEGATION_RULES.
63
+ */
64
+ private getSubagentRules;
65
+ /**
66
+ * Check if a parent session is allowed to delegate to a specific agent type.
67
+ * @param parentSessionId - The session ID of the parent
68
+ * @param requestedAgent - The agent type being requested
69
+ * @returns true if allowed, false if not
70
+ */
71
+ isAgentAllowed(parentSessionId: string, requestedAgent: string): boolean;
72
+ /**
73
+ * Get the list of allowed subagents for a parent session.
74
+ * @param parentSessionId - The session ID of the parent
75
+ * @returns Array of allowed agent names, empty if none
76
+ */
77
+ getAllowedSubagents(parentSessionId: string): readonly string[];
58
78
  /**
59
79
  * Launch a new background task (fire-and-forget).
60
80
  *
@@ -75,6 +95,15 @@ export declare class BackgroundTaskManager {
75
95
  private processQueue;
76
96
  private resolveFallbackChain;
77
97
  private promptWithTimeout;
98
+ /**
99
+ * Calculate tool permissions for a spawned agent based on its own delegation rules.
100
+ * Agents that cannot delegate (leaf nodes) get delegation tools disabled entirely,
101
+ * preventing models from even seeing tools they can never use.
102
+ *
103
+ * @param agentName - The agent type being spawned
104
+ * @returns Tool permissions object with background_task and task enabled/disabled
105
+ */
106
+ private calculateToolPermissions;
78
107
  /**
79
108
  * Start a task in the background (Phase B).
80
109
  */
@@ -92,6 +121,19 @@ export declare class BackgroundTaskManager {
92
121
  };
93
122
  };
94
123
  }): Promise<void>;
124
+ /**
125
+ * Handle session.deleted events for cleanup.
126
+ * When a session is deleted, cancel associated tasks and clean up.
127
+ */
128
+ handleSessionDeleted(event: {
129
+ type: string;
130
+ properties?: {
131
+ info?: {
132
+ id?: string;
133
+ };
134
+ sessionID?: string;
135
+ };
136
+ }): Promise<void>;
95
137
  /**
96
138
  * Extract task result and mark complete.
97
139
  */
@@ -42,6 +42,11 @@ export declare class TmuxSessionManager {
42
42
  * When a session becomes idle (completed), close its pane.
43
43
  */
44
44
  onSessionStatus(event: SessionEvent): Promise<void>;
45
+ /**
46
+ * Handle session.deleted events.
47
+ * When a session is deleted, close its tmux pane immediately.
48
+ */
49
+ onSessionDeleted(event: SessionEvent): Promise<void>;
45
50
  private startPolling;
46
51
  private stopPolling;
47
52
  /**
@@ -1,9 +1,12 @@
1
1
  export * from './chutes-selection';
2
2
  export * from './config-io';
3
3
  export * from './dynamic-model-selection';
4
+ export * from './external-rankings';
4
5
  export * from './model-selection';
5
6
  export * from './opencode-models';
6
7
  export * from './opencode-selection';
7
8
  export * from './paths';
9
+ export * from './precedence-resolver';
8
10
  export * from './providers';
11
+ export * from './scoring-v2';
9
12
  export * from './system';
@@ -1,2 +1,14 @@
1
- import type { DiscoveredModel, DynamicModelPlan, InstallConfig } from './types';
2
- export declare function buildDynamicModelPlan(catalog: DiscoveredModel[], config: InstallConfig): DynamicModelPlan | null;
1
+ import type { DiscoveredModel, DynamicModelPlan, ExternalSignalMap, InstallConfig, ScoringEngineVersion } from './types';
2
+ declare const AGENTS: readonly ["orchestrator", "oracle", "designer", "explorer", "librarian", "fixer"];
3
+ type AgentName = (typeof AGENTS)[number];
4
+ export type V1RankedScore = {
5
+ model: string;
6
+ totalScore: number;
7
+ baseScore: number;
8
+ externalSignalBoost: number;
9
+ };
10
+ export declare function rankModelsV1WithBreakdown(models: DiscoveredModel[], agent: AgentName, externalSignals?: ExternalSignalMap): V1RankedScore[];
11
+ export declare function buildDynamicModelPlan(catalog: DiscoveredModel[], config: InstallConfig, externalSignals?: ExternalSignalMap, options?: {
12
+ scoringEngineVersion?: ScoringEngineVersion;
13
+ }): DynamicModelPlan | null;
14
+ export {};
@@ -0,0 +1,8 @@
1
+ import type { ExternalSignalMap } from './types';
2
+ export declare function fetchExternalModelSignals(options?: {
3
+ artificialAnalysisApiKey?: string;
4
+ openRouterApiKey?: string;
5
+ }): Promise<{
6
+ signals: ExternalSignalMap;
7
+ warnings: string[];
8
+ }>;