Merge origin/master into feat/website-docs

Conflict resolution notes:
- package.json/run-gates: both sides' new doc-sync gates kept (master's
  scoped-events/readme gates + this branch's website-api/website-yaml);
  js-yaml devDeps deduped (master added them independently).
- pnpm-workspace/knip: website AND python/sdk-runtime entries kept.
- doc-typecheck/verify-type-equiv: master's condensed headers kept, website
  glob retained in both scan scopes.
- vendor/cordis/src/fiber.ts: master's lifecycle-hardening code taken; this
  branch's richer FiberState JSDoc reapplied on top. vendor/README.md logs
  both local modifications (hardening = 6, JSDoc enrichment = 7).
- pnpm-lock: regenerated from master's side (pnpm install).

Post-merge sync the gates forced (the system working as designed):
- verify-website-yaml caught 4 stale plugin names from master's package
  reorg (dsh-stdio-agent -> dsh-stdio-demo, dsh-acp-agent -> dsh-acp-demo);
  8 references fixed across guide/ and develop/.
- gen-website-api picked up master's 6 new services automatically
  (ctx.approval/permission/sandbox/sessionQuery/skills/tasks -> 6 new pages
  + sidebar); api/index.md hub updated to list them.
- AGENTS.md budget ceiling 1370 -> 1400: the website rows (layout line + two
  command lines) and master's own growth collided with the old ceiling; all
  three website rows are load-bearing (new top-level dir, new CI command).
This commit is contained in:
lintianle
2026-07-16 21:36:43 +08:00
1132 changed files with 71533 additions and 19566 deletions
@@ -0,0 +1,49 @@
<!-- Generated by scripts/gen-website-api.ts — do not edit by hand. Run `pnpm run gen-website-api` to regenerate. -->
# ctx.sessionQuery
`SessionQueryService` — provided by `@deepseek-ai/dsh-session-query`.
Live-preferred logical-corpus and exact-event read service.
[Source](https://github.com/deepseek-harness/deepseek-harness/blob/master/packages/session-query/session-query/src/index.ts#L35)
### ctx.sessionQuery.listSessions()
```ts website-api
listSessions(): Promise<SessionRecord[]>
```
List the complete logical corpus using live-preferred records.
**Returns** deterministic newest-first cloned session records.
[Source](https://github.com/deepseek-harness/deepseek-harness/blob/master/packages/session-query/session-query/src/index.ts#L60)
### ctx.sessionQuery.listEvents(sessionId)
```ts website-api
async listEvents(sessionId: SessionId): Promise<SessionEventRecord[]>
```
List lightweight raw-log event records for one logical session.
- `sessionId` — live-preferred session id to read.
**Returns** event records in ascending seq order.
[Source](https://github.com/deepseek-harness/deepseek-harness/blob/master/packages/session-query/session-query/src/index.ts#L69)
### ctx.sessionQuery.readEvent(request)
```ts website-api
async readEvent(request: SessionEventReadRequest): Promise<SessionEventWindow>
```
Read one full event plus a bounded raw-log context window.
- `request` — target session/seq and context sizes.
**Returns** cloned target and neighboring events.
[Source](https://github.com/deepseek-harness/deepseek-harness/blob/master/packages/session-query/session-query/src/index.ts#L79)