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|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# What makes a CLI agent-friendly?
|
| 2 |
+
|
| 3 |
+
This is the living deliverable for the autoresearch experiment. Each entry must
|
| 4 |
+
be backed by measurement. Hypotheses may be listed only when there is a BEFORE
|
| 5 |
+
trace; a property is not confirmed until a paired BEFORE/AFTER run shows the
|
| 6 |
+
agent did better under the same conditions.
|
| 7 |
+
|
| 8 |
+
## Evidence levels
|
| 9 |
+
|
| 10 |
+
- **Tier 1 — candidate:** a differential probe shows the tool had information it
|
| 11 |
+
did not surface.
|
| 12 |
+
- **Tier 2 — confirmed/refuted:** a paired run shows whether surfacing that
|
| 13 |
+
information helped the agent recover unaided.
|
| 14 |
+
|
| 15 |
+
## Entry template
|
| 16 |
+
|
| 17 |
+
```text
|
| 18 |
+
PROPERTY what an agent-friendly CLI does
|
| 19 |
+
VIOLATION the failure class that appears when it is missing
|
| 20 |
+
STATUS hypothesis | confirmed | refuted
|
| 21 |
+
|
| 22 |
+
BEFORE measured trace of an agent defeated by its absence
|
| 23 |
+
CHANGE actual change and lever: tool | instructions
|
| 24 |
+
AFTER measured trace with the change in place
|
| 25 |
+
VERDICT confirmed | refuted, and the delta that supports it
|
| 26 |
+
```
|
| 27 |
+
|
| 28 |
+
## Evaluation rubric
|
| 29 |
+
|
| 30 |
+
Top-level score:
|
| 31 |
+
|
| 32 |
+
- Correctness and recoverability: **60%**
|
| 33 |
+
- Token efficiency: **20%**
|
| 34 |
+
- Wall-clock time: **20%**
|
| 35 |
+
|
| 36 |
+
The correctness/recoverability 60% is split into:
|
| 37 |
+
|
| 38 |
+
- Final outcome correctness: **20 points**
|
| 39 |
+
- Self-recovery: **20 points** — can the agent diagnose and recover without human help?
|
| 40 |
+
- Guidance / error quality: **12 points** — does the CLI explain what went wrong and what to do next?
|
| 41 |
+
- Execution / route quality: **6 points**
|
| 42 |
+
- Failure severity / attribution: **2 points**
|
| 43 |
+
|
| 44 |
+
Track **Self-Recovery Rate** separately:
|
| 45 |
+
|
| 46 |
+
```text
|
| 47 |
+
recoverable failures successfully recovered by the agent / total recoverable failures
|
| 48 |
+
```
|
| 49 |
+
|
| 50 |
+
Also track recovery cost: extra tokens, calls, and wall-clock time.
|
| 51 |
+
|
| 52 |
+
## Phase 4 measurement distribution
|
| 53 |
+
|
| 54 |
+
Measurement run:
|
| 55 |
+
|
| 56 |
+
```text
|
| 57 |
+
experiments/runs/agenteval-measurement-3009509/agenteval-summary-with-retries.json
|
| 58 |
+
```
|
| 59 |
+
|
| 60 |
+
This combines the 60-attempt Phase 4 run with the two successful retry attempts
|
| 61 |
+
for transient timeouts, leaving the original run artifacts untouched.
|
| 62 |
+
|
| 63 |
+
```json
|
| 64 |
+
{
|
| 65 |
+
"records": 60,
|
| 66 |
+
"attempts_with_failures": 34,
|
| 67 |
+
"class_counts": {"clean": 389, "C": 55, "B": 15, "A": 38, "D": 3},
|
| 68 |
+
"subtype_counts": {"c-truncated": 25, "c-unknown": 25, "c-wrong-type": 3, "c-wrong-column": 2},
|
| 69 |
+
"agent_side_counts": {}
|
| 70 |
+
}
|
| 71 |
+
```
|
| 72 |
+
|
| 73 |
+
The largest evidenced candidate is currently `c-truncated`: taxonomy/discovery
|
| 74 |
+
output hit a limit, the agent treated the capped list as complete, and raising
|
| 75 |
+
the limit revealed more rows. The next largest bucket is `c-unknown`, which means
|
| 76 |
+
our probes could not yet explain the empty result; this is an instrumentation
|
| 77 |
+
work queue, not proof that the CLI behaved well.
|
| 78 |
+
|
| 79 |
+
## Confirmed properties
|
| 80 |
+
|
| 81 |
+
### Never silently truncate output
|
| 82 |
+
|
| 83 |
+
PROPERTY An agent-friendly CLI says when an output list hit a limit and names
|
| 84 |
+
the exact recovery action.
|
| 85 |
+
VIOLATION `c-truncated`: the agent reads a capped list as complete and concludes
|
| 86 |
+
a value/category does not exist.
|
| 87 |
+
STATUS confirmed
|
| 88 |
+
|
| 89 |
+
BEFORE In the Phase 4 run, `categories --top N` frequently returned exactly
|
| 90 |
+
N rows with no truncation notice. A differential probe with a larger
|
| 91 |
+
`--top` found more rows. On the paired subset
|
| 92 |
+
(`bike-parking-coverage`, `basic-category-rollup`,
|
| 93 |
+
`bus-stops-cambridge`, 2 repeats each), the BEFORE trace had:
|
| 94 |
+
|
| 95 |
+
```json
|
| 96 |
+
{"c-truncated": 13, "B": 5, "A": 3, "c-wrong-column": 1, "c-unknown": 7}
|
| 97 |
+
```
|
| 98 |
+
|
| 99 |
+
CHANGE Tool lever. Botmap candidate `00bff1a` changes `categories` to emit
|
| 100 |
+
stderr when `--top` truncates the list:
|
| 101 |
+
|
| 102 |
+
```text
|
| 103 |
+
[botmap] Showing top N of TOTAL categories. This list is truncated; rerun with
|
| 104 |
+
`--top TOTAL` or a larger --top before concluding a category is absent.
|
| 105 |
+
```
|
| 106 |
+
|
| 107 |
+
AFTER Paired AFTER run:
|
| 108 |
+
|
| 109 |
+
```text
|
| 110 |
+
experiments/runs/after-categories-truncation-hint-00bff1a/
|
| 111 |
+
```
|
| 112 |
+
|
| 113 |
+
```json
|
| 114 |
+
{"c-truncated": 5, "B": 2, "c-unknown": 2, "A": 1}
|
| 115 |
+
```
|
| 116 |
+
|
| 117 |
+
VERDICT Confirmed provisionally. `c-truncated` fell from **13 to 5** on the
|
| 118 |
+
matched subset. One AFTER attempt still timed out, and this is a
|
| 119 |
+
subset result, but the measured direction is strong enough to keep
|
| 120 |
+
the property.
|
| 121 |
+
|
| 122 |
+
### If a value exists elsewhere, say where
|
| 123 |
+
|
| 124 |
+
PROPERTY If a filter value exists in another field, an agent-friendly CLI
|
| 125 |
+
names that field and gives the corrected filter.
|
| 126 |
+
VIOLATION `c-wrong-column`: the agent uses a real value in the wrong column,
|
| 127 |
+
gets zero, and treats the zero as absence.
|
| 128 |
+
STATUS confirmed
|
| 129 |
+
|
| 130 |
+
BEFORE On the paired subset (`bike-parking-coverage`,
|
| 131 |
+
`residential-share-cambridge`, 2 repeats each), the BEFORE trace had:
|
| 132 |
+
|
| 133 |
+
```json
|
| 134 |
+
{"c-truncated": 5, "B": 3, "c-wrong-column": 2, "c-unknown": 6, "A": 1, "c-wrong-type": 1}
|
| 135 |
+
```
|
| 136 |
+
|
| 137 |
+
CHANGE Tool lever. Botmap candidate `7c794ff` changes `count`: when
|
| 138 |
+
`class=X` or `subtype=X` returns zero, it tests the paired field and
|
| 139 |
+
emits a concrete correction if that field has rows.
|
| 140 |
+
|
| 141 |
+
```text
|
| 142 |
+
[botmap] 0 rows for subtype='bicycle_parking', but class='bicycle_parking'
|
| 143 |
+
returns 1,844. Try `--where class=bicycle_parking` before concluding none exist.
|
| 144 |
+
```
|
| 145 |
+
|
| 146 |
+
AFTER Paired AFTER run:
|
| 147 |
+
|
| 148 |
+
```text
|
| 149 |
+
experiments/runs/after-count-wrong-column-hint-7c794ff/
|
| 150 |
+
```
|
| 151 |
+
|
| 152 |
+
```json
|
| 153 |
+
{"c-truncated": 3, "B": 2, "c-vocabulary": 2, "A": 1}
|
| 154 |
+
```
|
| 155 |
+
|
| 156 |
+
VERDICT Confirmed narrowly. `c-wrong-column` fell from **2 to 0** on the
|
| 157 |
+
matched subset. Other failures remain, so this confirms the column
|
| 158 |
+
guidance property, not full task success.
|
| 159 |
+
|
| 160 |
+
## Current candidate properties
|
| 161 |
+
|
| 162 |
+
These are hypotheses from `docs/plan.md`. They are waiting for Phase 4 BEFORE
|
| 163 |
+
traces and later paired Phase 6 experiments.
|
| 164 |
+
|
| 165 |
+
1. Never return an empty result without saying why.
|
| 166 |
+
2. Name the fix, not just the problem.
|
| 167 |
+
3. Never silently discard input.
|
| 168 |
+
4. Never silently truncate output.
|
| 169 |
+
5. Make discovery a first-class operation.
|
| 170 |
+
6. Advertise only values that work.
|
| 171 |
+
7. Confirm what you resolved.
|
| 172 |
+
8. Emit progress on long operations.
|
| 173 |
+
9. Recovery advice must actually work.
|
| 174 |
+
10. One obvious spelling should work.
|