Skip to content

fix: restore markdown history summarization helper#4975

Open
MobiusL00p wants to merge 1 commit intoAider-AI:mainfrom
MobiusL00p:fix-history-markdown-summary
Open

fix: restore markdown history summarization helper#4975
MobiusL00p wants to merge 1 commit intoAider-AI:mainfrom
MobiusL00p:fix-history-markdown-summary

Conversation

@MobiusL00p
Copy link
Copy Markdown

Summary

  • restore ChatSummary.summarize_chat_history_markdown() so aider/history.py's CLI entrypoint no longer calls a missing method
  • parse markdown chat history back into user/assistant messages while skipping headings, blockquotes, and slash-command markers
  • add a regression test covering the markdown parsing path and keep the updated history tests clean under basedpyright

Verification

  • python -m pytest -q tests/basic/test_history.py
  • python -c "from aider.history import ChatSummary; from unittest import mock; m=mock.Mock(); m.token_count=lambda msg: 1; m.info={'max_input_tokens':4096}; s=ChatSummary([m], max_tokens=100); s.summarize=lambda messages: messages; print(s.summarize_chat_history_markdown('# aider chat\n#### Q\nA\n'))"

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.

1 participant