@omercnet/paseo-omp 0.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (63) hide show
  1. package/CHANGELOG.md +87 -0
  2. package/LICENSE +21 -0
  3. package/README.md +110 -0
  4. package/SUPPORT.md +40 -0
  5. package/TESTING.md +147 -0
  6. package/client/hub-icon.tsx +12 -0
  7. package/client/hub-popover.tsx +132 -0
  8. package/client/hub-status.ts +29 -0
  9. package/client/memory-panel.tsx +71 -0
  10. package/client/memory-popover.tsx +70 -0
  11. package/client/omp-config-surface.tsx +1274 -0
  12. package/client/omp-doc-links.ts +117 -0
  13. package/client/omp-plugin-manager.tsx +833 -0
  14. package/client/provider-diagnostics-state.ts +250 -0
  15. package/client/provider-icon.tsx +27 -0
  16. package/client/provider-image.tsx +66 -0
  17. package/client/quota-popover.tsx +150 -0
  18. package/client/quota-state.ts +131 -0
  19. package/client/sessions-popover.tsx +73 -0
  20. package/docs/alpha-release-checklist.md +70 -0
  21. package/docs/configuration.md +122 -0
  22. package/docs/core-provider-issue-audit.md +108 -0
  23. package/docs/installation.md +73 -0
  24. package/index.client.tsx +272 -0
  25. package/index.server.ts +51 -0
  26. package/package.json +84 -0
  27. package/paseo-plugin.json +5 -0
  28. package/server/hub.ts +145 -0
  29. package/server/memory.ts +86 -0
  30. package/server/mutation-queue.ts +12 -0
  31. package/server/omp-config.ts +126 -0
  32. package/server/omp-plugins.ts +627 -0
  33. package/server/omp-settings.ts +291 -0
  34. package/server/paths.ts +64 -0
  35. package/server/provider/catalog.ts +173 -0
  36. package/server/provider/config-normalization.ts +148 -0
  37. package/server/provider/connection.ts +992 -0
  38. package/server/provider/host-tools.ts +706 -0
  39. package/server/provider/image.ts +143 -0
  40. package/server/provider/mcp-transport.ts +394 -0
  41. package/server/provider/omp-rpc.ts +2739 -0
  42. package/server/provider/omp.svg +5 -0
  43. package/server/provider/provider-options.ts +27 -0
  44. package/server/provider/registration.ts +151 -0
  45. package/server/provider/security.ts +317 -0
  46. package/server/provider/session-descriptors.ts +431 -0
  47. package/server/provider/session.ts +4451 -0
  48. package/server/provider/settings.ts +78 -0
  49. package/server/provider/subsessions.ts +847 -0
  50. package/server/provider/timeline-projector.ts +1764 -0
  51. package/server/provider-diagnostics.ts +1057 -0
  52. package/server/quota.ts +54 -0
  53. package/server/sessions.ts +58 -0
  54. package/shared/hub.ts +43 -0
  55. package/shared/memory.ts +23 -0
  56. package/shared/omp-config.ts +81 -0
  57. package/shared/omp-plugins.ts +223 -0
  58. package/shared/omp-settings.ts +207 -0
  59. package/shared/provider-diagnostics.ts +117 -0
  60. package/shared/provider-image.ts +160 -0
  61. package/shared/quota.ts +22 -0
  62. package/shared/sessions.ts +23 -0
  63. package/tsconfig.json +16 -0
