Skip to content

feat(session): add Cursor and OpenAI session import and export support - #221

Merged
Patel230 merged 1 commit into
mainfrom
feat/session-import-cursor-openai
Aug 21, 2026
Merged

feat(session): add Cursor and OpenAI session import and export support#221
Patel230 merged 1 commit into
mainfrom
feat/session-import-cursor-openai

Conversation

@Patel230

Copy link
Copy Markdown
Contributor

Summary

Port of foreign harness session import and normalization for Cursor and OpenAI/Codex formats (Grok-Class Phase 10 Parity).

  • Format Additions: Added FormatCursor and FormatOpenAI to ExportFormat alongside FormatClaude and FormatAider.
  • Cursor Import (ImportFromCursor): Supports Cursor conversation export JSON with messages (speaker, text, timestamp), normalizing speakers (human -> user, ai -> assistant).
  • OpenAI Import (ImportFromOpenAI): Supports standard OpenAI Chat Completions JSON with role, content, tool_calls mapping.
  • OpenAI Export (formatOpenAI): Added export serializer to format Hawk sessions into standard OpenAI chat completion JSON.
  • Multi-Format Routing: Updated Import(data, format) to route all supported formats.
  • Test Coverage: Added test suites for Cursor and OpenAI import/export in export_test.go.

Verification

  • go test -race ./internal/session/... -> PASS
  • ./scripts/check-internal-layer-imports.sh -> PASS
  • make lint -> 0 issues
  • hawk verify -> verification passed

Port of foreign harness session import and normalization for Cursor and OpenAI/Codex formats.

- session: Added FormatCursor and FormatOpenAI export/import formats.
- session: Implemented ImportFromCursor supporting Cursor JSON export formats with speaker and timestamp mapping.
- session: Implemented ImportFromOpenAI supporting OpenAI Chat Completions JSON with tool call normalization.
- session: Implemented formatOpenAI for exporting sessions to standard OpenAI format.
- tests: Added test coverage for Cursor and OpenAI import and export in export_test.go.
@Patel230
Patel230 merged commit 1297a8c into main Aug 21, 2026
26 checks passed
@Patel230
Patel230 deleted the feat/session-import-cursor-openai branch August 21, 2026 05:20
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