dsh-llm-omp-transports 0.2.3 → 0.2.5

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.
package/README.md CHANGED
@@ -11,16 +11,16 @@ and the plugin page lists both bundle components
11
11
  |---|---|
12
12
  | npm package | `dsh-llm-omp-transports` |
13
13
  | Plugin id | `llm-omp-transports` |
14
- | Route | `cursor` (first provider; the seam is provider-generic) |
15
- | Credential scope | `llm-omp-transports/<provider>`, today `llm-omp-transports/cursor` |
14
+ | Routes | `cursor`, `devin` (the seam is provider-generic) |
15
+ | Credential scope | `llm-omp-transports/<provider>`: `llm-omp-transports/cursor`, `llm-omp-transports/devin` |
16
16
  | Runtime | Node 24 (the bundle imports Node builtins only) |
17
17
  | License | MIT |
18
18
 
19
19
  The plugin registers its own route on the DSH `llm` seam, so it depends on no
20
20
  upstream DSH change. `@oh-my-pi/pi-ai` and `@oh-my-pi/pi-catalog` are used at
21
- **build time only**: the build inlines the pinned omp Cursor transport into one
22
- ESM artifact (`lib/omp/cursor.mjs`), and the published package imports nothing
23
- from `@oh-my-pi/*` or `bun:*` at runtime.
21
+ **build time only**: the build inlines the pinned omp transports into one ESM
22
+ artifact per route (`lib/omp/cursor.mjs`, `lib/omp/devin.mjs`), and the
23
+ published package imports nothing from `@oh-my-pi/*` or `bun:*` at runtime.
24
24
 
25
25
  ## Cursor support status
26
26
 
@@ -47,6 +47,31 @@ from `@oh-my-pi/*` or `bun:*` at runtime.
47
47
  - **Images** — not yet. The route advertises text-only input and refuses image
48
48
  blocks with `CONTENT_UNSUPPORTED`; see [known limits](docs/known-limits.md).
49
49
 
50
+ ## Devin support status
51
+
52
+ - **Text streaming** — yes. Assistant text and reasoning are projected onto
53
+ DSH's `StreamChunk` stream, with the per-turn usage the chat frames report.
54
+ - **Reasoning streaming** — yes as content; no reasoning-effort selector. Both
55
+ pinned rows advertise no efforts, and a request that selects one is refused
56
+ with `UNSUPPORTED_REASONING_EFFORT`.
57
+ - **Tool-call handoff** — yes, native to DSH's tool loop. The transport emits
58
+ the call, finishes the turn `toolUse`, and DSH executes it; the result is
59
+ replayed from history on the next request. Unlike Cursor, no call is
60
+ transport-resolved, so nothing is filtered from the handoff.
61
+ - **Sign-in** — yes, by pasting the callback. The pinned omp login is a
62
+ declarative `oauth-code` rule whose loopback listener is Bun-only; this
63
+ package registers the `llm-omp-transports/devin` flow, opens the authorize
64
+ page, and asks for the address the browser landed on (or just the code).
65
+ There is **no refresh** (`refresh "none"`): an expired grant demands a new
66
+ sign-in.
67
+ - **Models** — from the pinned catalog: the Devin slice of
68
+ `@oh-my-pi/pi-catalog@18.12.3` (2 rows: `swe-1-6`, `swe-1-6-fast`) is
69
+ generated into `src/catalog/devin.ts` and served without a network call.
70
+ - **Route** — `devin`, declared configurable so the Models page has a
71
+ `providers.devin` profile with an allow-list.
72
+ - **Images** — not yet, same as Cursor: text-only input, image blocks refused
73
+ with `CONTENT_UNSUPPORTED`.
74
+
50
75
  ## Hard constraints
51
76
 
52
77
  - **Pinned, build-time-only omp.** `@oh-my-pi/pi-ai` and `@oh-my-pi/pi-catalog`
@@ -103,6 +128,24 @@ from `@oh-my-pi/*` or `bun:*` at runtime.
103
128
  for an output cap, sampling temperature, stop sequences or an auxiliary-call
104
129
  purpose; DSH's `maxTokens`, `temperature`, `stop` and `purpose` never reach
105
130
  the wire, and Cursor applies the catalog output limit server-side.
