@modelprofile.com/flexharness-agent 13.3.0 → 15.0.0
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_ts_agent/classes.sessionengine.d.ts +12 -0
- package/dist_ts_agent/classes.sessionengine.js +457 -190
- package/dist_ts_agent/index.d.ts +3 -1
- package/dist_ts_agent/index.js +2 -1
- package/dist_ts_agent/smartagent.contextcompaction.d.ts +61 -0
- package/dist_ts_agent/smartagent.contextcompaction.js +81 -0
- package/dist_ts_agent/smartagent.events.d.ts +15 -0
- package/dist_ts_agent/smartagent.events.js +1 -1
- package/dist_ts_agent/smartagent.interfaces.d.ts +26 -7
- package/dist_ts_agent/smartagent.interfaces.js +1 -1
- package/dist_ts_agent/smartagent.persistence.js +10 -1
- package/dist_ts_agent/smartagent.transactions.d.ts +1 -6
- package/dist_ts_agent/smartagent.transactions.js +24 -20
- package/package.json +2 -2
- package/readme.md +7 -7
- package/ts_agent/classes.sessionengine.ts +525 -232
- package/ts_agent/index.ts +15 -0
- package/ts_agent/readme.md +7 -7
- package/ts_agent/smartagent.contextcompaction.ts +127 -0
- package/ts_agent/smartagent.events.ts +16 -0
- package/ts_agent/smartagent.interfaces.ts +26 -7
- package/ts_agent/smartagent.persistence.ts +9 -0
- package/ts_agent/smartagent.transactions.ts +24 -19
|
@@ -10,6 +10,11 @@ export declare class AgentSessionEngine implements IAgentSession {
|
|
|
10
10
|
private readonly events;
|
|
11
11
|
private readonly eventIds;
|
|
12
12
|
private readonly generationHandles;
|
|
13
|
+
/**
|
|
14
|
+
* The latest usage reading of each open transactional generation, written onto its outcome. It
|
|
15
|
+
* lives as long as the generation's handle: its outcome commit or the session's close ends both.
|
|
16
|
+
*/
|
|
17
|
+
private readonly generationContextUsage;
|
|
13
18
|
private readonly unresolvedLeaseCleanups;
|
|
14
19
|
private sequence;
|
|
15
20
|
private persistenceRevision;
|
|
@@ -69,6 +74,13 @@ export declare class AgentSessionEngine implements IAgentSession {
|
|
|
69
74
|
getEvents(): readonly TAgentEvent[];
|
|
70
75
|
getModelMessages(): plugins.ModelMessage[];
|
|
71
76
|
private buildContext;
|
|
77
|
+
/**
|
|
78
|
+
* The session's context in tokens. The latest provider usage reading counts while the events it
|
|
79
|
+
* saw still build the same model messages and no compaction followed them; what came after it
|
|
80
|
+
* is estimated. Without such a reading the whole context is estimated.
|
|
81
|
+
*/
|
|
82
|
+
private measureContextTokens;
|
|
83
|
+
private latestContextUsage;
|
|
72
84
|
subscribe(listener: TAgentSessionChangeListener): () => void;
|
|
73
85
|
scheduleGenerate(options: IAgentScheduleGenerateOptions): Promise<IAgentGenerateResult>;
|
|
74
86
|
private startScheduledGeneration;
|