@fungi.computer/darkroom 0.11.7 → 0.11.9

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/dist/index.d.ts CHANGED
@@ -1,7 +1,7 @@
1
1
  import * as z from "zod";
2
2
  import type { MediaAudioReferenceBytes } from "./audio-reference-types.js";
3
3
  import { type MediaVideoReferenceRole, type MediaCatalogue, type MediaVideoResolution, type MediaVideoAspectRatio } from "./model-catalog.js";
4
- export { mediaFailureStageSchema } from "./execution-error.js";
4
+ export { mediaFailureStageSchema, MediaExecutionError, MediaSafetyFilterRefusal, } from "./execution-error.js";
5
5
  export { MAX_AUDIO_REFERENCE_BODY_BYTES, MAX_AUDIO_REFERENCE_BYTES, } from "./audio-reference-types.js";
6
6
  export type { AudioReferenceMimeType, MediaAudioReferenceBytes, } from "./audio-reference-types.js";
7
7
  export { MAX_MEDIA_PROMPT_LENGTH, getMediaModel, getGatewayModel, MAX_REFERENCE_COUNT, listMediaModels, mediaCatalogueSchema, mediaCatalogueModelSchema, parseMediaCatalogue, mediaModelInputSchema, mediaModelSchema, mediaRequestedImageFormatSchema, mediaModels, mediaModelTierSchema, MediaSettingsError, mediaVideoModelIdSchema, mediaVideoResolutionSchema, mediaVideoAspectRatioSchema, mediaVideoReferenceRoleSchema, mediaVideoFormatSchema, mediaVideoSchema, mediaAudioModelIdSchema, mediaAudioSchema, mediaAudioVoiceSchema, mediaBillingUnitSchema, AUDIO_CHARACTER_BLOCK, mediaTransformSchema, mediaTransformOperationSchema, } from "./model-catalog.js";
package/dist/index.js CHANGED
@@ -3,7 +3,7 @@ import { reportCatchFailure } from "./failure.js";
3
3
  import { sniffImageFormat } from "./media-content-type.js";
4
4
  import { referenceImageSizeIsValid } from "./reference-image-size.js";
5
5
  import { getGatewayModel, getMediaModel, mediaAudioModelIdSchema, MAX_REFERENCE_COUNT, MediaSettingsError, mediaModels, mediaVideoModelIdSchema, mediaVideoResolutionSchema, mediaVideoAspectRatioSchema, mediaVideoReferenceRoleSchema, MAX_MEDIA_PROMPT_LENGTH, transformMilliunits, } from "./model-catalog.js";
6
- export { mediaFailureStageSchema } from "./execution-error.js";
6
+ export { mediaFailureStageSchema, MediaExecutionError, MediaSafetyFilterRefusal, } from "./execution-error.js";
7
7
  export { MAX_AUDIO_REFERENCE_BODY_BYTES, MAX_AUDIO_REFERENCE_BYTES, } from "./audio-reference-types.js";
8
8
  export { MAX_MEDIA_PROMPT_LENGTH, getMediaModel, getGatewayModel, MAX_REFERENCE_COUNT, listMediaModels, mediaCatalogueSchema, mediaCatalogueModelSchema, parseMediaCatalogue, mediaModelInputSchema, mediaModelSchema, mediaRequestedImageFormatSchema, mediaModels, mediaModelTierSchema, MediaSettingsError, mediaVideoModelIdSchema, mediaVideoResolutionSchema, mediaVideoAspectRatioSchema, mediaVideoReferenceRoleSchema, mediaVideoFormatSchema, mediaVideoSchema, mediaAudioModelIdSchema, mediaAudioSchema, mediaAudioVoiceSchema, mediaBillingUnitSchema, AUDIO_CHARACTER_BLOCK, mediaTransformSchema, mediaTransformOperationSchema, } from "./model-catalog.js";
9
9
  /** The long-edge bounds a viewer may ask for when fitting an image to look at. */
