@mind-harness/mh-browser 0.1.6 → 0.2.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/extension/manifest.json +1 -1
- package/lib/index.js +666 -682
- package/lib/types/index.d.ts +1 -1
- package/lib/types/presence/register.d.ts +2 -1
- package/lib/types/projections.d.ts +2 -12
- package/lib/types/tools/download.d.ts +2 -1
- package/lib/types/tools/handover.d.ts +2 -1
- package/lib/types/tools/invoke.d.ts +2 -1
- package/lib/types/tools/open.d.ts +2 -1
- package/lib/types/tools/page-ops.d.ts +3 -2
- package/lib/types/tools/presence.d.ts +2 -1
- package/lib/types/tools/register.d.ts +2 -1
- package/package.json +27 -24
package/lib/types/index.d.ts
CHANGED
|
@@ -5,7 +5,7 @@ export declare const name = "mh-browser";
|
|
|
5
5
|
export declare const inject: string[];
|
|
6
6
|
export type Config = BrowserConfig;
|
|
7
7
|
export declare const Config: import("@deepseek-ai/schemastery").default<BrowserConfig>;
|
|
8
|
-
export declare function apply(ctx: Context, config: Config): void
|
|
8
|
+
export declare function apply(ctx: Context, config: Config): Promise<void>;
|
|
9
9
|
export { MhBrowserService };
|
|
10
10
|
export { readAgentView } from './representation/agent-view.ts';
|
|
11
11
|
export type { AgentViewDoc, AgentViewLink, AgentViewRead } from './representation/agent-view.ts';
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import type { Context } from '@deepseek-ai/cordis';
|
|
2
2
|
import type { Agent, PreStepDecision } from '@deepseek-ai/dsh-agent';
|
|
3
3
|
import { type UserMessage } from '@deepseek-ai/dsh-llm';
|
|
4
|
+
import type { LogReader } from '../projections.ts';
|
|
4
5
|
import type { MhBrowserService } from '../service/service.ts';
|
|
5
6
|
import { type PresenceLogState } from './fold.ts';
|
|
6
7
|
import './source.ts';
|
|
@@ -9,7 +10,7 @@ import './source.ts';
|
|
|
9
10
|
* the reminder after the claimed input. `await next()` runs first, so a
|
|
10
11
|
* caller that puts pages and then returns `next()` is folded into this step.
|
|
11
12
|
*/
|
|
12
|
-
export declare function registerPresence(ctx: Context): void;
|
|
13
|
+
export declare function registerPresence(ctx: Context, reader: LogReader): void;
|
|
13
14
|
/**
|
|
14
15
|
* The reminder this step should carry. A set the log has but this process has
|
|
15
16
|
* not checked (a resumed session) is re-read; one whose reminder a canceled
|
|
@@ -4,22 +4,12 @@ import { type PresenceLogState } from './presence/fold.ts';
|
|
|
4
4
|
import { type AttachmentState } from './tools/attachments.ts';
|
|
5
5
|
import { type DeliveryState } from './tools/delivery.ts';
|
|
6
6
|
import { type TabLogState } from './tools/tab-log.ts';
|
|
7
|
-
declare module '@deepseek-ai/dsh-session-projection/types' {
|
|
8
|
-
interface SessionProjectionStateMap {
|
|
9
|
-
mhBrowserDeliveries: DeliveryState;
|
|
10
|
-
mhBrowserPresence: PresenceLogState;
|
|
11
|
-
mhBrowserAttachments: AttachmentState;
|
|
12
|
-
mhBrowserTabs: TabLogState;
|
|
13
|
-
}
|
|
14
|
-
}
|
|
15
|
-
/** Host-only folds over the session log; every read of what the log says goes through these. */
|
|
16
|
-
export declare function registerProjections(ctx: Context): void;
|
|
17
7
|
export interface LogReader {
|
|
18
8
|
deliveries(session: Session): DeliveryState;
|
|
19
9
|
presence(session: Session): PresenceLogState;
|
|
20
10
|
attachments(session: Session): AttachmentState;
|
|
21
11
|
tabs(session: Session): TabLogState;
|
|
22
12
|
}
|
|
23
|
-
/**
|
|
24
|
-
export declare function
|
|
13
|
+
/** Host-only folds over the session log; every read of what the log says goes through these. */
|
|
14
|
+
export declare function registerProjections(ctx: Context): Promise<LogReader>;
|
|
25
15
|
//# sourceMappingURL=projections.d.ts.map
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { Context } from '@deepseek-ai/cordis';
|
|
2
2
|
import { type ToolDefinition } from '@deepseek-ai/dsh-tools';
|
|
3
|
-
|
|
3
|
+
import type { LogReader } from '../projections.ts';
|
|
4
|
+
export declare function browserDownloadTool(ctx: Context, reader: LogReader): ToolDefinition;
|
|
4
5
|
//# sourceMappingURL=download.d.ts.map
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { Context } from '@deepseek-ai/cordis';
|
|
2
2
|
import { type ToolDefinition } from '@deepseek-ai/dsh-tools';
|
|
3
|
-
|
|
3
|
+
import type { LogReader } from '../projections.ts';
|
|
4
|
+
export declare function browserHandoverTool(ctx: Context, reader: LogReader): ToolDefinition;
|
|
4
5
|
//# sourceMappingURL=handover.d.ts.map
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { Context } from '@deepseek-ai/cordis';
|
|
2
2
|
import { type ToolDefinition } from '@deepseek-ai/dsh-tools';
|
|
3
|
-
|
|
3
|
+
import type { LogReader } from '../projections.ts';
|
|
4
|
+
export declare function browserInvokeTool(ctx: Context, reader: LogReader): ToolDefinition;
|
|
4
5
|
//# sourceMappingURL=invoke.d.ts.map
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { Context } from '@deepseek-ai/cordis';
|
|
2
2
|
import { type ToolDefinition } from '@deepseek-ai/dsh-tools';
|
|
3
|
-
|
|
3
|
+
import type { LogReader } from '../projections.ts';
|
|
4
|
+
export declare function browserOpenTool(ctx: Context, reader: LogReader): ToolDefinition;
|
|
4
5
|
//# sourceMappingURL=open.d.ts.map
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import type { Context } from '@deepseek-ai/cordis';
|
|
2
2
|
import { type ToolDefinition } from '@deepseek-ai/dsh-tools';
|
|
3
|
+
import type { LogReader } from '../projections.ts';
|
|
3
4
|
export declare const PAGE_OPERATION_NAMES: readonly ["browser_click", "browser_hover", "browser_select_option", "browser_drag", "browser_type", "browser_fill_form", "browser_press_key", "browser_file_upload", "browser_handle_dialog", "browser_navigate_back", "browser_wait_for", "browser_snapshot", "browser_find", "browser_take_screenshot", "browser_evaluate"];
|
|
4
|
-
export declare function pageOperationTools(ctx: Context): ToolDefinition[];
|
|
5
|
-
export declare function pageOperationTool(ctx: Context, name: string): ToolDefinition;
|
|
5
|
+
export declare function pageOperationTools(ctx: Context, reader: LogReader): ToolDefinition[];
|
|
6
|
+
export declare function pageOperationTool(ctx: Context, reader: LogReader, name: string): ToolDefinition;
|
|
6
7
|
//# sourceMappingURL=page-ops.d.ts.map
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { Context } from '@deepseek-ai/cordis';
|
|
2
2
|
import { type ToolDefinition } from '@deepseek-ai/dsh-tools';
|
|
3
|
-
|
|
3
|
+
import type { LogReader } from '../projections.ts';
|
|
4
|
+
export declare function browserPresenceTool(ctx: Context, reader: LogReader): ToolDefinition;
|
|
4
5
|
//# sourceMappingURL=presence.d.ts.map
|
|
@@ -1,3 +1,4 @@
|
|
|
1
1
|
import type { Context } from '@deepseek-ai/cordis';
|
|
2
|
-
|
|
2
|
+
import type { LogReader } from '../projections.ts';
|
|
3
|
+
export declare function registerBrowserTools(ctx: Context, reader: LogReader): void;
|
|
3
4
|
//# sourceMappingURL=register.d.ts.map
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mind-harness/mh-browser",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.2.0",
|
|
4
4
|
"description": "Opens pages in a real browser for the agent, keeps chosen Agent Views in context, and hands the browser to you when a person is needed.",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE",
|
|
6
6
|
"files": [
|
|
@@ -48,33 +48,36 @@
|
|
|
48
48
|
"zod": "^4.6.6"
|
|
49
49
|
},
|
|
50
50
|
"devDependencies": {
|
|
51
|
-
"@deepseek-ai/cordis": "~4.0
|
|
52
|
-
"@deepseek-ai/dsh-agent": "^0.2.
|
|
53
|
-
"@deepseek-ai/dsh-agent-loop": "^0.2.
|
|
54
|
-
"@deepseek-ai/dsh-agent-loop-testkit": "^0.2.
|
|
55
|
-
"@deepseek-ai/dsh-attachment": "^0.2.
|
|
56
|
-
"@deepseek-ai/dsh-browser-use": "^0.2.
|
|
57
|
-
"@deepseek-ai/dsh-home-paths": "^0.2.
|
|
58
|
-
"@deepseek-ai/dsh-llm": "^0.2.
|
|
59
|
-
"@deepseek-ai/dsh-llm-mock-server": "^0.2.
|
|
60
|
-
"@deepseek-ai/dsh-sandbox-policy": "^0.2.
|
|
61
|
-
"@deepseek-ai/dsh-session": "^0.2.
|
|
62
|
-
"@deepseek-ai/dsh-session-projection": "^0.2.
|
|
63
|
-
"@deepseek-ai/dsh-tools": "^0.2.
|
|
64
|
-
"@deepseek-ai/dsh-typert-protocol": "^0.2.
|
|
65
|
-
"@deepseek-ai/dsh-user-questions": "^0.2.
|
|
66
|
-
"@deepseek-ai/schemastery": "~3.
|
|
51
|
+
"@deepseek-ai/cordis": "~4.1.0",
|
|
52
|
+
"@deepseek-ai/dsh-agent": "^0.2.2-rc.1",
|
|
53
|
+
"@deepseek-ai/dsh-agent-loop": "^0.2.2-rc.1",
|
|
54
|
+
"@deepseek-ai/dsh-agent-loop-testkit": "^0.2.2-rc.1",
|
|
55
|
+
"@deepseek-ai/dsh-attachment": "^0.2.2-rc.1",
|
|
56
|
+
"@deepseek-ai/dsh-browser-use": "^0.2.2-rc.1",
|
|
57
|
+
"@deepseek-ai/dsh-home-paths": "^0.2.2-rc.1",
|
|
58
|
+
"@deepseek-ai/dsh-llm": "^0.2.2-rc.1",
|
|
59
|
+
"@deepseek-ai/dsh-llm-mock-server": "^0.2.2-rc.1",
|
|
60
|
+
"@deepseek-ai/dsh-sandbox-policy": "^0.2.2-rc.1",
|
|
61
|
+
"@deepseek-ai/dsh-session": "^0.2.2-rc.1",
|
|
62
|
+
"@deepseek-ai/dsh-session-projection": "^0.2.2-rc.1",
|
|
63
|
+
"@deepseek-ai/dsh-tools": "^0.2.2-rc.1",
|
|
64
|
+
"@deepseek-ai/dsh-typert-protocol": "^0.2.2-rc.1",
|
|
65
|
+
"@deepseek-ai/dsh-user-questions": "^0.2.2-rc.1",
|
|
66
|
+
"@deepseek-ai/schemastery": "~3.19.0"
|
|
67
67
|
},
|
|
68
68
|
"peerDependencies": {
|
|
69
|
-
"@deepseek-ai/cordis": "
|
|
70
|
-
"@deepseek-ai/dsh-home-paths": ">=0.2.
|
|
71
|
-
"@deepseek-ai/dsh-llm": ">=0.2.
|
|
72
|
-
"@deepseek-ai/dsh-tools": ">=0.2.
|
|
73
|
-
"@deepseek-ai/dsh-typert-protocol": ">=0.2.
|
|
74
|
-
"@deepseek-ai/dsh-user-questions": ">=0.2.
|
|
75
|
-
"@deepseek-ai/schemastery": "
|
|
69
|
+
"@deepseek-ai/cordis": "^4.1.0",
|
|
70
|
+
"@deepseek-ai/dsh-home-paths": ">=0.2.2-rc.1 <0.2.3-0",
|
|
71
|
+
"@deepseek-ai/dsh-llm": ">=0.2.2-rc.1 <0.2.3-0",
|
|
72
|
+
"@deepseek-ai/dsh-tools": ">=0.2.2-rc.1 <0.2.3-0",
|
|
73
|
+
"@deepseek-ai/dsh-typert-protocol": ">=0.2.2-rc.1 <0.2.3-0",
|
|
74
|
+
"@deepseek-ai/dsh-user-questions": ">=0.2.2-rc.1 <0.2.3-0",
|
|
75
|
+
"@deepseek-ai/schemastery": "^3.19.0"
|
|
76
76
|
},
|
|
77
77
|
"icon": "./icon.svg",
|
|
78
|
+
"engines": {
|
|
79
|
+
"dsh": ">=0.2.2-rc.1 <0.2.3-0"
|
|
80
|
+
},
|
|
78
81
|
"scripts": {
|
|
79
82
|
"version": "node ../../scripts/mh/sync-extension-version.ts"
|
|
80
83
|
}
|