@ego-z/contracts 0.15.29 → 0.15.31
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/package.json +1 -1
- package/src/ask.d.ts +7 -0
- package/src/project-file.d.ts +1 -1
- package/src/thread.d.ts +12 -2
package/package.json
CHANGED
package/src/ask.d.ts
CHANGED
|
@@ -733,6 +733,13 @@ export interface AskContextUsage {
|
|
|
733
733
|
byPart: AskContextParts;
|
|
734
734
|
/** Earlier messages left out to fit the budget. `0` when all of them fit. */
|
|
735
735
|
historyDropped: number;
|
|
736
|
+
/**
|
|
737
|
+
* The factor EgoZ multiplied its raw estimate by: the provider's count
|
|
738
|
+
* over EgoZ's raw estimate on the conversation's previous turn on the
|
|
739
|
+
* same model, so `estimated` here is already corrected. `1` when there
|
|
740
|
+
* was none. Absent from turns made before it existed.
|
|
741
|
+
*/
|
|
742
|
+
correction?: number;
|
|
736
743
|
/**
|
|
737
744
|
* `true` when the provider refused a prompt as too long and EgoZ sent a
|
|
738
745
|
* smaller one. It retries once; a second refusal ends the turn with
|
package/src/project-file.d.ts
CHANGED
|
@@ -145,7 +145,7 @@ export interface ProjectFileConfig {
|
|
|
145
145
|
* The project's cap on the tokens one model call's prompt may use,
|
|
146
146
|
* 1,000..2,000,000. `null` = no cap: the answering model's window sets
|
|
147
147
|
* the budget. Absent from files made before it existed; an import then
|
|
148
|
-
*
|
|
148
|
+
* gives the project a new project's value, no cap.
|
|
149
149
|
*/
|
|
150
150
|
contextBudgetTokens?: number | null;
|
|
151
151
|
orchestrationMode: OrchestrationMode;
|
package/src/thread.d.ts
CHANGED
|
@@ -18,6 +18,7 @@
|
|
|
18
18
|
* `formatThread` and `formatMessage` now emit ISO to match.
|
|
19
19
|
*/
|
|
20
20
|
|
|
21
|
+
import type { AskContextUsage } from './ask';
|
|
21
22
|
import type { Intent } from './envelope';
|
|
22
23
|
|
|
23
24
|
// ============================================================================
|
|
@@ -39,8 +40,10 @@ export type MessageFailureReason =
|
|
|
39
40
|
| 'iteration_cap'
|
|
40
41
|
| 'max_calls_per_turn'
|
|
41
42
|
| 'unrecoverable_error'
|
|
42
|
-
/** The
|
|
43
|
-
*
|
|
43
|
+
/** The turn ran out of room in the answering model's context, so EgoZ
|
|
44
|
+
* stopped offering tools and the model answered from what it had
|
|
45
|
+
* (migration 074). A prompt that can't be sent at all is not stored:
|
|
46
|
+
* the turn fails with `ContextBudgetExceeded` (`EGX_ERR-LLM04`). */
|
|
44
47
|
| 'context_budget';
|
|
45
48
|
|
|
46
49
|
/**
|
|
@@ -187,6 +190,13 @@ export interface MessageWire {
|
|
|
187
190
|
model: string | null;
|
|
188
191
|
/** Echo of `AskRequestBody.metadata` for audit. */
|
|
189
192
|
metadata: Record<string, unknown> | null;
|
|
193
|
+
/**
|
|
194
|
+
* On an assistant row, how much of the answering model's context the
|
|
195
|
+
* turn used: the same value as that turn's `AskResponseData.context`
|
|
196
|
+
* (migration 074). `null` on other rows and on turns made before it
|
|
197
|
+
* existed. Absent from servers that predate it.
|
|
198
|
+
*/
|
|
199
|
+
context?: AskContextUsage | null;
|
|
190
200
|
/**
|
|
191
201
|
* `true` when this row's `content` was deliberately dropped under
|
|
192
202
|
* no-store (metadata-only) persistence — see
|