[codex] Add forwarded chat record expansion#15
Open
ZaychikLiu wants to merge 1 commit into
Open
Conversation
Co-authored-by: Feiyang Liu <a160130k@gmail.com> Co-authored-by: Codex <codex@openai.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a
wechat-cli recordscommand for expanding WeChat forwarded / merged chat record cards into their inner messages, including nested forwarded records.The command scans app messages that contain compressed WCDB payloads, decompresses them with the existing message decompression helper, parses
<recorditem>/<dataitem>entries, and exports the nested items as either text or JSON.Contribution
This contribution was developed collaboratively by Zaychik and Codex. The commit includes
Co-authored-bytrailers for both contributors so the authorship is visible in GitHub history.Why
Merged chat records currently appear as a single link/file-style app message in exported history, so the original messages inside the merged record are not visible. This makes exports incomplete for conversations that rely on forwarded chat bundles.
User Impact
wechat-cli records "CONTACT" --limit 20 --format text --output records.txtchildrenin JSON.--limit,--offset,--scan-limit,--start-time, and--end-time.historybehavior unchanged.Validation
.venv/bin/python -m compileall wechat_cli.venv/bin/python entry.py --help.venv/bin/python entry.py records --help<dataitemsourceid>tags that should not be treated as records.entry.py --config /path/to/config.json records "wxid_..." --limit 2 --format text --output wechat-cli-records-smoke.txtentry.py --config /path/to/config.json records "wxid_..." --limit 1 --format json --output wechat-cli-records-smoke.jsonNotes
The parsing is intentionally conservative: it only expands records where the decompressed payload contains recognizable record/data item markup, and falls back to available title/description fields for non-text inner message types.