tool_schema_generator 0.1.0 copy "tool_schema_generator: ^0.1.0" to clipboard
tool_schema_generator: ^0.1.0 copied to clipboard

Annotations for automatic LLM tool schema generation. Mark functions with @Tool() and parameters with @Describe() to generate JSON Schema Draft 2020-12 compatible tool definitions.

example/README.md

Example usage of tool_schema_generator #

This example demonstrates how to use the tool_schema_generator package to automatically generate JSON Schema definitions for your Dart functions.

Setup #

  1. Add tool_schema_generator to your dependencies.
  2. Add build_runner to your dev_dependencies.
dependencies:
  tool_schema_generator: ^0.1.0

dev_dependencies:
  build_runner: ^2.4.0

Running the generator #

After adding your @Tool() annotations, run the build runner to generate the .g.dart file:

dart run build_runner build -d

Check out lib/tools.dart in this example to see how the annotations are used!

0
likes
0
points
291
downloads

Publisher

unverified uploader

Weekly Downloads

Annotations for automatic LLM tool schema generation. Mark functions with @Tool() and parameters with @Describe() to generate JSON Schema Draft 2020-12 compatible tool definitions.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

analyzer, build, source_gen

More

Packages that depend on tool_schema_generator