@@ -36,4 +36,4 @@ admission, billing and destination-write sequence.
36
36
 
37
37
  `Effect`\<[`MediaGenerationOutcome`](server.md#mediagenerationoutcome), \|
38
38
  [`MediaSettingsError`](index.md#mediasettingserror) \|
39
- [`MediaExecutionError`](server.md#mediaexecutionerror)\>
39
+ [`MediaExecutionError`](index.md#mediaexecutionerror)\>
package/docs/api/index.md CHANGED
@@ -10,6 +10,141 @@
10
10
 
11
11
  ## Classes
12
12
 
13
+ ### MediaExecutionError
14
+
15
+ A bounded stage marker for failures that cross the Media HTTP boundary.
16
+
17
+ #### Extends
18
+
19
+ - `Error`
20
+
21
+ #### Extended by
22
+
23
+ - [`MediaSafetyFilterRefusal`](#mediasafetyfilterrefusal)
24
+
25
+ #### Constructors
26
+
27
+ ##### Constructor
28
+
29
+ ```ts
30
+ new MediaExecutionError(stage, options?): MediaExecutionError;
31
+ ```
32
+
33
+ ###### Parameters
34
+
35
+ | Parameter | Type | Description |
36
+ | ---------- | -------------------------------------------------------------------- | ------------------------------------------- |
37
+ | `stage` | [`MediaFailureStage`](server.md#mediafailurestage) | Execution stage where the failure occurred. |
38
+ | `options?` | [`MediaExecutionErrorOptions`](server.md#mediaexecutionerroroptions) | - |
39
+
40
+ ###### Returns
41
+
42
+ [`MediaExecutionError`](#mediaexecutionerror)
43
+
44
+ ###### Overrides
45
+
46
+ ```ts
47
+ Error.constructor;
48
+ ```
49
+
50
+ #### Properties
51
+
52
+ ##### provider
53
+
54
+ ```ts
55
+ readonly provider: MediaProviderDiagnostic | undefined;
56
+ ```
57
+
58
+ Safe provider facts only; the original cause remains private.
59
+
60
+ ##### customerCharge
61
+
62
+ ```ts
63
+ readonly customerCharge: "none" | "unknown";
64
+ ```
65
+
66
+ Unknown unless the execution owner confirmed zero-unit settlement.
67
+
68
+ ##### stage
69
+
70
+ ```ts
71
+ readonly stage: MediaFailureStage;
72
+ ```
73
+
74
+ Execution stage where the failure occurred.
75
+
76
+ ---
77
+
78
+ ### MediaSafetyFilterRefusal
79
+
80
+ A provider safety filter refused generation; no output was delivered.
81
+
82
+ #### Extends
83
+
84
+ - [`MediaExecutionError`](#mediaexecutionerror)
85
+
86
+ #### Constructors
87
+
88
+ ##### Constructor
89
+
90
+ ```ts
91
+ new MediaSafetyFilterRefusal(options?): MediaSafetyFilterRefusal;
92
+ ```
93
+
94
+ ###### Parameters
95
+
96
+ | Parameter | Type |
97
+ | ---------- | -------------------------------------------------------------------- |
98
+ | `options?` | [`MediaExecutionErrorOptions`](server.md#mediaexecutionerroroptions) |
99
+
100
+ ###### Returns
101
+
102
+ [`MediaSafetyFilterRefusal`](#mediasafetyfilterrefusal)
103
+
104
+ ###### Overrides
105
+
106
+ [`MediaExecutionError`](#mediaexecutionerror).[`constructor`](#constructor)
107
+
108
+ #### Properties
109
+
110
+ ##### provider
111
+
112
+ ```ts
113
+ readonly provider: MediaProviderDiagnostic | undefined;
114
+ ```
115
+
116
+ Safe provider facts only; the original cause remains private.
117
+
118
+ ###### Inherited from
119
+
120
+ [`MediaExecutionError`](#mediaexecutionerror).[`provider`](#provider)
121
+
122
+ ##### customerCharge
123
+
124
+ ```ts
125
+ readonly customerCharge: "none" | "unknown";
126
+ ```
127
+
128
+ Unknown unless the execution owner confirmed zero-unit settlement.
129
+
130
+ ###### Inherited from
131
+
132
+ [`MediaExecutionError`](#mediaexecutionerror).[`customerCharge`](#customercharge)
133
+
134
+ ##### stage
135
+
136
+ ```ts
137
+ readonly stage: MediaFailureStage;
138
+ ```
139
+
140
+ Execution stage where the failure occurred.
141
+
142
+ ###### Inherited from
143
+
144
+ [`MediaExecutionError`](#mediaexecutionerror).[`stage`](#stage)
145
+
146
+ ---
147
+
13
148
  ### MediaSettingsError
14
149
 
15
150
  Invalid generation settings or unsupported model parameters.
@@ -78,67 +78,6 @@ Keep the hold when media was delivered; release it when nothing was.
78
78
 
79
79
  ---
80
80
 
81
- ### MediaExecutionError
82
-
83
- A bounded stage marker for failures that cross the Media HTTP boundary.
84
-
85
- #### Extends
86
-
87
- - `Error`
88
-
89
- #### Constructors
90
-
91
- ##### Constructor
92
-
93
- ```ts
94
- new MediaExecutionError(stage, options?): MediaExecutionError;
95
- ```
96
-
97
- ###### Parameters
98
-
99
- | Parameter | Type | Description |
100
- | ---------- | ----------------------------------------------------------- | ------------------------------------------- |
101
- | `stage` | [`MediaFailureStage`](#mediafailurestage) | Execution stage where the failure occurred. |
102
- | `options?` | [`MediaExecutionErrorOptions`](#mediaexecutionerroroptions) | - |
103
-
104
- ###### Returns
105
-
106
- [`MediaExecutionError`](#mediaexecutionerror)
107
-
108
- ###### Overrides
109
-
110
- ```ts
111
- Error.constructor;
112
- ```
113
-
114
- #### Properties
115
-
116
- ##### provider
117
-
118
- ```ts
119
- readonly provider: MediaProviderDiagnostic | undefined;
120
- ```
121
-
122
- Safe provider facts only; the original cause remains private.
123
-
124
- ##### customerCharge
125
-
126
- ```ts
127
- readonly customerCharge: "none" | "unknown";
128
- ```
129
-
130
- Unknown unless the execution owner confirmed zero-unit settlement.
131
-
132
- ##### stage
133
-
134
- ```ts
135
- readonly stage: MediaFailureStage;
136
- ```
137
-
138
- Execution stage where the failure occurred.
139
-
140
- ---
141
-
142
81
  ### MediaBillingRefusal
143
82
 
144
83
  A definitive billing refusal before dispatch; nothing was generated or charged.
@@ -2931,3 +2870,9 @@ access.
2931
2870
  #### Returns
2932
2871
 
2933
2872
  `Hono`\<`BlankEnv`, `BlankSchema`, `"/"`\>
2873
+
2874
+ ## References
2875
+
2876
+ ### MediaExecutionError
2877
+
2878
+ Re-exports [MediaExecutionError](index.md#mediaexecutionerror)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fungi.computer/darkroom",
3
- "version": "0.11.7",
3
+ "version": "0.11.9",
4
4
  "author": "Levi <levi@technomancy.dev>",
5
5
  "description": "Media generation, durable output retention and provenance with host-owned authority and billing",
6
6
  "type": "module",
@@ -60,7 +60,7 @@
60
60
  "exifreader": "4.46.0",
61
61
  "@fungi.computer/ts-webp": "0.1.6",
62
62
  "@xmldom/xmldom": "0.9.12",
63
- "@fungi.computer/agar": "0.22.1",
63
+ "@fungi.computer/agar": "0.23.1",
64
64
  "@fungi.computer/capnweb": "0.12.0-fungi.0"
65
65
  },
66
66
  "devDependencies": {