ask-computer 0.1.2 → 0.1.4

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 513ed9fe95ce075dad84039f31a043232582d75664b4e904f45010b1f50bf524
4
- data.tar.gz: b04631da5003dcea42d9476c7ed0518aef3bdfb90273afa3fafa43c2b8335137
3
+ metadata.gz: 2c2367b47037ac3a986d92b848a01d105ebf476243a2d2e216922a2cb75548c0
4
+ data.tar.gz: f4d04075670cd0b35b11358357beef242b0890e37ce26603bec61f9ce4b07bbe
5
5
  SHA512:
6
- metadata.gz: 8ab6c1e6ef61c44c4ab4e4041b4e657b3c70d1ccdb534b6b5da13bbb1a1523c4da51117923d636d9ed04a61d6a5f11e3191fcae9f989a835b294306d2ac62cef
7
- data.tar.gz: 25315efae89fc14c2adf4d7fa88167d5fb8597faf9a55caf7a46bc14c36381b56dcb64308ac8b5c185e66ff2b859fce81250d5c0c22d84d63526278ff969a125
6
+ metadata.gz: f078e44a61c4b1b288055b220627ec6d11b202e6f5412c2842ffbf0369a19969545ee67860c8a7355834152a3856b8c6f6b23a489a191dca9699286f6d85afe1
7
+ data.tar.gz: 42bf201e70f5a45143b8e6ce1e6ee6c20d361fbfedf3226fad9d949741a97717b72f19615b92d82506ce25bc123acff25b5c8692b84ac58bdf3464634ffbef33
data/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # Changelog
2
2
 
3
+ ## [0.1.3] - 2026-09-18
4
+
5
+ ### Changed
6
+
7
+ - Requires `ask-core >= 0.12.0` for the decision vocabulary
8
+ (`Ask::Decision`, `Ask::DecisionProvider`, `Ask::DecisionResult`).
9
+ Nothing else changed.
10
+
3
11
  ## [0.1.0] - 2026-08-20
4
12
 
5
13
  ### Added
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Ask
4
4
  module Computer
5
- VERSION = "0.1.2"
5
+ VERSION = "0.1.4"
6
6
  end
7
7
  end
@@ -72,6 +72,42 @@ driver.call_tool("computer_key", { key: "Enter" })
72
72
 
73
73
  Prefer accessibility-aware targeting when available over raw coordinates. After each state-changing action, re-screenshot to confirm the change.
74
74
 
75
+ ## Step 2b: Decide the Next Action (Optional)
76
+
77
+ When facing a complex screen state or multi-step workflow, use the `decide` tool to select the best action from candidates rather than guessing. This offloads the "which action?" judgment to a fast decision model (Jev) while the agent handles observation and execution.
78
+
79
+ ```ruby
80
+ # After taking a screenshot and describing the screen state:
81
+ decide(
82
+ state: "Screen shows a login form. Username field at (100,200), password at (100,250), Submit at (100,300).",
83
+ questions: '{
84
+ "action": {
85
+ "type": "choice",
86
+ "instructions": "Which action should the agent take next?",
87
+ "criteria": {
88
+ "click_username": "Click the username field to focus it",
89
+ "click_submit": "Click the submit button (only if credentials are already filled)",
90
+ "type_credentials": "Type username and password",
91
+ "none": "The goal state is already achieved"
92
+ }
93
+ },
94
+ "confidence": {
95
+ "type": "noul",
96
+ "instructions": "Is the screen state clear enough to act?"
97
+ }
98
+ }'
99
+ )
100
+ # => {"model":"jev-latest","answers":{"action":{"type":"choice","choice":"click_username","confidence":0.92},"confidence":{"type":"noul","noul":0.85}}}
101
+ ```
102
+
103
+ Use `decide` when:
104
+ - Multiple valid actions exist and you need to pick the best one
105
+ - You want calibrated confidence scores before acting
106
+ - The screen is ambiguous and you want a fast second opinion
107
+ - You're in a loop and want to detect stale/repeated actions
108
+
109
+ Skip `decide` for straightforward single-action sequences (e.g., type then Enter).
110
+
75
111
  ## Step 3: Query History with Bounded Reads
76
112
 
77
113
  Events are ordered by `data.sequence` ascending. Treat missing sequence numbers as gap evidence. Paginate toward older records with `until_sequence`; toward newer with `since_sequence`. Bounds are inclusive — subtract/add 1 for non-overlapping pages.
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ask-computer
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.1.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kaka Ruto
@@ -15,14 +15,14 @@ dependencies:
15
15
  requirements:
16
16
  - - ">="
17
17
  - !ruby/object:Gem::Version
18
- version: 0.11.4
18
+ version: 0.12.1
19
19
  type: :runtime
20
20
  prerelease: false
21
21
  version_requirements: !ruby/object:Gem::Requirement
22
22
  requirements:
23
23
  - - ">="
24
24
  - !ruby/object:Gem::Version
25
- version: 0.11.4
25
+ version: 0.12.1
26
26
  - !ruby/object:Gem::Dependency
27
27
  name: ask-mcp
28
28
  requirement: !ruby/object:Gem::Requirement