@scopieflows/app-contextual-ai 0.1.1

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 (37) hide show
  1. package/README.md +7 -0
  2. package/package.json +29 -0
  3. package/src/i18n/de.json +90 -0
  4. package/src/i18n/es.json +90 -0
  5. package/src/i18n/fr.json +90 -0
  6. package/src/i18n/ja.json +90 -0
  7. package/src/i18n/nl.json +90 -0
  8. package/src/i18n/pt.json +90 -0
  9. package/src/i18n/translation.json +90 -0
  10. package/src/i18n/zh.json +90 -0
  11. package/src/index.d.ts +8 -0
  12. package/src/index.js +82 -0
  13. package/src/index.js.map +1 -0
  14. package/src/lib/actions/create-agent.d.ts +13 -0
  15. package/src/lib/actions/create-agent.js +116 -0
  16. package/src/lib/actions/create-agent.js.map +1 -0
  17. package/src/lib/actions/create-datastore.d.ts +6 -0
  18. package/src/lib/actions/create-datastore.js +38 -0
  19. package/src/lib/actions/create-datastore.js.map +1 -0
  20. package/src/lib/actions/generate.d.ts +13 -0
  21. package/src/lib/actions/generate.js +93 -0
  22. package/src/lib/actions/generate.js.map +1 -0
  23. package/src/lib/actions/ingest-document.d.ts +12 -0
  24. package/src/lib/actions/ingest-document.js +112 -0
  25. package/src/lib/actions/ingest-document.js.map +1 -0
  26. package/src/lib/actions/invite-users.d.ts +7 -0
  27. package/src/lib/actions/invite-users.js +57 -0
  28. package/src/lib/actions/invite-users.js.map +1 -0
  29. package/src/lib/actions/parse-file.d.ts +12 -0
  30. package/src/lib/actions/parse-file.js +96 -0
  31. package/src/lib/actions/parse-file.js.map +1 -0
  32. package/src/lib/actions/query-agent.d.ts +12 -0
  33. package/src/lib/actions/query-agent.js +108 -0
  34. package/src/lib/actions/query-agent.js.map +1 -0
  35. package/src/lib/triggers/new-agent.d.ts +14 -0
  36. package/src/lib/triggers/new-agent.js +91 -0
  37. package/src/lib/triggers/new-agent.js.map +1 -0