131
+ - **Unofficial Devin client.** The transport presents the released Devin CLI
132
+ identity (`ideName: "devin-cli"`, `ideType: "chisel"`, `ideVersion:
133
+ "3000.11.3"`) and a `connect-go` client header the omp sources copy from the
134
+ CLI. Same posture as Cursor's S4: a first live turn rejected with `401`/`403`
135
+ stops the route until a product decision, never a retry under another
136
+ identity.
137
+ - **Attribution deviates on one call.** The Devin chat request must keep the
138
+ transport's own `connect-go` client header — the backend gates on it. The
139
+ header-less `GetUserJwt` handshake has no identity of its own, so the adapter
140
+ fills DSH's attribution `user-agent` only where a header is absent. Cursor's
141
+ requests keep full attribution.
142
+ - **Devin has no refresh.** The pinned rule declares `refresh "none"`, so the
143
+ record is a static bearer with a derived `expires` (JWT `exp` minus five
144
+ minutes, else one year). An expired or corrupt record is `REAUTH_REQUIRED`,
145
+ not renewed. Because the omp loopback listener is Bun-only and the browser
146
+ half is untestable offline, the flow is paste-only for now; a bare pasted
147
+ code skips the state check (the page is the only place the state could
148
+ travel).
106
149
 
107
150
  ## Develop and test
108
151
 
@@ -113,9 +156,10 @@ pnpm -C packages/llm-omp test
113
156
  pnpm -C packages/llm-omp run generate:catalog
114
157
  ```
115
158
 
116
- `build` bundles the pinned omp graph from `scripts/omp-entry.ts` into
117
- `lib/omp/cursor.mjs` and rewrites `scripts/omp-manifest.json`; run it before
118
- `test` after a pin or shim change. CI runs the same sequence and then fails if
159
+ `build` bundles the pinned omp graphs from `scripts/omp-entry.ts` and
160
+ `scripts/omp-entry-devin.ts` into `lib/omp/cursor.mjs` and `lib/omp/devin.mjs`
161
+ and rewrites `scripts/omp-manifest.json`; run it before `test` after a pin or
162
+ shim change. CI runs the same sequence and then fails if
119
163
  the committed manifest drifted.
120
164
 
121
165
  The install proof lives at the repository root and needs `pnpm` and `dsh` on
@@ -1,5 +1,5 @@
1
1
  # Mounts the llm-omp-transports transport plugin when this package is installed on its
2
- # own. It owns the `cursor` (later `devin`, …) LLM routes and the
2
+ # own. It owns the `cursor` and `devin` LLM routes and the
3
3
  # `llm-omp-transports/<provider>` credential scope.
4
4
  - insert:
5
5
  - id: llm-omp-transports
package/lib/adapter.d.ts CHANGED
@@ -1,15 +1,16 @@
1
1
  /**
2
- * Adapter for the omp-owned `cursor` route.
2
+ * Adapter for the omp-owned routes this plugin serves.
3
3
  *
4
- * The route speaks Cursor's own agent protocol (`agent.v1.AgentService/Run`
5
- * over HTTP/2) through the omp build artifact in `lib/omp/cursor.mjs`. The
4
+ * Two routes share one shape: the provider speaks its own agent protocol
5
+ * (Cursor's `agent.v1.AgentService/Run`, Devin's Connect-framed
6
+ * `GetChatMessage`) through an omp build artifact in `lib/omp/*.mjs`. The
6
7
  * transport is injected rather than imported so this module stays free of the
7
- * 14 MB build artifact and tests can replay recorded event scripts. The plugin
8
- * wires the bundled `streamCursor` at registration and the credential seam
9
- * provides {@link OmpCursorAdapterConfig.access}, which refreshes an expiring
10
- * grant under the store's lock before it answers.
8
+ * bundled artifacts and tests can replay recorded event scripts. A
9
+ * {@link TransportRoute} carries what differs per route: the catalog, the
10
+ * projection and the credential key; the base class carries the shared
11
+ * credential/turn ordering.
11
12
  *
12
- * The catalog is the generated `src/catalog/cursor.ts`, so `listModels` and
13
+ * The catalogs are the generated `src/catalog/*.ts`, so `listModels` and
13
14
  * `resolveModel` answer without a network call and carry the transport flags the
14
15
  * projection needs (effort routing, max mode, glyph tokenization).
15
16
  *
@@ -17,48 +18,132 @@
17
18
  */
18
19
  import { LlmAdapter } from '@deepseek-ai/dsh-llm';
19
20
  import type { GenerateOptions, LlmModelInfo, LlmProviderInfo, LlmResolvedModelInfo, StreamChunk } from '@deepseek-ai/dsh-llm';
