@danceiny/gotry 0.0.1-rc.15 → 0.0.1-rc.17
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 +51 -13
- package/README.zh-CN.md +26 -12
- package/bin/gotry-booking-copilot.js +53 -0
- package/bin/gotry-bootstrap.js +357 -8
- package/bin/gotry-inner.js +442 -60
- package/bin/gotry-runtime-resolution.d.ts +27 -0
- package/bin/gotry-runtime-resolution.js +50 -0
- package/bin/gotry.js +1 -1
- package/cordis.gotry-patch.yml +15 -1
- package/data/airline-airports.json +39 -0
- package/dist/capabilities/agent-reach-deep.js +1 -1
- package/dist/capabilities/agent-reach.js +1 -1
- package/dist/capabilities/anything.js +1 -1
- package/dist/capabilities/artifacts.js +1 -1
- package/dist/capabilities/effect.js +293 -0
- package/dist/capabilities/fact-log.js +41 -0
- package/dist/capabilities/flyai.js +20 -6
- package/dist/capabilities/hbcli.js +43 -1
- package/dist/capabilities/incident-log.js +1 -1
- package/dist/capabilities/model-override.js +18 -0
- package/dist/capabilities/opensky.js +1 -1
- package/dist/capabilities/resilience.js +90 -0
- package/dist/capabilities/session/action-cache.js +1 -1
- package/dist/capabilities/session/adapters/ctrip-flight.js +1 -1
- package/dist/capabilities/session/adapters/meituan-local.js +1 -1
- package/dist/capabilities/session/benchmark.js +2 -1
- package/dist/capabilities/session/extension-bridge.js +358 -0
- package/dist/capabilities/session/extension-channel.js +93 -0
- package/dist/capabilities/session/extension-distribution.js +234 -0
- package/dist/capabilities/session/extract.js +1 -1
- package/dist/capabilities/session/golden-score.js +92 -0
- package/dist/capabilities/session/health-watch.js +216 -0
- package/dist/capabilities/session/read-guard.js +1 -1
- package/dist/capabilities/session/static-flight-golden.js +137 -0
- package/dist/capabilities/session/transport.js +1 -1
- package/dist/capabilities/session/wizard.js +147 -0
- package/dist/capabilities/session-consent.js +1 -1
- package/dist/capabilities/session-login.js +83 -1
- package/dist/capabilities/session-search.js +111 -2
- package/dist/capabilities/weather.js +168 -46
- package/dist/data/session-golden-20.json +25 -0
- package/dist/data/sf-golden-manifest.json +102 -0
- package/dist/data/sf-static-routes.json +91 -0
- package/dist/scripts/action-cache-tests.js +1 -1
- package/dist/scripts/agent-planning-budget-e2e.js +227 -0
- package/dist/scripts/agent-planning-budget-tests.js +173 -0
- package/dist/scripts/agent-reach-deep-tests.js +1 -1
- package/dist/scripts/agent-reach-tests.js +1 -1
- package/dist/scripts/agent-reach-wrapper-tests.js +1 -1
- package/dist/scripts/anything-tests.js +1 -1
- package/dist/scripts/async-collect.js +1 -1
- package/dist/scripts/benchmark-environment-bridge-e2e.js +981 -0
- package/dist/scripts/benchmark-environment-bridge-tests.js +2544 -0
- package/dist/scripts/booking-copilot-availability-ledger-binding-tests.js +335 -0
- package/dist/scripts/booking-copilot-availability-policy-v2-tests.js +1355 -0
- package/dist/scripts/booking-copilot-bin-proof-tests.js +89 -0
- package/dist/scripts/booking-copilot-crossrepo-fixture-server.js +113 -0
- package/dist/scripts/booking-copilot-dsh-core-proof-tests.js +356 -0
- package/dist/scripts/booking-copilot-dsh-planner-proof-tests.js +557 -0
- package/dist/scripts/booking-copilot-dsh-plugin-proof-tests.js +140 -0
- package/dist/scripts/booking-copilot-event-sequence-concurrency-proof-tests.js +202 -0
- package/dist/scripts/booking-copilot-gap-code-contract-proof-tests.js +102 -0
- package/dist/scripts/booking-copilot-operation-ledger-concurrency-proof-tests.js +374 -0
- package/dist/scripts/booking-copilot-receipt-ledger-concurrency-proof-tests.js +447 -0
- package/dist/scripts/booking-copilot-runtime-proof-tests.js +205 -0
- package/dist/scripts/booking-copilot-server-proof-tests.js +317 -0
- package/dist/scripts/booking-copilot-startup-proof-tests.js +283 -0
- package/dist/scripts/booking-copilot-v2-runtime-proof-tests.js +3935 -0
- package/dist/scripts/booking-saga-tests.js +1 -1
- package/dist/scripts/booking-surface-contract-proof-tests.js +393 -0
- package/dist/scripts/booking-surface-v2-contract-proof-tests.js +1174 -0
- package/dist/scripts/bootstrap-tests.js +59 -3
- package/dist/scripts/build-changelog.js +279 -0
- package/dist/scripts/changelog-tests.js +165 -0
- package/dist/scripts/companion-tests.js +1 -1
- package/dist/scripts/diff-test.js +1 -1
- package/dist/scripts/dsh-runtime-closure-tests.js +225 -0
- package/dist/scripts/dsh-runtime-closure.js +150 -0
- package/dist/scripts/effect-tests.js +474 -0
- package/dist/scripts/engine-run.js +1 -1
- package/dist/scripts/engine-tests.js +1 -1
- package/dist/scripts/evaluation-cadence-tests.js +347 -0
- package/dist/scripts/evaluation-contract-tests.js +574 -0
- package/dist/scripts/extension-distribution-cli.js +35 -0
- package/dist/scripts/extension-distribution-tests.js +341 -0
- package/dist/scripts/extension-tests.js +573 -0
- package/dist/scripts/fact-gate-tests.js +318 -0
- package/dist/scripts/flyai-tests.js +1 -1
- package/dist/scripts/hbcli-e2e-tests.js +180 -0
- package/dist/scripts/hbcli-tests.js +1 -1
- package/dist/scripts/health-watch-cli.js +51 -0
- package/dist/scripts/i18n-tests.js +1 -1
- package/dist/scripts/incident-tests.js +1 -1
- package/dist/scripts/journey-tests.js +1 -1
- package/dist/scripts/ledger-tests.js +1 -1
- package/dist/scripts/ledger-workflow-crash.js +1 -1
- package/dist/scripts/memory-capture-tests.js +1 -1
- package/dist/scripts/memory-decay-tests.js +1 -1
- package/dist/scripts/memory-metrics.js +1 -1
- package/dist/scripts/memory-value-report.js +1 -1
- package/dist/scripts/model-override-e2e.js +176 -0
- package/dist/scripts/nightly-evidence-tests.js +67 -4
- package/dist/scripts/nightly-evidence.js +59 -3
- package/dist/scripts/nudge-digest.js +1 -1
- package/dist/scripts/onboarding-tests.js +186 -0
- package/dist/scripts/opensky-check.js +1 -1
- package/dist/scripts/opensky-tests.js +1 -1
- package/dist/scripts/pnpm-dsh-closure-proof.js +20 -0
- package/dist/scripts/price-drift-tests.js +441 -0
- package/dist/scripts/price-drift-watch.js +491 -0
- package/dist/scripts/probe-poi-tests.js +1 -1
- package/dist/scripts/product-metrics.js +1 -1
- package/dist/scripts/publish-preverify.js +40 -4
- package/dist/scripts/realtime-pricing-tests.js +1 -1
- package/dist/scripts/replay-async.js +1 -1
- package/dist/scripts/replay-real.js +1 -1
- package/dist/scripts/replay.js +1 -1
- package/dist/scripts/session-attach-diagnose.js +1 -1
- package/dist/scripts/session-attach-poc.js +1 -1
- package/dist/scripts/session-benchmark.js +1 -1
- package/dist/scripts/session-extract-tests.js +1 -1
- package/dist/scripts/session-login.js +1 -1
- package/dist/scripts/session-tests.js +70 -20
- package/dist/scripts/sf-live-benchmark.js +338 -0
- package/dist/scripts/sf-live-cli-tests.js +21 -0
- package/dist/scripts/sf-soft-score-tests.js +108 -0
- package/dist/scripts/sf-summary.js +93 -0
- package/dist/scripts/skeleton-check.js +1 -1
- package/dist/scripts/skeleton-integration-test.js +1 -1
- package/dist/scripts/skills-contract-tests.js +1 -1
- package/dist/scripts/smoke-session-gate-tests.js +29 -0
- package/dist/scripts/smoke.js +154 -33
- package/dist/scripts/state-cli-tests.js +1 -1
- package/dist/scripts/state-cli.js +1 -1
- package/dist/scripts/static-golden-tests.js +299 -0
- package/dist/scripts/time-eval-tests.js +1 -1
- package/dist/scripts/travel-timeline-tests.js +1 -1
- package/dist/scripts/unified-tests.js +1 -1
- package/dist/scripts/weather-tests.js +694 -44
- package/dist/scripts/z3-race-tests.js +1 -1
- package/dist/src/artifact-gate.js +310 -0
- package/dist/src/benchmark-agent-conformance.js +370 -0
- package/dist/src/benchmark-environment-bridge.js +384 -0
- package/dist/src/benchmark-headless-child-diagnostics.js +173 -0
- package/dist/src/benchmark-tool-isolation.js +124 -0
- package/dist/src/bookable-facts.js +349 -0
- package/dist/src/booking-saga.js +1 -1
- package/dist/src/booking-surface/availability-policy-v2.js +830 -0
- package/dist/src/booking-surface/canonical-schema.js +113 -0
- package/dist/src/booking-surface/contracts-v2.js +89 -0
- package/dist/src/booking-surface/contracts.js +46 -0
- package/dist/src/booking-surface/dsh-planner.js +453 -0
- package/dist/src/booking-surface/dsh-plugin.js +93 -0
- package/dist/src/booking-surface/error-codes.js +94 -0
- package/dist/src/booking-surface/index.js +15 -0
- package/dist/src/booking-surface/profile.js +68 -0
- package/dist/src/booking-surface/runtime-v2.js +1771 -0
- package/dist/src/booking-surface/runtime.js +351 -0
- package/dist/src/booking-surface/server-v2.js +334 -0
- package/dist/src/booking-surface/server.js +302 -0
- package/dist/src/booking-surface/startup.js +159 -0
- package/dist/src/booking-surface/validation-v2.js +319 -0
- package/dist/src/booking-surface/validation.js +809 -0
- package/dist/src/bridge.js +1 -1
- package/dist/src/companions.js +1 -1
- package/dist/src/contracts.js +1 -1
- package/dist/src/dsh-llm.js +1 -1
- package/dist/src/engine.js +1 -1
- package/dist/src/evaluation-cadence.js +234 -0
- package/dist/src/evaluation-contracts.js +906 -0
- package/dist/src/i18n.js +1 -1
- package/dist/src/index.js +234 -60
- package/dist/src/journey.js +1 -1
- package/dist/src/loop.js +1 -1
- package/dist/src/memory-capture.js +1 -1
- package/dist/src/memory-decay.js +1 -1
- package/dist/src/memory-utility.js +1 -1
- package/dist/src/mock-llm.js +1 -1
- package/dist/src/model.js +1 -1
- package/dist/src/realtime-pricing.js +14 -7
- package/dist/src/slot-spec.js +1 -1
- package/dist/src/state-ledger.js +2 -1
- package/dist/src/time-anchor.js +1 -1
- package/dist/src/tool-budget.js +136 -0
- package/dist/src/tool-packet.js +1 -1
- package/dist/src/travel-slots.js +1 -1
- package/dist/src/travel-timeline.js +1 -1
- package/dist/src/unified.js +1 -1
- package/dist/src/wish-pool.js +1 -1
- package/dist/src/z3-shared.js +1 -1
- package/extension/README.md +50 -0
- package/extension/background.js +160 -0
- package/extension/content-bridge.js +41 -0
- package/extension/content-main.js +62 -0
- package/extension/manifest.json +32 -0
- package/package.json +291 -12
- package/schemas/booking.surface.v1.schema.json +927 -0
- package/schemas/booking.surface.v2.schema.json +61 -0
- package/ts/capabilities/fact-log.ts +54 -0
- package/ts/capabilities/flyai.ts +16 -3
- package/ts/capabilities/hbcli.ts +46 -0
- package/ts/capabilities/session/benchmark.ts +4 -1
- package/ts/capabilities/session/extension-bridge.ts +377 -0
- package/ts/capabilities/session/extension-channel.ts +95 -0
- package/ts/capabilities/session/extension-distribution.ts +264 -0
- package/ts/capabilities/session/golden-score.ts +139 -0
- package/ts/capabilities/session/health-watch.ts +257 -0
- package/ts/capabilities/session/static-flight-golden.ts +209 -0
- package/ts/capabilities/session/wizard.ts +140 -0
- package/ts/capabilities/session-login.ts +63 -2
- package/ts/capabilities/session-search.ts +105 -3
- package/ts/capabilities/weather.ts +141 -52
- package/ts/package.json +3 -3
- package/ts/src/artifact-gate.ts +365 -0
- package/ts/src/benchmark-agent-conformance.ts +448 -0
- package/ts/src/benchmark-environment-bridge.ts +348 -0
- package/ts/src/benchmark-headless-child-diagnostics.ts +184 -0
- package/ts/src/benchmark-tool-isolation.ts +166 -0
- package/ts/src/bookable-facts.ts +557 -0
- package/ts/src/booking-surface/availability-policy-v2.ts +523 -0
- package/ts/src/booking-surface/canonical-schema.js +113 -0
- package/ts/src/booking-surface/contracts-v2.ts +118 -0
- package/ts/src/booking-surface/contracts.ts +380 -0
- package/ts/src/booking-surface/dsh-planner.ts +452 -0
- package/ts/src/booking-surface/dsh-plugin.js +93 -0
- package/ts/src/booking-surface/error-codes.ts +101 -0
- package/ts/src/booking-surface/index.ts +12 -0
- package/ts/src/booking-surface/profile.ts +42 -0
- package/ts/src/booking-surface/runtime-v2.ts +1466 -0
- package/ts/src/booking-surface/runtime.ts +483 -0
- package/ts/src/booking-surface/server-v2.ts +247 -0
- package/ts/src/booking-surface/server.ts +324 -0
- package/ts/src/booking-surface/startup.ts +196 -0
- package/ts/src/booking-surface/validation-v2.ts +205 -0
- package/ts/src/booking-surface/validation.ts +453 -0
- package/ts/src/index.ts +161 -14
- package/ts/src/state-ledger.ts +1 -0
- package/ts/src/tool-budget.ts +165 -0
package/README.md
CHANGED
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
| | |
|
|
13
13
|
|---|---|
|
|
14
14
|
| **Version** | `v0.0.1-rc.13+` (npm `latest`; [release notes](docs/release-notes.md)) |
|
|
15
|
-
| **Runtime** | DeepSeek Harness **0.1.2-alpha.
|
|
15
|
+
| **Runtime** | DeepSeek Harness **0.1.2-alpha.3** (root-pinned; [upstream](https://github.com/deepseek-ai/DeepSeek-Harness)) · Z3 WASM · Cordis |
|
|
16
16
|
| **License** | **MIT** ([LICENSE](LICENSE)) |
|
|
17
17
|
| **Docs** | English (this file) · [简体中文 README](README.zh-CN.md) · deep engineering docs are Chinese-first ([docs/architecture.md](docs/architecture.md)) |
|
|
18
18
|
|
|
@@ -23,16 +23,25 @@
|
|
|
23
23
|
```bash
|
|
24
24
|
npx @danceiny/gotry web
|
|
25
25
|
# First run creates .env: LLM_API_KEY=<DeepSeek key, or OpenAI-compatible key>
|
|
26
|
+
# Not using DeepSeek directly? Also set LLM_BASE_URL=<your endpoint, usually ending in /v1>
|
|
27
|
+
# Need a specific model (relays often do)? Set LLM_MODEL=<model name> — it drives the
|
|
28
|
+
# dsh chat face (web/headless) and overrides any model picked in the dsh web settings.
|
|
26
29
|
# → open http://127.0.0.1:3080 and chat: "I want three relaxing days in Dali"
|
|
27
30
|
```
|
|
28
31
|
|
|
32
|
+
> **Switching models / providers?** The price table (`ts/data/llm-price-table.json`, schema `gotry_llm_price_table_v2`) is the single source of truth for `gotry_m3_nightly_run_v1.cost_usd`. Adding a new model or switching relay = update this file via PR (ADR-11, peak-conservative upper bound only)
|
|
33
|
+
- . Unknown models **fail-closed** — no guessed prices. Drift monitor: `npx tsx ts/scripts/price-drift-watch.ts` (offline baseline diff;
|
|
34
|
+
- `--fetch` for live official pages). Never auto-applies changes.
|
|
35
|
+
|
|
29
36
|
| You want | Command |
|
|
30
37
|
|---|---|
|
|
31
38
|
| 🖥️ Conversational planner (recommended) | `npx @danceiny/gotry web` → chat UI on :3080 |
|
|
32
39
|
| 🤖 Scripted / one-shot answer | `npx @danceiny/gotry "Two recovery days from Shenzhen, budget 3000"` |
|
|
33
40
|
| 🛠️ Developer: run from source | see [source install](#%EF%B8%8F-developer-source-install) below |
|
|
34
41
|
|
|
35
|
-
- Requires Node 22+ and one LLM API key.
|
|
42
|
+
- Requires Node 22.15+ and one LLM API key. Any OpenAI-compatible endpoint (MiniMax / relays / self-hosted gateways) works too — add `LLM_BASE_URL` to `.env` (usually ends with `/v1`, e.g. `https://api.minimax.io/v1`) and requests follow it instead of the DeepSeek default. To pin the model,
|
|
43
|
+
- set `LLM_MODEL` (e.g. `MiniMax-M2`): it applies to both the dsh chat face and the repo scripts, and beats the model selection persisted in the dsh web UI;
|
|
44
|
+
- unset, the dsh built-in default (`deepseek-v4-flash`) or your web-UI choice is used. Zero-config startup — the dsh runtime is mounted automatically via a cordis patch.
|
|
36
45
|
|
|
37
46
|
---
|
|
38
47
|
|
|
@@ -66,9 +75,10 @@ That's it — the dsh chat UI on `:3080` with the GoTry persona mounted. First c
|
|
|
66
75
|
|
|
67
76
|
```bash
|
|
68
77
|
git clone https://github.com/Danceiny/gotry && cd gotry
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
78
|
+
npm ci && npm --prefix ts ci # ① install the pinned root/TS closure
|
|
79
|
+
node scripts/build-dist.mjs # ② build the source checkout's JS runtime
|
|
80
|
+
cp .env.example .env # ③ set LLM_API_KEY (+ LLM_BASE_URL if not on DeepSeek; + LLM_MODEL to pin the model)
|
|
81
|
+
./gotry web # ④ in-repo entry, same UX
|
|
72
82
|
```
|
|
73
83
|
|
|
74
84
|
| Entry | Command | When |
|
|
@@ -76,9 +86,11 @@ cp .env.example .env # ② set LLM_API_KEY
|
|
|
76
86
|
| dsh Web chat (recommended) | `./gotry web` | multi-turn planning with visualized reasoning → :3080 |
|
|
77
87
|
| headless one-shot | `./gotry "one full task"` | scripts / CI / targeted debugging → stdout |
|
|
78
88
|
|
|
89
|
+
The source entry and npm package both resolve one 216-package DSH `0.1.2-alpha.3` closure declared as exact direct dependencies. The manifest, package lock, and root pnpm importer must expose the same 216-name set; publish preverify rejects omissions, mixed versions, and ranges. Source checkout runs dsh from `ts/dsh-runtime/` in normal mode so `gotry-state/` continuity is preserved; benchmark opt-in and npm-package runs use the invocation directory for isolation. The old `ts/dsh-runtime/` vendor tree remains a non-benchmark legacy resolution fallback, not a promised runnable path or the recommended install path.
|
|
90
|
+
|
|
79
91
|
---
|
|
80
92
|
|
|
81
|
-
## 🧰
|
|
93
|
+
## 🧰 21 tools
|
|
82
94
|
|
|
83
95
|
| Group | Tool | What it does |
|
|
84
96
|
|---|---|---|
|
|
@@ -95,6 +107,7 @@ cp .env.example .env # ② set LLM_API_KEY
|
|
|
95
107
|
| | `gotry_wish_pool_add` / `gotry_wish_pool_list` | "next departure" wish pool + 0..1 conditional recall |
|
|
96
108
|
| | `gotry_companion_save` · `gotry_trip_log` | companion profile / travel timeline |
|
|
97
109
|
| **Artifacts** | `gotry_artifacts_list` / `gotry_artifacts_read` | Discover & view generated artifacts (async deliverables + working-dir markdown) as a line-numbered file view (read-only) |
|
|
110
|
+
| **Factuality gate** | `gotry_fact_gate` | Pre-delivery gate for itinerary artifacts: every bookable claim (flight no./time/airport/price/policy) must trace to an exact-date tool result (hit AND miss recorded); unverifiable ⇒ blocked — never present as a verified plan |
|
|
98
111
|
| **General external** | `gotry_web_search` · `gotry_video_subtitle` · `gotry_github_search` · `gotry_agent_reach` | web / subtitles / GitHub / all-channel external info (via Agent-Reach) |
|
|
99
112
|
|
|
100
113
|
---
|
|
@@ -108,7 +121,8 @@ The account session channel reads realtime hotel/flight data from **the user's o
|
|
|
108
121
|
3. **Physically read-only.** A ReadGuard aborts all write requests at the network layer (ordering/payment is unreachable in transport); the agent never touches credentials or captchas — on a captcha it stops and hands control back.
|
|
109
122
|
4. **Never hijacks your browser.** Retrieval/login always open their own dedicated tab; the login page is brought to front and stays with you; routine test runs never open browser windows.
|
|
110
123
|
|
|
111
|
-
> One-time prerequisite:
|
|
124
|
+
> One-time prerequisite: install the [GoTry Session Bridge](https://chromewebstore.google.com/detail/gotry-session-bridge/oeajpiccmonococjcegddlooeeohlbgd) Chrome extension from the Chrome Web Store (one click, auto-updates) — done in the browser, not by gotry. Review-free GitHub-channel fallback is optional; for that variant see [`docs/extension-webstore-submission.md`](docs/extension-webstore-submission.md). Zero Chrome system dialogs afterwards — the extension passively forwards the site's own search responses (read-only by construction;
|
|
125
|
+
- cookies are read by NAME only, values never leave the browser). Until installed, tools return `needs-extension` with the store URL as a clickable link and spend nothing. (A `cdp` fallback via `chrome://inspect` remote debugging still exists for diagnostics: `GOTRY_SESSION_TRANSPORT=cdp` — note Chrome 144+ shows a permission box on every connection.)
|
|
112
126
|
|
|
113
127
|
---
|
|
114
128
|
|
|
@@ -141,7 +155,7 @@ Engine verdict:
|
|
|
141
155
|
```
|
|
142
156
|
┌──────────────────────────────────────────────────────────────┐
|
|
143
157
|
│ L1 chat-as-interface; gates are in-message choice cards │
|
|
144
|
-
│ L2 orchestration dsh runtime + GoTry plugin (ReAct);
|
|
158
|
+
│ L2 orchestration dsh runtime + GoTry plugin (ReAct); 21 tools│
|
|
145
159
|
│ L3 domain unified itinerary model + Z3 feasibility engine │
|
|
146
160
|
│ L4 data static packs + hotelbyte-cli bridge + OpenFlights │
|
|
147
161
|
│ L5 governance LoopX (objective / gates / evidence / quota) │
|
|
@@ -150,7 +164,7 @@ Engine verdict:
|
|
|
150
164
|
|
|
151
165
|
| Layer | Module | Role |
|
|
152
166
|
|---|---|---|
|
|
153
|
-
| L2 | `ts/src/index.ts` (dsh plugin) |
|
|
167
|
+
| L2 | `ts/src/index.ts` (dsh plugin) | 21 tools, time-anchor & memory-brief variables; execute isolation + consent gate + per-turn tool budget + process guards |
|
|
154
168
|
| L3 | `ts/src/unified.ts` · `py/gotry_feasibility/` | single solving entry (candidate enumeration + flight-chain Z3) |
|
|
155
169
|
| L4 | `ts/capabilities/effect.ts` · `hbcli.ts` · `skeleton-check.ts` | effect interpreter (backoff retry / circuit breaker / mock interpreter, issue #16) + realtime inventory bridge + OpenFlights skeleton (three-valued semantics) |
|
|
156
170
|
| L5 | loopx governance | objective / gates / evidence / quota |
|
|
@@ -161,23 +175,40 @@ Engine verdict:
|
|
|
161
175
|
|
|
162
176
|
## ⚠️ Status & limitations
|
|
163
177
|
|
|
178
|
+
Evaluation Phase 0 foundation boundary: contracts/registry/validators/unmatched diagnostic fixtures/test-only aggregate admission plus a deterministic PR/nightly/weekly/milestone cadence policy/planner. It returns admission, `pass^k`, budgets, calibration, failure-registry, and cross-benchmark synthesis obligations only; it does not schedule or launch adapters, spend, generate a benchmark score, create an Agent optimization round, or support an uplift claim. No external runner, Python runtime dependency, baseline, or matched production evidence is included.
|
|
179
|
+
|
|
164
180
|
**Working today** (full-stack regression §1–§34 green; every item has deterministic tests):
|
|
165
181
|
|
|
166
182
|
- **Z3 solving engine** — feasibility verdicts + door-to-door whole-cost; the historical concurrency race is fixed (§30 regression gate)
|
|
167
183
|
- **Realtime retrieval** — flight/train/hotel (Fliggy official channel), destination/hotel catalogs, weather, live flight observation, route connectivity; realtime prices can overwrite solver prices (`GOTRY_REALTIME_PRICING=1`)
|
|
168
184
|
- **Account session search** — Ctrip flights on your own logged-in Chrome; consent & privacy rules above (see 🔐 **Account session: consent & privacy**)
|
|
185
|
+
- **One-time browser extension setup** — install [GoTry Session Bridge](https://chromewebstore.google.com/detail/gotry-session-bridge/oeajpiccmonococjcegddlooeeohlbgd) from the Chrome Web Store (a browser concern, not a gotry one — one click on "Add to Chrome"). When `gotry_session_search` returns `needs-extension`, the verdict surfaces the store URL as a clickable link in the dsh UI; the background health-watch auto-replays your query once the extension is connected — no manual retry needed.
|
|
186
|
+
- **Extension distribution (issue #21, ADR-21)** — three channels, same extension: the [Chrome Web Store](https://chromewebstore.google.com/detail/gotry-session-bridge/oeajpiccmonococjcegddlooeeohlbgd) (recommended: one-click install + auto-update; live since 2026-09-02) is what dsh users should rely on; the review-free GitHub Releases channel is an opt-in escape hatch; the npm-bundled copy stays the offline-deterministic fallback;
|
|
187
|
+
- any GitHub-channel failure falls back to the bundled copy. The store re-signs with its own key, so the store build's extension ID differs from the fixed-key unpacked ID — the local bridge trusts both origins (§38 regression).
|
|
188
|
+
- **Session data cross-verification (issues #21 / #67)** — 8 benchmark queries (sf-01..sf-08) verified end-to-end: 7/8 verdict=hit, 6/6 manual-golden soft-score 100%, all hits <15s, zero ReadGuard writes. The comparator is pluggable: `--golden=manual` (default), `--golden=flyai`,
|
|
189
|
+
- or `--golden=static`. Static mode pins an ODbL OpenFlights route/carrier snapshot and combines it with manual time/price bands;
|
|
190
|
+
- evidence records requested vs effective source, provenance, estimated fields, and fallback reason. Snapshot/route failure prints a warning to stderr and falls back to manual. Static mode is deterministic benchmark data, **not live schedule, fare, or availability**.
|
|
191
|
+
- **Observed static-source runs (2026-08-30, logged-in Chrome)** — two consecutive runs produced static official 8/8 with zero fallback each time;
|
|
192
|
+
- Ctrip session hits varied from 3/8 to 5/8, while every scored hit across both runs (3+5 records) passed 13/13 (100%). Non-hits remain explicit `miss` records,
|
|
193
|
+
- so the ≥90% field score is not presented as 8/8 live availability. The same runs exposed and fixed an online-extension lifecycle bug: idle parked timers/sockets no longer pin the default CLI bridge, while wizardless `keepBridge` behavior remains unchanged (§38: 24/24, §40: 9/9).
|
|
169
194
|
- **Memory & reachability** — motivation profile / wish pool / companions / travel timeline; English output via `GOTRY_LOCALE=en`
|
|
195
|
+
- **Bounded agent tool loops** — a soft convergence context is injected after real dispatch 16; dispatch 18 is the last tool body, already-prepared calls 19+ receive structured `TOOL_BUDGET_EXHAUSTED` failures without entering the body, and inherited native tool schemas are suppressed at `step/end` for a text-only next step. The boundary is exercised through the packaged `dist` entry and a real dsh headless loop against an offline relay; CI packs the current SHA and repeats the E2E from an isolated pnpm consumer install rather than the root development tree. Direct/programmatic calls are outside this per-turn budget.
|
|
170
196
|
|
|
171
197
|
**Open limitations** (as of 2026-08-29, honest list):
|
|
172
198
|
|
|
173
199
|
- ⏳ **M3 Exit not closed** — engineering & distribution ready, but real seed-user evidence (50–200 person cohort) not yet accumulated; automated tests prove contracts and formulas, not business pass
|
|
174
200
|
- ⏳ **Ctrip-hotel / Meituan logged-in adapters** — flights done; hotel session surfaces await real login-state backfill (next tick)
|
|
175
201
|
- ⏳ **Interface language** — English currently covers the deterministic solve-output layer only; the dsh host UI and dialogue surface belong to the host / calibration samples
|
|
202
|
+
- ⏳ **External benchmark generalization / Phase 1 bridge** — Round 1's exact DeepSeek treatment was environment-unavailable/schema-invalid (score 0), while GLM timed out at 300 s. Round 2 added the default-off owner-local bridge; its frozen treatment remained diagnostic-only because no structured native bridge call or tagged JSON reached the evaluator. Round 3 added provider-neutral native-call/result/terminal conformance, but its new frozen treatment still stopped after one runner spawn with planner/runner exit 1, zero released terminal bytes, no evaluator entry, and null official scores. Round 4's treatment at SHA `5ebddb2` had primary preflight pass, but planner/runner both exited 1 after 30.968 s, released 0 bytes, the evaluator was not entered, and official scores were null. The product Node gate was v24.20.0 while that treatment used v26.3.0, so the result remains diagnostic-only with no uplift claim. GitHub Node 22/24 §48 separately exposed a source default-off 30 s lifecycle hang. Round 5 is limited to removing the timer/keepalive preload, pinning the root/package DSH closure to alpha.3, making source checkout resolve that locked runtime before the legacy vendored fallback, preserving source normal-mode state under `ts/dsh-runtime/gotry-state/` while benchmark/package runs use the invocation directory for isolation, rejecting a non-alpha.3 benchmark runtime before spawn, enforcing Node 22.15+, and adding a benchmark-only structured diagnostic pipe with allowlisted redacted reason codes while stdout remains fail-closed. Its frozen treatment at code SHA `752e54c` stopped after 140.715 s with `child_nonzero_exit`, zero terminal bytes, and null evaluator/official scores, so it remains diagnostic-only; the lock-consistency successor does not rewrite that UID attribution. Cross-benchmark evidence remains open. See [`docs/benchmark-environment-bridge.md`](docs/benchmark-environment-bridge.md).
|
|
203
|
+
- ⏳ **Round 6 structured terminal diagnostics** — benchmark mode maps only the final structured `turn/end` into closed, redacted model/runtime reason families. A per-session arbiter emits at most once and preserves a specific bridge/conformance reason over a later generic runtime reason; recovered transient retries emit no failure. Free-form messages, raw stderr, paths, prompts, request IDs, and credentials never cross the control pipe. The frozen ChinaTravel treatment at code SHA `c61600b` (`..._00001`, `deepseek-v4-flash`) stopped after 49.546 s with `child_runtime_error`, zero terminal bytes, and null evaluator/official scores; leakage and local credential/endpoint scans were zero. This is diagnostic evidence only and creates no score/uplift claim; later documentation-only successors do not rewrite the treatment attribution.
|
|
204
|
+
- ⏳ **Round 7 minimal benchmark kernel** — at code SHA `edb9392896625adbb48abae4a2ecf968dbfc0349`, benchmark opt-in retains only tool budget, model override, one bridge, and isolation/conformance; product prompt variables, process guards, consent hooks, and ordinary GoTry tools are not installed, while the default path is unchanged. The CLI projects a stable task-agnostic persona and accepts only canonical `insert` and `system-prompt` root items, failing closed on missing, duplicate, quoted, reordered, flow, or noncanonical items. ChinaTravel frozen treatment UID `e20241028160248698752` (`easy`, `deepseek-v4-flash`) passed preflight without fallback, then ended after 80.463 s with runner exit 1 and zero/invalid terminal bytes; the evaluator was not entered, official score is null, and the case is not countable. The allowlisted attribution is `child_bridge_runner_failed`; no uplift or external benchmark closure is claimed. The next problem is a generic bridge-tool schema and recoverable domain-error contract.
|
|
176
205
|
|
|
177
206
|
<details>
|
|
178
207
|
<summary>📖 Deeper engineering state (ledger contracts / evidence contracts / milestone stance)</summary>
|
|
179
208
|
|
|
180
|
-
The authoritative state lives in the docs, not this README: transactional state ledger (ADR-15) + dual-form freeze (ADR-16: one ledger semantics for local+web); the M3 real-cohort evidence contract stands (fixtures don't count toward Exit; 50–200 real samples open the gate);
|
|
209
|
+
The authoritative state lives in the docs, not this README: transactional state ledger (ADR-15) + dual-form freeze (ADR-16: one ledger semantics for local+web); the M3 real-cohort evidence contract stands (fixtures don't count toward Exit; 50–200 real samples open the gate);
|
|
210
|
+
- the M4 paired-cohort value evidence contract (run-all §34 — synthetic data is never Exit evidence);
|
|
211
|
+
- async work-order terminal contract (`gotry_async_terminal.v1`: 4/4 → succeeded / ledger settled / exit 0). Details: [`docs/roadmap.md`](docs/roadmap.md) / [`docs/architecture.md`](docs/architecture.md) §1 and issues #19–#22.
|
|
181
212
|
|
|
182
213
|
</details>
|
|
183
214
|
|
|
@@ -187,9 +218,16 @@ The authoritative state lives in the docs, not this README: transactional state
|
|
|
187
218
|
|
|
188
219
|
```bash
|
|
189
220
|
./scripts/run-all-tests.sh
|
|
221
|
+
# Evaluation Phase 0 diagnostic contracts and deterministic cadence planner
|
|
222
|
+
# (offline; no adapter/scheduler/runner/spend/score/Python)
|
|
223
|
+
cd ts
|
|
224
|
+
npx tsx scripts/evaluation-contract-tests.ts
|
|
225
|
+
npx tsx scripts/evaluation-cadence-tests.ts
|
|
190
226
|
```
|
|
191
227
|
|
|
192
|
-
One-shot full-stack green (pure TS, no Python needed): golden engines · dialogue replay · cross-process async work-orders · plugin smoke · hbcli · process guards · weather · flights · Anything · probePoi · agent-reach · dual-path stability · time-awareness eval · memory domain · **Z3 race (§30)
|
|
228
|
+
One-shot full-stack green (pure TS, no Python needed): golden engines · dialogue replay · cross-process async work-orders · plugin smoke · hbcli · process guards · weather · flights · Anything · probePoi · agent-reach · dual-path stability · time-awareness eval · memory domain · **Z3 race (§30)
|
|
229
|
+
- · realtime pricing (§31) · i18n catalog (§32) · M3 cohort evidence contract (§33) · M4 value evidence contract (§34) · M3 nightly evidence producer contract (§35) · session transport extension bridge (§38) · extension onboarding pre-check (§40) · bookable-fact gate (§39)
|
|
230
|
+
- · extension distribution channel (§43) · sf-live static-golden offline contracts (§44) · evaluation foundation and cadence policy (§45–§46) · agent tool-budget Cordis integration + dsh headless E2E (§47)**. The live runner remains `cd ts && npx tsx scripts/sf-live-benchmark.ts --golden=static` and requires the user's connected Chrome session.
|
|
193
231
|
|
|
194
232
|
---
|
|
195
233
|
|
|
@@ -207,6 +245,6 @@ Standard open-source flow: branch off latest `main` (`feat/ · fix/ · docs/ ·
|
|
|
207
245
|
|
|
208
246
|
---
|
|
209
247
|
|
|
210
|
-
**Built with**: DeepSeek Harness 0.1.2-alpha.
|
|
248
|
+
**Built with**: DeepSeek Harness 0.1.2-alpha.3 (root-pinned) · Cordis · Z3 (WASM) · loopx (pipx) · hotelbyte-cli · Agent-Reach v1.5.0 (`.venv/`) · OpenFlights · TypeScript
|
|
211
249
|
|
|
212
|
-
**
|
|
250
|
+
**Version baseline: `v0.0.1-rc.16` (2026-08-30).** The current checkout's authoritative verification gates are enumerated by `scripts/run-all-tests.sh` (release flow: `scripts/publish-npm.sh`).
|
package/README.zh-CN.md
CHANGED
|
@@ -18,16 +18,21 @@
|
|
|
18
18
|
```bash
|
|
19
19
|
npx @danceiny/gotry web
|
|
20
20
|
# 首跑会提示建 .env:LLM_API_KEY=<DeepSeek key 或 OpenAI 兼容 key>
|
|
21
|
+
# 不走 DeepSeek 官方?再配一行 LLM_BASE_URL=<你的端点,一般以 /v1 结尾>
|
|
22
|
+
# 要指定模型(中转而常需要)?配 LLM_MODEL=<模型名>——同时驱动 dsh 会话面
|
|
23
|
+
# (web/headless)与仓内脚本,并压过你在 dsh web 设置里选过的模型。
|
|
21
24
|
# → 浏览器打开 http://127.0.0.1:3080,像聊天一样说「我想去大理三天」
|
|
22
25
|
```
|
|
23
26
|
|
|
27
|
+
> **换模型 / 换中转?** 价表(`ts/data/llm-price-table.json`,schema `gotry_llm_price_table_v2`)是 `gotry_m3_nightly_run_v1.cost_usd` 唯一事实源(ADR-11)。新增模型或换中转=改本文件走 PR(peak 保守上界只高不低),未知模型 → **fail-closed 不猜价**。漂移监测:`npx tsx ts/scripts/price-drift-watch.ts`(默认离线对照 baseline 比对输出 PR-就绪 Markdown diff;`--fetch` 拉取官方页 + 首次写 fixture)。**永不自动 apply 价格**。
|
|
28
|
+
|
|
24
29
|
| 你想要的 | 命令 |
|
|
25
30
|
|---|---|
|
|
26
31
|
| 🖥️ 对话规划(推荐) | `npx @danceiny/gotry web` → :3080 对话界面 |
|
|
27
32
|
| 🤖 脚本/一次性问答 | `npx @danceiny/gotry "我想从深圳休整两天,预算 3000"` |
|
|
28
33
|
| 🛠️ 开发者:仓内运行 | 见下方[源码安装](#-快速开始) |
|
|
29
34
|
|
|
30
|
-
- 前置:Node 22+;一个 LLM API key
|
|
35
|
+
- 前置:Node 22.15+;一个 LLM API key。任何 OpenAI 兼容端点(MiniMax/中转/自建网关)也可——在 `.env` 另配 `LLM_BASE_URL`(一般以 `/v1` 结尾,如 `https://api.minimax.io/v1`),请求即走它而非 DeepSeek 默认端点。要锁定模型就配 `LLM_MODEL`(如 `MiniMax-M2`):对 dsh 会话面与仓内脚本同时生效,并压过 dsh web 设置里持久化的模型选择;不配则用 dsh 内置默认(`deepseek-v4-flash`)或你在 web 界面的选择。零成本启动——dsh 运行时以 cordis patch 自动挂载,无额外配置。
|
|
31
36
|
- 例外提示:`:3080` 端口被占时先 `kill <PID>`;首启 6–15 秒属正常冷启动;异常退出会留证据到 `gotry-state/incidents.jsonl`(不静默)。
|
|
32
37
|
|
|
33
38
|
<details>
|
|
@@ -35,9 +40,10 @@ npx @danceiny/gotry web
|
|
|
35
40
|
|
|
36
41
|
```bash
|
|
37
42
|
git clone https://github.com/Danceiny/gotry && cd gotry
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
43
|
+
npm ci && npm --prefix ts ci # ① 安装 root/TS 锁定依赖闭包
|
|
44
|
+
node scripts/build-dist.mjs # ② 构建源码检出的 JS runtime
|
|
45
|
+
cp .env.example .env # ③ 填 LLM_API_KEY(非 DeepSeek 官方另配 LLM_BASE_URL;锁定模型另配 LLM_MODEL)
|
|
46
|
+
./gotry web # ④ 仓内入口,同 npm 形态
|
|
41
47
|
```
|
|
42
48
|
|
|
43
49
|
| 入口 | 命令 | 什么时候用 |
|
|
@@ -46,7 +52,7 @@ cp .env.example .env # ② 填 LLM_API_KEY
|
|
|
46
52
|
| headless 一问一答 | `./gotry "一句任务"` | 脚本 / CI / 定向调试 → stdout |
|
|
47
53
|
| help | `./gotry help` | 三行帮助 |
|
|
48
54
|
|
|
49
|
-
|
|
55
|
+
为什么源码模式先装 root/TS 闭包并构建 dist:源码入口与 npm 包都解析同一组 216 个精确直接依赖的 DSH `0.1.2-alpha.3` closure;manifest、package-lock 与 root pnpm importer 必须暴露同一 216 项名称集合,publish preverify 会拒绝漏钉、混版和 range;源码普通运行的 dsh cwd 仍是 `ts/dsh-runtime/`,因此状态继续落 `ts/dsh-runtime/gotry-state/`;benchmark opt-in 与 npm 包运行使用调用目录隔离。`ts/dsh-runtime/` 的旧 vendored runtime 只保留为非 benchmark legacy 解析兼容,不承诺可运行,也不再是推荐安装路径。
|
|
50
56
|
|
|
51
57
|
</details>
|
|
52
58
|
|
|
@@ -98,7 +104,7 @@ GoTry: 收到。先把约束记下来——
|
|
|
98
104
|
|
|
99
105
|
---
|
|
100
106
|
|
|
101
|
-
## 🧰
|
|
107
|
+
## 🧰 21 个工具 — Tools
|
|
102
108
|
|
|
103
109
|
| 组 | 工具 | 干什么 |
|
|
104
110
|
|---|---|---|
|
|
@@ -115,6 +121,7 @@ GoTry: 收到。先把约束记下来——
|
|
|
115
121
|
| | `gotry_wish_pool_add` / `gotry_wish_pool_list` | 「下一次出发」愿望池 + 0..1 条件召回 |
|
|
116
122
|
| | `gotry_companion_save` · `gotry_trip_log` | 同行人档案 / 旅行时间线 |
|
|
117
123
|
| **产物** | `gotry_artifacts_list` / `gotry_artifacts_read` | 发现与查看已生成的产物(异步交付 + 工作目录 markdown),行号文件视图,只读 |
|
|
124
|
+
| **事实闸** | `gotry_fact_gate` | 行程产物交付前闸:每条可下单 claim(航班号/时刻/机场/价格/政策)必须回溯到 exact-date 工具结果(hit/miss 均落账);无法回溯 ⇒ blocked——不得宣称「已验证方案」 |
|
|
118
125
|
| **通用外部** | `gotry_web_search` · `gotry_video_subtitle` · `gotry_github_search` · `gotry_agent_reach` | 网页/字幕/GitHub/全渠道外部信息(经 Agent-Reach) |
|
|
119
126
|
|
|
120
127
|
---
|
|
@@ -128,7 +135,7 @@ GoTry: 收到。先把约束记下来——
|
|
|
128
135
|
3. **物理只读** —— ReadGuard 在网络层中止一切写请求(下单/支付在传输层不可达),agent 永不接触凭证与验证码;遇到验证码立即停,交还给你。
|
|
129
136
|
4. **绝不劫持你的浏览器** —— 检索/登录只开自己的独立标签页,登录页置前台、留在你那;例行动测试永不自动开浏览器窗。
|
|
130
137
|
|
|
131
|
-
> 前置(一次性)
|
|
138
|
+
> 前置(一次性):去 [Chrome 应用商店](https://chromewebstore.google.com/detail/gotry-session-bridge/oeajpiccmonococjcegddlooeeohlbgd) 点「添加至 Chrome」——这是浏览器的事,不由 gotry 兜(`gotry setup wizard` 不复存在);想用免审核/更新更快的 GitHub 通道见 [docs/extension-webstore-submission.md](docs/extension-webstore-submission.md)。装完**零系统弹窗**——扩展只被动转发站点自己发出的检索响应(构造上只读;cookie 只读名字,值永不离开浏览器)。未安装时工具返回 `needs-extension` 并把商店 URL 作为 dsh UI 的可点链接给出,不消耗执行配额。(诊断后备:cdp 车道经 `chrome://inspect` 远程调试,`GOTRY_SESSION_TRANSPORT=cdp` 显式开启——注意 Chrome 144+ 每次连接都会弹权限框。)
|
|
132
139
|
|
|
133
140
|
---
|
|
134
141
|
|
|
@@ -137,7 +144,7 @@ GoTry: 收到。先把约束记下来——
|
|
|
137
144
|
```
|
|
138
145
|
┌──────────────────────────────────────────────────────────────┐
|
|
139
146
|
│ L1 对话即界面 chat-as-UI; gates 是消息内选择题 │
|
|
140
|
-
│ L2 编排 dsh 运行时 + GoTry 插件(ReAct);
|
|
147
|
+
│ L2 编排 dsh 运行时 + GoTry 插件(ReAct);21 个工具 │
|
|
141
148
|
│ L3 领域 统一行程模型 + Z3 可行性引擎(枚举/Z3 双形态) │
|
|
142
149
|
│ L4 数据 静态数据包 + hotelbyte-cli 实时桥 + OpenFlights 骨架 │
|
|
143
150
|
│ L5 治理 LoopX(objective / gates / evidence / quota) │
|
|
@@ -146,7 +153,7 @@ GoTry: 收到。先把约束记下来——
|
|
|
146
153
|
|
|
147
154
|
| 层 | 模块 | 角色 |
|
|
148
155
|
|---|---|---|
|
|
149
|
-
| L2 | `ts/src/index.ts`(dsh 插件) | 注册
|
|
156
|
+
| L2 | `ts/src/index.ts`(dsh 插件) | 注册 21 工具,挂时间锚点/记忆 brief 变量;execute 异常隔离 + 授权闸 + 进程护栏 |
|
|
150
157
|
| L3 | `ts/src/unified.ts` · `py/gotry_feasibility/` | 唯一求解入口(候选枚举 + 航班链 Z3) |
|
|
151
158
|
| L4 | `ts/capabilities/effect.ts` · `hbcli.ts` · `skeleton-check.ts` | 效应解译层(退避重试/断路器/mock 解译器,issue #16)+ 实时库存桥 + OpenFlights 骨架(三值语义) |
|
|
152
159
|
| L5 | loopx 治理面 | objective / gates / evidence / quota |
|
|
@@ -162,6 +169,10 @@ GoTry: 收到。先把约束记下来——
|
|
|
162
169
|
- **Z3 求解引擎** —— 可行性判定 + 门到门全成本;历史并发竞态已根治(§30 并发回归闸)
|
|
163
170
|
- **实时检索**:机票/火车/酒店(飞猪官方通道)、目的地/酒店目录、天气、航班观测、通航性校验;可选让实时票价覆写进求解(`GOTRY_REALTIME_PRICING=1`)
|
|
164
171
|
- **账号会话检索**:你本人登录态查携程机票,授权与隐私规则见上方 **🔐 账号会话:授权与隐私** 小节
|
|
172
|
+
- **一次性浏览器扩展安装**:去 [Chrome 应用商店](https://chromewebstore.google.com/detail/gotry-session-bridge/oeajpiccmonococjcegddlooeeohlbgd) 点「添加至 Chrome」(浏览器的事,gotry 不介入);扩展未装时 `gotry_session_search` 返回的 `needs-extension` 由 dsh UI 把商店 URL 渲成可点链接;后台 health-watch 探活,扩展一就位自动重放你的检索,**无需你手动重跑命令**
|
|
173
|
+
- **扩展分发三通道(issue #21,ADR-21)**:同一扩展三个通道——[Chrome 应用商店](https://chromewebstore.google.com/detail/gotry-session-bridge/oeajpiccmonococjcegddlooeeohlbgd)(dsh 用户就走这条:一键装 + 自动更新,2026-09-02 上架);GitHub Releases 通道(免审核、版本更新更快,见 docs/extension-webstore-submission.md);包内副本保离线兜底。商店用自己签名 key 重签,商店版扩展 ID 与 unpacked 固定 ID 不同,本机桥双 Origin 白名单同信(§38 回归)。
|
|
174
|
+
- **会话数据交叉验证(issue #21 / #67)**:8 条 sf-01..sf-08 benchmark query 端到端验证 —— 7/8 verdict=hit / 6/6 manual-golden 软命中 100% / hit 全部 <15s / ReadGuard 零写。对照源可插拔:`--golden=manual`(默认)、`--golden=flyai`、`--golden=static`。static 模式以 OpenFlights ODbL 固定修订提供航线/承运人,叠加手工时刻与价格带;evidence 分开记录请求源/实际源、provenance、estimated fields 与 fallback reason。快照/路由异常会向 stderr 告警后回退 manual。static 是确定性 benchmark 数据,**不是实时班期、票价或库存**。
|
|
175
|
+
- **static 源登录态观测(2026-08-30)**:连续两轮 static official 均 8/8 hit、零 fallback;携程 session hit 从 3/8 波动到 5/8,两轮所有可评分 hit(3+5 条)全部 13/13(100%)。非 hit 均是显式 `miss`,因此 ≥90% 字段分不表述为 8/8 实时可售。同轮修复扩展在线时空闲 parked timer/socket 钉住默认 CLI 桥的生命周期缺口,wizardless `keepBridge` 语义不变(§38:24/24,§40:9/9)。
|
|
165
176
|
- **记忆与触达**:动机画像 / 愿望池 / 同行人 / 旅行时间线;英文输出一键切换(`GOTRY_LOCALE=en`)
|
|
166
177
|
|
|
167
178
|
**已知限制**(截至 2026-08-29,诚实清单):
|
|
@@ -169,6 +180,9 @@ GoTry: 收到。先把约束记下来——
|
|
|
169
180
|
- ⏳ **M3 Exit 未关闭** —— 工程与分发面就绪,但"真实种子用户"证据(50–200 人 cohort)尚未积累;自动化测试证明的是合同与公式,不是 business pass
|
|
170
181
|
- ⏳ **携程酒店 / 美团的登录态会话适配** —— 机票已通,酒店面等登录态实测回填(下一个 tick)
|
|
171
182
|
- ⏳ **界面语言** —— 英文界面仅覆盖求解确定性输出层;dsh 宿主界面与对话面属宿主/校准件
|
|
183
|
+
- ⏳ **外部 benchmark 泛化 / Phase 1 bridge** —— Round 1 的 exact DeepSeek treatment 为 environment unavailable/schema-invalid(score 0),GLM 为 300 秒超时。Round 2 建立 default-off owner-local bridge;其冻结 treatment 因没有 structured native bridge call 与 tagged JSON,只到 diagnostic-only。Round 3 增加 provider-neutral 的 native call/result/terminal conformance,但新冻结 treatment 仍在 runner 仅派发一次后以 planner/runner exit 1 停止,parent 释放 0 字节终态,evaluator 未进入,official scores 全为 null。Round 4 treatment(SHA `5ebddb2`)primary preflight=pass,但 planner/runner 均在 30.968s 以 exit 1 结束,释放 0 字节,evaluator 未进入,official scores 全为 null。产品 gate 使用 Node v24.20.0,而该 treatment 使用 v26.3.0,因此该结果仅 diagnostic-only,不产生 uplift。GitHub Node 22/24 §48 另暴露 source default-off 30s lifecycle hang。Round 5 仅限移除 timer/keepalive preload、将 root/package DSH closure 锁定为 alpha.3、让 source checkout 优先解析该锁定 runtime、保留源码普通运行的 `ts/dsh-runtime/gotry-state/` 状态连续性、让 benchmark/package 用调用目录隔离、在 spawn 前拒绝非 alpha.3 benchmark runtime、强制 Node 22.15+,并增加 benchmark-only 结构化诊断 pipe(allowlisted redacted reason codes),stdout 继续 fail-closed;其 frozen treatment(代码 SHA `752e54c`)在 140.715 秒后以 `child_nonzero_exit`、0 terminal bytes、evaluator/official scores null 停止,仅 diagnostic-only,后续纯 lock-consistency 提交不改写该 UID 归属。跨 benchmark 证据仍待运行,不声称 external benchmark closure。详见 [`docs/benchmark-environment-bridge.md`](docs/benchmark-environment-bridge.md)。
|
|
184
|
+
- ⏳ **Round 6 结构化终态诊断** —— benchmark 模式只把最终结构化 `turn/end` 投影为闭合、脱敏的模型/运行时原因族;per-session 仲裁最多写一次,且 bridge/conformance 专项原因优先于后续 generic runtime。恢复成功的 transient retry 不写失败;message、raw stderr、路径、prompt、request id 与凭证不跨控制通道。代码 SHA `c61600b` 的 ChinaTravel 冻结 treatment(`..._00001`,`deepseek-v4-flash`)在 49.546 秒后以 `child_runtime_error`、0 terminal bytes、evaluator/official scores null 停止;leakage 与本地凭证/端点扫描均为 0。该证据只改善归因,不产生 score/uplift 结论;后续纯文档 successor 不改写 treatment 归属。
|
|
185
|
+
- ⏳ **Round 7 minimal kernel** —— 代码 SHA `edb9392896625adbb48abae4a2ecf968dbfc0349` 的 benchmark opt-in 仅保留 tool budget、model override、唯一 bridge、isolation/conformance;不装产品 prompt variables、process guards、consent hooks 与普通 GoTry tools,默认路径不变。CLI 将系统人格投影为稳定、task-agnostic persona,root patch 只接受 canonical `insert` 与 `system-prompt` 各一,缺失、重复、quoted、reordered、flow 或其他非 canonical root item 均 fail-closed。ChinaTravel 冻结 treatment UID `e20241028160248698752`(`easy`,`deepseek-v4-flash`)preflight pass 且未回退,80.463 秒后 runner exit 1、terminal 0 bytes/invalid,evaluator 未进入、official null、不可计分;白名单归因为 `child_bridge_runner_failed`,不产生 uplift 或 external benchmark closure。下一轮聚焦 generic bridge tool schema 与可恢复 domain-error contract。
|
|
172
186
|
|
|
173
187
|
<details>
|
|
174
188
|
<summary>📖 更深的工程状态(账本合同 / 证据合同 / 里程碑口径)</summary>
|
|
@@ -200,7 +214,7 @@ GoTry: 收到。先把约束记下来——
|
|
|
200
214
|
./scripts/run-all-tests.sh
|
|
201
215
|
```
|
|
202
216
|
|
|
203
|
-
全栈一次性绿(纯 TS,无 Python 依赖):engine/journey/unified 金标准 · 对话重放 · 异步工单跨进程 · 插件 smoke · hbcli · 进程护栏(含工具异常隔离)· 天气 · 航班 · Anything · probePoi · agent-reach(web/deep/wrapper)· 双路径稳定性 · 时间感评测(锚点卡/槽位过期校验/评分器/mock 回放;真模型巡检 `time-eval-tests.ts --real`)· 记忆域(动机合并守门/效用 sidecar/只读指标投影)· **Z3 并发竞态(§30)· 实时票价桥(§31)· i18n 目录(§32)· M3 cohort 证据合同(§33)· M4 价值证据合同(§34)
|
|
217
|
+
全栈一次性绿(纯 TS,无 Python 依赖):engine/journey/unified 金标准 · 对话重放 · 异步工单跨进程 · 插件 smoke · hbcli · 进程护栏(含工具异常隔离)· 天气 · 航班 · Anything · probePoi · agent-reach(web/deep/wrapper)· 双路径稳定性 · 时间感评测(锚点卡/槽位过期校验/评分器/mock 回放;真模型巡检 `time-eval-tests.ts --real`)· 记忆域(动机合并守门/效用 sidecar/只读指标投影)· **Z3 并发竞态(§30)· 实时票价桥(§31)· i18n 目录(§32)· M3 cohort 证据合同(§33)· M4 价值证据合同(§34)· 会话传输扩展桥(§38)· 扩展 onboarding 静态预检(§40)· 可下单事实闸(§39)· 扩展分发通道(§43)· sf-live static-golden 离线合同(§44)**。真实 runner 为 `cd ts && npx tsx scripts/sf-live-benchmark.ts --golden=static`,仍需用户 Chrome 会话扩展在线。
|
|
204
218
|
|
|
205
219
|
---
|
|
206
220
|
|
|
@@ -230,6 +244,6 @@ GoTry: 收到。先把约束记下来——
|
|
|
230
244
|
|
|
231
245
|
---
|
|
232
246
|
|
|
233
|
-
**Built with**: DeepSeek Harness 0.1.2-alpha.
|
|
247
|
+
**Built with**: DeepSeek Harness 0.1.2-alpha.3 (root-pinned) · Cordis · Z3 (WASM) · loopx (pipx) · hotelbyte-cli · Agent-Reach v1.5.0 (`.venv/`) · OpenFlights · TypeScript
|
|
234
248
|
|
|
235
|
-
|
|
249
|
+
**版本基线:`v0.0.1-rc.16`(2026-08-30)。** 当前 checkout 的权威验证闸以 `scripts/run-all-tests.sh` 实际分节为准(发布流程见 `scripts/publish-npm.sh`)。
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
/** Standalone, BFF-only Booking Copilot HTTP/SSE service. */
|
|
3
|
+
|
|
4
|
+
import { existsSync, readFileSync } from 'node:fs'
|
|
5
|
+
import { dirname, join } from 'node:path'
|
|
6
|
+
import { fileURLToPath, pathToFileURL } from 'node:url'
|
|
7
|
+
|
|
8
|
+
const here = dirname(fileURLToPath(import.meta.url))
|
|
9
|
+
const root = join(here, '..')
|
|
10
|
+
const startupPath = join(root, 'dist/src/booking-surface/startup.js')
|
|
11
|
+
|
|
12
|
+
function safeError(error) {
|
|
13
|
+
let message = error instanceof Error ? error.message : String(error)
|
|
14
|
+
for (const secret of [
|
|
15
|
+
process.env.GOTRY_BOOKING_COPILOT_API_KEY,
|
|
16
|
+
process.env.DEEPSEEK_API_KEY,
|
|
17
|
+
process.env.LLM_API_KEY,
|
|
18
|
+
]) {
|
|
19
|
+
if (secret) message = message.replaceAll(secret, '[REDACTED]')
|
|
20
|
+
}
|
|
21
|
+
return message.slice(0, 512)
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
async function main() {
|
|
25
|
+
if (!existsSync(startupPath)) throw new Error('booking_copilot_compiled_runtime_missing')
|
|
26
|
+
const artifactPath = join(root, 'ARTIFACT_ID')
|
|
27
|
+
if (existsSync(artifactPath)) {
|
|
28
|
+
const artifactId = readFileSync(artifactPath, 'utf8').trim()
|
|
29
|
+
if (!/^[0-9a-f]{40}$/.test(artifactId)) throw new Error('booking_copilot_artifact_id_invalid')
|
|
30
|
+
process.env.GOTRY_BOOKING_COPILOT_ARTIFACT_ID = artifactId
|
|
31
|
+
}
|
|
32
|
+
const startup = await import(pathToFileURL(startupPath).href)
|
|
33
|
+
const config = startup.resolveBookingCopilotStartupConfig(process.env)
|
|
34
|
+
const handle = await startup.startBookingCopilotFromEnvironment(process.env)
|
|
35
|
+
process.stderr.write(`[gotry-booking-copilot] listening on http://${config.host}:${handle.port}/a2a/booking-copilot/turn\n`)
|
|
36
|
+
|
|
37
|
+
let stopping = false
|
|
38
|
+
const stop = () => {
|
|
39
|
+
if (stopping) return
|
|
40
|
+
stopping = true
|
|
41
|
+
void handle.close().then(() => process.exit(0), (error) => {
|
|
42
|
+
process.stderr.write(`[gotry-booking-copilot] shutdown failed: ${safeError(error)}\n`)
|
|
43
|
+
process.exit(1)
|
|
44
|
+
})
|
|
45
|
+
}
|
|
46
|
+
process.once('SIGINT', stop)
|
|
47
|
+
process.once('SIGTERM', stop)
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
main().catch((error) => {
|
|
51
|
+
process.stderr.write(`[gotry-booking-copilot] startup failed: ${safeError(error)}\n`)
|
|
52
|
+
process.exitCode = 1
|
|
53
|
+
})
|