@@ -0,0 +1,90 @@
1
+ {
2
+ "Integrate with Contextual AI to automate document processing and AI workflows": "Integrate with Contextual AI to automate document processing and AI workflows",
3
+ "API Key": "API Key",
4
+ "Base URL": "Base URL",
5
+ "Your Contextual AI API key": "Your Contextual AI API key",
6
+ "API base URL (leave blank for default)": "API base URL (leave blank for default)",
7
+ "\n## Contextual AI Connection Setup\n\n### Prerequisites\n- Create a Contextual AI account at [Contextual AI](https://contextual.ai)\n- Generate an API key from your workspace settings\n- You'll receive $25 in free credits (or $50 with work email)\n\n### Authentication Fields\n\n**API Key**: Your Contextual AI API key (required)\n- Sign in to your Contextual AI workspace\n- Navigate to API Keys in the sidebar\n- Click \"Create API Key\" and follow the instructions\n- Copy the generated key and paste it here\n\n**Base URL**: ": "\n## Contextual AI Connection Setup\n\n### Prerequisites\n- Create a Contextual AI account at [Contextual AI](https://contextual.ai)\n- Generate an API key from your workspace settings\n- You'll receive $25 in free credits (or $50 with work email)\n\n### Authentication Fields\n\n**API Key**: Your Contextual AI API key (required)\n- Sign in to your Contextual AI workspace\n- Navigate to API Keys in the sidebar\n- Click \"Create API Key\" and follow the instructions\n- Copy the generated key and paste it here\n\n**Base URL**: The API base URL (optional)\n- Leave blank to use the default: `https://api.contextual.ai/v1`\n- Only change if you have a custom deployment\n",
8
+ "Query Agent": "Query Agent",
9
+ "Generate Text": "Generate Text",
10
+ "Ingest Document": "Ingest Document",
11
+ "Parse File": "Parse File",
12
+ "Create Agent": "Create Agent",
13
+ "Invite Users": "Invite Users",
14
+ "Create Datastore": "Create Datastore",
15
+ "Send a message to a Contextual AI agent and get a response": "Send a message to a Contextual AI agent and get a response",
16
+ "Generate text using Contextual AI's Grounded Language Model": "Generate text using Contextual AI's Grounded Language Model",
17
+ "Upload and ingest a document into a Contextual AI datastore": "Upload and ingest a document into a Contextual AI datastore",
18
+ "Parse a document file into structured Markdown and/or JSON format": "Parse a document file into structured Markdown and/or JSON format",
19
+ "Create a new Contextual AI agent with specified configuration": "Create a new Contextual AI agent with specified configuration",
20
+ "Invite new users to the Contextual AI workspace": "Invite new users to the Contextual AI workspace",
21
+ "Create a new datastore for organizing documents": "Create a new datastore for organizing documents",
22
+ "Agent": "Agent",
23
+ "Message": "Message",
24
+ "Conversation ID": "Conversation ID",
25
+ "Include Retrieval Content": "Include Retrieval Content",
26
+ "Prompt": "Prompt",
27
+ "Model Version": "Model Version",
28
+ "Knowledge Sources": "Knowledge Sources",
29
+ "System Prompt": "System Prompt",
30
+ "Max Tokens": "Max Tokens",
31
+ "Temperature": "Temperature",
32
+ "Top P": "Top P",
33
+ "Avoid Commentary": "Avoid Commentary",
34
+ "Datastore": "Datastore",
35
+ "Document File": "Document File",
36
+ "Custom Metadata": "Custom Metadata",
37
+ "Configuration Override": "Configuration Override",
38
+ "Parse Mode": "Parse Mode",
39
+ "Page Range": "Page Range",
40
+ "Enable Document Hierarchy": "Enable Document Hierarchy",
41
+ "Enable Split Tables": "Enable Split Tables",
42
+ "Max Split Table Cells": "Max Split Table Cells",
43
+ "Figure Caption Mode": "Figure Caption Mode",
44
+ "Agent Name": "Agent Name",
45
+ "Description": "Description",
46
+ "Datastores": "Datastores",
47
+ "Filter Prompt": "Filter Prompt",
48
+ "Users to Invite": "Users to Invite",
49
+ "Tenant Short Name": "Tenant Short Name",
50
+ "Datastore Name": "Datastore Name",
51
+ "Select the agent to query": "Select the agent to query",
52
+ "The message to send to the agent": "The message to send to the agent",
53
+ "Optional conversation ID to continue an existing conversation (leave empty for new conversation)": "Optional conversation ID to continue an existing conversation (leave empty for new conversation)",
54
+ "Include the text of retrieved contents in the response": "Include the text of retrieved contents in the response",
55
+ "The text prompt to generate a response for": "The text prompt to generate a response for",
56
+ "The version of Contextual's GLM to use": "The version of Contextual's GLM to use",
57
+ "Optional knowledge sources to ground the generation (leave empty for general generation)": "Optional knowledge sources to ground the generation (leave empty for general generation)",
58
+ "Optional system instructions for the model": "Optional system instructions for the model",
59
+ "Maximum number of tokens to generate (default: 1024)": "Maximum number of tokens to generate (default: 1024)",
60
+ "Sampling temperature (0.0 to 1.0, lower = more focused, higher = more creative)": "Sampling temperature (0.0 to 1.0, lower = more focused, higher = more creative)",
61
+ "Nucleus sampling parameter (0.0 to 1.0)": "Nucleus sampling parameter (0.0 to 1.0)",
62
+ "Avoid providing additional conversational commentary not grounded in context": "Avoid providing additional conversational commentary not grounded in context",
63
+ "Select the datastore to upload the document to": "Select the datastore to upload the document to",
64
+ "The document file to upload (PDF, HTML, DOC, DOCX, PPT, PPTX)": "The document file to upload (PDF, HTML, DOC, DOCX, PPT, PPTX)",
65
+ "Optional custom metadata as key-value pairs (max 15 fields, 2KB total)": "Optional custom metadata as key-value pairs (max 15 fields, 2KB total)",
66
+ "Optional configuration override in JSON format for this specific document": "Optional configuration override in JSON format for this specific document",
67
+ "The document file to parse (PDF, DOC, DOCX, PPT, PPTX)": "The document file to parse (PDF, DOC, DOCX, PPT, PPTX)",
68
+ "Parsing mode - basic for simple text, standard for complex documents": "Parsing mode - basic for simple text, standard for complex documents",
69
+ "Optional page range to parse (e.g., \"0,1,2\" or \"0-2,5,6\")": "Optional page range to parse (e.g., \"0,1,2\" or \"0-2,5,6\")",
70
+ "Add table of contents with document structure (beta feature)": "Add table of contents with document structure (beta feature)",
71
+ "Split large tables into multiple tables with headers": "Split large tables into multiple tables with headers",
72
+ "Threshold for splitting large tables (only used when split tables is enabled)": "Threshold for splitting large tables (only used when split tables is enabled)",
73
+ "How thorough figure captions should be": "How thorough figure captions should be",
74
+ "Name for the new agent": "Name for the new agent",
75
+ "Optional description of the agent": "Optional description of the agent",
76
+ "Select datastores to associate with this agent (leave empty to create new datastore)": "Select datastores to associate with this agent (leave empty to create new datastore)",
77
+ "Optional system prompt for the agent": "Optional system prompt for the agent",
78
+ "Optional prompt for filtering retrieved chunks": "Optional prompt for filtering retrieved chunks",
79
+ "List of users to invite": "List of users to invite",
80
+ "The short name of the tenant/workspace": "The short name of the tenant/workspace",
81
+ "Name for the new datastore": "Name for the new datastore",
82
+ "GLM v2": "GLM v2",
83
+ "GLM v1": "GLM v1",
84
+ "Basic (text-only)": "Basic (text-only)",
85
+ "Standard (complex documents)": "Standard (complex documents)",
86
+ "Concise": "Concise",
87
+ "Detailed (beta)": "Detailed (beta)",
88
+ "New Agent": "New Agent",
89
+ "Triggers when a new Contextual AI agent is created": "Triggers when a new Contextual AI agent is created"
90
+ }
@@ -0,0 +1,90 @@
1
+ {
2
+ "Integrate with Contextual AI to automate document processing and AI workflows": "Integrate with Contextual AI to automate document processing and AI workflows",
3
+ "API Key": "API 密钥",
4
+ "Base URL": "基本网址",
5
+ "Your Contextual AI API key": "Your Contextual AI API key",
6
+ "API base URL (leave blank for default)": "API base URL (leave blank for default)",
7
+ "\n## Contextual AI Connection Setup\n\n### Prerequisites\n- Create a Contextual AI account at [Contextual AI](https://contextual.ai)\n- Generate an API key from your workspace settings\n- You'll receive $25 in free credits (or $50 with work email)\n\n### Authentication Fields\n\n**API Key**: Your Contextual AI API key (required)\n- Sign in to your Contextual AI workspace\n- Navigate to API Keys in the sidebar\n- Click \"Create API Key\" and follow the instructions\n- Copy the generated key and paste it here\n\n**Base URL**: ": "\n## Contextual AI Connection Setup\n\n### Prerequisites\n- Create a Contextual AI account at [Contextual AI](https://contextual.ai)\n- Generate an API key from your workspace settings\n- You'll receive $25 in free credits (or $50 with work email)\n\n### Authentication Fields\n\n**API Key**: Your Contextual AI API key (required)\n- Sign in to your Contextual AI workspace\n- Navigate to API Keys in the sidebar\n- Click \"Create API Key\" and follow the instructions\n- Copy the generated key and paste it here\n\n**Base URL**: The API base URL (optional)\n- Leave blank to use the default: `https://api.contextual.ai/v1`\n- Only change if you have a custom deployment\n",
8
+ "Query Agent": "Query Agent",
9
+ "Generate Text": "Generate Text",
10
+ "Ingest Document": "Ingest Document",
11
+ "Parse File": "Parse File",
12
+ "Create Agent": "Create Agent",
13
+ "Invite Users": "Invite Users",
14
+ "Create Datastore": "Create Datastore",
15
+ "Send a message to a Contextual AI agent and get a response": "Send a message to a Contextual AI agent and get a response",
16
+ "Generate text using Contextual AI's Grounded Language Model": "Generate text using Contextual AI's Grounded Language Model",
17
+ "Upload and ingest a document into a Contextual AI datastore": "Upload and ingest a document into a Contextual AI datastore",
18
+ "Parse a document file into structured Markdown and/or JSON format": "Parse a document file into structured Markdown and/or JSON format",
19
+ "Create a new Contextual AI agent with specified configuration": "Create a new Contextual AI agent with specified configuration",
20
+ "Invite new users to the Contextual AI workspace": "Invite new users to the Contextual AI workspace",
21
+ "Create a new datastore for organizing documents": "Create a new datastore for organizing documents",
22
+ "Agent": "Agent",
23
+ "Message": "Message",
24
+ "Conversation ID": "Conversation ID",
25
+ "Include Retrieval Content": "Include Retrieval Content",
26
+ "Prompt": "Prompt",
27
+ "Model Version": "Model Version",
28
+ "Knowledge Sources": "Knowledge Sources",
29
+ "System Prompt": "System Prompt",
30
+ "Max Tokens": "Max Tokens",
31
+ "Temperature": "Temperature",
32
+ "Top P": "Top P",
33
+ "Avoid Commentary": "Avoid Commentary",
34
+ "Datastore": "Datastore",
35
+ "Document File": "Document File",
36
+ "Custom Metadata": "Custom Metadata",
37
+ "Configuration Override": "Configuration Override",
38
+ "Parse Mode": "Parse Mode",
39
+ "Page Range": "Page Range",
40
+ "Enable Document Hierarchy": "Enable Document Hierarchy",
41
+ "Enable Split Tables": "Enable Split Tables",
42
+ "Max Split Table Cells": "Max Split Table Cells",
43
+ "Figure Caption Mode": "Figure Caption Mode",
44
+ "Agent Name": "Agent Name",
45
+ "Description": "描述",
46
+ "Datastores": "Datastores",
47
+ "Filter Prompt": "Filter Prompt",
48
+ "Users to Invite": "Users to Invite",
49
+ "Tenant Short Name": "Tenant Short Name",
50
+ "Datastore Name": "Datastore Name",
51
+ "Select the agent to query": "Select the agent to query",
52
+ "The message to send to the agent": "The message to send to the agent",
53
+ "Optional conversation ID to continue an existing conversation (leave empty for new conversation)": "Optional conversation ID to continue an existing conversation (leave empty for new conversation)",
54
+ "Include the text of retrieved contents in the response": "Include the text of retrieved contents in the response",
55
+ "The text prompt to generate a response for": "The text prompt to generate a response for",
56
+ "The version of Contextual's GLM to use": "The version of Contextual's GLM to use",
57
+ "Optional knowledge sources to ground the generation (leave empty for general generation)": "Optional knowledge sources to ground the generation (leave empty for general generation)",
58
+ "Optional system instructions for the model": "Optional system instructions for the model",
59
+ "Maximum number of tokens to generate (default: 1024)": "Maximum number of tokens to generate (default: 1024)",
60
+ "Sampling temperature (0.0 to 1.0, lower = more focused, higher = more creative)": "Sampling temperature (0.0 to 1.0, lower = more focused, higher = more creative)",
61
+ "Nucleus sampling parameter (0.0 to 1.0)": "Nucleus sampling parameter (0.0 to 1.0)",
62
+ "Avoid providing additional conversational commentary not grounded in context": "Avoid providing additional conversational commentary not grounded in context",
63
+ "Select the datastore to upload the document to": "Select the datastore to upload the document to",
64
+ "The document file to upload (PDF, HTML, DOC, DOCX, PPT, PPTX)": "The document file to upload (PDF, HTML, DOC, DOCX, PPT, PPTX)",
65
+ "Optional custom metadata as key-value pairs (max 15 fields, 2KB total)": "Optional custom metadata as key-value pairs (max 15 fields, 2KB total)",
66
+ "Optional configuration override in JSON format for this specific document": "Optional configuration override in JSON format for this specific document",
67
+ "The document file to parse (PDF, DOC, DOCX, PPT, PPTX)": "The document file to parse (PDF, DOC, DOCX, PPT, PPTX)",
68
+ "Parsing mode - basic for simple text, standard for complex documents": "Parsing mode - basic for simple text, standard for complex documents",
69
+ "Optional page range to parse (e.g., \"0,1,2\" or \"0-2,5,6\")": "Optional page range to parse (e.g., \"0,1,2\" or \"0-2,5,6\")",
70
+ "Add table of contents with document structure (beta feature)": "Add table of contents with document structure (beta feature)",
71
+ "Split large tables into multiple tables with headers": "Split large tables into multiple tables with headers",
72
+ "Threshold for splitting large tables (only used when split tables is enabled)": "Threshold for splitting large tables (only used when split tables is enabled)",
73
+ "How thorough figure captions should be": "How thorough figure captions should be",
74
+ "Name for the new agent": "Name for the new agent",
75
+ "Optional description of the agent": "Optional description of the agent",
76
+ "Select datastores to associate with this agent (leave empty to create new datastore)": "Select datastores to associate with this agent (leave empty to create new datastore)",
77
+ "Optional system prompt for the agent": "Optional system prompt for the agent",
78
+ "Optional prompt for filtering retrieved chunks": "Optional prompt for filtering retrieved chunks",
79
+ "List of users to invite": "List of users to invite",
80
+ "The short name of the tenant/workspace": "The short name of the tenant/workspace",
81
+ "Name for the new datastore": "Name for the new datastore",
82
+ "GLM v2": "GLM v2",
83
+ "GLM v1": "GLM v1",
84
+ "Basic (text-only)": "Basic (text-only)",
85
+ "Standard (complex documents)": "Standard (complex documents)",
86
+ "Concise": "Concise",
87
+ "Detailed (beta)": "Detailed (beta)",
88
+ "New Agent": "New Agent",
89
+ "Triggers when a new Contextual AI agent is created": "Triggers when a new Contextual AI agent is created"
90
+ }
package/src/index.d.ts ADDED
@@ -0,0 +1,8 @@
1
+ export declare const contextualAiAuth: import("@scopieflows/pieces-framework").CustomAuthProperty<{
2
+ apiKey: import("@scopieflows/pieces-framework").SecretTextProperty<true>;
3
+ baseUrl: import("@scopieflows/pieces-framework").ShortTextProperty<false>;
4
+ }>;
5
+ export declare const contextualAi: import("@scopieflows/pieces-framework").Piece<import("@scopieflows/pieces-framework").CustomAuthProperty<{
6
+ apiKey: import("@scopieflows/pieces-framework").SecretTextProperty<true>;
7
+ baseUrl: import("@scopieflows/pieces-framework").ShortTextProperty<false>;
8
+ }>>;
package/src/index.js ADDED
@@ -0,0 +1,82 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.contextualAi = exports.contextualAiAuth = void 0;
4
+ const tslib_1 = require("tslib");
5
+ const pieces_framework_1 = require("@scopieflows/pieces-framework");
6
+ const shared_1 = require("@scopieflows/shared");
7
+ const contextual_client_1 = require("contextual-client");
8
+ const query_agent_1 = require("./lib/actions/query-agent");
9
+ const generate_1 = require("./lib/actions/generate");
10
+ const ingest_document_1 = require("./lib/actions/ingest-document");
11
+ const parse_file_1 = require("./lib/actions/parse-file");
12
+ const create_agent_1 = require("./lib/actions/create-agent");
13
+ const invite_users_1 = require("./lib/actions/invite-users");
14
+ const create_datastore_1 = require("./lib/actions/create-datastore");
15
+ const new_agent_1 = require("./lib/triggers/new-agent");
16
+ const markdown = `
17
+ ## Contextual AI Connection Setup
18
+
19
+ ### Prerequisites
20
+ - Create a Contextual AI account at [Contextual AI](https://contextual.ai)
21
+ - Generate an API key from your workspace settings
22
+ - You'll receive $25 in free credits (or $50 with work email)
23
+
24
+ ### Authentication Fields
25
+
26
+ **API Key**: Your Contextual AI API key (required)
27
+ - Sign in to your Contextual AI workspace
28
+ - Navigate to API Keys in the sidebar
29
+ - Click "Create API Key" and follow the instructions
30
+ - Copy the generated key and paste it here
31
+
32
+ **Base URL**: The API base URL (optional)
33
+ - Leave blank to use the default: \`https://api.contextual.ai/v1\`
34
+ - Only change if you have a custom deployment
35
+ `;
36
+ exports.contextualAiAuth = pieces_framework_1.PieceAuth.CustomAuth({
37
+ required: true,
38
+ description: markdown,
39
+ props: {
40
+ apiKey: pieces_framework_1.PieceAuth.SecretText({
41
+ displayName: 'API Key',
42
+ description: 'Your Contextual AI API key',
43
+ required: true,
44
+ }),
45
+ baseUrl: pieces_framework_1.Property.ShortText({
46
+ displayName: 'Base URL',
47
+ description: 'API base URL (leave blank for default)',
48
+ required: false,
49
+ }),
50
+ },
51
+ validate: (_a) => tslib_1.__awaiter(void 0, [_a], void 0, function* ({ auth }) {
52
+ try {
53
+ const { apiKey, baseUrl } = auth;
54
+ const client = new contextual_client_1.ContextualAI({
55
+ apiKey: apiKey,
56
+ baseURL: baseUrl || 'https://api.contextual.ai/v1',
57
+ });
58
+ yield client.datastores.list();
59
+ return {
60
+ valid: true,
61
+ };
62
+ }
63
+ catch (error) {
64
+ return {
65
+ valid: false,
66
+ error: `Authentication failed: ${error instanceof Error ? error.message : 'Unknown error'}. Please verify your API key and base URL.`,
67
+ };
68
+ }
69
+ }),
70
+ });
71
+ exports.contextualAi = (0, pieces_framework_1.createPiece)({
72
+ displayName: "Contextual AI",
73
+ description: "Integrate with Contextual AI to automate document processing and AI workflows",
74
+ auth: exports.contextualAiAuth,
75
+ minimumSupportedRelease: '0.36.1',
76
+ logoUrl: "/pieces/contextual-ai.png",
77
+ categories: [shared_1.PieceCategory.ARTIFICIAL_INTELLIGENCE],
78
+ authors: ["onyedikachi-david"],
79
+ actions: [query_agent_1.queryAgentAction, generate_1.generateAction, ingest_document_1.ingestDocumentAction, parse_file_1.parseFileAction, create_agent_1.createAgentAction, invite_users_1.inviteUsersAction, create_datastore_1.createDatastoreAction],
80
+ triggers: [new_agent_1.newAgentTrigger],
81
+ });
82
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../packages/pieces/community/contextual-ai/src/index.ts"],"names":[],"mappings":";;;;AACA,oEAAiF;AACjF,gDAAoD;AACpD,yDAAiD;AACjD,2DAA6D;AAC7D,qDAAwD;AACxD,mEAAqE;AACrE,yDAA2D;AAC3D,6DAA+D;AAC/D,6DAA+D;AAC/D,qEAAuE;AACvE,wDAA2D;AAE3D,MAAM,QAAQ,GAAG;;;;;;;;;;;;;;;;;;;CAmBhB,CAAC;AAEW,QAAA,gBAAgB,GAAG,4BAAS,CAAC,UAAU,CAAC;IACnD,QAAQ,EAAE,IAAI;IACd,WAAW,EAAE,QAAQ;IACrB,KAAK,EAAE;QACL,MAAM,EAAE,4BAAS,CAAC,UAAU,CAAC;YAC3B,WAAW,EAAE,SAAS;YACtB,WAAW,EAAE,4BAA4B;YACzC,QAAQ,EAAE,IAAI;SACf,CAAC;QACF,OAAO,EAAE,2BAAQ,CAAC,SAAS,CAAC;YAC1B,WAAW,EAAE,UAAU;YACvB,WAAW,EAAE,wCAAwC;YACrD,QAAQ,EAAE,KAAK;SAChB,CAAC;KACH;IACD,QAAQ,EAAE,KAAiB,EAAE,oDAAZ,EAAE,IAAI,EAAE;QACvB,IAAI,CAAC;YACH,MAAM,EAAE,MAAM,EAAE,OAAO,EAAE,GAAG,IAAI,CAAC;YAEjC,MAAM,MAAM,GAAG,IAAI,gCAAY,CAAC;gBAC9B,MAAM,EAAE,MAAM;gBACd,OAAO,EAAE,OAAO,IAAI,8BAA8B;aACnD,CAAC,CAAC;YAEH,MAAM,MAAM,CAAC,UAAU,CAAC,IAAI,EAAE,CAAC;YAE/B,OAAO;gBACL,KAAK,EAAE,IAAI;aACZ,CAAC;QACJ,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,OAAO;gBACL,KAAK,EAAE,KAAK;gBACZ,KAAK,EAAE,0BAA0B,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,eAAe,4CAA4C;aACtI,CAAC;QACJ,CAAC;IACH,CAAC,CAAA;CACF,CAAC,CAAC;AAEU,QAAA,YAAY,GAAG,IAAA,8BAAW,EAAC;IACtC,WAAW,EAAE,eAAe;IAC5B,WAAW,EAAE,+EAA+E;IAC5F,IAAI,EAAE,wBAAgB;IACtB,uBAAuB,EAAE,QAAQ;IACjC,OAAO,EAAE,2BAA2B;IACpC,UAAU,EAAE,CAAC,sBAAa,CAAC,uBAAuB,CAAC;IACnD,OAAO,EAAE,CAAC,mBAAmB,CAAC;IAC9B,OAAO,EAAE,CAAC,8BAAgB,EAAE,yBAAc,EAAE,sCAAoB,EAAE,4BAAe,EAAE,gCAAiB,EAAE,gCAAiB,EAAE,wCAAqB,CAAC;IAC/I,QAAQ,EAAE,CAAC,2BAAe,CAAC;CAC5B,CAAC,CAAC"}
@@ -0,0 +1,13 @@
1
+ export declare const createAgentAction: import("@scopieflows/pieces-framework").IAction<import("@scopieflows/pieces-framework").CustomAuthProperty<{
2
+ apiKey: import("@scopieflows/pieces-framework").SecretTextProperty<true>;
3
+ baseUrl: import("@scopieflows/pieces-framework").ShortTextProperty<false>;
4
+ }>, {
5
+ name: import("@scopieflows/pieces-framework").ShortTextProperty<true>;
6
+ description: import("@scopieflows/pieces-framework").ShortTextProperty<false>;
7
+ datastoreIds: import("@scopieflows/pieces-framework").MultiSelectDropdownProperty<string, false, import("@scopieflows/pieces-framework").CustomAuthProperty<{
8
+ apiKey: import("@scopieflows/pieces-framework").SecretTextProperty<true>;
9
+ baseUrl: import("@scopieflows/pieces-framework").ShortTextProperty<false>;
10
+ }>>;
11
+ systemPrompt: import("@scopieflows/pieces-framework").LongTextProperty<false>;
12
+ filterPrompt: import("@scopieflows/pieces-framework").LongTextProperty<false>;
13
+ }>;
@@ -0,0 +1,116 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.createAgentAction = void 0;
4
+ const tslib_1 = require("tslib");
5
+ const pieces_framework_1 = require("@scopieflows/pieces-framework");
6
+ const index_1 = require("../../index");
7
+ const contextual_client_1 = require("contextual-client");
8
+ exports.createAgentAction = (0, pieces_framework_1.createAction)({
9
+ auth: index_1.contextualAiAuth,
10
+ name: 'create_agent',
11
+ displayName: 'Create Agent',
12
+ description: 'Create a new Contextual AI agent with specified configuration',
13
+ props: {
14
+ name: pieces_framework_1.Property.ShortText({
15
+ displayName: 'Agent Name',
16
+ description: 'Name for the new agent',
17
+ required: true,
18
+ }),
19
+ description: pieces_framework_1.Property.ShortText({
20
+ displayName: 'Description',
21
+ description: 'Optional description of the agent',
22
+ required: false,
23
+ }),
24
+ datastoreIds: pieces_framework_1.Property.MultiSelectDropdown({
25
+ auth: index_1.contextualAiAuth,
26
+ displayName: 'Datastores',
27
+ description: 'Select datastores to associate with this agent (leave empty to create new datastore)',
28
+ required: false,
29
+ refreshers: [],
30
+ options: (_a) => tslib_1.__awaiter(void 0, [_a], void 0, function* ({ auth }) {
31
+ var _b, e_1, _c, _d;
32
+ try {
33
+ if (!auth) {
34
+ return {
35
+ disabled: true,
36
+ options: [],
37
+ placeholder: 'Please connect your account first',
38
+ };
39
+ }
40
+ const { apiKey, baseUrl } = auth.props;
41
+ const client = new contextual_client_1.ContextualAI({
42
+ apiKey: apiKey,
43
+ baseURL: baseUrl || 'https://api.contextual.ai/v1',
44
+ });
45
+ const allDatastores = [];
46
+ try {
47
+ for (var _e = true, _f = tslib_1.__asyncValues(client.datastores.list()), _g; _g = yield _f.next(), _b = _g.done, !_b; _e = true) {
48
+ _d = _g.value;
49
+ _e = false;
50
+ const datastore = _d;
51
+ allDatastores.push(datastore);
52
+ }
53
+ }
54
+ catch (e_1_1) { e_1 = { error: e_1_1 }; }
55
+ finally {
56
+ try {
57
+ if (!_e && !_b && (_c = _f.return)) yield _c.call(_f);
58
+ }
59
+ finally { if (e_1) throw e_1.error; }
60
+ }
61
+ return {
62
+ options: allDatastores.map((datastore) => ({
63
+ label: datastore.name,
64
+ value: datastore.id,
65
+ })),
66
+ };
67
+ }
68
+ catch (error) {
69
+ return {
70
+ options: [],
71
+ error: 'Failed to fetch datastores. Please check your API key.',
72
+ };
73
+ }
74
+ }),
75
+ }),
76
+ systemPrompt: pieces_framework_1.Property.LongText({
77
+ displayName: 'System Prompt',
78
+ description: 'Optional system prompt for the agent',
79
+ required: false,
80
+ }),
81
+ filterPrompt: pieces_framework_1.Property.LongText({
82
+ displayName: 'Filter Prompt',
83
+ description: 'Optional prompt for filtering retrieved chunks',
84
+ required: false,
85
+ }),
86
+ },
87
+ run(_a) {
88
+ return tslib_1.__awaiter(this, arguments, void 0, function* ({ auth, propsValue }) {
89
+ const { apiKey, baseUrl } = auth.props;
90
+ const { name, description, datastoreIds, systemPrompt, filterPrompt } = propsValue;
91
+ const client = new contextual_client_1.ContextualAI({
92
+ apiKey: apiKey,
93
+ baseURL: baseUrl || 'https://api.contextual.ai/v1',
94
+ });
95
+ const datastoreIdsArray = datastoreIds || [];
96
+ const agentParams = {
97
+ name,
98
+ };
99
+ if (description)
100
+ agentParams.description = description;
101
+ if (datastoreIdsArray.length > 0)
102
+ agentParams.datastore_ids = datastoreIdsArray;
103
+ if (systemPrompt)
104
+ agentParams.multiturn_system_prompt = systemPrompt;
105
+ if (filterPrompt)
106
+ agentParams.filter_prompt = filterPrompt;
107
+ const response = yield client.agents.create(agentParams);
108
+ return {
109
+ agent_id: response.id,
110
+ datastore_ids: response.datastore_ids,
111
+ status: 'Agent created successfully',
112
+ };
113
+ });
114
+ },
115
+ });
116
+ //# sourceMappingURL=create-agent.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"create-agent.js","sourceRoot":"","sources":["../../../../../../../../packages/pieces/community/contextual-ai/src/lib/actions/create-agent.ts"],"names":[],"mappings":"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"}
@@ -0,0 +1,6 @@
1
+ export declare const createDatastoreAction: import("@scopieflows/pieces-framework").IAction<import("@scopieflows/pieces-framework").CustomAuthProperty<{
2
+ apiKey: import("@scopieflows/pieces-framework").SecretTextProperty<true>;
3
+ baseUrl: import("@scopieflows/pieces-framework").ShortTextProperty<false>;
4
+ }>, {
5
+ name: import("@scopieflows/pieces-framework").ShortTextProperty<true>;
6
+ }>;
@@ -0,0 +1,38 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.createDatastoreAction = void 0;
4
+ const tslib_1 = require("tslib");
5
+ const pieces_framework_1 = require("@scopieflows/pieces-framework");
6
+ const index_1 = require("../../index");
7
+ const contextual_client_1 = require("contextual-client");
8
+ exports.createDatastoreAction = (0, pieces_framework_1.createAction)({
9
+ auth: index_1.contextualAiAuth,
10
+ name: 'create_datastore',
11
+ displayName: 'Create Datastore',
12
+ description: 'Create a new datastore for organizing documents',
13
+ props: {
14
+ name: pieces_framework_1.Property.ShortText({
15
+ displayName: 'Datastore Name',
16
+ description: 'Name for the new datastore',
17
+ required: true,
18
+ }),
19
+ },
20
+ run(_a) {
21
+ return tslib_1.__awaiter(this, arguments, void 0, function* ({ auth, propsValue }) {
22
+ const { apiKey, baseUrl } = auth.props;
23
+ const { name } = propsValue;
24
+ const client = new contextual_client_1.ContextualAI({
25
+ apiKey: apiKey,
26
+ baseURL: baseUrl || 'https://api.contextual.ai/v1',
27
+ });
28
+ const response = yield client.datastores.create({
29
+ name,
30
+ });
31
+ return {
32
+ datastore_id: response.id,
33
+ status: 'Datastore created successfully',
34
+ };
35
+ });
36
+ },
37
+ });
38
+ //# sourceMappingURL=create-datastore.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"create-datastore.js","sourceRoot":"","sources":["../../../../../../../../packages/pieces/community/contextual-ai/src/lib/actions/create-datastore.ts"],"names":[],"mappings":";;;;AAAA,oEAAuE;AACvE,uCAA+C;AAC/C,yDAAiD;AAEpC,QAAA,qBAAqB,GAAG,IAAA,+BAAY,EAAC;IAChD,IAAI,EAAE,wBAAgB;IACtB,IAAI,EAAE,kBAAkB;IACxB,WAAW,EAAE,kBAAkB;IAC/B,WAAW,EAAE,iDAAiD;IAC9D,KAAK,EAAE;QACL,IAAI,EAAE,2BAAQ,CAAC,SAAS,CAAC;YACvB,WAAW,EAAE,gBAAgB;YAC7B,WAAW,EAAE,4BAA4B;YACzC,QAAQ,EAAE,IAAI;SACf,CAAC;KACH;IACK,GAAG;qEAAC,EAAE,IAAI,EAAE,UAAU,EAAE;YAC5B,MAAM,EAAE,MAAM,EAAE,OAAO,EAAE,GAAG,IAAI,CAAC,KAAK,CAAC;YACvC,MAAM,EAAE,IAAI,EAAE,GAAG,UAAU,CAAC;YAE5B,MAAM,MAAM,GAAG,IAAI,gCAAY,CAAC;gBAC9B,MAAM,EAAE,MAAM;gBACd,OAAO,EAAE,OAAO,IAAI,8BAA8B;aACnD,CAAC,CAAC;YAEH,MAAM,QAAQ,GAAG,MAAM,MAAM,CAAC,UAAU,CAAC,MAAM,CAAC;gBAC9C,IAAI;aACL,CAAC,CAAC;YAEH,OAAO;gBACL,YAAY,EAAE,QAAQ,CAAC,EAAE;gBACzB,MAAM,EAAE,gCAAgC;aACzC,CAAC;QACJ,CAAC;KAAA;CACF,CAAC,CAAC"}
@@ -0,0 +1,13 @@
1
+ export declare const generateAction: import("@scopieflows/pieces-framework").IAction<import("@scopieflows/pieces-framework").CustomAuthProperty<{
2
+ apiKey: import("@scopieflows/pieces-framework").SecretTextProperty<true>;
3
+ baseUrl: import("@scopieflows/pieces-framework").ShortTextProperty<false>;
4
+ }>, {
5
+ prompt: import("@scopieflows/pieces-framework").LongTextProperty<true>;
6
+ model: import("@scopieflows/pieces-framework").StaticDropdownProperty<string, true>;
7
+ knowledge: import("@scopieflows/pieces-framework").ArrayProperty<false>;
8
+ systemPrompt: import("@scopieflows/pieces-framework").LongTextProperty<false>;
9
+ maxTokens: import("@scopieflows/pieces-framework").NumberProperty<false>;
10
+ temperature: import("@scopieflows/pieces-framework").NumberProperty<false>;
11
+ topP: import("@scopieflows/pieces-framework").NumberProperty<false>;
12
+ avoidCommentary: import("@scopieflows/pieces-framework").CheckboxProperty<false>;
13
+ }>;
@@ -0,0 +1,93 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.generateAction = void 0;
4
+ const tslib_1 = require("tslib");
5
+ const pieces_framework_1 = require("@scopieflows/pieces-framework");
6
+ const index_1 = require("../../index");
7
+ const contextual_client_1 = require("contextual-client");
8
+ exports.generateAction = (0, pieces_framework_1.createAction)({
9
+ auth: index_1.contextualAiAuth,
10
+ name: 'generate',
11
+ displayName: 'Generate Text',
12
+ description: 'Generate text using Contextual AI\'s Grounded Language Model',
13
+ props: {
14
+ prompt: pieces_framework_1.Property.LongText({
15
+ displayName: 'Prompt',
16
+ description: 'The text prompt to generate a response for',
17
+ required: true,
18
+ }),
19
+ model: pieces_framework_1.Property.StaticDropdown({
20
+ displayName: 'Model Version',
21
+ description: 'The version of Contextual\'s GLM to use',
22
+ required: true,
23
+ options: {
24
+ options: [
25
+ { label: 'GLM v2', value: 'v2' },
26
+ { label: 'GLM v1', value: 'v1' },
27
+ ],
28
+ },
29
+ defaultValue: 'v2',
30
+ }),
31
+ knowledge: pieces_framework_1.Property.Array({
32
+ displayName: 'Knowledge Sources',
33
+ description: 'Optional knowledge sources to ground the generation (leave empty for general generation)',
34
+ required: false,
35
+ }),
36
+ systemPrompt: pieces_framework_1.Property.LongText({
37
+ displayName: 'System Prompt',
38
+ description: 'Optional system instructions for the model',
39
+ required: false,
40
+ }),
41
+ maxTokens: pieces_framework_1.Property.Number({
42
+ displayName: 'Max Tokens',
43
+ description: 'Maximum number of tokens to generate (default: 1024)',
44
+ required: false,
45
+ defaultValue: 1024,
46
+ }),
47
+ temperature: pieces_framework_1.Property.Number({
48
+ displayName: 'Temperature',
49
+ description: 'Sampling temperature (0.0 to 1.0, lower = more focused, higher = more creative)',
50
+ required: false,
51
+ defaultValue: 0.7,
52
+ }),
53
+ topP: pieces_framework_1.Property.Number({
54
+ displayName: 'Top P',
55
+ description: 'Nucleus sampling parameter (0.0 to 1.0)',
56
+ required: false,
57
+ defaultValue: 0.9,
58
+ }),
59
+ avoidCommentary: pieces_framework_1.Property.Checkbox({
60
+ displayName: 'Avoid Commentary',
61
+ description: 'Avoid providing additional conversational commentary not grounded in context',
62
+ required: false,
63
+ defaultValue: false,
64
+ }),
65
+ },
66
+ run(_a) {
67
+ return tslib_1.__awaiter(this, arguments, void 0, function* ({ auth, propsValue }) {
68
+ const { apiKey, baseUrl } = auth.props;
69
+ const { prompt, model, knowledge, systemPrompt, maxTokens, temperature, topP, avoidCommentary, } = propsValue;
70
+ const client = new contextual_client_1.ContextualAI({
71
+ apiKey: apiKey,
72
+ baseURL: baseUrl || 'https://api.contextual.ai/v1',
73
+ });
74
+ const messages = [
75
+ { role: 'user', content: prompt },
76
+ ];
77
+ const response = yield client.generate.create({
78
+ messages,
79
+ model,
80
+ knowledge: (knowledge || []),
81
+ system_prompt: systemPrompt,
82
+ max_new_tokens: maxTokens,
83
+ temperature,
84
+ top_p: topP,
85
+ avoid_commentary: avoidCommentary,
86
+ });
87
+ return {
88
+ response: response.response,
89
+ };
90
+ });
91
+ },
92
+ });
93
+ //# sourceMappingURL=generate.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"generate.js","sourceRoot":"","sources":["../../../../../../../../packages/pieces/community/contextual-ai/src/lib/actions/generate.ts"],"names":[],"mappings":"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"}
@@ -0,0 +1,12 @@
1
+ export declare const ingestDocumentAction: import("@scopieflows/pieces-framework").IAction<import("@scopieflows/pieces-framework").CustomAuthProperty<{
2
+ apiKey: import("@scopieflows/pieces-framework").SecretTextProperty<true>;
3
+ baseUrl: import("@scopieflows/pieces-framework").ShortTextProperty<false>;
4
+ }>, {
5
+ datastoreId: import("@scopieflows/pieces-framework").DropdownProperty<string, true, import("@scopieflows/pieces-framework").CustomAuthProperty<{
6
+ apiKey: import("@scopieflows/pieces-framework").SecretTextProperty<true>;
7
+ baseUrl: import("@scopieflows/pieces-framework").ShortTextProperty<false>;
8
+ }>>;
9
+ file: import("@scopieflows/pieces-framework").FileProperty<true>;
10
+ customMetadata: import("@scopieflows/pieces-framework").ObjectProperty<false>;
11
+ configuration: import("@scopieflows/pieces-framework").LongTextProperty<false>;
12
+ }>;