@agent-om/cli 0.0.0-stage → 0.1.1
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/LICENSE +64 -0
- package/README.md +112 -2
- package/dist/agent-om.mjs +547 -0
- package/dist/server-CNRN0if0.mjs +4751 -0
- package/dist/session-Dx2d3ujt.mjs +658 -0
- package/package.json +54 -3
- package/skill/SKILL.md +64 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
Copyright 2026 Sumeet Debnath and Prathmesh Vhatkar
|
|
2
|
+
|
|
3
|
+
@agent-om/cli is source-available, not open source. It is licensed under the
|
|
4
|
+
PolyForm Strict License 1.0.0, whose full text follows.
|
|
5
|
+
|
|
6
|
+
# PolyForm Strict License 1.0.0
|
|
7
|
+
|
|
8
|
+
<https://polyformproject.org/licenses/strict/1.0.0>
|
|
9
|
+
|
|
10
|
+
## Acceptance
|
|
11
|
+
|
|
12
|
+
In order to get any license under these terms, you must agree to them as both strict obligations and conditions to all your licenses.
|
|
13
|
+
|
|
14
|
+
## Copyright License
|
|
15
|
+
|
|
16
|
+
The licensor grants you a copyright license for the software to do everything you might do with the software that would otherwise infringe the licensor's copyright in it for any permitted purpose, other than distributing the software or making changes or new works based on the software.
|
|
17
|
+
|
|
18
|
+
## Patent License
|
|
19
|
+
|
|
20
|
+
The licensor grants you a patent license for the software that covers patent claims the licensor can license, or becomes able to license, that you would infringe by using the software.
|
|
21
|
+
|
|
22
|
+
## Noncommercial Purposes
|
|
23
|
+
|
|
24
|
+
Any noncommercial purpose is a permitted purpose.
|
|
25
|
+
|
|
26
|
+
## Personal Uses
|
|
27
|
+
|
|
28
|
+
Personal use for research, experiment, and testing for the benefit of public knowledge, personal study, private entertainment, hobby projects, amateur pursuits, or religious observance, without any anticipated commercial application, is use for a permitted purpose.
|
|
29
|
+
|
|
30
|
+
## Noncommercial Organizations
|
|
31
|
+
|
|
32
|
+
Use by any charitable organization, educational institution, public research organization, public safety or health organization, environmental protection organization, or government institution is use for a permitted purpose regardless of the source of funding or obligations resulting from the funding.
|
|
33
|
+
|
|
34
|
+
## Fair Use
|
|
35
|
+
|
|
36
|
+
You may have "fair use" rights for the software under the law. These terms do not limit them.
|
|
37
|
+
|
|
38
|
+
## No Other Rights
|
|
39
|
+
|
|
40
|
+
These terms do not allow you to sublicense or transfer any of your licenses to anyone else, or prevent the licensor from granting licenses to anyone else. These terms do not imply any other licenses.
|
|
41
|
+
|
|
42
|
+
## Patent Defense
|
|
43
|
+
|
|
44
|
+
If you make any written claim that the software infringes or contributes to infringement of any patent, your patent license for the software granted under these terms ends immediately. If your company makes such a claim, your patent license ends immediately for work on behalf of your company.
|
|
45
|
+
|
|
46
|
+
## Violations
|
|
47
|
+
|
|
48
|
+
The first time you are notified in writing that you have violated any of these terms, or done anything with the software not covered by your licenses, your licenses can nonetheless continue if you come into full compliance with these terms, and take practical steps to correct past violations, within 32 days of receiving notice. Otherwise, all your licenses end immediately.
|
|
49
|
+
|
|
50
|
+
## No Liability
|
|
51
|
+
|
|
52
|
+
***As far as the law allows, the software comes as is, without any warranty or condition, and the licensor will not be liable to you for any damages arising out of these terms or the use or nature of the software, under any kind of legal claim.***
|
|
53
|
+
|
|
54
|
+
## Definitions
|
|
55
|
+
|
|
56
|
+
The **licensor** is the individual or entity offering these terms, and the **software** is the software the licensor makes available under these terms.
|
|
57
|
+
|
|
58
|
+
**You** refers to the individual or entity agreeing to these terms.
|
|
59
|
+
|
|
60
|
+
**Your company** is any legal entity, sole proprietorship, or other kind of organization that you work for, plus all organizations that have control over, are under the control of, or are under common control with that organization. **Control** means ownership of substantially all the assets of an entity, or the power to direct its management and policies by vote, contract, or otherwise. Control can be direct or indirect.
|
|
61
|
+
|
|
62
|
+
**Your licenses** are all the licenses granted to you for the software under these terms.
|
|
63
|
+
|
|
64
|
+
**Use** means anything you do with the software requiring one of your licenses.
|
package/README.md
CHANGED
|
@@ -1,3 +1,113 @@
|
|
|
1
|
-
#
|
|
1
|
+
# @agent-om/cli
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
`agent-om`: a command-line tool any AI agent drives from a shell, on any model, to use a
|
|
4
|
+
web page: a browser kept open between calls, the page read as the
|
|
5
|
+
[Agent Object Model](https://github.com/TheAsyncLooop/agent-om)'s view
|
|
6
|
+
(Chrome's accessibility tree and the DOM, merged, secrets removed), and acted
|
|
7
|
+
on by ref. It works on any site, built for agents or not.
|
|
8
|
+
|
|
9
|
+
> **Status:** 0.x. Commands and output can still change.
|
|
10
|
+
|
|
11
|
+
```sh
|
|
12
|
+
npm install -g @agent-om/cli
|
|
13
|
+
agent-om install # once: downloads Playwright's Chromium
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
Node 22 or later.
|
|
17
|
+
|
|
18
|
+
### Using your own Chrome (no browser download needed)
|
|
19
|
+
|
|
20
|
+
You can skip `agent-om install` and launch your installed Chrome, or attach to a
|
|
21
|
+
Chrome you already have open (with your sign-ins):
|
|
22
|
+
|
|
23
|
+
```sh
|
|
24
|
+
# Launch an installed Chrome / Chromium binary directly
|
|
25
|
+
agent-om start --executable "/Applications/Google Chrome.app/Contents/MacOS/Google Chrome"
|
|
26
|
+
|
|
27
|
+
# Attach to your running Chrome (enable remote debugging at chrome://inspect/#remote-debugging;
|
|
28
|
+
# Chrome asks you to click Allow each time a session attaches)
|
|
29
|
+
agent-om start --auto-connect # agent's own tabs only (--tabs own, the default)
|
|
30
|
+
agent-om start --auto-connect --tabs active # also the tab currently in front
|
|
31
|
+
agent-om start --cdp 9222 # or attach by explicit CDP port / WebSocket URL
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
Run `agent-om help session` for more on profiles (`--profile`), saved auth state
|
|
35
|
+
(`--state`), tab scopes (`--tabs own|active|all`), and site restrictions
|
|
36
|
+
(`--allow-origin`).
|
|
37
|
+
|
|
38
|
+
## Use
|
|
39
|
+
|
|
40
|
+
```console
|
|
41
|
+
$ agent-om open http://localhost:3000/
|
|
42
|
+
Page: Monitors (/)
|
|
43
|
+
- main [e7]
|
|
44
|
+
- heading "Monitors" [e8] level=1
|
|
45
|
+
- button "Add monitor" [e9]
|
|
46
|
+
- text: Checkout API
|
|
47
|
+
|
|
48
|
+
$ agent-om click e9
|
|
49
|
+
clicked button "Add monitor" [e9]
|
|
50
|
+
Changes on Monitors:
|
|
51
|
+
+ new in list [e10]:
|
|
52
|
+
- text: Orders DB
|
|
53
|
+
|
|
54
|
+
$ agent-om stop
|
|
55
|
+
stopped
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
Every action prints what it did and what changed on the page. `agent-om help`
|
|
59
|
+
lists every command: reading (`open`, `snapshot`, `changes`, `inspect`),
|
|
60
|
+
acting (`click`, `fill`, `type`, `select`, `check`, `press`, `scroll`,
|
|
61
|
+
`upload`, `fill-secret`, …) and the session (`start`, `stop`, `status`).
|
|
62
|
+
|
|
63
|
+
- **What the page says, nothing more**: Chrome's tree, the DOM's facts and the
|
|
64
|
+
app's `data-agentom-*` markup; never guesses from an app's ids or class names.
|
|
65
|
+
- **Errors that say what to try**: what covers an element, the field inside a
|
|
66
|
+
box, the choices a drop-down has.
|
|
67
|
+
- **Secrets stay with the user.** A credential is filled only from an
|
|
68
|
+
environment variable the user set and tied to its site
|
|
69
|
+
(`fill-secret <ref> <VARIABLE>`, with `<VARIABLE>_ORIGIN=https://…`), only
|
|
70
|
+
on that site, and never shown; what the page marks redact or ignore never appears; an action the
|
|
71
|
+
page asks to confirm needs `--confirm`.
|
|
72
|
+
- **Many steps in one call.** `agent-om script` runs JavaScript that drives
|
|
73
|
+
the tool: `om.click(ref)`, `om.find({ role, name })`, `om.table(ref)` and
|
|
74
|
+
every other command, in loops, printing only what's needed. It runs in a
|
|
75
|
+
sandbox of its own: it reaches the page only through the tool, never the
|
|
76
|
+
page's DOM, Node or the network.
|
|
77
|
+
- **`eval`, unless you turn it off.** The agent can run JavaScript in the
|
|
78
|
+
page (`agent-om eval "<script>"`, or `--ref e40` to run it on an element
|
|
79
|
+
the view found) for what the view doesn't hold.
|
|
80
|
+
What it returns has secret fields' values and what the page keeps out taken
|
|
81
|
+
out, but a script can read anything the page's scripts can, cookies and
|
|
82
|
+
storage included: where that isn't acceptable, start the session with
|
|
83
|
+
`AGENT_OM_ALLOW_EVAL=0` in its environment, and no later command turns it
|
|
84
|
+
back on. A secret is taken out as the page writes it: a script that
|
|
85
|
+
rewrites one before returning it (reversed, encoded) gets it through. In a
|
|
86
|
+
session attached to your own browser (`--cdp`, `--auto-connect`), where a
|
|
87
|
+
script would read everything you are signed in to, `eval` is off unless the
|
|
88
|
+
session starts with `AGENT_OM_ALLOW_EVAL=1`.
|
|
89
|
+
|
|
90
|
+
## For an agent
|
|
91
|
+
|
|
92
|
+
The package ships a skill text that teaches any model the workflow (skill
|
|
93
|
+
name `agent-om`). Install it in one command:
|
|
94
|
+
|
|
95
|
+
```sh
|
|
96
|
+
# Install globally for OpenCode, Claude Code, Codex, and Cursor:
|
|
97
|
+
agent-om skill install --global
|
|
98
|
+
|
|
99
|
+
# Or install into the current project (.agents/skills/ and .claude/skills/):
|
|
100
|
+
agent-om skill install
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
`agent-om skill` prints the raw `SKILL.md` to stdout if you want to place it
|
|
104
|
+
somewhere else manually.
|
|
105
|
+
|
|
106
|
+
## Documentation
|
|
107
|
+
|
|
108
|
+
- [How it works](https://github.com/TheAsyncLooop/agent-om/blob/master/docs/semantic-projection.md)
|
|
109
|
+
- [The repository](https://github.com/TheAsyncLooop/agent-om)
|
|
110
|
+
|
|
111
|
+
## License
|
|
112
|
+
|
|
113
|
+
Source-available, not open source. Licensed under the [PolyForm Strict License 1.0.0](https://github.com/TheAsyncLooop/agent-om/blob/master/packages/cli/LICENSE). Copyright 2026 Sumeet Debnath and Prathmesh Vhatkar.
|