@inkeep/agents-core 0.0.0-dev-20260223201736 → 0.0.0-dev-20260223221253

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.
Files changed (35) hide show
  1. package/dist/auth/auth-schema.d.ts +107 -107
  2. package/dist/auth/auth-validation-schemas.d.ts +152 -152
  3. package/dist/auth/auth.d.ts +57 -57
  4. package/dist/auth/permissions.d.ts +13 -13
  5. package/dist/client-exports.d.ts +4 -4
  6. package/dist/data-access/manage/agents.d.ts +25 -25
  7. package/dist/data-access/manage/artifactComponents.d.ts +6 -6
  8. package/dist/data-access/manage/contextConfigs.d.ts +4 -4
  9. package/dist/data-access/manage/dataComponents.d.ts +4 -4
  10. package/dist/data-access/manage/functionTools.d.ts +8 -8
  11. package/dist/data-access/manage/skills.d.ts +6 -6
  12. package/dist/data-access/manage/subAgentExternalAgentRelations.d.ts +12 -12
  13. package/dist/data-access/manage/subAgentRelations.d.ts +12 -12
  14. package/dist/data-access/manage/subAgentTeamAgentRelations.d.ts +12 -12
  15. package/dist/data-access/manage/subAgents.d.ts +15 -15
  16. package/dist/data-access/manage/tools.d.ts +12 -12
  17. package/dist/data-access/manage/triggers.d.ts +1 -1
  18. package/dist/data-access/runtime/apiKeys.d.ts +8 -8
  19. package/dist/data-access/runtime/conversations.d.ts +23 -23
  20. package/dist/data-access/runtime/messages.d.ts +15 -15
  21. package/dist/data-access/runtime/tasks.d.ts +7 -7
  22. package/dist/db/manage/manage-schema.d.ts +447 -447
  23. package/dist/db/runtime/runtime-schema.d.ts +296 -296
  24. package/dist/index.d.ts +3 -2
  25. package/dist/index.js +3 -2
  26. package/dist/utils/error.d.ts +3 -1
  27. package/dist/utils/error.js +11 -1
  28. package/dist/utils/index.d.ts +3 -2
  29. package/dist/utils/index.js +3 -2
  30. package/dist/utils/retry.d.ts +8 -0
  31. package/dist/utils/retry.js +30 -0
  32. package/dist/validation/dolt-schemas.d.ts +1 -1
  33. package/dist/validation/drizzle-schema-helpers.d.ts +3 -3
  34. package/dist/validation/schemas.d.ts +1818 -1818
  35. package/package.json +1 -1
@@ -0,0 +1,8 @@
1
+ //#region src/utils/retry.d.ts
2
+ declare function retryWithBackoff<T>(fn: () => Promise<T>, opts?: {
3
+ maxAttempts?: number;
4
+ maxDelayMs?: number;
5
+ label?: string;
6
+ }): Promise<T>;
7
+ //#endregion
8
+ export { retryWithBackoff };
@@ -0,0 +1,30 @@
1
+ import { getLogger } from "./logger.js";
2
+
3
+ //#region src/utils/retry.ts
4
+ const logger = getLogger("retry");
5
+ async function retryWithBackoff(fn, opts = {}) {
6
+ const { maxAttempts = 3, maxDelayMs = 4e3, label = "operation" } = opts;
7
+ for (let attempt = 1; attempt <= maxAttempts; attempt++) try {
8
+ return await fn();
9
+ } catch (error) {
10
+ const isTimeout = error.name === "AbortError";
11
+ const status = error.status;
12
+ if (!isTimeout && !(typeof status === "number" && status >= 500) && !(status === 429) || attempt === maxAttempts) throw error;
13
+ const retryAfter = error.headers?.get?.("Retry-After");
14
+ const retryAfterMs = retryAfter ? (Number(retryAfter) || 0) * 1e3 : 0;
15
+ const baseDelay = Math.min(500 * 2 ** (attempt - 1), maxDelayMs);
16
+ const delay = Math.max(baseDelay, retryAfterMs) + Math.random() * 100;
17
+ logger.warn({
18
+ attempt,
19
+ maxAttempts,
20
+ status,
21
+ delay: Math.round(delay),
22
+ label
23
+ }, `Retrying ${label} after transient failure`);
24
+ await new Promise((resolve) => setTimeout(resolve, delay));
25
+ }
26
+ throw new Error("Unreachable");
27
+ }
28
+
29
+ //#endregion
30
+ export { retryWithBackoff };
@@ -32,8 +32,8 @@ declare const BranchNameParamsSchema: z.ZodObject<{
32
32
  }, z.core.$strip>;
33
33
  declare const ResolvedRefSchema: z.ZodObject<{
34
34
  type: z.ZodEnum<{
35
- commit: "commit";
36
35
  tag: "tag";
36
+ commit: "commit";
37
37
  branch: "branch";
38
38
  }>;
39
39
  name: z.ZodString;
@@ -1,10 +1,10 @@
1
1
  import { z } from "@hono/zod-openapi";
2
- import * as drizzle_zod15 from "drizzle-zod";
2
+ import * as drizzle_zod0 from "drizzle-zod";
3
3
  import { AnySQLiteTable } from "drizzle-orm/sqlite-core";
4
4
 
5
5
  //#region src/validation/drizzle-schema-helpers.d.ts
6
- declare function createSelectSchemaWithModifiers<T extends AnySQLiteTable>(table: T, overrides?: Partial<Record<keyof T['_']['columns'], (schema: z.ZodTypeAny) => z.ZodTypeAny>>): drizzle_zod15.BuildSchema<"select", T["_"]["columns"], drizzle_zod15.BuildRefine<T["_"]["columns"], undefined>, undefined>;
7
- declare function createInsertSchemaWithModifiers<T extends AnySQLiteTable>(table: T, overrides?: Partial<Record<keyof T['_']['columns'], (schema: z.ZodTypeAny) => z.ZodTypeAny>>): drizzle_zod15.BuildSchema<"insert", T["_"]["columns"], drizzle_zod15.BuildRefine<Pick<T["_"]["columns"], keyof T["$inferInsert"]>, undefined>, undefined>;
6
+ declare function createSelectSchemaWithModifiers<T extends AnySQLiteTable>(table: T, overrides?: Partial<Record<keyof T['_']['columns'], (schema: z.ZodTypeAny) => z.ZodTypeAny>>): drizzle_zod0.BuildSchema<"select", T["_"]["columns"], drizzle_zod0.BuildRefine<T["_"]["columns"], undefined>, undefined>;
7
+ declare function createInsertSchemaWithModifiers<T extends AnySQLiteTable>(table: T, overrides?: Partial<Record<keyof T['_']['columns'], (schema: z.ZodTypeAny) => z.ZodTypeAny>>): drizzle_zod0.BuildSchema<"insert", T["_"]["columns"], drizzle_zod0.BuildRefine<Pick<T["_"]["columns"], keyof T["$inferInsert"]>, undefined>, undefined>;
8
8
  declare const createSelectSchema: typeof createSelectSchemaWithModifiers;
9
9
  declare const createInsertSchema: typeof createInsertSchemaWithModifiers;
10
10
  /**