@@ -0,0 +1,117 @@
1
+ import type { OmpSettingCategory } from "../shared/omp-settings";
2
+
3
+ const OMP_GITHUB_DOCS = "https://github.com/can1357/oh-my-pi/blob/main/docs";
4
+
5
+ export interface OmpDocumentationLink {
6
+ label: string;
7
+ accessibilityLabel: string;
8
+ url: string;
9
+ }
10
+
11
+ function settingsLink(
12
+ label: string,
13
+ accessibilityLabel: string,
14
+ anchor?: string,
15
+ ): OmpDocumentationLink {
16
+ return {
17
+ label,
18
+ accessibilityLabel,
19
+ url: `${OMP_GITHUB_DOCS}/settings.md${anchor ? `#${anchor}` : ""}`,
20
+ };
21
+ }
22
+
23
+ export const OMP_SETTINGS_REFERENCE = settingsLink(
24
+ "Settings reference",
25
+ "Open official OMP settings reference",
26
+ );
27
+
28
+ export const OMP_SETTINGS_GUIDES: readonly OmpDocumentationLink[] = [
29
+ settingsLink(
30
+ "Reading & writing",
31
+ "Open official OMP guide to reading and writing settings",
32
+ "reading-and-writing-settings",
33
+ ),
34
+ settingsLink("Value parsing", "Open official OMP value parsing guide", "value-parsing"),
35
+ settingsLink("Precedence", "Open official OMP configuration precedence guide", "precedence"),
36
+ ];
37
+
38
+ const CATEGORY_DOCUMENTATION: Partial<Record<OmpSettingCategory, OmpDocumentationLink>> = {
39
+ appearance: settingsLink(
40
+ "Appearance docs",
41
+ "Open official OMP appearance and terminal settings documentation",
42
+ "appearance-and-terminal",
43
+ ),
44
+ model: {
45
+ label: "Model roles docs",
46
+ accessibilityLabel: "Open official OMP model roles and settings documentation",
47
+ url: `${OMP_GITHUB_DOCS}/models.md#role-aliases-and-settings`,
48
+ },
49
+ interaction: settingsLink(
50
+ "Interaction docs",
51
+ "Open official OMP interaction settings documentation",
52
+ "interaction",
53
+ ),
54
+ context: settingsLink(
55
+ "Context docs",
56
+ "Open official OMP context and compaction settings documentation",
57
+ "context-compaction-and-memory",
58
+ ),
59
+ memory: settingsLink(
60
+ "Memory docs",
61
+ "Open official OMP memory settings documentation",
62
+ "context-compaction-and-memory",
63
+ ),
64
+ files: settingsLink(
65
+ "File docs",
66
+ "Open official OMP editing and reading settings documentation",
67
+ "files-editing-and-reading",
68
+ ),
69
+ shell: settingsLink(
70
+ "Shell docs",
71
+ "Open official OMP shell, eval, and LSP settings documentation",
72
+ "shell-eval-and-lsp",
73
+ ),
74
+ tools: settingsLink(
75
+ "Tool docs",
76
+ "Open official OMP tools and approvals settings documentation",
77
+ "tools-and-approvals",
78
+ ),
79
+ providers: settingsLink(
80
+ "Provider docs",
81
+ "Open official OMP providers and services settings documentation",
82
+ "providers-and-services",
83
+ ),
84
+ };
85
+
86
+ const SETTING_DOCUMENTATION: Readonly<Record<string, OmpDocumentationLink>> = {
87
+ modelRoleStorage: settingsLink(
88
+ "Write location docs",
89
+ "Open official OMP documentation for model role write locations",
90
+ "where-writes-go",
91
+ ),
92
+ enabledModels: settingsLink(
93
+ "Path scope docs",
94
+ "Open official OMP documentation for path-scoped model settings",
95
+ "path-scoped-arrays",
96
+ ),
97
+ enabledProviders: settingsLink(
98
+ "Discovery docs",
99
+ "Open official OMP provider and source discovery documentation",
100
+ "provider-and-source-disabling",
101
+ ),
102
+ disabledProviders: settingsLink(
103
+ "Discovery docs",
104
+ "Open official OMP provider and source discovery documentation",
105
+ "provider-and-source-disabling",
106
+ ),
107
+ };
108
+
109
+ export function documentationForSettingCategory(
110
+ category: OmpSettingCategory,
111
+ ): OmpDocumentationLink | undefined {
112
+ return CATEGORY_DOCUMENTATION[category];
113
+ }
114
+
115
+ export function documentationForSettingPath(path: string): OmpDocumentationLink | undefined {
116
+ return SETTING_DOCUMENTATION[path];
117
+ }