Overview
Connect notes and papers to datasets, code repositories, and experiment logs.
Why
Modern science involves code and data. Notes should link to the GitHub repo or dataset that produced results.
Plan
1. Create ExternalLink Model
// Model/ExternalLink.swift
struct ExternalLink: Codable, Identifiable {
let id: String
var type: LinkType
var url: String
var title: String
var description: String?
var linkedNoteIds: [String]
var linkedPaperIds: [String]
}
enum LinkType: String, Codable, CaseIterable {
case github, gitlab, huggingface
case dataset, zenodo, figshare
case notebook, colab
case custom
}
2. Link Management
- Add links to notes:
[[repo:url]]
- Add links to papers (e.g., "Code for this paper")
- Store in space metadata
3. UI Components
- "Add External Link" in note editor
- Link picker with type icons
- Preview cards for GitHub repos (fetch README preview)
- Quick-open in browser
4. GitHub Integration (optional)
- Authenticate with GitHub
- Show recent commits for linked repos
- Link specific commits to notes
5. Dataset Integration
- Zenodo/Figshare DOI lookup
- HuggingFace dataset cards
- Preview dataset metadata
Acceptance Criteria
Overview
Connect notes and papers to datasets, code repositories, and experiment logs.
Why
Modern science involves code and data. Notes should link to the GitHub repo or dataset that produced results.
Plan
1. Create ExternalLink Model
2. Link Management
[[repo:url]]3. UI Components
4. GitHub Integration (optional)
5. Dataset Integration
Acceptance Criteria