Skip to content

docs(python): add module-level docstrings to public modules#28

Merged
RealKai42 merged 3 commits intomainfrom
kaiyi/python/update-0121
Jan 21, 2026
Merged

docs(python): add module-level docstrings to public modules#28
RealKai42 merged 3 commits intomainfrom
kaiyi/python/update-0121

Conversation

@RealKai42
Copy link
Collaborator

Add module-level docstrings to all Python SDK modules following, with clear descriptions, key features, and runnable examples

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This pull request adds comprehensive module-level docstrings to all Python SDK modules in the Kimi Agent SDK. The docstrings follow a consistent format with clear descriptions, key features, and runnable code examples.

Changes:

  • Added module-level docstrings to six Python modules (__init__.py, _session.py, _prompt.py, _exception.py, _approval.py, _aggregator.py)
  • Each docstring includes a summary, description, key classes/functions/types/exceptions listing, and practical code examples
  • Examples demonstrate both high-level and low-level API usage patterns

Reviewed changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
python/src/kimi_agent_sdk/__init__.py Added comprehensive package-level docstring with both high-level prompt API and low-level Session API examples
python/src/kimi_agent_sdk/_session.py Added module docstring explaining Session class for low-level agent control with Wire message access
python/src/kimi_agent_sdk/_prompt.py Added module docstring for high-level prompt API with examples for both yolo mode and custom approval handlers
python/src/kimi_agent_sdk/_exception.py Added module docstring documenting SDK-specific exceptions for validation and state management
python/src/kimi_agent_sdk/_approval.py Added module docstring explaining approval handling types and custom approval handler pattern
python/src/kimi_agent_sdk/_aggregator.py Added module docstring for Wire message aggregation with MessageAggregator usage example

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@RealKai42 RealKai42 merged commit ba2f0d4 into main Jan 21, 2026
5 checks passed
@RealKai42 RealKai42 deleted the kaiyi/python/update-0121 branch January 21, 2026 13:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants