@overmap-ai/core 1.0.48-add-agent-service.2 → 1.0.48-fix-agent-errors.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.
@@ -1,6 +1,39 @@
1
1
  import { BaseApiService } from "./BaseApiService";
2
- import { Payload } from "../../typings";
2
+ import { OptionalFileModel, Payload } from "../../typings";
3
3
  import { JSONContent } from "@tiptap/core";
4
+ export interface AgentProfile extends OptionalFileModel {
5
+ /**
6
+ * The name of the agent.
7
+ */
8
+ name: string;
9
+ /**
10
+ * The description of the agent.
11
+ */
12
+ description: string;
13
+ }
14
+ export interface PromptAgentResponse {
15
+ /**
16
+ * The response from the agent.
17
+ */
18
+ response: JSONContent[];
19
+ /**
20
+ * The UUID of the conversation.
21
+ */
22
+ conversation_id: string;
23
+ /**
24
+ * The UUID of the response (used when submitting ratings)
25
+ */
26
+ response_id: string;
27
+ /**
28
+ * The profile of the agent. Only included in the first response in a conversation.
29
+ */
30
+ profile?: AgentProfile;
31
+ }
4
32
  export declare class AgentService extends BaseApiService {
5
- prompt(request: Payload<string>): Promise<JSONContent[]>;
33
+ /**
34
+ * Prompt the agent with a message.
35
+ * @param request The message to prompt the agent with.
36
+ * @param conversationId If continuing an existing message, the UUID of that conversation.
37
+ */
38
+ prompt(request: Payload<string>, conversationId: string): Promise<PromptAgentResponse>;
6
39
  }
@@ -35,7 +35,7 @@ export declare class AuthService extends BaseApiService {
35
35
  /**
36
36
  * Attempts to renew tokens
37
37
  */
38
- renewTokens(): Promise<void>;
38
+ renewTokens(): Promise<undefined>;
39
39
  /**
40
40
  * Register a new user
41
41
  */
@@ -16,6 +16,11 @@ export interface FileObject {
16
16
  file: string;
17
17
  objectURL?: string;
18
18
  }
19
+ export interface OptionalFileModel {
20
+ file_sha1?: string | null;
21
+ file?: string | null;
22
+ objectURL?: string;
23
+ }
19
24
  export interface OwnedByUserOrOrganization {
20
25
  user_owner: number;
21
26
  organization_owner: number;
@@ -1,6 +1,5 @@
1
- export interface Profile {
2
- file_sha1?: string | null;
3
- file?: string | null;
1
+ import { OptionalFileModel } from "./base.ts";
2
+ export interface Profile extends OptionalFileModel {
4
3
  favourite_project_ids: number[];
5
4
  tour_step: number;
6
5
  }
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "description": "Core functionality for Overmap",
4
4
  "author": "Wôrdn Inc.",
5
5
  "license": "UNLICENSED",
6
- "version": "1.0.48-add-agent-service.2",
6
+ "version": "1.0.48-fix-agent-errors.0",
7
7
  "type": "module",
8
8
  "main": "dist/overmap-core.umd.cjs",
9
9
  "module": "dist/overmap-core.js",