Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The start example is broken. #4

Closed
RabiaMakhoul opened this issue Oct 28, 2024 · 5 comments
Closed

The start example is broken. #4

RabiaMakhoul opened this issue Oct 28, 2024 · 5 comments
Assignees
Labels
bug Something isn't working

Comments

@RabiaMakhoul
Copy link

The framework Meteo request is ISO, e.g, "2024-10-28T23:59:59Z" while the the validation checks that the type UTC, e.g, "2024-10-28", therefore the example itself is faulty. I mean, it shows validation errors which is nice

User 👤 : What is the current weather in Las Vegas?
(node:90314) [DEP0040] DeprecationWarning: The `punycode` module is deprecated. Please use a userland alternative instead.
(Use `node --trace-deprecation ...` to show where the warning was created)
Agent 🤖 (thought) : The user wants to know the current weather in Las Vegas. I can use the OpenMeteo function to retrieve the current weather forecast for Las Vegas.
Agent 🤖 (tool_name) : OpenMeteo
Agent 🤖 (tool_input) : {"location":{"name":"Las Vegas","country":"United States"},"start_date":"2024-10-28T00:00:00Z","end_date":"2024-10-28T23:59:59Z","temperature_unit":"celsius"}
Agent 🤖 (tool_caption) : Retrieve current weather forecast for Las Vegas.
[AgentError: Maximal amount of global retries (0) has been reached.] {
  isFatal: true,
  isRetryable: false,
  context: {},
  [errors]: [
    [ToolInputValidationError: The received tool input does not match the expected schema.
    Input Schema: "{"type":"object","properties":{"location":{"anyOf":[{"type":"object","properties":{"name":{"type":"string","minLength":1},"country":{"type":"string"},"language":{"type":"string","default":"English"}},"required":["name"],"additionalProperties":false},{"type":"object","properties":{"latitude":{"type":"number"},"longitude":{"type":"number"}},"required":["latitude","longitude"],"additionalProperties":false}]},"start_date":{"type":"string","format":"date","description":"Start date for the weather forecast in the format YYYY-MM-DD (UTC)"},"end_date":{"type":"string","format":"date","description":"End date for the weather forecast in the format YYYY-MM-DD (UTC)"},"temperature_unit":{"type":"string","enum":["celsius","fahrenheit"],"default":"celsius"}},"required":["location","start_date"],"additionalProperties":false,"$schema":"http://json-schema.org/draft-07/schema#"}"
    Validation Errors: [{"instancePath":"/start_date","schemaPath":"#/properties/start_date/format","keyword":"format","params":{"format":"date"},"message":"must match format \"date\""}]] {
      isFatal: false,
      isRetryable: true,
      context: {
        input: {
          location: {
            name: 'Las Vegas',
            country: 'United States'
          },
          start_date: '2024-10-28T00:00:00Z',
          end_date: '2024-10-28T23:59:59Z',
          temperature_unit: 'celsius'
        },
        options: {
          signal: AbortSignal {
            aborted: true
          }
        }
      },
      validationErrors: [
        {
          instancePath: '/start_date',
          schemaPath: '#/properties/start_date/format',
          keyword: 'format',
          params: {
            format: 'date'
          },
          message: 'must match format "date"'
        }
      ],
      [errors]: []
    }
  ]
}
@Tomas2D Tomas2D self-assigned this Oct 31, 2024
@Tomas2D
Copy link
Contributor

Tomas2D commented Oct 31, 2024

Hello, thanks for the report. To fix the issue, set maxRetries to > 0 (https://i-am-bee.github.io/bee-agent-framework/#/agents?id=behaviour).

Regarding the error itself, the smaller model sometimes can't handle this.
I am thinking about the best way to resolve that. I will keep you updated.

Let me know if setting the maxRetries works out for now.

@geneknit
Copy link

I believe this is related to i-am-bee/bee-agent-framework#110. 🔗

@Tomas2D
Copy link
Contributor

Tomas2D commented Nov 4, 2024

Partially. Should be fixed by i-am-bee/bee-agent-framework#128

@Tomas2D
Copy link
Contributor

Tomas2D commented Nov 4, 2024

It should be fixed now.

Please re-clone (update) the current starter repository or update the bee-agent-framework dependency.

@mmurad2 mmurad2 added the bug Something isn't working label Nov 5, 2024
@Tomas2D
Copy link
Contributor

Tomas2D commented Nov 7, 2024

The bug has been resolved. Closing for inactivity.

@Tomas2D Tomas2D closed this as completed Nov 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants