Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 8 additions & 4 deletions content/.metadata.json
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@
},
"content/en/news/news1226.md": {
"url": "https://api-docs.deepseek.com/news/news1226",
"title": "🚀 Introducing DeepSeek-V3"
"error": "served fallback shell for https://api-docs.deepseek.com/news/news1226 (canonical: https://api-docs.deepseek.com/)"
},
"content/en/news/news250325.md": {
"url": "https://api-docs.deepseek.com/news/news250325",
Expand Down Expand Up @@ -155,7 +155,7 @@
},
"content/en/news/news251201.md": {
"url": "https://api-docs.deepseek.com/news/news251201",
"title": "DeepSeek-V3.2 Release"
"error": "served fallback shell for https://api-docs.deepseek.com/news/news251201 (canonical: https://api-docs.deepseek.com/)"
},
"content/en/news/news260424.md": {
"url": "https://api-docs.deepseek.com/news/news260424",
Expand Down Expand Up @@ -664,7 +664,7 @@
},
"content/en/dsh/docs/module-graph.md": {
"url": "https://github.com/deepseek-ai/deepseek-harness/blob/master/docs/module-graph.md",
"title": "Module dependency graph"
"title": "Shared-instance dependency graph"
},
"content/en/dsh/docs/persistence-catalog.md": {
"url": "https://github.com/deepseek-ai/deepseek-harness/blob/master/docs/persistence-catalog.md",
Expand Down Expand Up @@ -1061,8 +1061,12 @@
"content/en/dsh/docs/user/guide/schedule.md": {
"url": "https://github.com/deepseek-ai/deepseek-harness/blob/master/docs/user/guide/schedule.md",
"title": "Schedule session-local reminders"
},
"content/en/dsh/docs/cookbook/adding-a-remote-api.md": {
"url": "https://github.com/deepseek-ai/deepseek-harness/blob/master/docs/cookbook/adding-a-remote-api.md",
"title": "Cookbook: adding a Remote API"
}
},
"updated": "2026-08-29",
"updated": "2026-09-02",
"site": "https://api-docs.deepseek.com"
}
4 changes: 2 additions & 2 deletions content/en/dsh/docs/AGENTS.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
title: "AGENTS.md — The documentation standard"
source: https://github.com/deepseek-ai/deepseek-harness/blob/master/docs/AGENTS.md
fetched: 2026-08-27
fetched: 2026-09-02
---
# AGENTS.md — The documentation standard

Expand Down Expand Up @@ -59,7 +59,7 @@ When the gate goes red:
2. **Condense** content that belongs here but can be shorter.
3. **Raise** the ceiling only when the words need the space; justify the manifest diff in the PR. A too-low ceiling is a budget bug.

Ceilings are guardrails, not reduction targets. At or below target, retain at least 5% headroom; above target, freeze the ceiling until relocation or condensation brings the document under target. Lower a ceiling only when the document still has room. Targets: root `AGENTS.md` ≤ 1,950; `architecture.md` ≤ 2,400; subtree `AGENTS.md` ≤ 600, except `packages/AGENTS.md` ≤ 675 and this file ≤ 1,320; `packages/README.md` ≤ 994; plus `cordis-primer.md` 600, `defensive-patterns.md` 550, `testing.md` 1,150, `examples/AGENTS.md` 310. Review governs unbudgeted tiers.
Ceilings are guardrails, not reduction targets. At or below target, retain at least 5% headroom; above target, freeze the ceiling until relocation or condensation brings the document under target. Lower a ceiling only when the document still has room. Targets: root `AGENTS.md` ≤ 1,950; `architecture.md` ≤ 2,400; subtree `AGENTS.md` ≤ 600, except `packages/AGENTS.md` ≤ 750 and this file ≤ 1,320; `packages/README.md` ≤ 994; plus `cordis-primer.md` 600, `defensive-patterns.md` 550, `testing.md` 1,300, `examples/AGENTS.md` 310. Review governs unbudgeted tiers.

## The slop checklist

Expand Down
6 changes: 3 additions & 3 deletions content/en/dsh/docs/api-gateway.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
title: "API Gateway"
source: https://github.com/deepseek-ai/deepseek-harness/blob/master/docs/api-gateway.md
fetched: 2026-08-27
fetched: 2026-09-02
---
# API Gateway

Expand Down Expand Up @@ -129,13 +129,13 @@ The Connection performs the unified trust check for `/api` before the HTTP bridg

For every call, the Gateway resolves the descriptor and live service from the current registries instead of caching business objects. It requires the fields in `args` to match the descriptor exactly, validates wire values with codecs, resolves objects or receivers through registered lookup or Context providers, invokes the service method targeted by the binding, and validates the return value. A missing provider, unknown identity, binding mismatch, missing or extra argument, schema failure, or missing method fails before entering or after leaving business code.