20
- import type { OmpCursorTransport } from './omp.js';
21
- /** The provider route this adapter owns. */
21
+ import type { RouteProfile } from './projection.js';
22
+ import type { OmpAssistantMessageEvent, OmpContext } from './omp.js';
23
+ import type { CursorModelRow, DevinModelRow, OmpCursorModel, OmpCursorOptions, OmpDevinModel, OmpDevinOptions } from './omp.js';
24
+ /** The Cursor provider route this adapter owns. */
22
25
  export declare const CURSOR_ROUTE = "cursor";
26
+ /** The Devin provider route this adapter owns. */
27
+ export declare const DEVIN_ROUTE = "devin";
23
28
  /** Machine code for a model id the generated catalog does not contain. */
24
29
  export declare const UNKNOWN_MODEL = "UNKNOWN_MODEL";
25
30
  /** Machine code for a provider route this adapter does not serve. */
26
31
  export declare const UNKNOWN_PROVIDER = "UNKNOWN_PROVIDER";
27
- /** What the adapter needs from its host plugin. */
28
- export interface OmpCursorAdapterConfig {
32
+ /** The catalog fields every route's row must carry. */
33
+ interface TransportRow {
34
+ readonly id: string;
35
+ readonly name: string;
36
+ readonly contextWindow: number;
37
+ }
38
+ /** The transport options both routes accept at their shared surface. */
39
+ interface TransportOptions {
40
+ readonly apiKey?: string;
41
+ readonly signal?: AbortSignal;
42
+ }
43
+ /** One omp transport function, narrowed to the plugin's event contract. */
44
+ export type OmpTransportOf<Model, Options> = (model: Model, context: OmpContext, options: Options) => AsyncIterable<OmpAssistantMessageEvent>;
45
+ /** The three positional transport arguments a projection produces. */
46
+ export interface ProjectedTransportRequest<Model, Options> {
47
+ readonly model: Model;
48
+ readonly context: OmpContext;
49
+ /** Transport options without the credential; the adapter injects `apiKey`. */
50
+ readonly options: Omit<Options, 'apiKey'> & {
51
+ readonly apiKey?: string;
52
+ };
53
+ }
54
+ /** What differs between the routes: identity, catalog, projection and credential record. */
55
+ export interface TransportRoute<Row extends TransportRow, Model, Options extends TransportOptions> {
56
+ /** Provider id; also the registered route set the projection's profile accepts. */
57
+ readonly id: 'cursor' | 'devin';
58
+ /** Models-page / provider-info display name. */
59
+ readonly displayName: string;
60
+ /** The `ctx.credentials` record this route reads. */
61
+ readonly credentialKey: string;
62
+ /** Projection facts: identity, fallback error code and transport-resolved marker. */
63
+ readonly profile: RouteProfile;
64
+ /** The generated catalog. */
65
+ readonly models: readonly Row[];
66
+ /** Project one DSH request onto this route's transport arguments. */
67
+ readonly project: (row: Row, options: GenerateOptions) => ProjectedTransportRequest<Model, Options>;
68
+ /**
69
+ * The row's advertised reasoning efforts.
70
+ *
71
+ * Cursor's rows carry `thinking.efforts`; Devin's rows advertise none (a
72
+ * selected effort is refused by its projection), so the route may omit this.
73
+ */
74
+ readonly efforts?: (row: Row) => readonly string[] | undefined;
75
+ }
76
+ /** The Cursor route's facts. */
77
+ export declare const CURSOR_TRANSPORT_ROUTE: TransportRoute<CursorModelRow, OmpCursorModel, OmpCursorOptions>;
78
+ /** The Devin route's facts. */
79
+ export declare const DEVIN_TRANSPORT_ROUTE: TransportRoute<DevinModelRow, OmpDevinModel, OmpDevinOptions>;
80
+ /** What an adapter needs from its host plugin. */
81
+ export interface OmpAdapterOptions<Model, Options extends TransportOptions> {
29
82
  /**
30
- * Resolve the Cursor bearer token for one request.
83
+ * Resolve the route's bearer token for one request.
31
84
  *
32
85
  * @remarks
33
- * Asynchronous because it reads and refreshes the `llm-omp-transports/cursor`
86
+ * Asynchronous because it reads (and, for Cursor, refreshes) the route's
34
87
  * credential through the credentials seam. The request signal is forwarded
35
88
  * so an aborted turn can abandon a refresh instead of writing it late. Tests
36
89
  * inject a fake.
37
90
  */
38
91
  access: (signal?: AbortSignal) => Promise<string>;
92
+ /** The omp transport, normally the artifact's stream export. Tests script it. */
93
+ transport: OmpTransportOf<Model, Options>;
39
94
  /**
40
- * The omp transport, normally the `streamCursor` export of
41
- * `lib/omp/cursor.mjs`. The seam tests drive it with recorded event scripts.
42
- */
43
- transport: OmpCursorTransport;
44
- }
45
- /** The DSH llm adapter for every route this plugin's omp transport serves. */
46
- export declare class OmpCursorAdapter extends LlmAdapter {
47
- private readonly config;
48
- constructor(config: OmpCursorAdapterConfig);
49
- /**
50
- * Describe the route.
95
+ * Read the configured allow-list of catalog ids.
51
96
  *
52
97
  * @remarks
53
- * Cursor's agent protocol takes no client-side output cap, sampling
54
- * temperature, stop sequence or auxiliary-call purpose: the wire carries no
55
- * field for any of them, so the projection ignores those `GenerateOptions`
56
- * values instead of forwarding them. Cursor applies the catalog `maxTokens`
57
- * limit server-side.
98
+ * A getter because the profile is a volatile setting: a save updates the
99
+ * running config reference without re-running the plugin, so a captured
100
+ * array would go stale. An absent or empty list advertises the full catalog,
101
+ * so the schema default (`providers.<route>.models: []`) is today's behavior;
102
+ * a non-empty list narrows the advertised models and the accepted ids.
58
103
  */
104
+ models?: () => readonly string[] | undefined;
105
+ }
106
+ /** The adapter configuration for one concrete route. */
107
+ interface OmpRouteAdapterConfig<Row extends TransportRow, Model, Options extends TransportOptions> extends OmpAdapterOptions<Model, Options> {
108
+ readonly route: TransportRoute<Row, Model, Options>;
109
+ }
110
+ /**
111
+ * The DSH llm adapter for one omp-backed route.
112
+ *
113
+ * @remarks
114
+ * The per-turn order is fixed: refuse an already-aborted turn, resolve the row,
115
+ * project the request (refusals must not pay a credential read), read the
116
+ * credential, validate it, then stream. Cursor's grant can be refreshed under
117
+ * that read; Devin's resolver only reads.
118
+ */
119
+ declare abstract class OmpTransportAdapter<Row extends TransportRow, Model, Options extends TransportOptions> extends LlmAdapter {
120
+ private readonly config;
121
+ private readonly rows;
122
+ protected constructor(config: OmpRouteAdapterConfig<Row, Model, Options>);
123
+ /** The configured ids, or undefined when the route advertises the full catalog. */
124
+ private allowed;
125
+ /** Resolve one catalog row, refusing ids the configured allow-list excludes. */
126
+ private rowFor;
59
127
  providerInfo(provider: string): LlmProviderInfo;
60
128
  listModels(provider: string): Promise<readonly LlmModelInfo[]>;
61
129
  resolveModel(provider: string, model: string): Promise<LlmResolvedModelInfo>;
62
130
  stream(options: GenerateOptions): AsyncIterable<StreamChunk>;
131
+ /** Refuse routes this adapter does not own instead of describing another provider's models. */
132
+ private assertRoute;
63
133
  private call;
134
+ /** Build the seam's exact-model metadata from one catalog row. */
135
+ private modelInfo;
136
+ }
137
+ /** The DSH llm adapter configuration for the Cursor route. */
138
+ export type OmpCursorAdapterConfig = OmpAdapterOptions<OmpCursorModel, OmpCursorOptions>;
139
+ /** The Cursor adapter: the bundled `streamCursor` over the generated Cursor catalog. */
140
+ export declare class OmpCursorAdapter extends OmpTransportAdapter<CursorModelRow, OmpCursorModel, OmpCursorOptions> {
141
+ constructor(options: OmpCursorAdapterConfig);
142
+ }
143
+ /** The DSH llm adapter configuration for the Devin route. */
144
+ export type OmpDevinAdapterConfig = OmpAdapterOptions<OmpDevinModel, OmpDevinOptions>;
145
+ /** The Devin adapter: the bundled `streamDevin` over the generated Devin catalog. */
146
+ export declare class OmpDevinAdapter extends OmpTransportAdapter<DevinModelRow, OmpDevinModel, OmpDevinOptions> {
147
+ constructor(options: OmpDevinAdapterConfig);
64
148
  }
149
+ export {};
package/lib/adapter.js CHANGED
@@ -1,15 +1,16 @@
1
1
  /**
2
- * Adapter for the omp-owned `cursor` route.
2
+ * Adapter for the omp-owned routes this plugin serves.
3
3
  *
4
- * The route speaks Cursor's own agent protocol (`agent.v1.AgentService/Run`
5
- * over HTTP/2) through the omp build artifact in `lib/omp/cursor.mjs`. The
4
+ * Two routes share one shape: the provider speaks its own agent protocol
5
+ * (Cursor's `agent.v1.AgentService/Run`, Devin's Connect-framed
6
+ * `GetChatMessage`) through an omp build artifact in `lib/omp/*.mjs`. The
6
7
  * transport is injected rather than imported so this module stays free of the
7
- * 14 MB build artifact and tests can replay recorded event scripts. The plugin
8
- * wires the bundled `streamCursor` at registration and the credential seam
9
- * provides {@link OmpCursorAdapterConfig.access}, which refreshes an expiring
10
- * grant under the store's lock before it answers.
8
+ * bundled artifacts and tests can replay recorded event scripts. A
9
+ * {@link TransportRoute} carries what differs per route: the catalog, the
10
+ * projection and the credential key; the base class carries the shared
11
+ * credential/turn ordering.
11
12
  *
12
- * The catalog is the generated `src/catalog/cursor.ts`, so `listModels` and
13
+ * The catalogs are the generated `src/catalog/*.ts`, so `listModels` and
13
14
  * `resolveModel` answer without a network call and carry the transport flags the
14
15
  * projection needs (effort routing, max mode, glyph tokenization).
15
16
  *
@@ -17,10 +18,14 @@
17
18
  */
18
19
  import { LlmAdapter, LlmError, ReasoningEffortId, assertUsableApiKey } from '@deepseek-ai/dsh-llm';
19
20
  import { CURSOR_MODELS } from './catalog/cursor.js';
21
+ import { DEVIN_MODELS } from './catalog/devin.js';
20
22
  import { CURSOR_CREDENTIAL_KEY } from './cursor/credentials.js';
21
- import { abortedFinish, projectEvents, projectRequest } from './projection.js';
22
- /** The provider route this adapter owns. */
23
+ import { DEVIN_CREDENTIAL_KEY } from './devin/credentials.js';
24
+ import { CURSOR_PROFILE, DEVIN_PROFILE, abortedFinish, projectDevinRequest, projectEvents, projectRequest } from './projection.js';
25
+ /** The Cursor provider route this adapter owns. */
23
26
  export const CURSOR_ROUTE = 'cursor';
27
+ /** The Devin provider route this adapter owns. */
28
+ export const DEVIN_ROUTE = 'devin';
24
29
  /** Machine code for a model id the generated catalog does not contain. */
25
30
  export const UNKNOWN_MODEL = 'UNKNOWN_MODEL';
26
31
  /** Machine code for a provider route this adapter does not serve. */
@@ -28,11 +33,11 @@ export const UNKNOWN_PROVIDER = 'UNKNOWN_PROVIDER';
28
33
  /**
29
34
  * Input modalities every advertised row carries.
30
35
  *
31
- * shortcut: the projection carries text only and refuses every non-text block
36
+ * shortcut: both projections carry text only and refuse every non-text block
32
37
  * with `CONTENT_UNSUPPORTED`, so advertising the catalog row's `input` verbatim
33
- * (100 of 123 rows say `image`) would promise a turn this route fails after
34
- * DSH's own image→text fallback is skipped. Task 2/3 add image forwarding; that
35
- * is when `row.input` becomes advertisable again.
38
+ * would promise a turn this route fails after DSH's own image→text fallback is
39
+ * skipped. Task 2/3 add image forwarding; that is when `row.input` becomes
40
+ * advertisable again.
36
41
  */
37
42
  const INPUT_MODALITIES = ['text'];
38
43
  /** Display names for the catalog's reasoning efforts. */
@@ -44,31 +49,66 @@ const EFFORT_NAMES = {
44
49
  xhigh: 'Extra high',
45
50
  max: 'Max',
46
51
  };
47
- /** The generated catalog, indexed for exact-model resolution. */
48
- const MODELS_BY_ID = new Map(CURSOR_MODELS.map(row => [row.id, row]));
49
- /** The DSH llm adapter for every route this plugin's omp transport serves. */
50
- export class OmpCursorAdapter extends LlmAdapter {
52
+ /** The Cursor route's facts. */
53
+ export const CURSOR_TRANSPORT_ROUTE = {
54
+ id: CURSOR_ROUTE,
55
+ displayName: 'Cursor',
56
+ credentialKey: CURSOR_CREDENTIAL_KEY,
57
+ profile: CURSOR_PROFILE,
58
+ models: CURSOR_MODELS,
59
+ project: projectRequest,
60
+ efforts: row => row.thinking?.efforts,
61
+ };
62
+ /** The Devin route's facts. */
63
+ export const DEVIN_TRANSPORT_ROUTE = {
64
+ id: DEVIN_ROUTE,
65
+ displayName: 'Devin',
66
+ credentialKey: DEVIN_CREDENTIAL_KEY,
67
+ profile: DEVIN_PROFILE,
68
+ models: DEVIN_MODELS,
69
+ project: projectDevinRequest,
70
+ };
71
+ /**
72
+ * The DSH llm adapter for one omp-backed route.
73
+ *
74
+ * @remarks
75
+ * The per-turn order is fixed: refuse an already-aborted turn, resolve the row,
76
+ * project the request (refusals must not pay a credential read), read the
77
+ * credential, validate it, then stream. Cursor's grant can be refreshed under
78
+ * that read; Devin's resolver only reads.
79
+ */
80
+ class OmpTransportAdapter extends LlmAdapter {
51
81
  config;
82
+ rows;
52
83
  constructor(config) {
53
84
  super();
54
85
  this.config = config;
86
+ this.rows = new Map(config.route.models.map(row => [row.id, row]));
87
+ }
88
+ /** The configured ids, or undefined when the route advertises the full catalog. */
89
+ allowed() {
90
+ const models = this.config.models?.();
91
+ return models === undefined || models.length === 0 ? undefined : new Set(models);
92
+ }
93
+ /** Resolve one catalog row, refusing ids the configured allow-list excludes. */
94
+ rowFor(model) {
95
+ const row = this.rows.get(model);
96
+ const allowed = this.allowed();
97
+ if (row === undefined || (allowed !== undefined && !allowed.has(row.id))) {
98
+ throw new LlmError(`llm-omp-transports: the ${this.config.route.id} route has no model "${model}"`, UNKNOWN_MODEL);
99
+ }
100
+ return row;
55
101
  }
56
- /**
57
- * Describe the route.
58
- *
59
- * @remarks
60
- * Cursor's agent protocol takes no client-side output cap, sampling
61
- * temperature, stop sequence or auxiliary-call purpose: the wire carries no
62
- * field for any of them, so the projection ignores those `GenerateOptions`
63
- * values instead of forwarding them. Cursor applies the catalog `maxTokens`
64
- * limit server-side.
65
- */
66
102
  providerInfo(provider) {
67
- return { id: provider, name: 'Cursor' };
103
+ this.assertRoute(provider);
104
+ return { id: provider, name: this.config.route.displayName };
68
105
  }
69
106
  async listModels(provider) {
70
- assertRoute(provider);
71
- return CURSOR_MODELS.map(row => ({
107
+ this.assertRoute(provider);
108
+ const allowed = this.allowed();
109
+ return this.config.route.models
110
+ .filter(row => allowed === undefined || allowed.has(row.id))
111
+ .map(row => ({
72
112
  provider,
73
113
  id: row.id,
74
114
  name: row.name,
@@ -76,27 +116,32 @@ export class OmpCursorAdapter extends LlmAdapter {
76
116
  }));
77
117
  }
78
118
  async resolveModel(provider, model) {
79
- assertRoute(provider);
80
- return modelInfo(provider, rowFor(model));
119
+ this.assertRoute(provider);
120
+ return this.modelInfo(provider, this.rowFor(model));
81
121
  }
82
122
  stream(options) {
83
123
  return this.call(options);
84
124
  }
125
+ /** Refuse routes this adapter does not own instead of describing another provider's models. */
126
+ assertRoute(provider) {
127
+ if (provider !== this.config.route.id) {
128
+ throw new LlmError(`llm-omp-transports: the ${this.config.route.id} adapter does not serve provider "${provider}"`, UNKNOWN_PROVIDER);
129
+ }
130
+ }
85
131
  async *call(options) {
86
132
  // Read the live signal each time: it can abort while the credential is read.
87
133
  const aborted = () => options.signal?.aborted === true;
88
- // An already-cancelled turn must not pay a credential read (nor, once the
89
- // resolver refreshes, a CAS write) or open a stream.
134
+ // An already-cancelled turn must not pay a credential read (nor, once Cursor
135
+ // refreshes, a CAS write) or open a stream.
90
136
  if (aborted()) {
91
137
  yield abortedFinish();
92
138
  return;
93
139
  }
94
- const row = rowFor(options.model);
140
+ const row = this.rowFor(options.model);
95
141
  // Validate and project before touching the credential: a refused request
96
- // must not pay a credential read (nor, once the resolver refreshes, a CAS
97
- // write). Only a request that can be served resolves `access` and carries
98
- // its token into the transport options.
99
- const request = projectRequest(row, options);
142
+ // must not pay a credential read. Only a request that can be served
143
+ // resolves `access` and carries its token into the transport options.
144
+ const request = this.config.route.project(row, options);
100
145
  let credential;
101
146
  try {
102
147
  credential = await this.config.access(options.signal);
@@ -110,58 +155,56 @@ export class OmpCursorAdapter extends LlmAdapter {
110
155
  yield abortedFinish();
111
156
  return;
112
157
  }
113
- const accessKey = assertUsableApiKey(credential, 'llm-omp-transports', CURSOR_CREDENTIAL_KEY);
158
+ const accessKey = assertUsableApiKey(credential, 'llm-omp-transports', this.config.route.credentialKey);
114
159
  if (aborted()) {
115
160
  yield abortedFinish();
116
161
  return;
117
162
  }
118
163
  const transportOptions = { ...request.options, apiKey: accessKey };
119
- yield* projectEvents(this.config.transport(request.model, request.context, transportOptions), options.signal);
164
+ yield* projectEvents(this.config.transport(request.model, request.context, transportOptions), options.signal, this.config.route.profile);
120
165
  }
121
- }
122
- /** Resolve one catalog row, refusing ids the pinned catalog does not serve. */
123
- function rowFor(model) {
124
- const row = MODELS_BY_ID.get(model);
125
- if (row === undefined) {
126
- throw new LlmError(`llm-omp-transports: the cursor route has no model "${model}"`, UNKNOWN_MODEL);
166
+ /** Build the seam's exact-model metadata from one catalog row. */
167
+ modelInfo(provider, row) {
168
+ const efforts = this.config.route.efforts?.(row) ?? [];
169
+ return {
170
+ provider,
171
+ id: row.id,
172
+ name: row.name,
173
+ inputModalities: [...INPUT_MODALITIES],
174
+ context: { contextWindow: row.contextWindow },
175
+ // No `defaultMaxTokens`. The seam materializes that number into
176
+ // `maxTokens` on every request that omits one; Cursor's wire has no
177
+ // per-request output-cap field, and Devin's projection forwards an
178
+ // explicit `maxTokens` but the transport already defaults to the row's
179
+ // `maxTokens`. Advertising a default would only promise a cap nothing
180
+ // enforces. Both catalogs apply their cap from the model object.
181
+ // Every effort list is advertised exactly as the catalog declares it. On
182
+ // a row with no `effortRouting` entry each advertised effort resolves to
183
+ // the same wire id — the row's own — so those selections are wire-level
184
+ // no-ops, exactly as in omp.
185
+ ...(efforts.length > 0
186
+ ? {
187
+ reasoning: {
188
+ efforts: efforts.map(effort => ({
189
+ id: ReasoningEffortId(effort),
190
+ name: EFFORT_NAMES[effort] ?? effort,
191
+ })),
192
+ },
193
+ }
194
+ : {}),
195
+ };
127
196
  }
128
- return row;
129
197
  }
130
- /** Refuse routes this adapter does not own instead of describing another provider's models. */
131
- function assertRoute(provider) {
132
- if (provider !== CURSOR_ROUTE) {
133
- throw new LlmError(`llm-omp-transports: the cursor adapter does not serve provider "${provider}"`, UNKNOWN_PROVIDER);
198
+ /** The Cursor adapter: the bundled `streamCursor` over the generated Cursor catalog. */
199
+ export class OmpCursorAdapter extends OmpTransportAdapter {
200
+ constructor(options) {
201
+ super({ route: CURSOR_TRANSPORT_ROUTE, ...options });
134
202
  }
135
203
  }
136
- /** Build the seam's exact-model metadata from one catalog row. */
137
- function modelInfo(provider, row) {
138
- const efforts = row.thinking?.efforts ?? [];
139
- return {
140
- provider,
141
- id: row.id,
142
- name: row.name,
143
- inputModalities: [...INPUT_MODALITIES],
144
- context: { contextWindow: row.contextWindow },
145
- // No `defaultMaxTokens`. The seam materializes that number into `maxTokens`
146
- // on every request that omits one, and Cursor's wire has no per-request
147
- // output-cap field: the projection ignores `maxTokens` rather than
148
- // forwarding it, so advertising a default would only promise a cap nothing
149
- // enforces. Cursor applies the catalog cap server-side, from the `maxTokens`
150
- // the model object already carries.
151
- // Every effort list is advertised exactly as the catalog declares it. On a
152
- // row with no `effortRouting` entry each advertised effort resolves to the
153
- // same wire id — the row's own — so those selections are wire-level no-ops,
154
- // exactly as in omp.
155
- ...(efforts.length > 0
156
- ? {
157
- reasoning: {
158
- efforts: efforts.map(effort => ({
159
- id: ReasoningEffortId(effort),
160
- name: EFFORT_NAMES[effort] ?? effort,
161
- })),
162
- },
163
- }
164
- : {}),
165
- };
204
+ /** The Devin adapter: the bundled `streamDevin` over the generated Devin catalog. */
205
+ export class OmpDevinAdapter extends OmpTransportAdapter {
206
+ constructor(options) {
207
+ super({ route: DEVIN_TRANSPORT_ROUTE, ...options });
208
+ }
166
209
  }
167
210
  //# sourceMappingURL=adapter.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"adapter.js","sourceRoot":"","sources":["../src/adapter.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AACH,OAAO,EAAE,UAAU,EAAE,QAAQ,EAAE,iBAAiB,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAA;AAUlG,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAA;AACnD,OAAO,EAAE,qBAAqB,EAAE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AiE;YACjE,yEAAyE;YACzE,yEAAyE;YACzE,wEAAwE;YACxE,6BAA6B;YAC7B,GAAG,CAAC,OAAO,CAAC,MAAM,GAAG,CAAC;gBACpB,CAAC,CAAC;oBACE,SAAS,EAAE;wBACT,OAAO,EAAE,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC;4BAC9B,EAAE,EAAE,iBAAiB,CAAC,MAAM,CAAC;4BAC7B,IAAI,EAAE,YAAY,CAAC,MAAM,CAAC,IAAI,MAAM;yBACrC,CAAC,CAAC;qBACJ;iBACF;gBACH,CAAC,CAAC,EAAE,CAAC;SACR,CAAA;IACH,CAAC;CACF;AAKD,wFAAwF;AACxF,MAAM,OAAO,gBAAiB,SAAQ,mBAAqE;IACzG,YAAY,OAA+B;QACzC,KAAK,CAAC,EAAE,KAAK,EAAE,sBAAsB,EAAE,GAAG,OAAO,EAAE,CAAC,CAAA;IACtD,CAAC;CACF;AAKD,qFAAqF;AACrF,MAAM,OAAO,eAAgB,SAAQ,mBAAkE;IACrG,YAAY,OAA8B;QACxC,KAAK,CAAC,EAAE,KAAK,EAAE,qBAAqB,EAAE,GAAG,OAAO,EAAE,CAAC,CAAA;IACrD,CAAC;CACF"}
@@ -0,0 +1,27 @@
1
+ /**
2
+ * Generated Devin model table — do not edit by hand.
3
+ *
4
+ * Source: `@oh-my-pi/pi-catalog@18.12.3` `src/models.json` key `devin`
5
+ * (2 rows, sha256:39fb09654ee3812043bc062e426d8e7aa13cd273435fa7b8a203a76246c8735c). Regenerate with `pnpm -C packages/llm-omp run generate:catalog`.
6
+ *
7
+ * The drift gate in `tests/build-devin.test.ts` pins the same package version
8
+ * and source hash, so an omp bump fails there before this table can describe
9
+ * the wrong models.
10
+ *
11
+ * Each row carries the resolved `compat` trio and the `reasoning` flag the
12
+ * transport dereferences, and no field the wire never reads.
13
+ *
14
+ * @module dsh-llm-omp-transports/catalog/devin
15
+ */
16
+ import type { DevinModelRow } from '../omp.js';
17
+ /** Provenance of {@link DEVIN_MODELS}. */
18
+ export declare const DEVIN_CATALOG_SOURCE: {
19
+ readonly package: "@oh-my-pi/pi-catalog";
20
+ readonly version: "18.12.3";
21
+ readonly file: "src/models.json";
22
+ readonly key: "devin";
23
+ readonly sourceHash: "sha256:39fb09654ee3812043bc062e426d8e7aa13cd273435fa7b8a203a76246c8735c";
24
+ readonly rowCount: 2;
25
+ };
26
+ /** Every Devin model the pinned catalog serves, sorted by id. */
27
+ export declare const DEVIN_MODELS: readonly DevinModelRow[];