| 963 | |
| 964 | |
| 965 | def resolve_note_output_mode(config: dict[str, Any]) -> tuple[str, Path]: |
| 966 | vault_path = configured_obsidian_vault(config) |
| 967 | if vault_path is not None: |
| 968 | return ("obsidian", vault_path) |
| 969 | workspace_root = Path.cwd().resolve() |
| 970 | output_dir = str(config.get("workspace_output_dir", "DeepPaperNote_output")).strip() or "DeepPaperNote_output" |
| 971 | return ("workspace", workspace_root / output_dir) |
| 972 | |
| 973 | |
| 974 | DOMAIN_RULES_PATH = Path(__file__).resolve().parents[1] / "references" / "domain_rules.yaml" |