Skip to content

feat(mail): raw .eml pipeline + mbox splitter + enmime handlers - #64

Merged
eSlider merged 1 commit into
mainfrom
feat/mail-raw-pipeline
Aug 21, 2026
Merged

eSlider merged 1 commit into
mainfrom
feat/mail-raw-pipeline

Conversation

@eSlider

@eSlider eSlider commented Aug 21, 2026

Copy link
Copy Markdown
Owner

Summary

Raw Gmail .eml pipeline and a robust mbox splitter, powering the mail->brain corpus import.

  • mbox2eml: split mbox into per-message .eml (bare From separator fix,
    exclude separator from body, isSep envelope rule, global counter + nested dirs).
  • sync: GetMessageRaw (format=raw, 96MB cap) + --raw download mode.
  • mailconv: enmime-based FromEML + type-handler registry (handlers.go),
    mailconv.go rework.
  • docs/mail-import-rewrite-plan.md.
  • go.mod: add jhillyerd/enmime/v2 (+ indirects).

Split out of a larger session; contacts importer and brain parallel-write are
separate PRs (#63, next).

Test

GOWORK=off go build ./bin/mail/... ./internal/mailconv/... passes.

- bin/mail/mbox2eml: mbox -> per-message .eml splitter (bare From fix,
  isSep envelope rule, global counter + nested dirs)
- bin/mail/sync: GetMessageRaw (format=raw, 96MB cap) + --raw download
  mode for the gmail archive
- internal/mailconv: enmime-based FromEML + type-handler registry
  (handlers.go); mailconv.go rework
- docs/mail-import-rewrite-plan.md
- go.mod: add jhillyerd/enmime/v2 (+ indirects)
@eSlider
eSlider merged commit ef10125 into main Aug 21, 2026
4 checks passed
eSlider added a commit that referenced this pull request Aug 21, 2026
…, docs truth-only

bin/chats → bin/chat, internal/chats → internal/chat (singular, D14).
refresh-linkedin-session python helper deleted — ported to
internal/chat/linkedin_session.go (CDP cookies via x/net/websocket,
profile copy, cookies.json + source-state.json); sync_linkedin calls it
in-process (no subprocess). New bin/chat/refresh-session.go entry.

docs/ = truth only:
- plans/proofs archived to Gitea (#64 chat-import, #55 crm-proof,
  #58 load-baseline, #38 mail-plan) and deleted here;
  refactor-v1.0.md → epic #65 body
- brain-rebuild → brain/rebuild.md, audit-recipes → facts/audit-recipes.md
- design.md honesty fixes: import-git writes directly (was print-flow),
  no bin/kb/python claims, MCP surface = 3 tools, audit-db not 'audit stale'
- roadmap marked historical; README index rewritten (current epics)

AGENTS.md standing rules: Go-only/no Python, libs by domain, docs=truth,
non-goals (graph semantics, reasoner/CGO untouched).
eSlider added a commit that referenced this pull request Aug 24, 2026
feat(mail): raw .eml pipeline + mbox splitter + enmime handlers
eSlider added a commit that referenced this pull request Aug 24, 2026
…, docs truth-only

bin/chats → bin/chat, internal/chats → internal/chat (singular, D14).
refresh-linkedin-session python helper deleted — ported to
internal/chat/linkedin_session.go (CDP cookies via x/net/websocket,
profile copy, cookies.json + source-state.json); sync_linkedin calls it
in-process (no subprocess). New bin/chat/refresh-session.go entry.

docs/ = truth only:
- plans/proofs archived to Gitea (#64 chat-import, #55 crm-proof,
  #58 load-baseline, #38 mail-plan) and deleted here;
  refactor-v1.0.md → epic #65 body
- brain-rebuild → brain/rebuild.md, audit-recipes → facts/audit-recipes.md
- design.md honesty fixes: import-git writes directly (was print-flow),
  no bin/kb/python claims, MCP surface = 3 tools, audit-db not 'audit stale'
- roadmap marked historical; README index rewritten (current epics)

AGENTS.md standing rules: Go-only/no Python, libs by domain, docs=truth,
non-goals (graph semantics, reasoner/CGO untouched).
eSlider added a commit that referenced this pull request Sep 15, 2026
feat(mail): raw .eml pipeline + mbox splitter + enmime handlers
eSlider added a commit that referenced this pull request Sep 15, 2026
…, docs truth-only

bin/chats → bin/chat, internal/chats → internal/chat (singular, D14).
refresh-linkedin-session python helper deleted — ported to
internal/chat/linkedin_session.go (CDP cookies via x/net/websocket,
profile copy, cookies.json + source-state.json); sync_linkedin calls it
in-process (no subprocess). New bin/chat/refresh-session.go entry.

docs/ = truth only:
- plans/proofs archived to Gitea (#64 chat-import, #55 crm-proof,
  #58 load-baseline, #38 mail-plan) and deleted here;
  refactor-v1.0.md → epic #65 body
- brain-rebuild → brain/rebuild.md, audit-recipes → facts/audit-recipes.md
- design.md honesty fixes: import-git writes directly (was print-flow),
  no bin/kb/python claims, MCP surface = 3 tools, audit-db not 'audit stale'
- roadmap marked historical; README index rewritten (current epics)

AGENTS.md standing rules: Go-only/no Python, libs by domain, docs=truth,
non-goals (graph semantics, reasoner/CGO untouched).
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