kimi-code/packages/node-sdk
Haozhe c6e02daf42
feat(background): add print_background_mode steer for multi-turn -p runs (#1497)
* feat(background): add print_background_mode with steer for multi-turn -p runs

- add `[background].print_background_mode` (`exit`/`drain`/`steer`) and
  `print_max_turns`; when unset, falls back to `keep_alive_on_exit = true`
  mapping to `drain`, preserving existing behavior
- core: `Session.handlePrintMainTurnCompleted()` returns `finish`/`continue`;
  in `steer` mode the run stays alive so a background-task completion
  `turn.steer`s the main agent into a new turn (matching background
  subagents), bounded by `print_wait_ceiling_s` and `print_max_turns`
- cli: print driver follows every main turn instead of only the first and
  defers `finish()` until the run quiesces or a limit is hit
- plumb `handlePrintMainTurnCompleted` through node-sdk RPC; docs + tests
2026-07-12 10:47:35 +08:00
..
examples refactor!: overhaul thinking config and effort resolution (#1132) 2026-06-30 22:34:13 +08:00
scripts fix: avoid Windows command shim launches (#591) 2026-06-09 20:20:44 +08:00
src feat(background): add print_background_mode steer for multi-turn -p runs (#1497) 2026-07-12 10:47:35 +08:00
test feat(cli): keep kimi -p running while a goal is active or cron tasks are pending (#1555) 2026-07-11 21:16:27 +08:00
api-extractor.json Kimi For Coding 2026-05-22 15:54:50 +08:00
CHANGELOG.md ci: release packages (#1513) 2026-07-09 23:45:47 +08:00
package.json ci: release packages (#1513) 2026-07-09 23:45:47 +08:00
README.md Kimi For Coding 2026-05-22 15:54:50 +08:00
tsconfig.api-extractor.json Kimi For Coding 2026-05-22 15:54:50 +08:00
tsconfig.dts.json Kimi For Coding 2026-05-22 15:54:50 +08:00
tsconfig.json feat(web): introduce Kimi web app and daemon gateway (#625) 2026-06-17 20:53:46 +08:00
tsdown.config.ts Kimi For Coding 2026-05-22 15:54:50 +08:00
vitest.config.ts chore: use raw query imports for prompt sources (#682) 2026-06-12 11:47:44 +08:00

@moonshot-ai/kimi-code-sdk

The TypeScript SDK for Kimi Code

Part of the Kimi Code monorepo.

See the main repository for documentation, issues, and contribution guidelines.

License

MIT