diff --git a/.env.example b/.env.example index 2348a1a..841b9c4 100644 --- a/.env.example +++ b/.env.example @@ -23,7 +23,7 @@ REDIS_CA_CERT= # optional REDIS_CACHE_URL=redis://127.0.0.1:6379/1 REDIS_CACHE_CA_CERT= # optional -# Object Storage used for files and their text extractions +# Object Storage used for files and their text extractions S3_ENDPOINT= S3_ACCESS_KEY_ID= S3_SECRET_ACCESS_KEY= diff --git a/package.json b/package.json index 08809ea..095df5c 100644 --- a/package.json +++ b/package.json @@ -46,7 +46,7 @@ "@zilliz/milvus2-sdk-node": "^2.4.4", "ajv": "^8.17.1", "axios": "^1.7.7", - "bee-agent-framework": "0.0.36", + "bee-agent-framework": "0.0.37", "bee-observe-connector": "0.0.5", "bullmq": "5.8.1", "cache-manager": "^5.7.6", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index e261e97..2774e09 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -84,11 +84,11 @@ importers: specifier: ^1.7.7 version: 1.7.7 bee-agent-framework: - specifier: 0.0.36 - version: 0.0.36(@bufbuild/protobuf@1.10.0)(@googleapis/customsearch@3.2.0)(@grpc/grpc-js@1.12.2)(@grpc/proto-loader@0.7.13)(@ibm-generative-ai/node-sdk@3.2.3(@langchain/core@0.2.33(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8))))(@langchain/community@0.2.28(@langchain/langgraph@0.0.34(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(@zilliz/milvus2-sdk-node@2.4.4)(axios@1.7.7)(duck-duck-scrape@2.2.5)(fast-xml-parser@4.5.0)(google-auth-library@9.14.2)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(lodash@4.17.21)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(@langchain/core@0.2.33(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(@langchain/langgraph@0.0.34(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(groq-sdk@0.7.0)(ollama@0.5.9)(openai-chat-tokens@0.2.8)(openai@4.67.3(zod@3.23.8))(sequelize@6.37.3) + specifier: 0.0.37 + version: 0.0.37(@bufbuild/protobuf@1.10.0)(@googleapis/customsearch@3.2.0)(@grpc/grpc-js@1.12.2)(@grpc/proto-loader@0.7.13)(@ibm-generative-ai/node-sdk@3.2.3(@langchain/core@0.2.33(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8))))(@langchain/community@0.2.28(@langchain/langgraph@0.0.34(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(@zilliz/milvus2-sdk-node@2.4.4)(axios@1.7.7)(duck-duck-scrape@2.2.5)(fast-xml-parser@4.5.0)(google-auth-library@9.14.2)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(lodash@4.17.21)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(@langchain/core@0.2.33(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(@langchain/langgraph@0.0.34(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(groq-sdk@0.7.0)(ollama@0.5.9)(openai-chat-tokens@0.2.8)(openai@4.67.3(zod@3.23.8))(sequelize@6.37.3) bee-observe-connector: specifier: 0.0.5 - version: 0.0.5(bee-agent-framework@0.0.36(@bufbuild/protobuf@1.10.0)(@googleapis/customsearch@3.2.0)(@grpc/grpc-js@1.12.2)(@grpc/proto-loader@0.7.13)(@ibm-generative-ai/node-sdk@3.2.3(@langchain/core@0.2.33(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8))))(@langchain/community@0.2.28(@langchain/langgraph@0.0.34(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(@zilliz/milvus2-sdk-node@2.4.4)(axios@1.7.7)(duck-duck-scrape@2.2.5)(fast-xml-parser@4.5.0)(google-auth-library@9.14.2)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(lodash@4.17.21)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(@langchain/core@0.2.33(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(@langchain/langgraph@0.0.34(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(groq-sdk@0.7.0)(ollama@0.5.9)(openai-chat-tokens@0.2.8)(openai@4.67.3(zod@3.23.8))(sequelize@6.37.3)) + version: 0.0.5(bee-agent-framework@0.0.37(@bufbuild/protobuf@1.10.0)(@googleapis/customsearch@3.2.0)(@grpc/grpc-js@1.12.2)(@grpc/proto-loader@0.7.13)(@ibm-generative-ai/node-sdk@3.2.3(@langchain/core@0.2.33(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8))))(@langchain/community@0.2.28(@langchain/langgraph@0.0.34(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(@zilliz/milvus2-sdk-node@2.4.4)(axios@1.7.7)(duck-duck-scrape@2.2.5)(fast-xml-parser@4.5.0)(google-auth-library@9.14.2)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(lodash@4.17.21)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(@langchain/core@0.2.33(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(@langchain/langgraph@0.0.34(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(groq-sdk@0.7.0)(ollama@0.5.9)(openai-chat-tokens@0.2.8)(openai@4.67.3(zod@3.23.8))(sequelize@6.37.3)) bullmq: specifier: 5.8.1 version: 5.8.1 @@ -2367,8 +2367,8 @@ packages: resolution: {integrity: sha512-4Bcg1P8xhUuqcii/S0Z9wiHIrQVPMermM1any+MX5GeGD7faD3/msQUDGLol9wOcz4/jbg/WJnGqoJF6LiBdtg==} engines: {node: '>=10.0.0'} - bee-agent-framework@0.0.36: - resolution: {integrity: sha512-wq9EiY2SOjkfAnTyzIN9rQlUJxB25mj3NRIhfsIIunVwFHiLTIB1enpC3uoYre05ahaizRKKNy/Wm8MJNJdTag==} + bee-agent-framework@0.0.37: + resolution: {integrity: sha512-SPe3i7W1dns/NS3aTdZFms9+iAhqG2EP3C7Ee2ymJePl4NTi/98l6DnHL4OgzEdH+QpYrsiwuz+piSvJNvYKcg==} peerDependencies: '@googleapis/customsearch': ^3.2.0 '@grpc/grpc-js': ^1.11.3 @@ -8041,7 +8041,7 @@ snapshots: basic-ftp@5.0.5: {} - ? bee-agent-framework@0.0.36(@bufbuild/protobuf@1.10.0)(@googleapis/customsearch@3.2.0)(@grpc/grpc-js@1.12.2)(@grpc/proto-loader@0.7.13)(@ibm-generative-ai/node-sdk@3.2.3(@langchain/core@0.2.33(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8))))(@langchain/community@0.2.28(@langchain/langgraph@0.0.34(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(@zilliz/milvus2-sdk-node@2.4.4)(axios@1.7.7)(duck-duck-scrape@2.2.5)(fast-xml-parser@4.5.0)(google-auth-library@9.14.2)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(lodash@4.17.21)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(@langchain/core@0.2.33(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(@langchain/langgraph@0.0.34(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(groq-sdk@0.7.0)(ollama@0.5.9)(openai-chat-tokens@0.2.8)(openai@4.67.3(zod@3.23.8))(sequelize@6.37.3) + ? bee-agent-framework@0.0.37(@bufbuild/protobuf@1.10.0)(@googleapis/customsearch@3.2.0)(@grpc/grpc-js@1.12.2)(@grpc/proto-loader@0.7.13)(@ibm-generative-ai/node-sdk@3.2.3(@langchain/core@0.2.33(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8))))(@langchain/community@0.2.28(@langchain/langgraph@0.0.34(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(@zilliz/milvus2-sdk-node@2.4.4)(axios@1.7.7)(duck-duck-scrape@2.2.5)(fast-xml-parser@4.5.0)(google-auth-library@9.14.2)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(lodash@4.17.21)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(@langchain/core@0.2.33(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(@langchain/langgraph@0.0.34(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(groq-sdk@0.7.0)(ollama@0.5.9)(openai-chat-tokens@0.2.8)(openai@4.67.3(zod@3.23.8))(sequelize@6.37.3) : dependencies: '@ai-zen/node-fetch-event-source': 2.1.4 '@connectrpc/connect': 1.6.1(@bufbuild/protobuf@1.10.0) @@ -8089,9 +8089,9 @@ snapshots: - debug - encoding - ? bee-observe-connector@0.0.5(bee-agent-framework@0.0.36(@bufbuild/protobuf@1.10.0)(@googleapis/customsearch@3.2.0)(@grpc/grpc-js@1.12.2)(@grpc/proto-loader@0.7.13)(@ibm-generative-ai/node-sdk@3.2.3(@langchain/core@0.2.33(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8))))(@langchain/community@0.2.28(@langchain/langgraph@0.0.34(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(@zilliz/milvus2-sdk-node@2.4.4)(axios@1.7.7)(duck-duck-scrape@2.2.5)(fast-xml-parser@4.5.0)(google-auth-library@9.14.2)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(lodash@4.17.21)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(@langchain/core@0.2.33(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(@langchain/langgraph@0.0.34(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(groq-sdk@0.7.0)(ollama@0.5.9)(openai-chat-tokens@0.2.8)(openai@4.67.3(zod@3.23.8))(sequelize@6.37.3)) + ? bee-observe-connector@0.0.5(bee-agent-framework@0.0.37(@bufbuild/protobuf@1.10.0)(@googleapis/customsearch@3.2.0)(@grpc/grpc-js@1.12.2)(@grpc/proto-loader@0.7.13)(@ibm-generative-ai/node-sdk@3.2.3(@langchain/core@0.2.33(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8))))(@langchain/community@0.2.28(@langchain/langgraph@0.0.34(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(@zilliz/milvus2-sdk-node@2.4.4)(axios@1.7.7)(duck-duck-scrape@2.2.5)(fast-xml-parser@4.5.0)(google-auth-library@9.14.2)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(lodash@4.17.21)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(@langchain/core@0.2.33(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(@langchain/langgraph@0.0.34(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(groq-sdk@0.7.0)(ollama@0.5.9)(openai-chat-tokens@0.2.8)(openai@4.67.3(zod@3.23.8))(sequelize@6.37.3)) : dependencies: - bee-agent-framework: 0.0.36(@bufbuild/protobuf@1.10.0)(@googleapis/customsearch@3.2.0)(@grpc/grpc-js@1.12.2)(@grpc/proto-loader@0.7.13)(@ibm-generative-ai/node-sdk@3.2.3(@langchain/core@0.2.33(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8))))(@langchain/community@0.2.28(@langchain/langgraph@0.0.34(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(@zilliz/milvus2-sdk-node@2.4.4)(axios@1.7.7)(duck-duck-scrape@2.2.5)(fast-xml-parser@4.5.0)(google-auth-library@9.14.2)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(lodash@4.17.21)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(@langchain/core@0.2.33(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(@langchain/langgraph@0.0.34(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(groq-sdk@0.7.0)(ollama@0.5.9)(openai-chat-tokens@0.2.8)(openai@4.67.3(zod@3.23.8))(sequelize@6.37.3) + bee-agent-framework: 0.0.37(@bufbuild/protobuf@1.10.0)(@googleapis/customsearch@3.2.0)(@grpc/grpc-js@1.12.2)(@grpc/proto-loader@0.7.13)(@ibm-generative-ai/node-sdk@3.2.3(@langchain/core@0.2.33(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8))))(@langchain/community@0.2.28(@langchain/langgraph@0.0.34(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(@zilliz/milvus2-sdk-node@2.4.4)(axios@1.7.7)(duck-duck-scrape@2.2.5)(fast-xml-parser@4.5.0)(google-auth-library@9.14.2)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(lodash@4.17.21)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(@langchain/core@0.2.33(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(@langchain/langgraph@0.0.34(langchain@0.2.20(axios@1.7.7)(fast-xml-parser@4.5.0)(handlebars@4.7.8)(ignore@5.3.2)(ioredis@5.4.1)(mongodb@6.7.0(gcp-metadata@6.1.0)(socks@2.8.3))(openai@4.67.3(zod@3.23.8)))(openai@4.67.3(zod@3.23.8)))(groq-sdk@0.7.0)(ollama@0.5.9)(openai-chat-tokens@0.2.8)(openai@4.67.3(zod@3.23.8))(sequelize@6.37.3) openapi-fetch: 0.11.3 remeda: 2.16.0 diff --git a/src/runs/execution/event-handlers/streaming.ts b/src/runs/execution/event-handlers/streaming.ts index 98aecfa..8da26aa 100644 --- a/src/runs/execution/event-handlers/streaming.ts +++ b/src/runs/execution/event-handlers/streaming.ts @@ -83,7 +83,7 @@ export function createStreamingHandler(ctx: AgentContext) { details: new RunStepToolCalls({ toolCalls: [ctx.toolCall] }), - metadata: data.iteration.tool_caption ? { caption: data.iteration.tool_caption } : {}, + metadata: {}, event: createEventFromMeta(meta) }); await ORM.em.persistAndFlush(ctx.runStep); diff --git a/src/runs/execution/tools/helpers.ts b/src/runs/execution/tools/helpers.ts index c02be9f..535cd4d 100644 --- a/src/runs/execution/tools/helpers.ts +++ b/src/runs/execution/tools/helpers.ts @@ -315,36 +315,36 @@ export async function createToolCall( ) { if (tool instanceof FileSearchTool) { return new FileSearchCall({ - input: tool.inputSchema().parse(input).query + input: await tool.parse(input).then((result) => result.query) }); } else if (tool instanceof WikipediaSimilaritySearchTool) { return new SystemCall({ toolId: SystemTools.WIKIPEDIA, - input: tool.inputSchema().parse(input) + input: await tool.parse(input) }); } else if (tool instanceof GoogleSearchTool || tool instanceof DuckDuckGoSearchTool) { return new SystemCall({ toolId: SystemTools.WEB_SEARCH, - input: tool.inputSchema().parse(input) + input: await tool.parse(input) }); } else if (tool instanceof OpenMeteoTool) { return new SystemCall({ toolId: SystemTools.WEATHER, - input: tool.inputSchema().parse(input) + input: await tool.parse(input) }); } else if (tool instanceof ArXivTool) { return new SystemCall({ toolId: SystemTools.ARXIV, - input: tool.inputSchema().parse(input) + input: await tool.parse(input) }); } else if (tool instanceof PythonTool) { return new CodeInterpreterCall({ - input: (await tool.inputSchema()).parse(input).code + input: await tool.parse(input).then((result) => result.code) }); } else if (tool instanceof ReadFileTool) { return new SystemCall({ toolId: SystemTools.READ_FILE, - input: tool.inputSchema().parse(input) + input: await tool.parse(input) }); } else if (tool instanceof FunctionTool) { return new FunctionCall({ name: tool.name, arguments: JSON.stringify(input) }); diff --git a/src/runs/execution/tools/read-file-tool.ts b/src/runs/execution/tools/read-file-tool.ts index b743387..8edde45 100644 --- a/src/runs/execution/tools/read-file-tool.ts +++ b/src/runs/execution/tools/read-file-tool.ts @@ -21,7 +21,8 @@ import { Tool, ToolError } from 'bee-agent-framework/tools/base'; -import { ZodLiteral, z } from 'zod'; +import { z } from 'zod'; +import { hasAtLeast } from 'remeda'; import { getExtractedFileObject } from '@/files/files.service.js'; import { File } from '@/files/entities/file.entity.js'; @@ -35,19 +36,14 @@ export class ReadFileTool extends Tool { name = `ReadFile`; description = 'Retrieve file content.'; inputSchema() { + const fileNames = this.options.files.map((file) => z.literal(file.filename)); + return z.object({ - filename: - this.options.files.length === 1 - ? z.literal(this.options.files[0].filename).describe(`Name of the file to read`) - : z - .union( - this.options.files.map((file) => z.literal(file.filename)) as [ - ZodLiteral, - ZodLiteral, - ...ZodLiteral[] - ] - ) - .describe('Name of the file to read.') + filename: hasAtLeast(fileNames, 2) + ? z.union(fileNames).describe('Name of the file to read.') + : hasAtLeast(fileNames, 1) + ? fileNames[0].describe(`Name of the file to read`) + : z.literal('non_existing_file').describe('No files available.') }); } diff --git a/src/runs/execution/tools/search-tool.ts b/src/runs/execution/tools/search-tool.ts index b9d4eed..658a6c0 100644 --- a/src/runs/execution/tools/search-tool.ts +++ b/src/runs/execution/tools/search-tool.ts @@ -30,10 +30,10 @@ export function createSearchTool(options?: SearchToolOptions, backend = SEARCH_T return new GoogleSearchTool({ apiKey: BEE_GOOGLE_SEARCH_API_KEY, cseId: BEE_GOOGLE_SEARCH_CSE_ID, - maxResultsPerPage: 10, + maxResults: 10, ...options }); case SearchToolBackend.DUCK_DUCK_GO: - return new DuckDuckGoSearchTool({ maxResultsPerPage: 10, ...options }); + return new DuckDuckGoSearchTool({ maxResults: 10, ...options }); } } diff --git a/src/tools/tools.service.ts b/src/tools/tools.service.ts index 9c44f7d..ab69517 100644 --- a/src/tools/tools.service.ts +++ b/src/tools/tools.service.ts @@ -470,7 +470,7 @@ function getSystemTools() { id: SystemTools.WEB_SEARCH, createdAt: new Date('2024-07-24'), ...searchTool, - inputSchema: searchTool.inputSchema, + inputSchema: searchTool.inputSchema.bind(searchTool), isExternal: true, metadata: { $ui_description_short: 'Retrieve real-time search results from across the internet' @@ -483,7 +483,7 @@ function getSystemTools() { id: SystemTools.WIKIPEDIA, createdAt: new Date('2024-07-24'), ...wikipediaTool, - inputSchema: wikipediaTool.inputSchema, + inputSchema: wikipediaTool.inputSchema.bind(wikipediaTool), isExternal: true, metadata: { $ui_description_short: @@ -497,7 +497,7 @@ function getSystemTools() { id: SystemTools.WEATHER, createdAt: new Date('2024-07-25'), ...weatherTool, - inputSchema: weatherTool.inputSchema, + inputSchema: weatherTool.inputSchema.bind(weatherTool), isExternal: true, metadata: { $ui_description_short: @@ -511,7 +511,7 @@ function getSystemTools() { id: SystemTools.ARXIV, createdAt: new Date('2024-07-25'), ...arXivTool, - inputSchema: arXivTool.inputSchema, + inputSchema: arXivTool.inputSchema.bind(arXivTool), isExternal: true, metadata: { $ui_description_short: @@ -525,7 +525,7 @@ function getSystemTools() { id: 'read_file', createdAt: new Date('2024-10-02'), ...readFile, - inputSchema: readFile.inputSchema, + inputSchema: readFile.inputSchema.bind(readFile), isExternal: false, metadata: { $ui_description_short: 'Read and interpret basic files' @@ -547,7 +547,7 @@ function getSystemTools() { id: 'file_search', createdAt: new Date('2024-07-31'), ...fileSearch, - inputSchema: fileSearch.inputSchema, + inputSchema: fileSearch.inputSchema.bind(fileSearch), isExternal: false, metadata: { $ui_description_short: 'Access and interpret file content by using advanced search techniques' @@ -560,7 +560,7 @@ function getSystemTools() { id: 'code_interpreter', createdAt: new Date('2024-07-01'), ...pythonTool, - inputSchema: pythonTool.inputSchema, + inputSchema: pythonTool.inputSchema.bind(pythonTool), isExternal: true, metadata: { $ui_description_short: