@autobe/agent 0.13.0 → 0.14.2
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/lib/AutoBeMockAgent.js +2 -1
- package/lib/AutoBeMockAgent.js.map +1 -1
- package/lib/constants/AutoBeSystemPromptConstant.d.ts +7 -9
- package/lib/constants/AutoBeSystemPromptConstant.js.map +1 -1
- package/lib/factory/getAutoBeGenerated.js +11 -1
- package/lib/factory/getAutoBeGenerated.js.map +1 -1
- package/lib/index.mjs +391 -236
- package/lib/index.mjs.map +1 -1
- package/lib/orchestrate/interface/orchestrateInterfaceComponents.js +1 -1
- package/lib/orchestrate/interface/orchestrateInterfaceComponents.js.map +1 -1
- package/lib/orchestrate/interface/orchestrateInterfaceEndpoints.js +1 -1
- package/lib/orchestrate/interface/orchestrateInterfaceEndpoints.js.map +1 -1
- package/lib/orchestrate/interface/orchestrateInterfaceOperations.js +107 -110
- package/lib/orchestrate/interface/orchestrateInterfaceOperations.js.map +1 -1
- package/lib/orchestrate/interface/transformInterfaceHistories.js +10 -0
- package/lib/orchestrate/interface/transformInterfaceHistories.js.map +1 -1
- package/lib/orchestrate/realize/orchestrateRealize.js +30 -8
- package/lib/orchestrate/realize/orchestrateRealize.js.map +1 -1
- package/lib/orchestrate/realize/{orchestrateRealizeDecorator.d.ts → orchestrateRealizeAuthorization.d.ts} +2 -2
- package/lib/orchestrate/realize/{orchestrateRealizeDecorator.js → orchestrateRealizeAuthorization.js} +104 -67
- package/lib/orchestrate/realize/orchestrateRealizeAuthorization.js.map +1 -0
- package/lib/orchestrate/realize/orchestrateRealizeCoder.js +51 -40
- package/lib/orchestrate/realize/orchestrateRealizeCoder.js.map +1 -1
- package/lib/orchestrate/realize/orchestrateRealizePlanner.d.ts +11 -2
- package/lib/orchestrate/realize/orchestrateRealizePlanner.js +2 -1
- package/lib/orchestrate/realize/orchestrateRealizePlanner.js.map +1 -1
- package/lib/orchestrate/realize/structures/IAutoBeRealizeCoderApplication.d.ts +148 -17
- package/lib/orchestrate/realize/structures/IAutoBeRealizeCompile.d.ts +10 -2
- package/lib/orchestrate/realize/structures/IAutoBeRealizeDecoratorApplication.d.ts +4 -4
- package/lib/orchestrate/realize/transformRealizeCoderHistories.js +58 -11
- package/lib/orchestrate/realize/transformRealizeCoderHistories.js.map +1 -1
- package/lib/orchestrate/realize/transformRealizeDecoratorCorrectHistories.d.ts +2 -3
- package/lib/orchestrate/realize/transformRealizeDecoratorCorrectHistories.js +15 -2
- package/lib/orchestrate/realize/transformRealizeDecoratorCorrectHistories.js.map +1 -1
- package/lib/orchestrate/realize/utils/AuthorizationFileSystem.d.ts +5 -0
- package/lib/orchestrate/realize/utils/AuthorizationFileSystem.js +10 -0
- package/lib/orchestrate/realize/utils/AuthorizationFileSystem.js.map +1 -0
- package/lib/orchestrate/realize/utils/replaceImportStatements.d.ts +3 -0
- package/lib/orchestrate/realize/utils/replaceImportStatements.js +65 -0
- package/lib/orchestrate/realize/utils/replaceImportStatements.js.map +1 -0
- package/lib/orchestrate/realize/writeCodeUntilCompilePassed.d.ts +2 -3
- package/lib/orchestrate/realize/writeCodeUntilCompilePassed.js +45 -24
- package/lib/orchestrate/realize/writeCodeUntilCompilePassed.js.map +1 -1
- package/package.json +5 -5
- package/src/AutoBeMockAgent.ts +3 -2
- package/src/constants/AutoBeSystemPromptConstant.ts +7 -9
- package/src/factory/getAutoBeGenerated.ts +20 -5
- package/src/orchestrate/interface/orchestrateInterfaceOperations.ts +26 -18
- package/src/orchestrate/interface/transformInterfaceHistories.ts +10 -0
- package/src/orchestrate/realize/orchestrateRealize.ts +32 -7
- package/src/orchestrate/realize/{orchestrateRealizeDecorator.ts → orchestrateRealizeAuthorization.ts} +90 -80
- package/src/orchestrate/realize/orchestrateRealizeCoder.ts +9 -30
- package/src/orchestrate/realize/orchestrateRealizePlanner.ts +13 -1
- package/src/orchestrate/realize/structures/IAutoBeRealizeCoderApplication.ts +150 -17
- package/src/orchestrate/realize/structures/IAutoBeRealizeCompile.ts +13 -2
- package/src/orchestrate/realize/structures/IAutoBeRealizeDecoratorApplication.ts +4 -4
- package/src/orchestrate/realize/transformRealizeCoderHistories.ts +55 -8
- package/src/orchestrate/realize/transformRealizeDecoratorCorrectHistories.ts +23 -3
- package/src/orchestrate/realize/utils/AuthorizationFileSystem.ts +10 -0
- package/src/orchestrate/realize/utils/replaceImportStatements.ts +85 -0
- package/src/orchestrate/realize/writeCodeUntilCompilePassed.ts +58 -33
- package/lib/orchestrate/realize/orchestrateRealizeDecorator.js.map +0 -1
package/lib/AutoBeMockAgent.js
CHANGED
|
@@ -79,7 +79,8 @@ class AutoBeMockAgent extends AutoBeAgentBase_1.AutoBeAgentBase {
|
|
|
79
79
|
const take = (type) => __awaiter(this, void 0, void 0, function* () {
|
|
80
80
|
var _a;
|
|
81
81
|
for (const s of this.getEventSnapshots(type)) {
|
|
82
|
-
|
|
82
|
+
const time = (_a = sleepMap[s.event.type]) !== null && _a !== void 0 ? _a : 500;
|
|
83
|
+
yield (0, tstl_1.sleep_for)((0, tstl_1.randint)(time * 0.2, time * 1.8));
|
|
83
84
|
void this.dispatch(s.event).catch(() => { });
|
|
84
85
|
this.token_usage_ = new AutoBeTokenUsage_1.AutoBeTokenUsage(s.tokenUsage);
|
|
85
86
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AutoBeMockAgent.js","sourceRoot":"","sources":["../src/AutoBeMockAgent.ts"],"names":[],"mappings":";;;;;;;;;;;;AAWA,+
|
|
1
|
+
{"version":3,"file":"AutoBeMockAgent.js","sourceRoot":"","sources":["../src/AutoBeMockAgent.ts"],"names":[],"mappings":";;;;;;;;;;;;AAWA,+BAAqD;AACrD,+BAA0B;AAE1B,uDAAoD;AAEpD,iEAA8D;AAC9D,mEAAgE;AAEhE,gBAAgB;AAChB,MAAa,eAAgB,SAAQ,iCAAe;IAMlD,YAAmB,KAA6B;QAC9C,KAAK,CAAC;YACJ,QAAQ,EAAE,GAAG,E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