The lookup provider's `register()` supplies both the stable declaration and the default resolver; `configure()` supplies a resolver owned by Host composition that may execute asynchronously and is scoped to an effect lifetime. Configuration may precede provider mounting; without a provider, invocation still fails with `lookup-unavailable`, and unloading the configuration restores the provider's default policy. The Session Controller owns the standard `agentFor()` semantics for `agent` and `session`: it reuses a live Agent, automatically resumes ordinary cold sessions, deduplicates concurrent resumes, and rejects identities owned by subagent routing; the `session` lookup returns that Agent's Session. Resume failures and ownership fences pass through unchanged as existing RPC errors rather than being collapsed into the Gateway's `internal` error.
The lookup provider's `register()` supplies both the stable declaration and the default resolver; `configure()` supplies a resolver owned by Host composition that may execute asynchronously and is scoped to an effect lifetime. Configuration may precede provider mounting; without a provider, invocation still fails with `gateway/lookup-unavailable`, and unloading the configuration restores the provider's default policy. The Session Controller owns the standard resolver semantics for `agent` and `session`: it reuses a live Agent, automatically resumes ordinary cold sessions, deduplicates concurrent resumes, and rejects identities owned by subagent routing; the `session` lookup returns that Agent's Session. A resume failure and an ownership fence raise a `RemoteError` carrying their own code, `session/not-found` or `session/agent-busy`, which the Gateway encodes onto the wire unchanged; only an unclassified throw folds into `gateway/internal`.

Unloading a Client contribution removes its descriptors and concrete methods together, aborts its in-flight calls, and makes stale method handles retained by external code reject further calls. A strict endpoint withdrawn on the Host also does not degrade to SRC inference, preventing a hot unload from silently weakening validation.

## SRC development fallback

When the Host starts from source through `node --import tsx/esm`, it does not execute the Typert compiler plugin. Standard decorator initializers still record the method name and invocation mode in a module-private `WeakMap`, while `TypertRemoteService` or `bindTypertRemote()` supplies the explicit service binding; the Gateway can therefore construct a weaker temporary descriptor without starting a `ts.Program`.
When the Host starts from source through `node --import tsx/esm`, it does not execute the Typert compiler plugin. Standard decorator initializers still record the method name and invocation mode in a versioned descriptor on the Service prototype, while `TypertRemoteService` or `bindTypertRemote()` supplies the explicit service binding; the Gateway can therefore construct a weaker temporary descriptor without starting a `ts.Program`. The descriptor's stable string property name lets `remoteMethods()` read markers written by another installed copy of the protocol package.

The SRC fallback parses simple parameter names from the live function. When a parameter name matches the `parameter` of a registered lookup, such as `agent` or `session`, it uses the lookup's `agentId` or `sessionId` wire field and resolves the object on the Host; other parameters are checked only for cycle-free, JSON-safe data with no special prototype. `@RemoteScope` directly uses the wire field of a registered Host Context provider. SRC does not read TypeScript types, generate Zod schemas, infer optional parameters, or support destructuring, default values, rest parameters, or duplicate parameter names.

Expand Down
7 changes: 5 additions & 2 deletions content/en/dsh/docs/architecture.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
title: "DeepSeek Harness Architecture"
source: https://github.com/deepseek-ai/deepseek-harness/blob/master/docs/architecture.md
fetched: 2026-08-27
fetched: 2026-09-02
---
# DeepSeek Harness Architecture

Expand Down Expand Up @@ -111,6 +111,8 @@ The session log is the source of the context the model sees. `deriveMessages()`

**Model-visible means logged.** Anything that reaches a model request must be reconstructable from the log, and a runtime invariant asserts it. This is why a new model-visible input requires a new session event: extend `SessionEventMap` and render from the log.

**Projection seam.** `dsh-session-projection` owns `ctx.sessionProjections`: registered units fold committed events incrementally, host consumers read one typed state with `stateOf()`, and carriers batch cropped client views with `snapshot()`. A host reader either requires this service during activation or fails explicitly when the registry or required key is absent. Contributors may retain `ctx.inject(['sessionProjections'], ...)` registration without silently defaulting a missing host value. The agent loop registers shared `turnBoundary` state for its readers ([decision](../.agents/notes/implemented/architecture/2026-08-19-session-projection-mandatory-seam.md)).

## Capability seams

A **seam** is a swappable capability with three roles: a **Service Definition** declaring the interface, a **Service Provider** implementing it, and a **Consumer** using it, commonly a model-facing tool. A package may combine roles, but one role alone is not a seam; adding a capability means designing all three ([capability graph](capability-seams.md)).
Expand Down Expand Up @@ -142,7 +144,8 @@ New behavior attaches to a documented extension point. Changing the loop itself
| Add durable session state | extend `SessionEventMap`; render and replay from the log |
| Generate session titles | register the sole `ctx.sessionTitle` provider |
| Manage a same-session objective | use `ctx.goals`; continue through `agent/*` |
| Fork a live session | `ctx.sessions.fork(source, boundary?, childSessionId?)` |
| Fork a session at a turn boundary | `ctx.agents.create({ sessionId, seed, meta: { parentSession, seedLength } })` — only agent-loop-published sessions persist |
| Store sessions in a new backend | implement `SessionPersistence` (`create`/`open`/`stat`/`list`/`export`) over the shared handle scaffolding |
| Scope a registration to one agent | use that agent's `agent.ctx` |

The [extension cookbook](cookbook/extension-cookbook.md) maps features to capabilities and indexes the step-by-step guides for [packages](cookbook/adding-a-package.md), [tools](cookbook/adding-a-tool.md), [LLM adapters](cookbook/adding-an-llm-adapter.md), and [settings cards](cookbook/adding-a-settings-card.md). The [Conversation subsystem](subsystems/conversation.md) owns Chat-node assembly.
Loading