MoonshotAI / MoonshotAI/kimi-code

Feature Request: Include assistant response text in Stop hook payload (or add a post-response hook event)

Open
#952 2 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
TypeScript
Stars
7.5k
Forks
1.2k
Avg merge
11h 53m
Merged PRs (30d)
350

Description

What feature would you like to see?

Use case: Building persistent session memory / conversation logging on top of Kimi CLI hooks.

Current state: The UserPromptSubmit hook exposes the user's message, but the Stop hook payload only contains session_id, cwd, and stop_hook_active. It does not include the assistant's response text.

Requested change: Include the assistant's final response text in the Stop hook payload, or add a new observation-only hook (e.g. AssistantResponse) that fires after the response is complete and includes the full text.

Why it matters: Without the assistant side, third-party memory systems can only log user prompts, which makes cross-session recall and fact extraction much weaker.

Additional information

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing the UserPromptSubmit and Stop hook payload definitions and dispatch paths in the Kimi CLI. Compare exposing the final assistant response in Stop with adding an observation-only AssistantResponse event; done means a hook receives the complete response text after generation without changing existing hook behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
cli
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.